	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function h_mbtowc
_h_mbtowc:                              ## @h_mbtowc
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%r15
	pushq	%r14
	pushq	%r13
	pushq	%r12
	pushq	%rbx
	subq	$72, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r14
	movq	%rsi, %r15
	movq	%rdi, %r12
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_LC_ALL@GOTPCREL(%rip), %r13
	movl	(%r13), %edi
	leaq	L_.str(%rip), %rbx
	movq	%rbx, %rsi
	callq	_setlocale
	movq	%rax, %rdi
	movq	%rbx, %rsi
	callq	_ATF_REQUIRE_STREQ
	movq	_LC_CTYPE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	%r12, %rsi
	callq	_setlocale
	testq	%rax, %rax
	je	LBB0_1
## %bb.3:
	movl	(%r13), %edi
	xorl	%esi, %esi
	callq	_setlocale
	movq	%rax, %rbx
	xorl	%edi, %edi
	testq	%rax, %rax
	setne	%dil
	callq	_ATF_REQUIRE
	leaq	L_.str.2(%rip), %rdi
	movq	%rbx, %rsi
	xorl	%eax, %eax
	callq	_printf
	xorl	%edi, %edi
	xorl	%esi, %esi
	callq	_wctomb
	movq	%rax, %r12
	testq	%rax, %rax
	leaq	L_.str.5(%rip), %rax
	leaq	L_.str.4(%rip), %rsi
	cmoveq	%rax, %rsi
	leaq	L_.str.3(%rip), %rdi
	xorl	%eax, %eax
	callq	_printf
	xorl	%edi, %edi
	xorl	%esi, %esi
	xorl	%edx, %edx
	callq	_mbtowc
	xorl	%edi, %edi
	testq	%rax, %rax
	sete	%dil
	testq	%r12, %r12
	cmovnel	%eax, %edi
	callq	_ATF_REQUIRE
	movq	_VIS_WHITE@GOTPCREL(%rip), %rax
	movq	_VIS_OCTAL@GOTPCREL(%rip), %r13
	movl	(%r13), %edx
	orl	(%rax), %edx
	leaq	-112(%rbp), %rbx
	movq	%rbx, %rdi
	movq	%r15, %rsi
	callq	_strvis
	leaq	L_.str.6(%rip), %rdi
	movq	%rbx, %rsi
	xorl	%eax, %eax
	callq	_printf
	movq	%r15, %rdi
	callq	_strlen
	xorl	%edi, %edi
	movq	%r15, %rsi
	movl	%eax, %edx
	callq	_mbtowc
	movq	%rax, %rbx
	leaq	L_.str.7(%rip), %rdi
	movq	%rax, %rsi
	xorl	%eax, %eax
	callq	_printf
	movq	%rbx, %rdi
	movq	$-1, %rsi
	callq	_ATF_REQUIRE_EQ
	movq	_errno@GOTPCREL(%rip), %r15
	movq	(%r15), %rdi
	callq	_strerror
	leaq	L_.str.8(%rip), %rdi
	movq	%rax, %rsi
	xorl	%eax, %eax
	callq	_printf
	movq	(%r15), %rdi
	movq	_EILSEQ@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	callq	_ATF_REQUIRE_EQ
	testq	%r12, %r12
	je	LBB0_5
## %bb.4:
	xorl	%edi, %edi
	xorl	%esi, %esi
	xorl	%edx, %edx
	callq	_mbtowc
	movl	%eax, %edi
	callq	_ATF_REQUIRE
