	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function tr_parse_pattern
_tr_parse_pattern:                      ## @tr_parse_pattern
	.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	%rcx, %r15
	movl	%edx, %ebx
	movq	%rsi, %r14
	movq	%rdi, -48(%rbp)                 ## 8-byte Spill
	movl	%edx, %edi
	callq	_RSTRING_PTR
	movq	%rax, %r12
	movl	%ebx, %edi
	callq	_RSTRING_LEN
	movl	%eax, %ebx
	movq	_FALSE@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	xorl	%edx, %edx
	testq	%r15, %r15
	je	LBB0_5
## %bb.1:
	cmpl	$2, %ebx
	jl	LBB0_5
## %bb.2:
	xorl	%edx, %edx
	cmpb	$94, (%r12)
	sete	%al
	jne	LBB0_4
## %bb.3:
	movq	_TRUE@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	%rcx, -56(%rbp)                 ## 8-byte Spill
LBB0_4:
	movb	%al, %dl
LBB0_5:
	movq	%r14, %r8
	cmpl	%ebx, %edx
	jge	LBB0_34
## %bb.6:
	movslq	%ebx, %r13
	movq	%r12, -64(%rbp)                 ## 8-byte Spill
	jmp	LBB0_9
	.p2align	4, 0x90
LBB0_7:                                 ##   in Loop: Header=BB0_9 Depth=1
	movq	%r15, %r8
	cmpl	%ebx, %edx
	jge	LBB0_34
LBB0_9:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_19 Depth 2
                                        ##     Child Loop BB0_30 Depth 2
	movq	(%r8), %rdi
	movq	_TR_UNINITIALIZED@GOTPCREL(%rip), %rax
	movq	(%rax), %r9
	movq	%r8, %r15
	cmpq	%r9, %rdi
	movq	%rdi, -80(%rbp)                 ## 8-byte Spill
	movq	%r9, -72(%rbp)                  ## 8-byte Spill
	je	LBB0_11
## %bb.10:                              ##   in Loop: Header=BB0_9 Depth=1
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movl	$48, %esi
	movq	%r8, %r14
	movq	%rdx, %r15
	callq	_mrb_malloc_simple
	movq	-72(%rbp), %r9                  ## 8-byte Reload
	movq	-80(%rbp), %rdi                 ## 8-byte Reload
	movq	%r15, %rdx
	movq	%r14, %r8
	movq	%rax, %r15
LBB0_11:                                ##   in Loop: Header=BB0_9 Depth=1
	movslq	%edx, %rax
	leaq	2(%rax), %rcx
	cmpl	%ebx, %ecx
	jge	LBB0_16
## %bb.12:                              ##   in Loop: Header=BB0_9 Depth=1
	cmpb	$92, (%r12,%rax)
	je	LBB0_16
## %bb.13:                              ##   in Loop: Header=BB0_9 Depth=1
	cmpb	$45, 1(%rax,%r12)
	jne	LBB0_16
## %bb.14:                              ##   in Loop: Header=BB0_9 Depth=1
	testq	%r15, %r15
	je	LBB0_33
## %bb.15:                              ##   in Loop: Header=BB0_9 Depth=1
	xorl	%edx, %edx
	cmpq	%r9, %rdi
	setne	%dl
	movq	_TR_RANGE@GOTPCREL(%rip), %rsi
	movq	(%rsi), %rsi
	movq	%rsi, (%r15)
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	movq	%rsi, 40(%r15)
	movl	%edx, 8(%r15)
	movq	-64(%rbp), %r12                 ## 8-byte Reload
	movb	(%r12,%rcx), %dl
	subb	(%r12,%rax), %dl
	incb	%dl
	movb	%dl, 12(%r15)
	movq	$0, 16(%r15)
	movb	(%r12,%rax), %dl
	movq	24(%r15), %rsi
	movb	%dl, (%rsi)
	movb	(%r12,%rcx), %cl
	movq	24(%r15), %rdx
	movb	%cl, 1(%rdx)
	addl	$3, %eax
	movl	%eax, %edx
	testq	%r8, %r8
	jne	LBB0_28
	jmp	LBB0_7
	.p2align	4, 0x90
LBB0_16:                                ##   in Loop: Header=BB0_9 Depth=1
	leal	1(%rdx), %r14d
	cmpl	%ebx, %r14d
	jge	LBB0_23
