1 # FIXME : does not work, the small data array needs to be relocated.
2 # see elfspec_ppc.pdf, page 76-84
6 mr 9, 1 # Save the original stack pointer.
7 clrrwi 1, 1, 4 # Align the stack to 16 bytes.
8 lis 13, _SDA_BASE_@ha # r13 points to the small data area.
9 addi 13, 13, _SDA_BASE_@l
10 li 0, 0 # Zero the frame pointer.
11 lwz 3, 0(9) # and argc...
12 addi 4, 9, 4 # and argv ...
13 mtlr 0 # Clear the link register.
14 # Go to the musl dynamic linker entry point.
16 cmpi 4, 0, 3, 1 # Check for a 1.
18 mtlr 3 # Set the link address...
22 .size _start, .-_start