◄ WORLD V · SONNY 5DART 377 · a helldive at the net

CARRY-LOOKAHEAD generate and propagate — compute every carry at once, not one by one

The carry does not have to walk. For each bit define two signals: generate g = a & b (this bit makes a carry no matter what) and propagate p = a ⊕ b (this bit passes a carry through). Then every carry is a formula in the g's and p's — ci+1 = gi | (pi & ci), unrolled — so all carries can be computed in parallel, in logarithmic depth instead of linear. The answer is identical to the ripple's; only the time changes. It is the idea under every fast adder in every CPU.

THE TECHNIQUE g = a&b, p = a⊕b ; carries as a parallel formula

The demo computes the same 11+6 via generate/propagate — same sum 17, carries in parallel: live demo


HISTORY & CREDIT Weinberger & Smith, 1958

“The carry must ripple.” — generate/propagate turns every carry into a parallel formula, so the whole width resolves in log depth. The answer is the same; the wait is not. cited

1958 · Arnold Weinberger & J. L. Smith (National Bureau of Standards, NBS Circular 591 — not IBM) — the carry-lookahead adder; a competing IBM claim runs through Gerald Rosenberger's 1957 patent.
g / p · generate a&b, propagate a⊕b — the two signals that decouple the carry.
now · the basis of every fast adder; the parallel-prefix form is Kogge-Stone (dart 379).

Say which bits make a carry and which pass one, and every carry is a formula solved at once. Same sum, log-depth wait. Weinberger–Smith 1958

RECOMMEND FOR I-13 the parallel carry, on the compiler

On the canonical compiler, generate/propagate adds 11+6=17 — the same answer as the ripple, carries decoupled:

$ i13 run c_carrylookahead.i13 # g=a&b, p=a^b ; c_{i+1}=g|(p&c) RUN OK · 260 step(s) · peak stack 8 · call depth 6 sum = 17 -- identical to ripple; only the carry timing changed
Recommend: carry-lookahead is the carry decoupled — generate/propagate turn a walk into a parallel formula — and i13 gets the same 17 as the ripple. Not a keeper, and cleanly so: it is a pure speed mechanism, its output bit-identical to the ripple's; the only delta is the timing. That is exactly the B40 resource-property tell — efficiency, not structure. A canonical illustration of the excluded class.