## %bb.17:                              ##   in Loop: Header=BB0_9 Depth=1
	movslq	%r14d, %r14
	jmp	LBB0_19
	.p2align	4, 0x90
LBB0_18:                                ##   in Loop: Header=BB0_19 Depth=2
	incq	%r14
	cmpq	%r14, %r13
	je	LBB0_22
LBB0_19:                                ##   Parent Loop BB0_9 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	leal	2(%r14), %eax
	cmpl	%ebx, %eax
	jge	LBB0_18
## %bb.20:                              ##   in Loop: Header=BB0_19 Depth=2
	cmpb	$92, (%r12,%r14)
	je	LBB0_18
## %bb.21:                              ##   in Loop: Header=BB0_19 Depth=2
	leal	1(%r14), %eax
	cltq
	cmpb	$45, (%r12,%rax)
	jne	LBB0_18
	jmp	LBB0_23
	.p2align	4, 0x90
LBB0_22:                                ##   in Loop: Header=BB0_9 Depth=1
	movl	%ebx, %r14d
LBB0_23:                                ##   in Loop: Header=BB0_9 Depth=1
	movl	%r14d, %r12d
	subl	%edx, %r12d
	movq	_UINT16_MAX@GOTPCREL(%rip), %rax
	cmpl	(%rax), %r12d
	jle	LBB0_25
## %bb.24:                              ##   in Loop: Header=BB0_9 Depth=1
	movq	_E_ARGUMENT_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movq	%rdx, -88(%rbp)                 ## 8-byte Spill
	leaq	L_.str(%rip), %rdx
	movq	%r8, -96(%rbp)                  ## 8-byte Spill
	callq	_mrb_raise
	movq	-72(%rbp), %r9                  ## 8-byte Reload
	movq	-80(%rbp), %rdi                 ## 8-byte Reload
	movq	-88(%rbp), %rdx                 ## 8-byte Reload
	movq	-96(%rbp), %r8                  ## 8-byte Reload
LBB0_25:                                ##   in Loop: Header=BB0_9 Depth=1
	testq	%r15, %r15
	jne	LBB0_27
## %bb.26:                              ##   in Loop: Header=BB0_9 Depth=1
	testq	%r8, %r8
	jne	LBB0_33
LBB0_27:                                ##   in Loop: Header=BB0_9 Depth=1
	xorl	%eax, %eax
	cmpq	%r9, %rdi
	setne	%al
	movq	_TR_IN_ORDER@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	%rcx, (%r15)
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
	movq	%rcx, 40(%r15)
	movl	%eax, 8(%r15)
	movb	%r12b, 12(%r15)
	movq	$0, 16(%r15)
	movl	%edx, 32(%r15)
	movl	%r14d, %edx
	movq	-64(%rbp), %r12                 ## 8-byte Reload
	testq	%r8, %r8
	je	LBB0_7
LBB0_28:                                ##   in Loop: Header=BB0_9 Depth=1
	cmpq	%r9, %rdi
	je	LBB0_7
## %bb.29:                              ##   in Loop: Header=BB0_9 Depth=1
	movq	%r8, %rcx
	.p2align	4, 0x90
LBB0_30:                                ##   Parent Loop BB0_9 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movq	%rcx, %rax
	movq	16(%rcx), %rcx
	testq	%rcx, %rcx
	jne	LBB0_30
## %bb.31:                              ##   in Loop: Header=BB0_9 Depth=1
	movq	%r15, 16(%rax)
	cmpl	%ebx, %edx
	jl	LBB0_9
	jmp	LBB0_34
