	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function EDIT_CharFromPos
_EDIT_CharFromPos:                      ## @EDIT_CharFromPos
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %rbx
	movq	%rdi, %r12
	movq	_ES_MULTILINE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	testl	%eax, (%rdi)
	je	LBB0_3
## %bb.1:
	subq	48(%r12), %rdx
	movq	8(%r12), %rsi
	movq	%rdx, %rax
	orq	%rsi, %rax
	shrq	$32, %rax
	movq	%rbx, -80(%rbp)                 ## 8-byte Spill
	movq	%rcx, -72(%rbp)                 ## 8-byte Spill
	je	LBB0_9
## %bb.2:
	movq	%rdx, %rax
	cqto
	idivq	%rsi
	movq	%rax, %r13
	jmp	LBB0_10
LBB0_3:
	movq	$0, -56(%rbp)
	testq	%rcx, %rcx
	je	LBB0_5
## %bb.4:
	movq	_FALSE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, (%rcx)
LBB0_5:
	movq	24(%r12), %r14
	movq	56(%r12), %rcx
	subq	%rcx, %rbx
	je	LBB0_57
## %bb.6:
	testq	%r14, %r14
	jne	LBB0_34
## %bb.7:
	movslq	64(%r12), %rax
	addq	32(%r12), %rcx
	subq	%rcx, %rax
	movl	(%r12), %ecx
	movq	_ES_RIGHT@GOTPCREL(%rip), %rdx
	testl	%ecx, (%rdx)
	je	LBB0_32
## %bb.8:
	subq	%rax, %rbx
	jmp	LBB0_34
LBB0_9:
	movl	%edx, %eax
	xorl	%edx, %edx
	divl	%esi
	movl	%eax, %r13d
LBB0_10:
	movq	16(%r12), %r15
	movq	72(%r12), %rbx
	leaq	(%r15,%r13), %rdx
	xorl	%r14d, %r14d
	movq	%r12, %rdi
	xorl	%esi, %esi
	callq	_EDIT_UpdateUniscribeData
	movq	%r15, %rax
	addq	%r13, %rax
	jle	LBB0_14
## %bb.11:
	leaq	(%r15,%r13), %rax
	incq	%rax
	xorl	%r14d, %r14d
	movq	-80(%rbp), %rdx                 ## 8-byte Reload
	movq	-72(%rbp), %r15                 ## 8-byte Reload
	.p2align	4, 0x90
LBB0_12:                                ## =>This Inner Loop Header: Depth=1
	movq	40(%rbx), %r13
	testq	%r13, %r13
	je	LBB0_15
## %bb.13:                              ##   in Loop: Header=BB0_12 Depth=1
	addq	(%rbx), %r14
	decq	%rax
	movq	%r13, %rbx
	cmpq	$1, %rax
	jg	LBB0_12
	jmp	LBB0_16
LBB0_14:
	movq	%rbx, %r13
	movq	-80(%rbp), %rdx                 ## 8-byte Reload
	movq	-72(%rbp), %r15                 ## 8-byte Reload
	jmp	LBB0_16
LBB0_15:
	movq	%rbx, %r13
LBB0_16:
	movq	24(%r12), %rsi
	movl	(%r12), %eax
	movq	_ES_RIGHT@GOTPCREL(%rip), %rcx
	testl	%eax, (%rcx)
	je	LBB0_18
## %bb.17:
	movslq	64(%r12), %rcx
	movslq	8(%r13), %rax
	addq	%rdx, %rsi
	subq	%rcx, %rsi
	addq	%rax, %rsi
	cmpq	%rax, %rsi
	jge	LBB0_29
LBB0_20:
	testq	%rsi, %rsi
	jle	LBB0_26
## %bb.21:
	movq	32(%r13), %rdi
	testq	%rdi, %rdi
	je	LBB0_26
