klauspost / crc32

CRC32 hash with x64 optimizations
BSD 3-Clause "New" or "Revised" License
74 stars 23 forks source link

crc32: align more with Go standard library hash/crc32 #14

Closed rsc closed 8 years ago

rsc commented 8 years ago

I diffed klauspost/crc32 against standard hash/crc32 and made some changes to align them a bit more closely. I expect that many of these are simply changes that have been made in hash/crc32 since you forked it. This is just to reduce the diffs when you send this code in for Go 1.7.

I didn't look closely at the assembly files because of all the spacing diffs. If there are important changes there (the only one I found was possibly MOVOA turning into MOVOU), please make them anew in the eventual Go 1.7 CL so as to avoid including all the formatting changes. In general I'm in favor of having some kind of asmfmt, but we don't yet, and it's much easier to review if the CL only contains semantic changes.

Thanks very much.

klauspost commented 8 years ago

LGTM. I will recheck the assembly when sending in the CL.

Thank you for taking the time to fix this.