1 |
.section .data |
2 |
|
3 |
.globl __uar_data_start |
4 |
.globl __uar_data_end |
5 |
.globl __uar_data_size |
6 |
|
7 |
__uar_data_start: |
8 |
.incbin "test-archive.uar" |
9 |
__uar_data_end: |
10 |
.byte 0x00 |
11 |
__uar_data_size: |
12 |
.quad __uar_data_end - __uar_data_start |
13 |
|
14 |
.text |
15 |
|
16 |
.globl main |
17 |
.type main, @function |
18 |
main: |
19 |
call uar_init |
20 |
call uar_main |
21 |
push %rax |
22 |
call uar_deinit |
23 |
pop %rax |
24 |
ret |
25 |
|
26 |
.globl uar_get_data_start |
27 |
.type uar_get_data_start, @function |
28 |
|
29 |
uar_get_data_start: |
30 |
lea __uar_data_start(%rip), %rax |
31 |
ret |
32 |
|
33 |
.globl _start |
34 |
_start: |
35 |
call plibc_init |
36 |
mov $0, %rdi |
37 |
mov %rsp, %rsi |
38 |
mov $0, %rdx |
39 |
call main |
40 |
push %rax |
41 |
call _plibc_call_exit_handlers |
42 |
call plibc_deinit |
43 |
pop %rdi |
44 |
call _exit |
45 |
|
46 |
.section .note.GNU-stack,"",@progbits |