We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
2 parents 7ac5155 + 97217e3 commit ac9f96fCopy full SHA for ac9f96f
src/arm.rs
@@ -9,21 +9,24 @@ pub unsafe fn __aeabi_uidivmod() {
9
sub sp, sp, #4
10
mov r2, sp
11
bl __udivmodsi4
12
- ldr r1, [sp], #4
+ ldr r1, [sp]
13
+ add sp, sp, #4
14
pop {pc}");
15
intrinsics::unreachable();
16
}
17
18
#[naked]
19
#[cfg_attr(not(test), no_mangle)]
20
pub unsafe fn __aeabi_uldivmod() {
- asm!("push {lr}
21
- sub r12, sp, #12
22
- str r12, [sp, #-20]!
+ asm!("push {r4, lr}
+ sub sp, sp, #16
23
+ add r4, sp, #8
24
+ str r4, [sp]
25
bl __udivmoddi4
- ldrd r2, r3, [sp, #8]
- add sp, sp, #20
26
- pop {pc}");
+ ldr r2, [sp, #8]
27
+ ldr r3, [sp, #12]
28
+ add sp, sp, #16
29
+ pop {r4, pc}");
30
31
32
0 commit comments