summaryrefslogtreecommitdiff
path: root/crt/i386/crt1.s
blob: 66ee11ab1a8bdf4342ad6d5bb3c442e76499170c (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
.weak _init
.weak _fini
.text
.global _start
_start:
	xorl %ebp,%ebp
	popl %ecx
	movl %esp,%eax
	andl $-16,%esp
	pushl %esp
	pushl %esp
	pushl %edx
	call 1f
1:	addl $[_fini-.],(%esp)
	call 1f
1:	addl $[_init-.],(%esp)
	pushl %eax
	pushl %ecx
	call 1f
1:	addl $[main-.],(%esp)
	call __libc_start_main
1:	jmp 1b