	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	___wcsnrtombs_std               ## -- Begin function __wcsnrtombs_std
	.p2align	4, 0x90
___wcsnrtombs_std:                      ## @__wcsnrtombs_std
	.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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%r9, -88(%rbp)                  ## 8-byte Spill
	movq	%r8, %r14
	movq	%rcx, -72(%rbp)                 ## 8-byte Spill
	movq	%rdx, -64(%rbp)                 ## 8-byte Spill
	movq	%rsi, %rbx
	movq	%rdi, %r13
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	_MB_LEN_MAX@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	callq	____chkstk_darwin
	addq	$15, %rax
	andq	$-16, %rax
	subq	%rax, %rsp
	movq	%rsp, -80(%rbp)                 ## 8-byte Spill
	movq	(%rbx), %r12
	testq	%r13, %r13
	je	LBB0_3
## %bb.1:
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	movq	-64(%rbp), %rbx                 ## 8-byte Reload
	movq	-72(%rbp), %rax                 ## 8-byte Reload
	testq	%rax, %rax
	je	LBB0_2
## %bb.11:
	movq	%r13, %r15
	xorl	%r13d, %r13d
	movq	%r14, -96(%rbp)                 ## 8-byte Spill
	.p2align	4, 0x90
LBB0_12:                                ## =>This Inner Loop Header: Depth=1
	subq	$1, %rbx
	jb	LBB0_23
## %bb.13:                              ##   in Loop: Header=BB0_12 Depth=1
	movq	%rax, -72(%rbp)                 ## 8-byte Spill
	movq	_MB_CUR_MAX@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jbe	LBB0_16
## %bb.14:                              ##   in Loop: Header=BB0_12 Depth=1
	movl	(%r12), %esi
	movq	%r15, %rdi
	movq	%r14, %rdx
	callq	*-88(%rbp)                      ## 8-byte Folded Reload
	movq	%rax, %r14
	cmpq	$-1, %rax
	je	LBB0_15
## %bb.20:                              ##   in Loop: Header=BB0_12 Depth=1
	cmpl	$0, (%r12)
	jne	LBB0_22
	jmp	LBB0_21
	.p2align	4, 0x90
LBB0_16:                                ##   in Loop: Header=BB0_12 Depth=1
	movl	(%r14), %eax
	movl	%eax, -64(%rbp)                 ## 4-byte Spill
	movl	(%r12), %esi
	movq	-80(%rbp), %rdi                 ## 8-byte Reload
	movq	%r14, %rdx
	callq	*-88(%rbp)                      ## 8-byte Folded Reload
	cmpq	$-1, %rax
	je	LBB0_15
## %bb.17:                              ##   in Loop: Header=BB0_12 Depth=1
	movq	%rax, %r14
	movslq	-72(%rbp), %rax                 ## 4-byte Folded Reload
	cmpq	%rax, %r14
	ja	LBB0_18
## %bb.19:                              ##   in Loop: Header=BB0_12 Depth=1
	movq	%r15, %rdi
	movq	-80(%rbp), %rsi                 ## 8-byte Reload
	movq	%r14, %rdx
	callq	_memcpy
	cmpl	$0, (%r12)
	je	LBB0_21
LBB0_22:                                ##   in Loop: Header=BB0_12 Depth=1
	addq	$4, %r12
	addq	%r14, %r15
	addq	%r14, %r13
	movq	-72(%rbp), %rax                 ## 8-byte Reload
	subq	%r14, %rax
	movq	-96(%rbp), %r14                 ## 8-byte Reload
	jne	LBB0_12
	jmp	LBB0_23
LBB0_3:
	movq	-64(%rbp), %r15                 ## 8-byte Reload
	testq	%r15, %r15
	je	LBB0_4
## %bb.5:
	xorl	%ebx, %ebx
	xorl	%r13d, %r13d
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r12,%rbx,4), %esi
	movq	-80(%rbp), %rdi                 ## 8-byte Reload
	movq	%r14, %rdx
	callq	*-88(%rbp)                      ## 8-byte Folded Reload
	cmpq	$-1, %rax
	je	LBB0_7
## %bb.8:                               ##   in Loop: Header=BB0_6 Depth=1
	cmpl	$0, (%r12,%rbx,4)
	je	LBB0_9
## %bb.10:                              ##   in Loop: Header=BB0_6 Depth=1
	addq	%rax, %r13
	incq	%rbx
	cmpq	%rbx, %r15
	jne	LBB0_6
	jmp	LBB0_24
LBB0_2:
	xorl	%r13d, %r13d
LBB0_23:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	%r12, (%rax)
	jmp	LBB0_24
LBB0_4:
	xorl	%r13d, %r13d
	jmp	LBB0_24
LBB0_15:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	%r12, (%rax)
	movq	$-1, %r13
	jmp	LBB0_24
LBB0_21:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movq	$0, (%rax)
	addq	%r14, %r13
	decq	%r13
	jmp	LBB0_24
LBB0_7:
	movq	$-1, %r13
	jmp	LBB0_24
LBB0_9:
	addq	%rax, %r13
	decq	%r13
