	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_utf8_unescape                  ## -- Begin function utf8_unescape
	.p2align	4, 0x90
_utf8_unescape:                         ## @utf8_unescape
	.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
	xorl	%eax, %eax
	testq	%rdi, %rdi
	je	LBB0_18
## %bb.1:
	movq	%rdx, %r15
	testq	%rdx, %rdx
	je	LBB0_18
## %bb.2:
	movq	%rcx, %r14
	movq	%rdi, %rbx
	testq	%rsi, %rsi
	jne	LBB0_4
## %bb.3:
	movq	%rbx, %rdi
	callq	_os_strlen
	movq	%rax, %rsi
LBB0_4:
	cmpb	$39, (%rbx)
	sete	%al
	testq	%rsi, %rsi
	setne	%cl
	andb	%al, %cl
	movzbl	%cl, %eax
	subq	%rax, %rsi
	je	LBB0_12
## %bb.5:
	addq	%rax, %rbx
	xorl	%eax, %eax
	jmp	LBB0_8
	.p2align	4, 0x90
LBB0_6:                                 ##   in Loop: Header=BB0_8 Depth=1
	cmpl	$39, %edi
	je	LBB0_15
LBB0_7:                                 ##   in Loop: Header=BB0_8 Depth=1
	incq	%rbx
	movb	%dl, (%r15,%rax)
	incq	%rax
	movq	%rcx, %rsi
	testq	%rcx, %rcx
	je	LBB0_14
LBB0_8:                                 ## =>This Inner Loop Header: Depth=1
	cmpq	%rax, %r14
	je	LBB0_17
## %bb.9:                               ##   in Loop: Header=BB0_8 Depth=1
	leaq	-1(%rsi), %rcx
	movzbl	(%rbx), %edx
	movsbl	%dl, %edi
	cmpl	$92, %edi
	jne	LBB0_6
## %bb.10:                              ##   in Loop: Header=BB0_8 Depth=1
	testq	%rcx, %rcx
	je	LBB0_17
## %bb.11:                              ##   in Loop: Header=BB0_8 Depth=1
	addq	$-2, %rsi
	movzbl	1(%rbx), %edx
	incq	%rbx
	movq	%rsi, %rcx
	jmp	LBB0_7
LBB0_12:
	xorl	%eax, %eax
	cmpq	%r14, %rax
	jb	LBB0_16
	jmp	LBB0_18
LBB0_17:
	xorl	%eax, %eax
	jmp	LBB0_18
LBB0_14:
	addq	%rax, %r15
	cmpq	%r14, %rax
	jb	LBB0_16
	jmp	LBB0_18
LBB0_15:
	addq	%rax, %r15
LBB0_16:
	movb	$0, (%r15)
LBB0_18:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_utf8_unescape                  ; -- Begin function utf8_unescape
	.p2align	2
_utf8_unescape:                         ; @utf8_unescape
	.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	x21, x0
	mov	x0, #0
	cbz	x21, LBB0_18
; %bb.1:
	mov	x19, x2
	cbz	x2, LBB0_18
; %bb.2:
	mov	x20, x3
	cbnz	x1, LBB0_4
; %bb.3:
	mov	x0, x21
	bl	_os_strlen
	mov	x1, x0
LBB0_4:
	ldrb	w8, [x21]
	cmp	w8, #39
	ccmp	x1, #0, #4, eq
	cset	w8, ne
	mov	x0, #0
	subs	x10, x1, x8
	b.eq	LBB0_15
; %bb.5:
	add	x8, x21, w8, uxtw
	b	LBB0_9
LBB0_6:                                 ;   in Loop: Header=BB0_9 Depth=1
	cmp	w11, #39
	b.eq	LBB0_16
; %bb.7:                                ;   in Loop: Header=BB0_9 Depth=1
	and	w10, w11, #0xff
LBB0_8:                                 ;   in Loop: Header=BB0_9 Depth=1
	add	x8, x8, #1
	strb	w10, [x19, x0]
	add	x0, x0, #1
	mov	x10, x9
	cbz	x9, LBB0_14
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	cmp	x20, x0
	b.eq	LBB0_13
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=1
	sub	x9, x10, #1
	ldrsb	w11, [x8]
	cmp	w11, #92
	b.ne	LBB0_6
; %bb.11:                               ;   in Loop: Header=BB0_9 Depth=1
	cbz	x9, LBB0_13
; %bb.12:                               ;   in Loop: Header=BB0_9 Depth=1
	sub	x9, x10, #2
	ldrb	w10, [x8, #1]!
	b	LBB0_8
LBB0_13:
	mov	x0, #0
	b	LBB0_18
LBB0_14:
	add	x19, x19, x0
LBB0_15:
	cmp	x0, x20
	b.lo	LBB0_17
	b	LBB0_18
LBB0_16:
	add	x19, x19, x0
LBB0_17:
	strb	wzr, [x19]
LBB0_18:
	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
	.cfi_endproc
                                        ; -- End function
.subsections_via_symbols