## %bb.22:
	xorl	%ebx, %ebx
	leaq	-48(%rbp), %rdx
	leaq	-56(%rbp), %rcx
	xorl	%eax, %eax
	callq	_ScriptStringXtoCP
	movq	-48(%rbp), %rax
	cmpl	$1, -56(%rbp)
	sbbq	$-1, %rax
	addq	%rax, %r14
	movq	%r14, -48(%rbp)
	testq	%r15, %r15
	je	LBB0_57
## %bb.23:
	cmpq	24(%r13), %rax
	jne	LBB0_25
## %bb.24:
	movq	16(%r13), %rax
	movq	_END_WRAP@GOTPCREL(%rip), %rcx
	xorl	%ebx, %ebx
	cmpq	(%rcx), %rax
	sete	%bl
LBB0_25:
	movl	%ebx, (%r15)
	jmp	LBB0_57
LBB0_18:
	movq	56(%r12), %rcx
	subq	%rcx, %rsi
	addq	%rdx, %rsi
	movq	_ES_CENTER@GOTPCREL(%rip), %rdx
	testl	%eax, (%rdx)
	je	LBB0_28
## %bb.19:
	movslq	64(%r12), %rdx
	movslq	8(%r13), %rax
	addq	%rax, %rcx
	subq	%rcx, %rdx
	movq	%rdx, %rcx
	shrq	$63, %rcx
	addq	%rdx, %rcx
	sarq	%rcx
	subq	%rcx, %rsi
	cmpq	%rax, %rsi
	jl	LBB0_20
LBB0_29:
	testq	%r15, %r15
	je	LBB0_31
## %bb.30:
	movq	16(%r13), %rax
	movq	_END_WRAP@GOTPCREL(%rip), %rcx
	xorl	%edx, %edx
	cmpq	(%rcx), %rax
	sete	%dl
	movl	%edx, (%r15)
LBB0_31:
	addq	24(%r13), %r14
	jmp	LBB0_57
LBB0_26:
	testq	%r15, %r15
	je	LBB0_57
## %bb.27:
	movq	_FALSE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, (%r15)
	jmp	LBB0_57
LBB0_28:
	movslq	8(%r13), %rax
	cmpq	%rax, %rsi
	jl	LBB0_20
	jmp	LBB0_29
LBB0_32:
	movq	_ES_CENTER@GOTPCREL(%rip), %rdx
	testl	%ecx, (%rdx)
	je	LBB0_34
## %bb.33:
	movq	%rax, %rcx
	shrq	$63, %rcx
	addq	%rax, %rcx
	sarq	%rcx
	subq	%rcx, %rbx
LBB0_34:
	movq	%r12, %rdi
	xorl	%esi, %esi
	xorl	%edx, %edx
	callq	_EDIT_UpdateUniscribeData
	movq	24(%r12), %r14
	testq	%r14, %r14
	je	LBB0_39
## %bb.35:
	cmpq	$0, 40(%r12)
	je	LBB0_45
## %bb.36:
	movq	%r12, %rdi
	callq	_get_text_length
	cmpq	%rax, %r14
	jl	LBB0_38
## %bb.37:
	movq	40(%r12), %rdi
	callq	_ScriptString_pSize
	movq	(%rax), %rax
	movq	%rax, -56(%rbp)
LBB0_38:
	movq	24(%r12), %rsi
	movq	40(%r12), %rdi
	movq	_FALSE@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	leaq	-56(%rbp), %rcx
	callq	_ScriptStringCPtoX
LBB0_39:
	testq	%rbx, %rbx
	js	LBB0_46
LBB0_40:
	je	LBB0_49
## %bb.41:
	movq	40(%r12), %rdi
	testq	%rdi, %rdi
	je	LBB0_55
## %bb.42:
	callq	_ScriptString_pSize
	testq	%rax, %rax
	je	LBB0_55
## %bb.43:
	cmpq	(%rax), %rbx
	jle	LBB0_53
