They use the carry bit to add and subtract. Assembler operations for "add with hyphenation" and "subtract with hyphenation" (or "borrow") can be used to add and subtract with the addition and subtraction of an arbitrary bit length.
For multiplication, if you only have a 32-bit multiplication result, you can split it into 16-bit value pairs and multiply, then shift and add (with a carry) to get the full 64-bit result from the 32-bit multiply. In principle, using a long version (any two 16-bit multiplications corresponding to a 32-bit result) can be used to generate arbitrary bit length multiplications using more limited precision.
FWIW, Intel's 32-bit ASM "mul" command can put a 64-bit result in EDX: EAX so that you can actually multiply in 32-bit fragments (with the addition of 64-bit values) rather than 16- (with 32- bit values ββfor offset and add).
Adisak
source share