
Originally Posted by
dilettante
But I'm a bit curious what kind of software needs to calculate CRC32s much anyway, or for that matter needs to checksum so much data that a straight VB6 function isn't fast enough.
Actually recently refactored an unzipping class and noticed that calculating CRC32 reduced speed a lot (probably in half). That's when I decided to skip it altogether with a conditional compilation option.
Unfortunately OP code is too bloated to be easily plugged in my skinny class. I doubt that he can beat a for cycle and a XOR for brevity
Code:
For lIdx = 0 To lSize - 1
lOutputCrc32 = (((lOutputCrc32 And &HFFFFFF00) \ &H100) And &HFFFFFF) Xor (m_lCrc32Table((lOutputCrc32 And &HFF) Xor uCtx.baInStream(lOffset + lIdx)))
Next
cheers,
</wqw>