add_u32_u32.inc
Original bytes preserved. This is a browser-readable view.
; ======================================================================
; CS617 NUMERIC LIBRARY
; add_u32_u32.inc
;
; ROM-independent exact transplant of OM-52C C-ROM routine E964.
;
; Contract:
; input:
; $15-$18 unsigned 32-bit augend, low word first
; $5-$8 unsigned 32-bit addend, low word first
;
; output:
; $15-$18 ($15-$18 + $5-$8) mod 2^32
;
; arithmetic:
; unsigned wraparound modulo 2^32
;
; Historical donor:
; OM-52C E964..E96E
; length 11 bytes
; SHA-256:
; 8a1bd7c8a4d41aa90f95c8a21ce8d98eb305725a9661b1ee9bcc89930e5ab469
;
; The donor propagates low-word carry by adding the word value 1 via $SY.
; No overflow/status result is returned.
; ======================================================================
#LIST
UADD32:
ADW $15,$5
JR NC,UADD_HI
ADW $17,$SY
UADD_HI:
ADW $17,$7
RTN