LBB0_24:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_26
## %bb.25:
	movq	%r13, %rax
	leaq	-40(%rbp), %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_18:
	movq	-96(%rbp), %rax                 ## 8-byte Reload
	movl	-64(%rbp), %ecx                 ## 4-byte Reload
	movl	%ecx, (%rax)
	jmp	LBB0_23
LBB0_26:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_MB_LEN_MAX,4,2                 ## @MB_LEN_MAX
	.comm	_MB_CUR_MAX,8,3                 ## @MB_CUR_MAX
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	___wcsnrtombs_std               ; -- Begin function __wcsnrtombs_std
	.p2align	2
___wcsnrtombs_std:                      ; @__wcsnrtombs_std
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	sub	sp, sp, #32
	mov	x27, x5
	mov	x20, x4
	mov	x25, x3
	mov	x22, x2
	mov	x26, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-88]
Lloh3:
	adrp	x8, _MB_LEN_MAX@GOTPAGE
Lloh4:
	ldr	x8, [x8, _MB_LEN_MAX@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	mov	x9, x8
Lloh6:
	adrp	x16, ___chkstk_darwin@GOTPAGE
Lloh7:
	ldr	x16, [x16, ___chkstk_darwin@GOTPAGEOFF]
	blr	x16
	mov	x9, sp
	add	x8, x8, #15
	and	x8, x8, #0x1fffffff0
	sub	x23, x9, x8
	mov	sp, x23
	ldr	x28, [x1]
	cbz	x0, LBB0_11
; %bb.1:
	stur	x1, [x29, #-104]                ; 8-byte Folded Spill
	mov	x19, #0
	cbz	x25, LBB0_20
; %bb.2:
Lloh8:
	adrp	x24, _MB_CUR_MAX@GOTPAGE
Lloh9:
	ldr	x24, [x24, _MB_CUR_MAX@GOTPAGEOFF]
	stur	x27, [x29, #-96]                ; 8-byte Folded Spill
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	cbz	x22, LBB0_20
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	x8, [x24]
	cmp	x25, x8
	b.ls	LBB0_7
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w1, [x28]
	mov	x0, x26
	mov	x2, x20
	blr	x27
	mov	x27, x0
	cmn	x0, #1
	b.eq	LBB0_15
; %bb.6:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w8, [x28]
	cbnz	w8, LBB0_10
	b	LBB0_16
LBB0_7:                                 ;   in Loop: Header=BB0_3 Depth=1
	ldr	w21, [x20]
	ldr	w1, [x28]
	mov	x0, x23
	mov	x2, x20
	blr	x27
	cmn	x0, #1
	b.eq	LBB0_15
; %bb.8:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x27, x0
	cmp	x0, w25, sxtw
	b.hi	LBB0_19
; %bb.9:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x0, x26
	mov	x1, x23
	mov	x2, x27
	bl	_memcpy
	ldr	w8, [x28]
	cbz	w8, LBB0_16
LBB0_10:                                ;   in Loop: Header=BB0_3 Depth=1
	add	x28, x28, #4
	add	x26, x26, x27
	add	x19, x27, x19
	sub	x22, x22, #1
	sub	x25, x25, x27
	ldur	x27, [x29, #-96]                ; 8-byte Folded Reload
	cbnz	x25, LBB0_3
	b	LBB0_20
LBB0_11:
	mov	x19, #0
	cbz	x22, LBB0_21
LBB0_12:                                ; =>This Inner Loop Header: Depth=1
	ldr	w1, [x28]
	mov	x0, x23
	mov	x2, x20
	blr	x27
	cmn	x0, #1
	b.eq	LBB0_17
; %bb.13:                               ;   in Loop: Header=BB0_12 Depth=1
	ldr	w8, [x28]
	cbz	w8, LBB0_18
; %bb.14:                               ;   in Loop: Header=BB0_12 Depth=1
	add	x28, x28, #4
	add	x19, x0, x19
	sub	x22, x22, #1
	cbnz	x22, LBB0_12
	b	LBB0_21
LBB0_15:
	ldur	x8, [x29, #-104]                ; 8-byte Folded Reload
	str	x28, [x8]
	mov	x19, #-1
	b	LBB0_21
LBB0_16:
	ldur	x8, [x29, #-104]                ; 8-byte Folded Reload
	str	xzr, [x8]
	add	x8, x27, x19
	sub	x19, x8, #1
	b	LBB0_21
LBB0_17:
	mov	x19, #-1
	b	LBB0_21
LBB0_18:
	add	x8, x0, x19
	sub	x19, x8, #1
	b	LBB0_21
LBB0_19:
	str	w21, [x20]
LBB0_20:
	ldur	x8, [x29, #-104]                ; 8-byte Folded Reload
	str	x28, [x8]
LBB0_21:
	ldur	x8, [x29, #-88]
Lloh10:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh11:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh12:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_23
; %bb.22:
	mov	x0, x19
	sub	sp, x29, #80
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	ret
LBB0_23:
	bl	___stack_chk_fail
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_MB_LEN_MAX,4,2                 ; @MB_LEN_MAX
	.comm	_MB_CUR_MAX,8,3                 ; @MB_CUR_MAX
.subsections_via_symbols
