replaced some db.. instructions; they are wrong if the count register
authorceriel <none@none>
Fri, 7 Jul 1989 13:53:37 +0000 (13:53 +0000)
committerceriel <none@none>
Fri, 7 Jul 1989 13:53:37 +0000 (13:53 +0000)
contains a count > 65535

mach/m68020/libem/exg.s
mach/m68020/libem/lar.s
mach/m68020/libem/los.s
mach/m68020/libem/sar.s
mach/m68020/libem/set.s
mach/m68020/libem/sts.s

index 4abbf97..d10cb93 100644 (file)
        lea     (4,sp,d0), a0   ! address of bottom block
        lea     (4,sp), a1      ! address of top block
        asr.l   #2, d0
-       sub.l   #1, d0
 1:
        move.l  (a1), d1
        move.l  (a0), (a1)+
        move.l  d1, (a0)+
-       dbf     d0, 1b
+       sub.l   #1, d0
+       bne     1b
        rts
 .align 2
index 9251987..000bb58 100644 (file)
@@ -45,10 +45,10 @@ EILLINS=18
        add.l   d0, a1          ! address of 4n byte element
        add.l   d1, a1          ! because of predecrement
        asr.l   #2, d1
-       sub.l   #1, d1
        move.l  (sp)+,a0
 1:
        move.l  -(a1), -(sp)
-       dbf     d1, 1b
+       sub.l   #1, d1
+       bne     1b
        jmp     (a0)
 .align 2
index 3aa2d01..de5b9c9 100644 (file)
 2:
        add.l   d0, a0          !>=4 bytes
        asr.l   #2, d0
-       sub.l   #1, d0
 
 4:     move.l  -(a0), -(sp)    
-       dbf     d0, 4b
+       sub.l   #1, d0
+       bne     4b
 3:
        jmp     (a1)
 .align 2
index 380665f..5ed87b0 100644 (file)
@@ -47,10 +47,10 @@ EILLINS=18
        muls.l  d1, d0
        add.l   d0, a1          ! address of 4n byte element
        asr.l   #2, d1
-       sub.l   #1, d1
        move.l  (sp)+,a0
 1:
        move.l  (sp)+, (a1)+
-       dbf     d1, 1b
+       sub.l   #1, d1
+       bne     1b
        jmp     (a0)
 .align 2
index fd1f8cf..7bc9570 100644 (file)
@@ -15,10 +15,10 @@ ESET=2
        move.l  d2, a1
        move.l  d1, d2
        asr.l   #2, d2
-       sub.l   #1, d2
 1:
        clr.l   -(sp)
-       dbf     d2, 1b
+       sub.l   #1, d2
+       bne     1b
 
        move.l  d0, d2
        asr.l   #3, d2          ! offset from sp in bytes
index a1685f6..4bbbc5f 100644 (file)
        bra     4f
 2:
        asr.l   #2, d0
-       sub.l   #1, d0
 3:
        move.l  (sp)+, (a0)+
-       dbf     d0, 3b
+       sub.l   #1, d0
+       bne     3b
 4:
        jmp     (a1)            ! return
 .align 2