clarify the purpose of this project
[nyanglibc.git] / stdlib / strfromf.shared.s
blob08f1da5f80014a8ac40a0324c4beb507c6953354
1 .text
2 #APP
3 memmove = __GI_memmove
4 memset = __GI_memset
5 memcpy = __GI_memcpy
6 #NO_APP
7 .p2align 4,,15
8 .globl strfromf
9 .type strfromf, @function
10 strfromf:
11 pushq %r15
12 pushq %r14
13 cvtss2sd %xmm0, %xmm0
14 pushq %r13
15 pushq %r12
16 pushq %rbp
17 pushq %rbx
18 subq $360, %rsp
19 cmpb $37, (%rdx)
20 movq %rsp, %rax
21 movq $0, 184(%rsp)
22 movsd %xmm0, (%rsp)
23 movq %rax, 8(%rsp)
24 jne .L14
25 movzbl 1(%rdx), %ebx
26 movq %rdi, %r15
27 cmpb $46, %bl
28 je .L3
29 movsbl %bl, %r14d
30 movl $-1, %r13d
31 .L4:
32 leal -65(%rbx), %eax
33 cmpb $38, %al
34 ja .L14
35 movabsq $485331304561, %rdx
36 btq %rax, %rdx
37 jnc .L14
38 testq %rsi, %rsi
39 je .L24
40 leaq -1(%rsi), %r12
41 leaq 48(%rsp), %rbp
42 .L15:
43 xorl %r8d, %r8d
44 xorl %ecx, %ecx
45 movl $-1, %edx
46 movl $32768, %esi
47 movq %rbp, %rdi
48 andl $-33, %ebx
49 call _IO_no_init@PLT
50 leaq _IO_strn_jumps(%rip), %rax
51 movq %r15, %rcx
52 movq %r12, %rdx
53 movq %r15, %rsi
54 movq %rbp, %rdi
55 movq %rax, 264(%rsp)
56 call _IO_str_init_static_internal@PLT
57 pxor %xmm0, %xmm0
58 cmpb $65, %bl
59 leaq 16(%rsp), %rax
60 movl %r13d, 16(%rsp)
61 movups %xmm0, 20(%rsp)
62 movl %r14d, 24(%rsp)
63 je .L16
64 leaq 8(%rsp), %rcx
65 movq %rbp, %rdi
66 movq __libc_tsd_LOCALE@gottpoff(%rip), %rdx
67 movq %fs:(%rdx), %rsi
68 movq %rax, %rdx
69 call __GI___printf_fp_l
70 .L17:
71 addq $240, %rbp
72 cmpq %rbp, 104(%rsp)
73 je .L1
74 movq 88(%rsp), %rdx
75 movb $0, (%rdx)
76 .L1:
77 addq $360, %rsp
78 popq %rbx
79 popq %rbp
80 popq %r12
81 popq %r13
82 popq %r14
83 popq %r15
84 ret
85 .p2align 4,,10
86 .p2align 3
87 .L24:
88 leaq 48(%rsp), %rbp
89 movl $63, %r12d
90 leaq 240(%rbp), %r15
91 jmp .L15
92 .p2align 4,,10
93 .p2align 3
94 .L16:
95 leaq 8(%rsp), %rdx
96 movq %rax, %rsi
97 movq %rbp, %rdi
98 call __printf_fphex
99 jmp .L17
100 .p2align 4,,10
101 .p2align 3
102 .L3:
103 movsbl 2(%rdx), %r14d
104 leaq 2(%rdx), %rax
105 xorl %r13d, %r13d
106 leal -48(%r14), %edx
107 movl %r14d, %ebx
108 cmpl $9, %edx
109 ja .L4
110 movl %edx, %r13d
111 movl $2147483647, %edi
112 movl $-1, %r8d
113 .L5:
114 movsbl 1(%rax), %r14d
115 leaq 1(%rax), %r9
116 leal -48(%r14), %edx
117 movl %r14d, %ebx
118 cmpl $9, %edx
119 ja .L4
120 testl %r13d, %r13d
121 js .L6
122 cmpl $214748364, %r13d
123 jg .L33
124 leal 0(%r13,%r13,4), %r13d
125 movl %edi, %ecx
126 subl %edx, %ecx
127 addl %r13d, %r13d
128 cmpl %ecx, %r13d
129 jg .L33
130 addl %edx, %r13d
131 .L6:
132 movq %r9, %rax
133 jmp .L5
134 .p2align 4,,10
135 .p2align 3
136 .L33:
137 movsbl 2(%rax), %r14d
138 leal -48(%r14), %edx
139 movl %r14d, %ebx
140 cmpl $9, %edx
141 ja .L22
142 movsbl 3(%rax), %r14d
143 leal -48(%r14), %edx
144 movl %r14d, %ebx
145 cmpl $9, %edx
146 ja .L22
147 movsbl 4(%rax), %r14d
148 leal -48(%r14), %edx
149 movl %r14d, %ebx
150 cmpl $9, %edx
151 ja .L22
152 movsbl 5(%rax), %r14d
153 leaq 5(%rax), %r9
154 leal -48(%r14), %eax
155 movl %r14d, %ebx
156 cmpl $9, %eax
157 ja .L22
158 movl %r8d, %r13d
159 jmp .L6
160 .p2align 4,,10
161 .p2align 3
162 .L22:
163 movl $-1, %r13d
164 jmp .L4
165 .L14:
166 call __GI_abort
167 .size strfromf, .-strfromf
168 .weak strfromf32
169 .set strfromf32,strfromf
170 .hidden __printf_fphex
171 .hidden _IO_strn_jumps