clarify the purpose of this project
[nyanglibc.git] / debug / wctomb_chk.s
blobf887d9314d3377742935fba7f7559adaa6e10a74
1 .text
2 .p2align 4,,15
3 .globl __wctomb_chk
4 .type __wctomb_chk, @function
5 __wctomb_chk:
6 subq $8, %rsp
7 movq _nl_current_LC_CTYPE@gottpoff(%rip), %rax
8 movq %fs:(%rax), %rax
9 movq (%rax), %rax
10 movl 168(%rax), %eax
11 cmpq %rdx, %rax
12 ja .L5
13 leaq __wctomb_state(%rip), %rdx
14 call __wcrtomb
15 addq $8, %rsp
16 ret
17 .L5:
18 call __chk_fail
19 .size __wctomb_chk, .-__wctomb_chk
20 .hidden __chk_fail
21 .hidden __wcrtomb
22 .hidden __wctomb_state
23 .hidden _nl_current_LC_CTYPE