소스 검색

fix hwcap access in powerpc-sf setjmp/longjmp

commit 7be59733d71ada3a32a98622507399253f1d5e48 introduced the
hwcap-based branches to support the SPE FPU, but wrongly coded them as
bitwise tests on the computed address of __hwcap, not a value loaded
from that address. replace the add with indexed load to fix it.
Rich Felker 3 년 전
부모
커밋
8274aaaaa1
2개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 1 1
      src/setjmp/powerpc/longjmp.S
  2. 1 1
      src/setjmp/powerpc/setjmp.S

+ 1 - 1
src/setjmp/powerpc/longjmp.S

@@ -44,7 +44,7 @@ longjmp:
 	.long __hwcap-.
 1:	mflr 4
 	lwz 5, 0(4)
-	add 4, 4, 5
+	lwzx 4, 4, 5
 	andis. 4, 4, 0x80
 	beq 1f
 	.long 0x11c35b01 /* evldd 14,88(3) */

+ 1 - 1
src/setjmp/powerpc/setjmp.S

@@ -44,7 +44,7 @@ setjmp:
 	.long __hwcap-.
 1:	mflr 4
 	lwz 5, 0(4)
-	add 4, 4, 5
+	lwzx 4, 4, 5
 	andis. 4, 4, 0x80
 	beq 1f
 	.long 0x11c35b21 /* evstdd 14,88(3) */