mirror of
https://git.eden-emu.dev/eden-emu/eden
synced 2026-10-21 12:19:35 +02:00
- [x] I have read and followed the [Contribution Guidelines](https://git.eden-emu.dev/eden-emu/eden/src/branch/master/CONTRIBUTING.md#code-contributions). - [x] I have read and followed the [AI Policy](https://git.eden-emu.dev/eden-emu/eden/src/branch/master/docs/policies/AI.md) - [x] I have read and followed the [Coding Guidelines](https://git.eden-emu.dev/eden-emu/eden/src/branch/master/docs/policies/Coding.md) to the best of my ability. ------------------- A new NSO compression method was introduced in Switch 22.0.0. This is a customized variant of zstd and is used when NSO flags have bit 7 set. Key characteristics: - ZSTD_MAGICNUMBER is set to 0x4349425A (b'ZBIC') instead of 0xFD2FB528 - ZSTD_LEGACY_SUPPORT is set to 0 - ZSTD_TRACE is set to 1, zstd version used is 1.5.7 (10507) - FSE_readNCount is replaced with a BIC (Binary Interpolative Coding) version which improves compression of entropy tables significantly Source: https://switchbrew.org/wiki/22.0.0 Implementation: - Detect ZBIC segments via NSO flag bit 7 (NsoFlags_UseZbicCompression) and/or ZBIC magic scan in nso.cpp - Fall back to LZ4 when ZBIC is not detected or returns unexpected size - Handle segment 0 alternate offset (0x100 vs 0x108) for both ZBIC and LZ4 References: - Atmosphère loader/strat zstd-zbic integration: |
||
|---|---|---|
| .. | ||
| arm | ||
| crypto | ||
| debugger | ||
| file_sys | ||
| frontend | ||
| hle | ||
| internal_network | ||
| loader | ||
| memory | ||
| tools | ||
| CMakeLists.txt | ||
| constants.cpp | ||
| constants.h | ||
| core.cpp | ||
| core.h | ||
| core_timing.cpp | ||
| core_timing.h | ||
| cpu_manager.cpp | ||
| cpu_manager.h | ||
| device_memory.cpp | ||
| device_memory.h | ||
| device_memory_manager.h | ||
| device_memory_manager.inc | ||
| game_settings.cpp | ||
| game_settings.h | ||
| gpu_dirty_memory_manager.h | ||
| guest_memory.h | ||
| hardware_properties.h | ||
| launch_params.cpp | ||
| launch_params.h | ||
| launch_timestamp_cache.cpp | ||
| launch_timestamp_cache.h | ||
| memory.cpp | ||
| memory.h | ||
| perf_stats.cpp | ||
| perf_stats.h | ||
| reporter.cpp | ||
| reporter.h | ||