## %bb.44:
	movq	%r12, %rdi
	callq	_get_text_length
	jmp	LBB0_50
LBB0_45:
	movq	$0, -56(%rbp)
	testq	%rbx, %rbx
	jns	LBB0_40
LBB0_46:
	movq	40(%r12), %rdi
	addq	-56(%rbp), %rbx
	jle	LBB0_51
LBB0_47:
	leaq	-48(%rbp), %rdx
	leaq	-64(%rbp), %rcx
	movq	%rbx, %rsi
	xorl	%eax, %eax
	callq	_ScriptStringXtoCP
	cmpq	$0, -64(%rbp)
	je	LBB0_56
## %bb.48:
	incq	-48(%rbp)
	jmp	LBB0_56
LBB0_49:
	movq	24(%r12), %rax
LBB0_50:
	movq	%rax, -48(%rbp)
	jmp	LBB0_56
LBB0_51:
	testq	%rdi, %rdi
	jne	LBB0_55
## %bb.52:
	xorl	%edi, %edi
	jmp	LBB0_47
LBB0_53:
	movq	40(%r12), %rdi
	testq	%rdi, %rdi
	je	LBB0_55
## %bb.54:
	addq	-56(%rbp), %rbx
	jmp	LBB0_47
LBB0_55:
	movq	$0, -48(%rbp)
LBB0_56:
	movq	-48(%rbp), %r14
LBB0_57:
	movq	%r14, %rax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ES_MULTILINE,4,2               ## @ES_MULTILINE
	.comm	_ES_RIGHT,4,2                   ## @ES_RIGHT
	.comm	_ES_CENTER,4,2                  ## @ES_CENTER
	.comm	_END_WRAP,8,3                   ## @END_WRAP
	.comm	_FALSE,4,2                      ## @FALSE
	.no_dead_strip	_EDIT_CharFromPos
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function EDIT_CharFromPos
_EDIT_CharFromPos:                      ; @EDIT_CharFromPos
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	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
	mov	x20, x3
	mov	x22, x1
	mov	x19, x0
	ldr	w8, [x0]
Lloh0:
	adrp	x9, _ES_MULTILINE@GOTPAGE