LBB0_5:
	movl	(%r13), %edx
	movq	_VIS_WHITE@GOTPCREL(%rip), %rax
	orl	(%rax), %edx
	leaq	-112(%rbp), %rbx
	movq	%rbx, %rdi
	movq	%r14, %rsi
	callq	_strvis
	leaq	L_.str.9(%rip), %rdi
	movq	%rbx, %rsi
	xorl	%eax, %eax
	callq	_printf
	movq	$0, (%r15)
	movq	%r14, %rdi
	callq	_strlen
	xorl	%edi, %edi
	movq	%r14, %rsi
	movl	%eax, %edx
	callq	_mbtowc
	movq	%rax, %rbx
	leaq	L_.str.7(%rip), %rdi
	movq	%rax, %rsi
	xorl	%eax, %eax
	callq	_printf
	xorl	%edi, %edi
	cmpq	$-1, %rbx
	setne	%dil
	callq	_ATF_REQUIRE
	movq	(%r15), %rdi
	callq	_strerror
	leaq	L_.str.8(%rip), %rdi
	movq	%rax, %rsi
	xorl	%eax, %eax
	callq	_printf
	movq	(%r15), %rdi
	xorl	%esi, %esi
	callq	_ATF_REQUIRE_EQ
	leaq	L_str(%rip), %rdi
	callq	_puts
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_7
## %bb.6:
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_7
## %bb.2:
	leaq	L_.str.1(%rip), %rsi
	movq	%r12, %rdx
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_fprintf                        ## TAILCALL
LBB0_7:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_LC_ALL,4,2                     ## @LC_ALL
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"C"

	.comm	_LC_CTYPE,4,2                   ## @LC_CTYPE
	.comm	_stderr,4,2                     ## @stderr
L_.str.1:                               ## @.str.1
	.asciz	"Locale %s not found.\n"

L_.str.2:                               ## @.str.2
	.asciz	"Using locale: %s\n"

L_.str.3:                               ## @.str.3
	.asciz	"Locale is state-%sdependent\n"

L_.str.4:                               ## @.str.4
	.asciz	"in"

L_.str.5:                               ## @.str.5
	.space	1

	.comm	_VIS_WHITE,4,2                  ## @VIS_WHITE
	.comm	_VIS_OCTAL,4,2                  ## @VIS_OCTAL
L_.str.6:                               ## @.str.6
	.asciz	"Checking illegal sequence: \"%s\"\n"

L_.str.7:                               ## @.str.7
	.asciz	"mbtowc() returned: %zd\n"

L_.str.8:                               ## @.str.8
	.asciz	"errno: %s\n"

	.comm	_errno,8,3                      ## @errno
	.comm	_EILSEQ,8,3                     ## @EILSEQ
L_.str.9:                               ## @.str.9
	.asciz	"Checking legal sequence: \"%s\"\n"

L_str:                                  ## @str
	.asciz	"Ok."

	.no_dead_strip	_h_mbtowc
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function h_mbtowc
_h_mbtowc:                              ; @h_mbtowc
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #144
	.cfi_def_cfa_offset 144
	stp	x24, x23, [sp, #80]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #96]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #112]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #128]            ; 16-byte Folded Spill
	add	x29, sp, #128
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	.cfi_offset w23, -56
	.cfi_offset w24, -64
	mov	x19, x2
	mov	x20, x1
	mov	x21, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-56]
Lloh3:
	adrp	x23, _LC_ALL@GOTPAGE
Lloh4:
	ldr	x23, [x23, _LC_ALL@GOTPAGEOFF]
	ldr	w0, [x23]
Lloh5:
	adrp	x22, l_.str@PAGE
Lloh6:
	add	x22, x22, l_.str@PAGEOFF
	mov	x1, x22
	bl	_setlocale
	mov	x1, x22
	bl	_ATF_REQUIRE_STREQ
Lloh7:
	adrp	x8, _LC_CTYPE@GOTPAGE
Lloh8:
	ldr	x8, [x8, _LC_CTYPE@GOTPAGEOFF]
Lloh9:
	ldr	w0, [x8]
	mov	x1, x21
	bl	_setlocale
	cbz	x0, LBB0_5
