	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function find_notes_merge_pair_pos
_find_notes_merge_pair_pos:             ## @find_notes_merge_pair_pos
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, -64(%rbp)                 ## 8-byte Spill
	movl	%esi, %ebx
	movl	_find_notes_merge_pair_pos.last_index(%rip), %eax
	leal	-1(%rbx), %r12d
	cmpl	%esi, %eax
	cmovll	%eax, %r12d
	testl	%r12d, %r12d
	movq	%r8, -56(%rbp)                  ## 8-byte Spill
	movl	%ecx, -44(%rbp)                 ## 4-byte Spill
	js	LBB0_8
## %bb.1:
	xorl	%r14d, %r14d
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	%r12d, %r15d
	movq	%rdi, %r13
	leaq	(%rdi,%r15,4), %rsi
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	callq	_oidcmp
	testl	%eax, %eax
	je	LBB0_13
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	testl	%r14d, %r14d
	jle	LBB0_6
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	testl	%eax, %eax
	js	LBB0_5
LBB0_6:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	%eax, %ecx
	notl	%ecx
	shrl	$31, %ecx
	testl	%r14d, %r14d
	leal	-1(%rcx,%rcx), %ecx
	movl	$1, %edx
	cmovgl	%edx, %ecx
	addl	%ecx, %r12d
	movq	%r13, %rdi
	js	LBB0_8
## %bb.7:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	%eax, %r14d
	cmpl	%ebx, %r12d
	jl	LBB0_2
	jmp	LBB0_8
LBB0_13:
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	$1, (%rax)
	movq	%r13, %rdi
	jmp	LBB0_12
LBB0_5:
	movq	%r13, %rdi
LBB0_8:
	xorl	%r15d, %r15d
	testl	%r12d, %r12d
	cmovgl	%r12d, %r15d
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	$0, (%rax)
	cmpl	$0, -44(%rbp)                   ## 4-byte Folded Reload
	je	LBB0_11
## %bb.9:
	cmpl	%ebx, %r15d
	jge	LBB0_11
## %bb.10:
	leaq	(%rdi,%r15,4), %r12
	movq	%rdi, %r14
	leaq	(%rdi,%r15,4), %rdi
	addq	$4, %rdi
	subl	%r15d, %ebx
	movq	%r12, %rsi
	movl	%ebx, %edx
	callq	_MOVE_ARRAY
	movq	%r12, %rdi
	xorl	%esi, %esi
	movl	$4, %edx
	callq	_memset
	movq	%r14, %rdi
LBB0_11:
	movl	%r15d, %r12d
LBB0_12:
	movl	%r12d, _find_notes_merge_pair_pos.last_index(%rip)
	leaq	(%rdi,%r15,4), %rax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
.zerofill __DATA,__bss,_find_notes_merge_pair_pos.last_index,4,2 ## @find_notes_merge_pair_pos.last_index
	.no_dead_strip	_find_notes_merge_pair_pos
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function find_notes_merge_pair_pos
_find_notes_merge_pair_pos:             ; @find_notes_merge_pair_pos
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	mov	x21, x4
	mov	x22, x3
	mov	x20, x1
	mov	x19, x0
	adrp	x24, _find_notes_merge_pair_pos.last_index@PAGE
	ldr	w8, [x24, _find_notes_merge_pair_pos.last_index@PAGEOFF]
	sub	w9, w1, #1
	cmp	w8, w1
	csel	w25, w8, w9, lt
	tbnz	w25, #31, LBB0_7
; %bb.1:
	mov	x23, x2
	mov	w26, #0
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	add	x1, x19, w25, uxtw #2
	mov	x0, x23
	bl	_oidcmp
	cbz	w0, LBB0_11
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	cmp	w26, #1
	b.lt	LBB0_5
; %bb.4:                                ;   in Loop: Header=BB0_2 Depth=1
	tbnz	w0, #31, LBB0_7
LBB0_5:                                 ;   in Loop: Header=BB0_2 Depth=1
	sub	w8, w25, #1
	cmp	w0, #0
	ccmp	w26, #1, #0, lt
	csinc	w25, w8, w25, lt
	tbnz	w25, #31, LBB0_7
; %bb.6:                                ;   in Loop: Header=BB0_2 Depth=1
	mov	x26, x0
	cmp	w25, w20
	b.lt	LBB0_2
LBB0_7:
	cmp	w25, #0
	csel	w23, w25, wzr, gt
	str	wzr, [x21]
	cbz	w22, LBB0_10
; %bb.8:
	cmp	w23, w20
	b.ge	LBB0_10
; %bb.9:
	add	x21, x19, x23, lsl #2
	add	x0, x21, #4
	sub	w2, w20, w23
	mov	x1, x21
	bl	_MOVE_ARRAY
	mov	x0, x21
	mov	w1, #0
	mov	w2, #4
	bl	_memset
LBB0_10:
	mov	x25, x23
	b	LBB0_12
LBB0_11:
	mov	w23, w25
	mov	w8, #1
	str	w8, [x21]
LBB0_12:
	str	w25, [x24, _find_notes_merge_pair_pos.last_index@PAGEOFF]
	add	x0, x19, x23, lsl #2
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.cfi_endproc
                                        ; -- End function
.zerofill __DATA,__bss,_find_notes_merge_pair_pos.last_index,4,2 ; @find_notes_merge_pair_pos.last_index
	.no_dead_strip	_find_notes_merge_pair_pos
.subsections_via_symbols