Lloh1:
	ldr	x9, [x9, _ES_MULTILINE@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_5
; %bb.1:
	ldr	x8, [x19, #48]
	sub	x8, x2, x8
	ldp	x9, x10, [x19, #8]
	sdiv	x8, x8, x9
	add	x23, x10, x8
	ldr	x24, [x19, #72]
	mov	x0, x19
	mov	x1, #0
	mov	x2, x23
	bl	_EDIT_UpdateUniscribeData
	cmp	x23, #1
	b.lt	LBB0_11
; %bb.2:
	mov	x21, #0
	add	x8, x23, #1
	mov	x9, x24
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x24, [x9, #40]
	cbz	x24, LBB0_12
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	x9, [x9]
	add	x21, x9, x21
	sub	x8, x8, #1
	mov	x9, x24
	cmp	x8, #1
	b.gt	LBB0_3
	b	LBB0_13
LBB0_5:
	str	xzr, [sp, #16]
	cbz	x20, LBB0_7
; %bb.6:
Lloh3:
	adrp	x8, _FALSE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _FALSE@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	str	w8, [x20]
LBB0_7:
	ldr	x8, [x19, #56]
	ldr	x21, [x19, #24]
	subs	x20, x22, x8
	b.eq	LBB0_52
; %bb.8:
	cbnz	x21, LBB0_30
; %bb.9:
	ldrsw	x9, [x19, #64]
	ldr	x10, [x19, #32]
	add	x8, x10, x8
	sub	x8, x9, x8
	ldr	w9, [x19]
Lloh6:
	adrp	x10, _ES_RIGHT@GOTPAGE
Lloh7:
	ldr	x10, [x10, _ES_RIGHT@GOTPAGEOFF]
Lloh8:
	ldr	w10, [x10]
	tst	w10, w9
	b.eq	LBB0_29
; %bb.10:
	sub	x20, x20, x8
	b	LBB0_30
LBB0_11:
	mov	x21, #0
	b	LBB0_13
LBB0_12:
	mov	x24, x9
LBB0_13:
	ldr	x9, [x19, #24]
	ldr	w8, [x19]
Lloh9:
	adrp	x10, _ES_RIGHT@GOTPAGE
Lloh10:
	ldr	x10, [x10, _ES_RIGHT@GOTPAGEOFF]
Lloh11:
	ldr	w10, [x10]
	tst	w10, w8
	b.eq	LBB0_20
; %bb.14:
	ldrsw	x10, [x19, #64]
	ldrsw	x8, [x24, #8]
	add	x9, x9, x22
	sub	x9, x9, x10
	add	x1, x9, x8
	cmp	x1, x8
	b.ge	LBB0_22
LBB0_15:
	cmp	x1, #1
	b.lt	LBB0_25
; %bb.16:
	ldr	x0, [x24, #32]
	cbz	x0, LBB0_25
; %bb.17:
	add	x8, sp, #16
	str	x8, [sp]
	add	x2, sp, #24
	bl	_ScriptStringXtoCP
	ldr	w8, [sp, #16]
	cmp	w8, #0
	ldr	x8, [sp, #24]
	cinc	x8, x8, ne
	add	x21, x8, x21
	str	x21, [sp, #24]
	cbz	x20, LBB0_52
; %bb.18:
	ldr	x9, [x24, #24]
	cmp	x8, x9
	b.ne	LBB0_28
; %bb.19:
	ldr	x8, [x24, #16]
Lloh12:
	adrp	x9, _END_WRAP@GOTPAGE
Lloh13:
	ldr	x9, [x9, _END_WRAP@GOTPAGEOFF]
Lloh14:
	ldr	x9, [x9]
	cmp	x8, x9
	cset	w8, eq
	str	w8, [x20]
	b	LBB0_52
LBB0_20:
	ldr	x10, [x19, #56]
	sub	x9, x9, x10
	add	x1, x9, x22
Lloh15:
	adrp	x9, _ES_CENTER@GOTPAGE
Lloh16:
	ldr	x9, [x9, _ES_CENTER@GOTPAGEOFF]
Lloh17:
	ldr	w9, [x9]
	tst	w9, w8
	b.eq	LBB0_27
; %bb.21:
	ldrsw	x9, [x19, #64]
	ldrsw	x8, [x24, #8]
	add	x10, x10, x8
	sub	x9, x9, x10
	cmp	x9, #0
	cinc	x9, x9, lt
	sub	x1, x1, x9, asr #1
	cmp	x1, x8
	b.lt	LBB0_15
LBB0_22:
	cbz	x20, LBB0_24
; %bb.23:
	ldr	x8, [x24, #16]
Lloh18:
	adrp	x9, _END_WRAP@GOTPAGE
Lloh19:
	ldr	x9, [x9, _END_WRAP@GOTPAGEOFF]
Lloh20:
	ldr	x9, [x9]
	cmp	x8, x9
	cset	w8, eq
	str	w8, [x20]
LBB0_24:
	ldr	x8, [x24, #24]
	add	x21, x8, x21
	b	LBB0_52
LBB0_25:
	cbz	x20, LBB0_52
; %bb.26:
Lloh21:
	adrp	x8, _FALSE@GOTPAGE
Lloh22:
	ldr	x8, [x8, _FALSE@GOTPAGEOFF]
Lloh23:
	ldr	w8, [x8]
	str	w8, [x20]
	b	LBB0_52
LBB0_27:
	ldrsw	x8, [x24, #8]
	cmp	x1, x8
	b.lt	LBB0_15
	b	LBB0_22
LBB0_28:
	mov	w8, #0
	str	wzr, [x20]
	b	LBB0_52
LBB0_29:
Lloh24:
	adrp	x10, _ES_CENTER@GOTPAGE
Lloh25:
	ldr	x10, [x10, _ES_CENTER@GOTPAGEOFF]
Lloh26:
	ldr	w10, [x10]
	cmp	x8, #0
	cinc	x8, x8, lt
	sub	x8, x20, x8, asr #1
	tst	w10, w9
	csel	x20, x20, x8, eq
LBB0_30:
	mov	x0, x19
	mov	x1, #0
	mov	x2, #0
	bl	_EDIT_UpdateUniscribeData
	ldr	x21, [x19, #24]
	cbz	x21, LBB0_35
; %bb.31:
	ldr	x8, [x19, #40]
	cbz	x8, LBB0_41
; %bb.32:
	mov	x0, x19
	bl	_get_text_length
	cmp	x21, x0
	b.lt	LBB0_34
; %bb.33:
	ldr	x0, [x19, #40]
	bl	_ScriptString_pSize
	ldr	x8, [x0]
	str	x8, [sp, #16]
LBB0_34:
	ldr	x0, [x19, #40]
	ldr	x1, [x19, #24]
Lloh27:
	adrp	x8, _FALSE@GOTPAGE
Lloh28:
	ldr	x8, [x8, _FALSE@GOTPAGEOFF]
Lloh29:
	ldr	w2, [x8]
	add	x3, sp, #16
	bl	_ScriptStringCPtoX
LBB0_35:
	tbnz	x20, #63, LBB0_42
LBB0_36:
	cbz	x20, LBB0_45
; %bb.37:
	ldr	x0, [x19, #40]
	cbz	x0, LBB0_50
; %bb.38:
	bl	_ScriptString_pSize
	cbz	x0, LBB0_50
; %bb.39:
	ldr	x8, [x0]
	cmp	x20, x8
	b.le	LBB0_48
; %bb.40:
	mov	x0, x19
	bl	_get_text_length
	str	x0, [sp, #24]
	b	LBB0_51
LBB0_41:
	str	xzr, [sp, #16]
	tbz	x20, #63, LBB0_36
LBB0_42:
	ldr	x8, [sp, #16]
	add	x1, x8, x20
	ldr	x0, [x19, #40]
	cmp	x1, #0
	b.le	LBB0_47
LBB0_43:
	add	x8, sp, #8
	str	x8, [sp]
	add	x2, sp, #24
	bl	_ScriptStringXtoCP
	ldr	x8, [sp, #8]
	cbz	x8, LBB0_51
; %bb.44:
	ldr	x8, [sp, #24]
	add	x8, x8, #1
	b	LBB0_46
LBB0_45:
	ldr	x8, [x19, #24]
LBB0_46:
	str	x8, [sp, #24]
	b	LBB0_51
LBB0_47:
	cbnz	x0, LBB0_50
	b	LBB0_43
LBB0_48:
	ldr	x0, [x19, #40]
	cbz	x0, LBB0_50
; %bb.49:
	ldr	x8, [sp, #16]
	add	x1, x8, x20
	b	LBB0_43
LBB0_50:
	str	xzr, [sp, #24]
LBB0_51:
	ldr	x21, [sp, #24]
LBB0_52:
	mov	x0, x21
	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
	add	sp, sp, #96
	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 AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGotLdr	Lloh27, Lloh28, Lloh29
	.cfi_endproc
                                        ; -- End function
	.comm	_ES_MULTILINE,4,2               ; @ES_MULTILINE
	.comm	_ES_RIGHT,4,2                   ; @ES_RIGHT
	.comm	_ES_CENTER,4,2                  ; @ES_CENTER
	.comm	_END_WRAP,8,3                   ; @END_WRAP
	.comm	_FALSE,4,2                      ; @FALSE
	.no_dead_strip	_EDIT_CharFromPos
.subsections_via_symbols
