	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function delete_char
_delete_char:                           ## @delete_char
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %r14d
	movq	%rdi, %r15
	movq	40(%rdi), %r12
	movl	(%rdi), %ebx
	movl	4(%rdi), %eax
	incl	%ebx
	subl	%esi, %eax
	cmpl	%eax, %ebx
	ja	LBB0_3
## %bb.1:
	movl	%r14d, %r13d
	addq	%r13, %r13
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	leaq	(%r12,%r13), %rdi
	callq	_scr_readw
	movl	%eax, %edi
	movq	%r12, %rsi
	callq	_scr_writew
	addq	$2, %r12
	incl	%ebx
	movl	4(%r15), %eax
	subl	%r14d, %eax
	cmpl	%eax, %ebx
	jbe	LBB0_2
LBB0_3:
	movl	8(%r15), %esi
	leal	(%r14,%r14), %edx
	movq	%r12, %rdi
	callq	_scr_memsetw
	movq	$0, 32(%r15)
	movq	%r15, %rdi
	callq	_DO_UPDATE
	testq	%rax, %rax
	je	LBB0_9
## %bb.4:
	movzwl	12(%r15), %r12d
	movq	24(%r15), %rax
	movl	16(%r15), %ecx
	movl	(%r15), %r8d
	movl	4(%r15), %esi
	leal	(%r8,%r14), %edx
	subl	%edx, %esi
	movl	%esi, (%rsp)
	movq	%r15, %rdi
	movl	%ecx, %esi
                                        ## kill: def $r8d killed $r8d killed $r8
	movl	$1, %r9d
	callq	*8(%rax)
	movl	8(%r15), %esi
	movl	%esi, %eax
	shrl	$8, %eax
	movw	%ax, 12(%r15)
	testl	%r14d, %r14d
	je	LBB0_8
## %bb.5:
	movq	24(%r15), %rax
	movl	4(%r15), %ecx
	movl	16(%r15), %edx
	subl	%r14d, %ecx
	movq	%r15, %rdi
	callq	*(%rax)
	cmpl	$1, %r14d
	je	LBB0_8
## %bb.6:
	movl	$1, %ebx
	subl	%r14d, %ebx
	.p2align	4, 0x90
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movq	24(%r15), %rax
	movl	8(%r15), %esi
	movl	16(%r15), %edx
	movl	4(%r15), %ecx
	addl	%ebx, %ecx
	movq	%r15, %rdi
	callq	*(%rax)
	incl	%ebx
	jne	LBB0_7
LBB0_8:
	movw	%r12w, 12(%r15)
LBB0_9:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_delete_char
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function delete_char
_delete_char:                           ; @delete_char
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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, x1
	mov	x19, x0
	ldr	x21, [x0, #40]
	ldp	w8, w9, [x0]
	add	w22, w8, #1
	sub	w8, w9, w1
	cmp	w22, w8
	b.hi	LBB0_3
; %bb.1:
	mov	w8, w20
	lsl	x23, x8, #1
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	add	x0, x21, x23
	bl	_scr_readw
	mov	x1, x21
	bl	_scr_writew
	add	x21, x21, #2
	add	w22, w22, #1
	ldr	w8, [x19, #4]
	sub	w8, w8, w20
	cmp	w22, w8
	b.ls	LBB0_2
LBB0_3:
	ldr	w1, [x19, #8]
	lsl	w2, w20, #1
	mov	x0, x21
	bl	_scr_memsetw
	str	xzr, [x19, #32]
	mov	x0, x19
	bl	_DO_UPDATE
	cbz	x0, LBB0_9
; %bb.4:
	ldrh	w21, [x19, #12]
	ldr	x8, [x19, #24]
	ldr	x8, [x8, #8]
	ldr	w1, [x19, #16]
	ldp	w4, w9, [x19]
	add	w2, w4, w20
	sub	w6, w9, w2
	mov	x0, x19
	mov	x3, x1
	mov	w5, #1
	blr	x8
	ldr	w1, [x19, #8]
	lsr	w8, w1, #8
	strh	w8, [x19, #12]
	cbz	w20, LBB0_8
; %bb.5:
	ldr	x8, [x19, #24]
	ldr	x8, [x8]
	ldr	w2, [x19, #16]
	ldr	w9, [x19, #4]
	sub	w3, w9, w20
	mov	x0, x19
	blr	x8
	cmp	w20, #1
	b.eq	LBB0_8
; %bb.6:
	mov	w8, #1
	sub	w20, w8, w20
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #24]
	ldr	x8, [x8]
	ldr	w2, [x19, #16]
	ldp	w9, w1, [x19, #4]
	add	w3, w20, w9
	mov	x0, x19
	blr	x8
	adds	w20, w20, #1
	b.lo	LBB0_7
LBB0_8:
	strh	w21, [x19, #12]
LBB0_9:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_delete_char
.subsections_via_symbols
