File tree Expand file tree Collapse file tree 1 file changed +37
-37
lines changed Expand file tree Collapse file tree 1 file changed +37
-37
lines changed Original file line number Diff line number Diff line change @@ -6462,55 +6462,55 @@ _MultiplyHLDE:
64626462 pop bc
64636463
64646464;-------------------------------------------------------------------------------
6465+ ; identical to __imulu, but doesn't preserve AF
64656466_MultiplyHLBC:
64666467; Performs (un)signed integer multiplication
64676468; Inputs:
64686469; HL : Operand 1
64696470; BC : Operand 2
64706471; Outputs:
64716472; HL = HL*BC
6472- push iy
6473+ ; push af ; optional
6474+ push de
6475+ ld d , b
6476+ ld e , h
6477+ mlt de
6478+ ld a , e
6479+ dec sp
64736480 push hl
64746481 push bc
6475- push hl
6476- ld iy , 0
6477- ld d , l
6478- ld e , b
6479- mlt de
6480- add iy , de
6481- ld d , c
6482- ld e , h
6482+ inc sp
6483+ pop de
6484+ ld e , l
64836485 mlt de
6484- add iy , de
6485- ld d , c
6486- ld e , l
6486+ add a , e
6487+ pop de
6488+ ld e , c
64876489 mlt de
6488- ld c , h
6489- mlt bc
6490- ld a , c
6491- inc sp
6492- inc sp
6493- pop hl
6490+ add a , e
6491+ ld e , l
6492+ ld l , c
64946493 mlt hl
6495- add a , l
6496- pop hl
6497- inc sp
6498- mlt hl
6499- add a , l
6500- ld b , a
6501- ld c , 0
6502- lea hl , iy + 0
6503- add hl , bc
6504- add hl , hl
6505- add hl , hl
6506- add hl , hl
6507- add hl , hl
6508- add hl , hl
6509- add hl , hl
6510- add hl , hl
6511- add hl , hl
6512- add hl , de
6513- pop iy
6494+ add a , h
6495+ ld h , a
6496+ ld a , e
6497+ ld d , b
6498+ mlt de
6499+ add hl , de
6500+ add hl , hl
6501+ add hl , hl
6502+ add hl , hl
6503+ add hl , hl
6504+ add hl , hl
6505+ add hl , hl
6506+ add hl , hl
6507+ add hl , hl
6508+ ld d , a
6509+ ld e , c
6510+ mlt de
6511+ add hl , de
6512+ pop de
6513+ ; pop af ; optional
65146514 ret
65156515
65166516;-------------------------------------------------------------------------------
You can’t perform that action at this time.
0 commit comments