clarify the purpose of this project
[nyanglibc.git] / csu / unwind-resume.shared.s
blob2d1cbb2d88ef52ea58dc317c4ec4e1bf448bac56
1 .text
2 #APP
3 memmove = __GI_memmove
4 memset = __GI_memset
5 memcpy = __GI_memcpy
6 .section .rodata.str1.1,"aMS",@progbits,1
7 .LC0:
8 .string "libgcc_s.so.1"
9 .section .rodata.str1.8,"aMS",@progbits,1
10 .align 8
11 .LC1:
12 .string "libgcc_s.so.1 must be installed for unwinding to work\n"
13 .section .rodata.str1.1
14 .LC2:
15 .string "_Unwind_Resume"
16 .LC3:
17 .string "__gcc_personality_v0"
18 #NO_APP
19 .section .text.unlikely,"ax",@progbits
20 .globl __libgcc_s_init
21 .hidden __libgcc_s_init
22 .type __libgcc_s_init, @function
23 __libgcc_s_init:
24 pushq %rbp
25 pushq %rbx
26 leaq .LC0(%rip), %rdi
27 movl $-2147483646, %esi
28 subq $8, %rsp
29 call __GI___libc_dlopen_mode
30 testq %rax, %rax
31 jne .L2
32 .L3:
33 leaq .LC1(%rip), %rdi
34 call __GI___libc_fatal
35 .L2:
36 leaq .LC2(%rip), %rsi
37 movq %rax, %rdi
38 movq %rax, %rbp
39 call __GI___libc_dlsym
40 testq %rax, %rax
41 movq %rax, %rbx
42 je .L3
43 leaq .LC3(%rip), %rsi
44 movq %rbp, %rdi
45 call __GI___libc_dlsym
46 testq %rax, %rax
47 je .L3
48 movq %rbx, %rdx
49 #APP
50 # 52 "../sysdeps/gnu/unwind-resume.c" 1
51 xor %fs:48, %rax
52 rol $2*8+1, %rax
53 # 0 "" 2
54 # 48 "../sysdeps/gnu/unwind-resume.c" 1
55 xor %fs:48, %rdx
56 rol $2*8+1, %rdx
57 # 0 "" 2
58 #NO_APP
59 movq %rax, libgcc_s_personality(%rip)
60 movq %rdx, __libgcc_s_resume(%rip)
61 popq %rax
62 popq %rbx
63 popq %rbp
64 ret
65 .size __libgcc_s_init, .-__libgcc_s_init
66 .text
67 .p2align 4,,15
68 .globl _Unwind_Resume
69 .type _Unwind_Resume, @function
70 _Unwind_Resume:
71 subq $24, %rsp
72 movq __libgcc_s_resume(%rip), %rax
73 testq %rax, %rax
74 je .L15
75 .L13:
76 #APP
77 # 66 "../sysdeps/gnu/unwind-resume.c" 1
78 ror $2*8+1, %rax
79 xor %fs:48, %rax
80 # 0 "" 2
81 #NO_APP
82 call *%rax
83 .p2align 4,,10
84 .p2align 3
85 .L15:
86 movq %rdi, 8(%rsp)
87 call __libgcc_s_init
88 movq __libgcc_s_resume(%rip), %rax
89 movq 8(%rsp), %rdi
90 jmp .L13
91 .size _Unwind_Resume, .-_Unwind_Resume
92 .p2align 4,,15
93 .globl __gcc_personality_v0
94 .type __gcc_personality_v0, @function
95 __gcc_personality_v0:
96 subq $40, %rsp
97 movq libgcc_s_personality(%rip), %rax
98 testq %rax, %rax
99 je .L19
100 .L17:
101 #APP
102 # 80 "../sysdeps/gnu/unwind-resume.c" 1
103 ror $2*8+1, %rax
104 xor %fs:48, %rax
105 # 0 "" 2
106 #NO_APP
107 addq $40, %rsp
108 jmp *%rax
109 .p2align 4,,10
110 .p2align 3
111 .L19:
112 movq %r8, 24(%rsp)
113 movq %rcx, 16(%rsp)
114 movq %rdx, 8(%rsp)
115 movl %esi, 4(%rsp)
116 movl %edi, (%rsp)
117 call __libgcc_s_init
118 movq libgcc_s_personality(%rip), %rax
119 movq 24(%rsp), %r8
120 movq 16(%rsp), %rcx
121 movq 8(%rsp), %rdx
122 movl 4(%rsp), %esi
123 movl (%rsp), %edi
124 jmp .L17
125 .size __gcc_personality_v0, .-__gcc_personality_v0
126 .local libgcc_s_personality
127 .comm libgcc_s_personality,8,8
128 .hidden __libgcc_s_resume
129 .comm __libgcc_s_resume,8,8