Blame SOURCES/glibc-rh694386.patch
|
|
b9ba6d |
2011-03-28 Andreas Schwab <schwab@linux-m68k.org>
|
|
|
b9ba6d |
|
|
|
b9ba6d |
* sysdeps/powerpc/powerpc32/power4/strncmp.S: Don't read past
|
|
|
b9ba6d |
differing bytes.
|
|
|
b9ba6d |
* sysdeps/powerpc/powerpc64/power4/strncmp.S: Likewise.
|
|
|
b9ba6d |
|
|
|
b9ba6d |
diff --git a/sysdeps/powerpc/powerpc32/power4/strncmp.S b/sysdeps/powerpc/powerpc32/power4/strncmp.S
|
|
|
b9ba6d |
index fc0835e..f5d47af 100644
|
|
|
b9ba6d |
--- a/sysdeps/powerpc/powerpc32/power4/strncmp.S
|
|
|
b9ba6d |
+++ b/sysdeps/powerpc/powerpc32/power4/strncmp.S
|
|
|
b9ba6d |
@@ -139,30 +139,31 @@ L(u1):
|
|
|
b9ba6d |
bdz L(u4)
|
|
|
b9ba6d |
cmpw rWORD1, rWORD2
|
|
|
b9ba6d |
beq- cr1, L(u4)
|
|
|
b9ba6d |
+ bne- L(u4)
|
|
|
b9ba6d |
lbzu rWORD3, 1(rSTR1)
|
|
|
b9ba6d |
lbzu rWORD4, 1(rSTR2)
|
|
|
b9ba6d |
- bne- L(u4)
|
|
|
b9ba6d |
cmpwi cr1, rWORD3, 0
|
|
|
b9ba6d |
bdz L(u3)
|
|
|
b9ba6d |
cmpw rWORD3, rWORD4
|
|
|
b9ba6d |
beq- cr1, L(u3)
|
|
|
b9ba6d |
+ bne- L(u3)
|
|
|
b9ba6d |
lbzu rWORD1, 1(rSTR1)
|
|
|
b9ba6d |
lbzu rWORD2, 1(rSTR2)
|
|
|
b9ba6d |
- bne- L(u3)
|
|
|
b9ba6d |
cmpwi cr1, rWORD1, 0
|
|
|
b9ba6d |
bdz L(u4)
|
|
|
b9ba6d |
cmpw rWORD1, rWORD2
|
|
|
b9ba6d |
beq- cr1, L(u4)
|
|
|
b9ba6d |
+ bne- L(u4)
|
|
|
b9ba6d |
lbzu rWORD3, 1(rSTR1)
|
|
|
b9ba6d |
lbzu rWORD4, 1(rSTR2)
|
|
|
b9ba6d |
- bne- L(u4)
|
|
|
b9ba6d |
cmpwi cr1, rWORD3, 0
|
|
|
b9ba6d |
bdz L(u3)
|
|
|
b9ba6d |
cmpw rWORD3, rWORD4
|
|
|
b9ba6d |
beq- cr1, L(u3)
|
|
|
b9ba6d |
+ bne- L(u3)
|
|
|
b9ba6d |
lbzu rWORD1, 1(rSTR1)
|
|
|
b9ba6d |
lbzu rWORD2, 1(rSTR2)
|
|
|
b9ba6d |
- beq+ L(u1)
|
|
|
b9ba6d |
+ b L(u1)
|
|
|
b9ba6d |
|
|
|
b9ba6d |
L(u3): sub rRTN, rWORD3, rWORD4
|
|
|
b9ba6d |
blr
|
|
|
b9ba6d |
diff --git a/sysdeps/powerpc/powerpc64/power4/strncmp.S b/sysdeps/powerpc/powerpc64/power4/strncmp.S
|
|
|
b9ba6d |
index 7a1665d..94ae85b 100644
|
|
|
b9ba6d |
--- a/sysdeps/powerpc/powerpc64/power4/strncmp.S
|
|
|
b9ba6d |
+++ b/sysdeps/powerpc/powerpc64/power4/strncmp.S
|
|
|
b9ba6d |
@@ -143,30 +143,31 @@ L(u1):
|
|
|
b9ba6d |
bdz L(u4)
|
|
|
b9ba6d |
cmpd rWORD1, rWORD2
|
|
|
b9ba6d |
beq- cr1, L(u4)
|
|
|
b9ba6d |
+ bne- L(u4)
|
|
|
b9ba6d |
lbzu rWORD3, 1(rSTR1)
|
|
|
b9ba6d |
lbzu rWORD4, 1(rSTR2)
|
|
|
b9ba6d |
- bne- L(u4)
|
|
|
b9ba6d |
cmpdi cr1, rWORD3, 0
|
|
|
b9ba6d |
bdz L(u3)
|
|
|
b9ba6d |
cmpd rWORD3, rWORD4
|
|
|
b9ba6d |
beq- cr1, L(u3)
|
|
|
b9ba6d |
+ bne- L(u3)
|
|
|
b9ba6d |
lbzu rWORD1, 1(rSTR1)
|
|
|
b9ba6d |
lbzu rWORD2, 1(rSTR2)
|
|
|
b9ba6d |
- bne- L(u3)
|
|
|
b9ba6d |
cmpdi cr1, rWORD1, 0
|
|
|
b9ba6d |
bdz L(u4)
|
|
|
b9ba6d |
cmpd rWORD1, rWORD2
|
|
|
b9ba6d |
beq- cr1, L(u4)
|
|
|
b9ba6d |
+ bne- L(u4)
|
|
|
b9ba6d |
lbzu rWORD3, 1(rSTR1)
|
|
|
b9ba6d |
lbzu rWORD4, 1(rSTR2)
|
|
|
b9ba6d |
- bne- L(u4)
|
|
|
b9ba6d |
cmpdi cr1, rWORD3, 0
|
|
|
b9ba6d |
bdz L(u3)
|
|
|
b9ba6d |
cmpd rWORD3, rWORD4
|
|
|
b9ba6d |
beq- cr1, L(u3)
|
|
|
b9ba6d |
+ bne- L(u3)
|
|
|
b9ba6d |
lbzu rWORD1, 1(rSTR1)
|
|
|
b9ba6d |
lbzu rWORD2, 1(rSTR2)
|
|
|
b9ba6d |
- beq+ L(u1)
|
|
|
b9ba6d |
+ b L(u1)
|
|
|
b9ba6d |
|
|
|
b9ba6d |
L(u3): sub rRTN, rWORD3, rWORD4
|
|
|
b9ba6d |
blr
|