mirror of
git://git.musl-libc.org/musl
synced 2024-12-30 02:42:37 +00:00
63caf1d207
i386 and x86_64 versions already had the .text directive; other archs did not. normally, top-level (file scope) __asm__ starts in the .text section anyway, but problems were reported with some versions of clang, and it seems preferable to set it explicitly anyway, at least for the sake of consistency between archs.
16 lines
274 B
C
16 lines
274 B
C
__asm__(
|
|
".text \n"
|
|
".global " START "\n"
|
|
".type " START ",%function\n"
|
|
START ":\n"
|
|
" mov x29, #0\n"
|
|
" mov x30, #0\n"
|
|
" mov x0, sp\n"
|
|
".weak _DYNAMIC\n"
|
|
".hidden _DYNAMIC\n"
|
|
" adrp x1, _DYNAMIC\n"
|
|
" add x1, x1, #:lo12:_DYNAMIC\n"
|
|
" and sp, x0, #-16\n"
|
|
" b " START "_c\n"
|
|
);
|