News for hackers. Stuff that matters.
Re:Computing Adler32 Checksums at 41 GB/s by TAForObvReasons on Sunday August 07, 2022 @02:38PM (#32378622)
While micro-optimizations are interesting, there are two questions left unanswered:

- Does this change noticeably affect the total runtime? The checksum seems simple enough that the slight difference here wouldn't show up in PNG benchmarks.

- The proposed solution uses AVX2, which is not currently used in the original codebase. Would any other part of the processing benefit from using newer instructions?

Re:Computing Adler32 Checksums at 41 GB/s by londons_explore on Sunday August 07, 2022 @05:19PM (#32380015)
If checksum calculation was any substantial portion of image decoding, I think that would be a strong case for simply not checking the checksum.

If you put corrupted data into a PNG decoder, I don't think it's awfully important to most users whether they get a decode error or a garbled image out.

Re:Computing Adler32 Checksums at 41 GB/s by wooosh on Sunday August 07, 2022 @05:29PM (#32380101)
This was actually considered, and other libraries do ignore checksums, or at least have options to:

https://github.com/richgel999/fpng/issues/9