; %bb.1:
	ldr	w0, [x23]
	mov	x1, #0
	bl	_setlocale
	mov	x21, x0
	cmp	x0, #0
	cset	w0, ne
	bl	_ATF_REQUIRE
	str	x21, [sp]
Lloh10:
	adrp	x0, l_.str.2@PAGE
Lloh11:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_printf
	mov	x0, #0
	mov	w1, #0
	bl	_wctomb
	mov	x21, x0
Lloh12:
	adrp	x8, l_.str.4@PAGE
Lloh13:
	add	x8, x8, l_.str.4@PAGEOFF
Lloh14:
	adrp	x9, l_.str.5@PAGE
Lloh15:
	add	x9, x9, l_.str.5@PAGEOFF
	cmp	x0, #0
	csel	x8, x9, x8, eq
	str	x8, [sp]
Lloh16:
	adrp	x0, l_.str.3@PAGE
Lloh17:
	add	x0, x0, l_.str.3@PAGEOFF
	bl	_printf
	mov	x0, #0
	mov	x1, #0
	mov	w2, #0
	bl	_mbtowc
	cmp	x0, #0
	cset	w8, eq
	cmp	x21, #0
	csel	w0, w8, w0, eq
	bl	_ATF_REQUIRE
Lloh18:
	adrp	x23, _VIS_WHITE@GOTPAGE
Lloh19:
	ldr	x23, [x23, _VIS_WHITE@GOTPAGEOFF]
	ldr	w8, [x23]
Lloh20:
	adrp	x24, _VIS_OCTAL@GOTPAGE
Lloh21:
	ldr	x24, [x24, _VIS_OCTAL@GOTPAGEOFF]
	ldr	w9, [x24]
	orr	w2, w9, w8
	add	x22, sp, #8
	add	x0, sp, #8
	mov	x1, x20
	bl	_strvis
	str	x22, [sp]
Lloh22:
	adrp	x0, l_.str.6@PAGE
Lloh23:
	add	x0, x0, l_.str.6@PAGEOFF
	bl	_printf
	mov	x0, x20
	bl	_strlen
	mov	x2, x0
	mov	x0, #0
	mov	x1, x20
	bl	_mbtowc
	mov	x20, x0
	str	x0, [sp]
Lloh24:
	adrp	x0, l_.str.7@PAGE
Lloh25:
	add	x0, x0, l_.str.7@PAGEOFF
	bl	_printf
	mov	x0, x20
	mov	x1, #-1
	bl	_ATF_REQUIRE_EQ
Lloh26:
	adrp	x20, _errno@GOTPAGE
Lloh27:
	ldr	x20, [x20, _errno@GOTPAGEOFF]
	ldr	x0, [x20]
	bl	_strerror
	str	x0, [sp]
Lloh28:
	adrp	x0, l_.str.8@PAGE
Lloh29:
	add	x0, x0, l_.str.8@PAGEOFF
	bl	_printf
	ldr	x0, [x20]
Lloh30:
	adrp	x8, _EILSEQ@GOTPAGE
Lloh31:
	ldr	x8, [x8, _EILSEQ@GOTPAGEOFF]
Lloh32:
	ldr	x1, [x8]
	bl	_ATF_REQUIRE_EQ
	cbz	x21, LBB0_3
; %bb.2:
	mov	x0, #0
	mov	x1, #0
	mov	w2, #0
	bl	_mbtowc
                                        ; kill: def $w0 killed $w0 killed $x0
	bl	_ATF_REQUIRE
LBB0_3:
	ldr	w8, [x23]
	ldr	w9, [x24]
	orr	w2, w9, w8
	add	x0, sp, #8
	mov	x1, x19
	bl	_strvis
	str	x22, [sp]
Lloh33:
	adrp	x0, l_.str.9@PAGE