LBB0_33:
	movq	-48(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rdi
	movq	%r8, %rsi
	callq	_tr_free_pattern
	movl	(%rbx), %edi
	callq	_mrb_obj_value
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_mrb_exc_raise
	xorl	%r8d, %r8d
LBB0_34:
	movq	%r8, %rax
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_FALSE,8,3                      ## @FALSE
	.comm	_TRUE,8,3                       ## @TRUE
	.comm	_TR_UNINITIALIZED,8,3           ## @TR_UNINITIALIZED
	.comm	_TR_RANGE,8,3                   ## @TR_RANGE
	.comm	_UINT16_MAX,4,2                 ## @UINT16_MAX
	.comm	_E_ARGUMENT_ERROR,4,2           ## @E_ARGUMENT_ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"tr pattern too long (max 65536)"

	.comm	_TR_IN_ORDER,8,3                ## @TR_IN_ORDER
	.no_dead_strip	_tr_parse_pattern
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function tr_parse_pattern
_tr_parse_pattern:                      ; @tr_parse_pattern
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	mov	x23, x3
	mov	x22, x2
	mov	x20, x1
	str	x0, [sp, #8]                    ; 8-byte Folded Spill
	mov	x0, x2
	bl	_RSTRING_PTR
	mov	x21, x0
	mov	x0, x22
	bl	_RSTRING_LEN
	mov	x22, x0
	mov	w28, #0
Lloh0:
	adrp	x8, _FALSE@GOTPAGE
Lloh1:
	ldr	x8, [x8, _FALSE@GOTPAGEOFF]
Lloh2:
	ldr	x25, [x8]
	cbz	x23, LBB0_3
; %bb.1:
	cmp	w22, #2
	b.lt	LBB0_3
; %bb.2:
	ldrb	w8, [x21]
	cmp	w8, #94
	cset	w28, eq
Lloh3:
	adrp	x8, _TRUE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _TRUE@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	csel	x25, x8, x25, eq
LBB0_3:
	cmp	w28, w22
	b.ge	LBB0_30
; %bb.4:
	sxtw	x8, w22
	str	x8, [sp]                        ; 8-byte Folded Spill
	b	LBB0_6
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=1
	mov	x20, x24
	cmp	w28, w22
	b.ge	LBB0_30
LBB0_6:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_16 Depth 2
                                        ;     Child Loop BB0_27 Depth 2
	ldr	x23, [x20]
Lloh6:
	adrp	x8, _TR_UNINITIALIZED@GOTPAGE
Lloh7:
	ldr	x8, [x8, _TR_UNINITIALIZED@GOTPAGEOFF]
Lloh8:
	ldr	x27, [x8]
	mov	x24, x20
	cmp	x23, x27
	b.eq	LBB0_8
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	x0, [sp, #8]                    ; 8-byte Folded Reload
	mov	w1, #48
	bl	_mrb_malloc_simple
	mov	x24, x0
LBB0_8:                                 ;   in Loop: Header=BB0_6 Depth=1
	sxtw	x9, w28
	add	x8, x9, #2
	cmp	w8, w22
	b.ge	LBB0_13
; %bb.9:                                ;   in Loop: Header=BB0_6 Depth=1
	ldrb	w10, [x21, x9]
	cmp	w10, #92
	b.eq	LBB0_13
; %bb.10:                               ;   in Loop: Header=BB0_6 Depth=1
	add	x10, x9, x21
	ldrb	w10, [x10, #1]
	cmp	w10, #45
	b.ne	LBB0_13
; %bb.11:                               ;   in Loop: Header=BB0_6 Depth=1
	cbz	x24, LBB0_29
; %bb.12:                               ;   in Loop: Header=BB0_6 Depth=1
	cmp	x23, x27
	cset	w10, ne
Lloh9:
	adrp	x11, _TR_RANGE@GOTPAGE
Lloh10:
	ldr	x11, [x11, _TR_RANGE@GOTPAGEOFF]
Lloh11:
	ldr	x11, [x11]
	str	x11, [x24]
	str	x25, [x24, #40]
	str	w10, [x24, #8]
	ldrb	w10, [x21, x8]
	ldrb	w11, [x21, x9]
	sub	w10, w10, w11
	add	w10, w10, #1
	strb	w10, [x24, #12]
	str	xzr, [x24, #16]
	ldrb	w9, [x21, x9]
	ldr	x10, [x24, #24]
	strb	w9, [x10]
	ldrb	w8, [x21, x8]
	ldr	x9, [x24, #24]
	strb	w8, [x9, #1]
	add	w28, w28, #3
	cbnz	x20, LBB0_25
	b	LBB0_5
LBB0_13:                                ;   in Loop: Header=BB0_6 Depth=1
	add	w26, w28, #1
	cmp	w26, w22
	b.ge	LBB0_20
; %bb.14:                               ;   in Loop: Header=BB0_6 Depth=1
	sxtw	x9, w26
	add	x8, x21, x9
	ldr	x10, [sp]                       ; 8-byte Folded Reload
	sub	x9, x10, x9
	b	LBB0_16
LBB0_15:                                ;   in Loop: Header=BB0_16 Depth=2
	add	w26, w26, #1
	add	x8, x8, #1
	subs	x9, x9, #1
	b.eq	LBB0_19
LBB0_16:                                ;   Parent Loop BB0_6 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	add	w10, w26, #2
	cmp	w10, w22
	b.ge	LBB0_15
; %bb.17:                               ;   in Loop: Header=BB0_16 Depth=2
	ldrb	w10, [x8]
	cmp	w10, #92
	b.eq	LBB0_15
; %bb.18:                               ;   in Loop: Header=BB0_16 Depth=2
	add	w10, w26, #1
	ldrb	w10, [x21, w10, sxtw]
	cmp	w10, #45
	b.ne	LBB0_15
	b	LBB0_20
LBB0_19:                                ;   in Loop: Header=BB0_6 Depth=1
	mov	x26, x22
LBB0_20:                                ;   in Loop: Header=BB0_6 Depth=1
Lloh12:
	adrp	x8, _UINT16_MAX@GOTPAGE
Lloh13:
	ldr	x8, [x8, _UINT16_MAX@GOTPAGEOFF]
Lloh14:
	ldr	w8, [x8]
	sub	w19, w26, w28
	cmp	w19, w8
	b.le	LBB0_22
; %bb.21:                               ;   in Loop: Header=BB0_6 Depth=1
Lloh15:
	adrp	x8, _E_ARGUMENT_ERROR@GOTPAGE
Lloh16:
	ldr	x8, [x8, _E_ARGUMENT_ERROR@GOTPAGEOFF]
Lloh17:
	ldr	w1, [x8]
	ldr	x0, [sp, #8]                    ; 8-byte Folded Reload
Lloh18:
	adrp	x2, l_.str@PAGE
Lloh19:
	add	x2, x2, l_.str@PAGEOFF
	bl	_mrb_raise
LBB0_22:                                ;   in Loop: Header=BB0_6 Depth=1
	cbnz	x24, LBB0_24
; %bb.23:                               ;   in Loop: Header=BB0_6 Depth=1
	cbnz	x20, LBB0_29
LBB0_24:                                ;   in Loop: Header=BB0_6 Depth=1
	cmp	x23, x27
Lloh20:
	adrp	x8, _TR_IN_ORDER@GOTPAGE
Lloh21:
	ldr	x8, [x8, _TR_IN_ORDER@GOTPAGEOFF]
Lloh22:
	ldr	x8, [x8]
	cset	w9, ne
	str	x8, [x24]
	str	x25, [x24, #40]
	str	w9, [x24, #8]
	strb	w19, [x24, #12]
	str	xzr, [x24, #16]
	str	w28, [x24, #32]
	mov	x28, x26
	cbz	x20, LBB0_5
LBB0_25:                                ;   in Loop: Header=BB0_6 Depth=1
	cmp	x23, x27
	b.eq	LBB0_5
; %bb.26:                               ;   in Loop: Header=BB0_6 Depth=1
	mov	x9, x20
LBB0_27:                                ;   Parent Loop BB0_6 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	mov	x8, x9
	ldr	x9, [x9, #16]
	cbnz	x9, LBB0_27
; %bb.28:                               ;   in Loop: Header=BB0_6 Depth=1
	str	x24, [x8, #16]
	cmp	w28, w22
	b.lt	LBB0_6
	b	LBB0_30
LBB0_29:
	ldr	x19, [sp, #8]                   ; 8-byte Folded Reload
	mov	x0, x19
	mov	x1, x20
	bl	_tr_free_pattern
	ldr	w0, [x19]
	bl	_mrb_obj_value
	mov	x1, x0
	mov	x0, x19
	bl	_mrb_exc_raise
	mov	x20, #0
LBB0_30:
	mov	x0, x20
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.cfi_endproc
                                        ; -- End function
	.comm	_FALSE,8,3                      ; @FALSE
	.comm	_TRUE,8,3                       ; @TRUE
	.comm	_TR_UNINITIALIZED,8,3           ; @TR_UNINITIALIZED
	.comm	_TR_RANGE,8,3                   ; @TR_RANGE
	.comm	_UINT16_MAX,4,2                 ; @UINT16_MAX
	.comm	_E_ARGUMENT_ERROR,4,2           ; @E_ARGUMENT_ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"tr pattern too long (max 65536)"

	.comm	_TR_IN_ORDER,8,3                ; @TR_IN_ORDER
	.no_dead_strip	_tr_parse_pattern
.subsections_via_symbols
