	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_find_ap                        ## -- Begin function find_ap
	.p2align	4, 0x90
_find_ap:                               ## @find_ap
	.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
	movq	_last_used_map@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	testl	%ebx, %ebx
	js	LBB0_6
## %bb.1:
	movq	%rdi, %r14
	incq	%rbx
	movq	_exported_ap@GOTPCREL(%rip), %r15
	movq	_AMF_ROOT@GOTPCREL(%rip), %r12
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	decq	%rbx
	jle	LBB0_6
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r15), %rax
	movq	-8(%rax,%rbx,8), %rsi
	testq	%rsi, %rsi
	je	LBB0_5
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	(%r12), %eax
	testl	%eax, (%rsi)
	je	LBB0_5
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	%r14, %rdi
	callq	_find_ap_recursive
	testq	%rax, %rax
	je	LBB0_5
	jmp	LBB0_7
LBB0_6:
	xorl	%eax, %eax
LBB0_7:
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_last_used_map,4,2              ## @last_used_map
	.comm	_exported_ap,8,3                ## @exported_ap
	.comm	_AMF_ROOT,4,2                   ## @AMF_ROOT
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_find_ap                        ; -- Begin function find_ap
	.p2align	2
_find_ap:                               ; @find_ap
	.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
Lloh0:
	adrp	x8, _last_used_map@GOTPAGE
Lloh1:
	ldr	x8, [x8, _last_used_map@GOTPAGEOFF]
Lloh2:
	ldr	w20, [x8]
	tbnz	w20, #31, LBB0_6
; %bb.1:
	mov	x19, x0
Lloh3:
	adrp	x21, _exported_ap@GOTPAGE
Lloh4:
	ldr	x21, [x21, _exported_ap@GOTPAGEOFF]
Lloh5:
	adrp	x22, _AMF_ROOT@GOTPAGE
Lloh6:
	ldr	x22, [x22, _AMF_ROOT@GOTPAGEOFF]
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	sub	x8, x20, #1
	cmp	x20, #0
	mov	x20, x8
	b.le	LBB0_6
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x21]
	ldr	x1, [x8, x20, lsl #3]
	cbz	x1, LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w8, [x1]
	ldr	w9, [x22]
	tst	w9, w8
	b.eq	LBB0_2
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x0, x19
	bl	_find_ap_recursive
	cbz	x0, LBB0_2
	b	LBB0_7
LBB0_6:
	mov	x0, #0
LBB0_7:
	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
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_last_used_map,4,2              ; @last_used_map
	.comm	_exported_ap,8,3                ; @exported_ap
	.comm	_AMF_ROOT,4,2                   ; @AMF_ROOT
.subsections_via_symbols
