| > the pages within a CBZ are going to be encoded (JPEG/PNG/etc) rather than just being bitmaps. They need to be decoded first, the GPU isn't going to let you create a texture directly from JPEG data. It seems that JPEG can be decoded on the GPU [1] [2] > CRC32 is limited by memory bandwidth if you're using a normal (i.e. SIMD) implementation. According to smhasher tests [3] CRC32 is not limited by memory bandwidth. Even if we multiply CRC32 scores x4 (to estimate 512 bit wide SIMD from 128 bit wide results), we still don't get close to memory bandwidth. The 32 bit hash of CRC32 is too low for file checksums. xxhash is definitely an improvement over CRC32. > to actually check the integrity of archived files you want to use something like sha256, not CRC32 or xxhash Why would you need to use a cryptographic hash function to check integrity of archived files? Quality a non-cryptographic hash function will detect corruptions due to things like bit-rot, bad RAM, etc. just the same. And why is 256 bits needed here? Kopia developers, for example, think 128 bit hashes are big enough for backup archives [4]. [1] https://docs.nvidia.com/cuda/nvjpeg/index.html [2] https://github.com/CESNET/GPUJPEG [3] https://github.com/rurban/smhasher [4] https://github.com/kopia/kopia/issues/692 |
[1] claims 15 GB/s for the slowest implementation (Chromium) they compared (all vectorized).
> The 32 bit hash of CRC32 is too low for file checksums. xxhash is definitely an improvement over CRC32.
Why? What kind of error rate do you expect, and what kind of reliability do you want to achieve? Assumptions that would lead to a >32bit checksum requirement seem outlandish to me.
[1] https://github.com/corsix/fast-crc32?tab=readme-ov-file#x86_...