Skip to main content

Module multiword

Module multiword 

Source
Expand description

The multi-word integer core: every wider-than-a-word integer operation, built once from lane operations and parameterized by the lane shape.

A Builder writes a Routine; its word-level methods emit one lane operation each, and its mw_* methods compose them into operations on multi-word values (Mw, little-endian words). The algorithms are the textbook ones a narrow datapath uses: ripple carries, schoolbook products from multiplier-width digits accumulated by column, restoring division, barrel shifts from constant shifts and selects, a binary-search leading-zero count. None branches on data.

Structsยง

Builder
The routine under construction.
Mw
A multi-word value: little-endian lane registers.