Frage

I got a program that I know will run only on very specific hardware, so I started using crc32 as supplied by the SSE4.2 instruction set, but now I need crc16 for a different purpose. Is there a way to coax the hardware to give me crc16 with the same performance as SSE's crc32?

Thanks

War es hilfreich?

Lösung

If you have the PCLMULQDQ instruction, you can use that to make a fast CRC. Though not quite as fast as the crc32 instruction.

Alternatively, a poor man's check value could be the low 16 bits of the result of crc32.

Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top