Simple Scalar

# Simple Scalar - for(i = 0 i< ALPHABET i...

This preview shows pages 1–2. Sign up to view the full content.

This preview has intentionally blurred sections. Sign up to view the full version.

View Full Document
This is the end of the preview. Sign up to access the rest of the document.

Unformatted text preview: for (i = 0; i < ALPHABET; i++) { if (alPhrase[i].uFrequency == 0) { auGlobalFrequency[i] = ~0; /* to make it sort last */ } else { auGlobalFrequency[i] = 0; for (cbtNeed = 1, qNeed = 1; alPhrase[i].uFrequency >= qNeed; cbtNeed++, qNeed <<= 1); if (cbtUsed + cbtNeed > MASK_BITS) { if (++iq >= MAX_QUADS) Fatal("MAX_QUADS not large enough\n", 0); cbtUsed = 0; } alPhrase[i].uBits = qNeed-1; if (cbtUsed) qNeed <<= cbtUsed; aqMainSign[iq] |= qNeed; aqMainMask[iq] |= (Quad)alPhrase[i].uFrequency << cbtUsed; alPhrase[i].uShift = cbtUsed; alPhrase[i].iq = iq; cbtUsed += cbtNeed; } } } PWord NewWord(void) { PWord pw;...
View Full Document

{[ snackBarMessage ]}

### Page1 / 2

Simple Scalar - for(i = 0 i< ALPHABET i...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document
Ask a homework question - tutors are online