mirror of
https://github.com/switchbrew/libnx.git
synced 2025-06-21 20:42:44 +02:00
Crt0, still untested
This commit is contained in:
parent
a35cdc698b
commit
2fa19f45b0
@ -29,15 +29,15 @@ bss_loop:
|
|||||||
ldr x0, =__got_start__
|
ldr x0, =__got_start__
|
||||||
ldr x1, =__got_end__
|
ldr x1, =__got_end__
|
||||||
sub x1, x1, x0 // calculate size
|
sub x1, x1, x0 // calculate size
|
||||||
add x1, x1, #3 // round up to 4
|
add x1, x1, #7 // round up to 8
|
||||||
bic x1, x1, #3
|
bic x1, x1, #7
|
||||||
add x0, x0, x30 // relocate ptr
|
add x0, x0, x30 // relocate ptr
|
||||||
|
|
||||||
got_loop:
|
got_loop:
|
||||||
ldr x2, [x0]
|
ldr x2, [x0]
|
||||||
ldr x3, [x2]
|
ldr x3, [x2]
|
||||||
add x3, x3, x30
|
add x3, x3, x30
|
||||||
str x3, [x2], #8
|
str x3, [x2]
|
||||||
subs x1, x1, #8
|
subs x1, x1, #8
|
||||||
bne got_loop
|
bne got_loop
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user