]> git.sur5r.net Git - cc65/commitdiff
Sqeezed one byte out of the zerobss routine:-)
authorcuz <cuz@b7a2c559-68d2-44c3-8de9-860c34a00d81>
Thu, 23 Nov 2000 22:15:57 +0000 (22:15 +0000)
committercuz <cuz@b7a2c559-68d2-44c3-8de9-860c34a00d81>
Thu, 23 Nov 2000 22:15:57 +0000 (22:15 +0000)
git-svn-id: svn://svn.cc65.org/cc65/trunk@480 b7a2c559-68d2-44c3-8de9-860c34a00d81

libsrc/common/zerobss.s

index 9e1d005248e2997e01d9fcb53f0e88f775283cf3..321a1f560a05231c91baec27114e41fd001ebb6c 100644 (file)
@@ -32,16 +32,15 @@ L2: sta     (ptr1),y
 
 ; Clear remaining page (y is zero on entry)
 
-L3:    ldx     #<__BSS_SIZE__
-       beq     L5
-L4:    sta     (ptr1),y
-       iny
-       dex
-       bne     L4
+L3:    cpy     #<__BSS_SIZE__
+       beq     L4
+       sta     (ptr1),y
+       iny
+       bne     L3
 
 ; Done
 
-L5:    rts
+L4:    rts