Lloh34:
	add	x0, x0, l_.str.9@PAGEOFF
	bl	_printf
	str	xzr, [x20]
	mov	x0, x19
	bl	_strlen
	mov	x2, x0
	mov	x0, #0
	mov	x1, x19
	bl	_mbtowc
	mov	x19, x0
	str	x0, [sp]
Lloh35:
	adrp	x0, l_.str.7@PAGE
Lloh36:
	add	x0, x0, l_.str.7@PAGEOFF
	bl	_printf
	cmn	x19, #1
	cset	w0, ne
	bl	_ATF_REQUIRE
	ldr	x0, [x20]
	bl	_strerror
	str	x0, [sp]
Lloh37:
	adrp	x0, l_.str.8@PAGE
Lloh38:
	add	x0, x0, l_.str.8@PAGEOFF
	bl	_printf
	ldr	x0, [x20]
	mov	x1, #0
	bl	_ATF_REQUIRE_EQ
Lloh39:
	adrp	x0, l_str@PAGE
Lloh40:
	add	x0, x0, l_str@PAGEOFF
	bl	_puts
	ldur	x8, [x29, #-56]
Lloh41:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh42:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh43:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_7
; %bb.4:
	ldp	x29, x30, [sp, #128]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #112]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #96]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #80]             ; 16-byte Folded Reload
	add	sp, sp, #144
	ret
LBB0_5:
Lloh44:
	adrp	x8, _stderr@GOTPAGE
Lloh45:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh46:
	ldr	w0, [x8]
	ldur	x8, [x29, #-56]
Lloh47:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh48:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh49:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_7
; %bb.6:
Lloh50:
	adrp	x1, l_.str.1@PAGE
Lloh51:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x2, x21
	ldp	x29, x30, [sp, #128]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #112]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #96]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #80]             ; 16-byte Folded Reload
	add	sp, sp, #144
	b	_fprintf
LBB0_7:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpAdd	Lloh28, Lloh29
	.loh AdrpLdrGot	Lloh26, Lloh27
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh41, Lloh42, Lloh43
	.loh AdrpAdd	Lloh39, Lloh40
	.loh AdrpAdd	Lloh37, Lloh38
	.loh AdrpAdd	Lloh35, Lloh36
	.loh AdrpAdd	Lloh33, Lloh34
	.loh AdrpLdrGotLdr	Lloh47, Lloh48, Lloh49
	.loh AdrpLdrGotLdr	Lloh44, Lloh45, Lloh46
	.loh AdrpAdd	Lloh50, Lloh51
	.cfi_endproc
                                        ; -- End function
	.comm	_LC_ALL,4,2                     ; @LC_ALL
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"C"

	.comm	_LC_CTYPE,4,2                   ; @LC_CTYPE
	.comm	_stderr,4,2                     ; @stderr
l_.str.1:                               ; @.str.1
	.asciz	"Locale %s not found.\n"

l_.str.2:                               ; @.str.2
	.asciz	"Using locale: %s\n"

l_.str.3:                               ; @.str.3
	.asciz	"Locale is state-%sdependent\n"

l_.str.4:                               ; @.str.4
	.asciz	"in"

l_.str.5:                               ; @.str.5
	.space	1

	.comm	_VIS_WHITE,4,2                  ; @VIS_WHITE
	.comm	_VIS_OCTAL,4,2                  ; @VIS_OCTAL
l_.str.6:                               ; @.str.6
	.asciz	"Checking illegal sequence: \"%s\"\n"

l_.str.7:                               ; @.str.7
	.asciz	"mbtowc() returned: %zd\n"

l_.str.8:                               ; @.str.8
	.asciz	"errno: %s\n"

	.comm	_errno,8,3                      ; @errno
	.comm	_EILSEQ,8,3                     ; @EILSEQ
l_.str.9:                               ; @.str.9
	.asciz	"Checking legal sequence: \"%s\"\n"

l_str:                                  ; @str
	.asciz	"Ok."

	.no_dead_strip	_h_mbtowc
.subsections_via_symbols
