shave off 2 bytes from crt1.o _start
[musl] / crt / x86_64 / crt1.s
1 /* Written 2011 Nicholas J. Kain, released as Public Domain */
2 .text
3 .global _start
4 _start:
5         xor %rbp,%rbp   /* rbp:undefined -> mark as zero 0 (ABI) */
6         mov %rdx,%r9    /* 6th arg: ptr to register with atexit() */
7         pop %rsi        /* 2nd arg: argc */
8         mov %rsp,%rdx   /* 3rd arg: argv */
9         andq $-16,%rsp  /* align stack pointer */
10         push %rax       /* 8th arg: glibc ABI compatible */
11         push %rsp       /* 7th arg: glibc ABI compatible */
12         xor %r8,%r8     /* 5th arg: always 0 */
13         xor %rcx,%rcx   /* 4th arg: always 0 */
14         mov $main,%rdi  /* 1st arg: application entry ip */
15         call __libc_start_main /* musl init will run the program */
16 .L0:    jmp .L0