	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_register_commit_graft          ## -- Begin function register_commit_graft
	.p2align	4, 0x90
_register_commit_graft:                 ## @register_commit_graft
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %r12d
	movq	%rsi, %r14
	movq	%rdi, %r15
	movl	(%rsi), %esi
	callq	_commit_graft_pos
	movl	%eax, %ebx
	testl	%eax, %eax
	js	LBB0_3
## %bb.1:
	testl	%r12d, %r12d
	je	LBB0_6
## %bb.2:
	movq	%r14, %rdi
	callq	_free
	jmp	LBB0_7
LBB0_3:
	movl	%ebx, %r12d
	notl	%r12d
	movq	(%r15), %rax
	movq	8(%rax), %rdi
	movl	(%rax), %esi
	incl	%esi
	movl	16(%rax), %edx
	callq	_ALLOC_GROW
	movq	(%r15), %rax
	movl	(%rax), %ecx
	leal	1(%rcx), %edx
	movl	%edx, (%rax)
	cmpl	%r12d, %ecx
	jl	LBB0_5
## %bb.4:
	movq	8(%rax), %rax
	movslq	%r12d, %rcx
	leaq	(%rax,%rcx,8), %rsi
	leaq	(%rax,%rcx,8), %rdi
	addq	$8, %rdi
	addl	%ebx, %edx
	shll	$3, %edx
	callq	_memmove
	movq	(%r15), %rax
LBB0_5:
	movq	8(%rax), %rax
	movl	%r12d, %ecx
	movq	%r14, (%rax,%rcx,8)
	xorl	%eax, %eax
	jmp	LBB0_8
LBB0_6:
	movq	(%r15), %rax
	movq	8(%rax), %rax
	movl	%ebx, %ebx
	movq	(%rax,%rbx,8), %rdi
	callq	_free
	movq	(%r15), %rax
	movq	8(%rax), %rax
	movq	%r14, (%rax,%rbx,8)
LBB0_7:
	movl	$1, %eax
LBB0_8:
	popq	%rbx
	popq	%r12
	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	_register_commit_graft          ; -- Begin function register_commit_graft
	.p2align	2
_register_commit_graft:                 ; @register_commit_graft
	.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	x22, x2
	mov	x19, x1
	mov	x20, x0
	ldr	w1, [x1]
	bl	_commit_graft_pos
	mov	x21, x0
	tbnz	w0, #31, LBB0_3
; %bb.1:
	cbz	w22, LBB0_6
; %bb.2:
	mov	x0, x19
	bl	_free
	b	LBB0_7
LBB0_3:
	mvn	w22, w21
	ldr	x8, [x20]
	ldr	x0, [x8, #8]
	ldr	w9, [x8]
	add	w1, w9, #1
	ldr	w2, [x8, #16]
	bl	_ALLOC_GROW
	ldr	x8, [x20]
	ldr	w10, [x8]
	add	w9, w10, #1
	str	w9, [x8]
	cmp	w10, w22
	b.lt	LBB0_5
; %bb.4:
	ldr	x8, [x8, #8]
	add	x1, x8, w22, sxtw #3
	add	x0, x1, #8
	add	w8, w9, w21
	lsl	w2, w8, #3
	bl	_memmove
	ldr	x8, [x20]
LBB0_5:
	mov	w0, #0
	ldr	x8, [x8, #8]
	str	x19, [x8, w22, uxtw #3]
	b	LBB0_8
LBB0_6:
	ldr	x8, [x20]
	ldr	x8, [x8, #8]
	mov	w9, w21
	lsl	x21, x9, #3
	ldr	x0, [x8, x21]
	bl	_free
	ldr	x8, [x20]
	ldr	x8, [x8, #8]
	str	x19, [x8, x21]
LBB0_7:
	mov	w0, #1
LBB0_8:
	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
