Bug #12340
opencrc16 implementations need disambiguation
0%
Description
While reviewing a BHYVE upstream today, I noticed this:
http://src.illumos.org/source/search?q=&defs=crc16&refs=&path=&hist=&project=illumos-gate
At least two crc16() implementations, and those are just the ones named "crc16".
Updated by Joshua M. Clulow over 2 years ago
If one were to collapse these into a single implementation, it would be good to first make sure they all produce the same output for every possible input. There are, as I recall, many different options for CRC routines; e.g., different polynomials, different initialisation vectors, etc.
Updated by Dan McDonald over 2 years ago
Wow. I thought crc16 was a single standard... nope:
https://en.wikipedia.org/wiki/Cyclic_redundancy_check
Looks like there are 8 different "crc16" routines. Perhaps this bug should be re-summarized to perhaps say "crc16 implementations need name-level disambiguation"?
Updated by Dan McDonald over 2 years ago
- Subject changed from Too many crc16 implementations to crc16 implementations need disambiguation
- Priority changed from Normal to Low
Per Josh's comment, and my response.