Cleared the top bytes for use in arrays.
authormichaelh <michaelh@4a8a32a2-be11-0410-ad9d-d568d2c75423>
Wed, 1 Aug 2001 03:33:57 +0000 (03:33 +0000)
committermichaelh <michaelh@4a8a32a2-be11-0410-ad9d-d568d2c75423>
Wed, 1 Aug 2001 03:33:57 +0000 (03:33 +0000)
git-svn-id: https://sdcc.svn.sourceforge.net/svnroot/sdcc/trunk/sdcc@1117 4a8a32a2-be11-0410-ad9d-d568d2c75423

device/lib/z80/mul.s

index fa3fb63ebfcebfa43eb9e0686ef39e767a8daa55..f0817aefdc99d8f3aab992c3d0ba4f1ab2db6e8e 100644 (file)
@@ -32,9 +32,15 @@ __muluchar_rr_s::
         add     hl,sp
 
         ld      e,(hl)
+
         inc     hl
         ld      c,(hl)                
 
+        ;; Clear the top
+        xor     a
+        ld      d,a
+        ld      b,a
+        
         jp      .mulu16
         
 __mulsint_rr_s::