Computation of CRC - Parallel Computation

Parallel Computation

Another common optimization uses a lookup table indexed by highest order coefficients of rem to perform the inner loop over 8 bits in fewer steps. A 256-entry lookup table is a particularly common choice, although using a 16-entry table twice per byte is very compact and still faster than the bit at a time version. This replaces the inner loop over j with

// Msbit-first rem = (rem leftShift 8) xor big_endian_table // Lsbit-first rem = (rem rightShift 8) xor little_endian_table
Code fragment 6: Cores of table based division

One of the most commonly encountered CRC algorithms is known as CRC-32, used by (among others) Ethernet, FDDI, ZIP and other archive formats, and PNG image format. Its polynomial can be written msbit-first as 0x04C11DB7, or lsbit-first as 0xEDB88320. The W3C webpage on PNG includes an appendix with a short and simple table-driven implementation in C of CRC-32. You will note that the code corresponds to the lsbit-first byte-at-a-time pseudocode presented here, and the table is generated using the bit-at-a-time code.

Read more about this topic:  Computation Of CRC

Famous quotes containing the words parallel and/or computation:

    The parallel between antifeminism and race prejudice is striking. The same underlying motives appear to be at work, namely fear, jealousy, feelings of insecurity, fear of economic competition, guilt feelings, and the like. Many of the leaders of the feminist movement in the nineteenth-century United States clearly understood the similarity of the motives at work in antifeminism and race discrimination and associated themselves with the anti slavery movement.
    Ashley Montagu (b. 1905)

    I suppose that Paderewski can play superbly, if not quite at his best, while his thoughts wander to the other end of the world, or possibly busy themselves with a computation of the receipts as he gazes out across the auditorium. I know a great actor, a master technician, can let his thoughts play truant from the scene ...
    Minnie Maddern Fiske (1865–1932)