	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function CHIN1
_CHIN1:                                 ## @CHIN1
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r15
	movq	%rdi, %r14
	movq	%rsi, %rdi
	shrq	$63, %rdi
	xorl	$1, %edi
                                        ## kill: def $edi killed $edi killed $rdi
	callq	_assert
	movq	_NC@GOTPCREL(%rip), %rax
	cmpq	%r15, (%rax)
	jle	LBB0_1
## %bb.7:
	movq	(%r14), %rax
	movq	%r15, %rcx
	sarq	$3, %rcx
	movl	(%rax,%rcx,4), %ecx
	andb	$7, %r15b
	movzbl	%r15b, %edx
	xorl	%eax, %eax
	btl	%edx, %ecx
	setb	%al
	xorl	8(%r14), %eax
	jmp	LBB0_21
LBB0_1:
	movl	12(%r14), %eax
	testl	%eax, %eax
	je	LBB0_8
## %bb.2:
	xorl	%ebx, %ebx
	jmp	LBB0_3
	.p2align	4, 0x90
LBB0_15:                                ##   in Loop: Header=BB0_3 Depth=1
	cmpq	%r15, %rdi
	je	LBB0_19
LBB0_16:                                ##   in Loop: Header=BB0_3 Depth=1
	incq	%rbx
	movl	%eax, %ecx
	cmpq	%rcx, %rbx
	jae	LBB0_8
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	cmpq	$0, 48(%r14)
	movq	16(%r14), %rcx
	movq	(%rcx,%rbx,8), %rdi
	je	LBB0_15
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=1
	callq	_towlower
	cmpq	%r15, %rax
	je	LBB0_19
## %bb.5:                               ##   in Loop: Header=BB0_3 Depth=1
	movq	16(%r14), %rax
	movq	(%rax,%rbx,8), %rdi
	callq	_towupper
	cmpq	%r15, %rax
	je	LBB0_19
## %bb.6:                               ##   in Loop: Header=BB0_3 Depth=1
	movl	12(%r14), %eax
	jmp	LBB0_16
LBB0_8:
	movl	24(%r14), %eax
	testq	%rax, %rax
	je	LBB0_13
## %bb.9:
	movq	40(%r14), %rcx
	shlq	$4, %rax
	xorl	%edx, %edx
	jmp	LBB0_10
	.p2align	4, 0x90
LBB0_12:                                ##   in Loop: Header=BB0_10 Depth=1
	addq	$16, %rdx
	cmpq	%rdx, %rax
	je	LBB0_13
LBB0_10:                                ## =>This Inner Loop Header: Depth=1
	cmpq	%r15, (%rcx,%rdx)
	jg	LBB0_12
## %bb.11:                              ##   in Loop: Header=BB0_10 Depth=1
	cmpq	%r15, 8(%rcx,%rdx)
	jl	LBB0_12
LBB0_19:
	xorl	%eax, %eax
	cmpl	$0, 8(%r14)
	sete	%al
	jmp	LBB0_21
LBB0_13:
	cmpl	$0, 28(%r14)
	je	LBB0_20
## %bb.14:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_18:                                ## =>This Inner Loop Header: Depth=1
	movq	32(%r14), %rax
	movl	(%rax,%rbx,4), %esi
	movq	%r15, %rdi
	callq	_iswctype
	testq	%rax, %rax
	jne	LBB0_19
## %bb.17:                              ##   in Loop: Header=BB0_18 Depth=1
	incq	%rbx
	movl	28(%r14), %eax
	cmpq	%rax, %rbx
	jb	LBB0_18
LBB0_20:
	movl	8(%r14), %eax
LBB0_21:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_NC,8,3                         ## @NC
	.no_dead_strip	_CHIN1
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function CHIN1
_CHIN1:                                 ; @CHIN1
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	mov	x20, x1
	mov	x19, x0
	lsr	x8, x1, #63
	eor	w0, w8, #0x1
	bl	_assert
Lloh0:
	adrp	x8, _NC@GOTPAGE
Lloh1:
	ldr	x8, [x8, _NC@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	cmp	x8, x20
	b.le	LBB0_2
; %bb.1:
	ldr	x8, [x19]
	asr	x9, x20, #3
	ldr	w8, [x8, x9, lsl #2]
	and	w9, w20, #0x7
	lsr	w8, w8, w9
	and	w8, w8, #0x1
	ldr	w9, [x19, #8]
	eor	w0, w8, w9
	b	LBB0_21
LBB0_2:
	ldr	w8, [x19, #12]
	cbz	w8, LBB0_10
; %bb.3:
	mov	x21, #0
	b	LBB0_6
LBB0_4:                                 ;   in Loop: Header=BB0_6 Depth=1
	cmp	x0, x20
	b.eq	LBB0_15
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=1
	add	x21, x21, #1
	cmp	x21, w8, uxtw
	b.hs	LBB0_10
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x9, [x19, #48]
	ldr	x10, [x19, #16]
	ldr	x0, [x10, x21, lsl #3]
	cbz	x9, LBB0_4
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	bl	_towlower
	cmp	x0, x20
	b.eq	LBB0_15
; %bb.8:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	x8, [x19, #16]
	ldr	x0, [x8, x21, lsl #3]
	bl	_towupper
	cmp	x0, x20
	b.eq	LBB0_15
; %bb.9:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	w8, [x19, #12]
	b	LBB0_5
LBB0_10:
	ldr	w8, [x19, #24]
	cbz	w8, LBB0_16
; %bb.11:
	ldr	x9, [x19, #40]
	add	x9, x9, #8
	b	LBB0_13
LBB0_12:                                ;   in Loop: Header=BB0_13 Depth=1
	add	x9, x9, #16
	subs	x8, x8, #1
	b.eq	LBB0_16
LBB0_13:                                ; =>This Inner Loop Header: Depth=1
	ldur	x10, [x9, #-8]
	cmp	x10, x20
	b.gt	LBB0_12
; %bb.14:                               ;   in Loop: Header=BB0_13 Depth=1
	ldr	x10, [x9]
	cmp	x10, x20
	b.lt	LBB0_12
LBB0_15:
	ldr	w8, [x19, #8]
	cmp	w8, #0
	cset	w0, eq
	b	LBB0_21
LBB0_16:
	ldr	w8, [x19, #28]
	cbz	w8, LBB0_20
; %bb.17:
	mov	x21, #0
LBB0_18:                                ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #32]
	ldr	w1, [x8, x21, lsl #2]
	mov	x0, x20
	bl	_iswctype
	cbnz	x0, LBB0_15
; %bb.19:                               ;   in Loop: Header=BB0_18 Depth=1
	add	x21, x21, #1
	ldr	w8, [x19, #28]
	cmp	x21, x8
	b.lo	LBB0_18
LBB0_20:
	ldr	w0, [x19, #8]
LBB0_21:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_NC,8,3                         ; @NC
	.no_dead_strip	_CHIN1
.subsections_via_symbols
