Created
May 20, 2022 01:18
-
-
Save rokuyama/3d791f2ceb2757dc389a95910162c9cb to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Index: common/lib/libc/arch/arm/atomic/atomic_cas_16.S | |
=================================================================== | |
RCS file: /home/netbsd/src/common/lib/libc/arch/arm/atomic/atomic_cas_16.S,v | |
retrieving revision 1.3 | |
diff -p -u -r1.3 atomic_cas_16.S | |
--- common/lib/libc/arch/arm/atomic/atomic_cas_16.S 28 Jul 2021 07:32:20 -0000 1.3 | |
+++ common/lib/libc/arch/arm/atomic/atomic_cas_16.S 19 May 2022 07:05:34 -0000 | |
@@ -40,6 +40,10 @@ ENTRY_NP(_atomic_cas_16) | |
mov ip, r0 /* we need r0 for return value */ | |
1: | |
ldrexh r0, [ip] /* load old value */ | |
+#if 1 /* XXX port-arm/56839 */ | |
+ lsl r1, r1, #16 /* r1 &= 0xffff */ | |
+ lsr r1, r1, #16 | |
+#endif | |
cmp r0, r1 /* compare? */ | |
#ifdef __thumb__ | |
bne 2f | |
Index: common/lib/libc/arch/arm/atomic/atomic_cas_8.S | |
=================================================================== | |
RCS file: /home/netbsd/src/common/lib/libc/arch/arm/atomic/atomic_cas_8.S,v | |
retrieving revision 1.9 | |
diff -p -u -r1.9 atomic_cas_8.S | |
--- common/lib/libc/arch/arm/atomic/atomic_cas_8.S 28 Jul 2021 07:32:20 -0000 1.9 | |
+++ common/lib/libc/arch/arm/atomic/atomic_cas_8.S 19 May 2022 07:02:45 -0000 | |
@@ -41,6 +41,9 @@ ENTRY_NP(_atomic_cas_8) | |
mov ip, r0 /* we need r0 for return value */ | |
1: | |
ldrexb r0, [ip] /* load old value */ | |
+#if 1 /* XXX port-arm/56839 */ | |
+ and r1, r1, #0xff | |
+#endif | |
cmp r0, r1 /* compare? */ | |
#ifdef __thumb__ | |
bne 2f | |
Index: common/lib/libc/arch/arm/atomic/atomic_cas_up.S | |
=================================================================== | |
RCS file: /home/netbsd/src/common/lib/libc/arch/arm/atomic/atomic_cas_up.S,v | |
retrieving revision 1.8 | |
diff -p -u -r1.8 atomic_cas_up.S | |
--- common/lib/libc/arch/arm/atomic/atomic_cas_up.S 9 Mar 2020 11:21:54 -0000 1.8 | |
+++ common/lib/libc/arch/arm/atomic/atomic_cas_up.S 19 May 2022 07:07:37 -0000 | |
@@ -73,6 +73,10 @@ ENTRY(_atomic_cas_16_up) | |
.align 0 | |
RAS_START_ASM_HIDDEN(_atomic_cas_16) | |
ldrh r0, [r3] | |
+#if 1 /* XXX port-arm/56839 */ | |
+ lsl r1, r1, #16 /* r1 &= 0xffff */ | |
+ lsr r1, r1, #16 | |
+#endif | |
cmp r0, r1 | |
#if defined(__thumb__) | |
beq 1f | |
@@ -90,6 +94,9 @@ ENTRY(_atomic_cas_8_up) | |
.align 0 | |
RAS_START_ASM_HIDDEN(_atomic_cas_8) | |
ldrb r0, [r3] | |
+#if 1 /* XXX port-arm/56839 */ | |
+ and r1, r1, #0xff | |
+#endif | |
cmp r0, r1 | |
#if defined(__thumb__) | |
beq 1f |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment