2 ; Ullrich von Bassewitz, 2010-11-02
4 ; CC65 runtime: 8x8 => 16 unsigned multiplication
7 .export umul8x8r16, umul8x8r16m
11 ;---------------------------------------------------------------------------
12 ; 8x8 => 16 unsigned multiplication routine.
14 ; LHS RHS result result in also
15 ; -------------------------------------------------------------
16 ; .A (ptr3-low) ptr1-low .XA ptr1
23 ldy #8 ; Number of bits
24 lsr ptr1 ; Get first bit of RHS into carry
33 stx ptr1+1 ; Result in .XA and ptr1
34 lda ptr1 ; Load the result