	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function amd64_fetch_size
_amd64_fetch_size:                      ## @amd64_fetch_size
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	xorl	%ebx, %ebx
	xorl	%edi, %edi
	callq	_node_to_amd_nb
	movq	(%rax), %rdi
	testq	%rdi, %rdi
	je	LBB0_7
## %bb.1:
	movq	_AMD64_GARTAPERTURECTL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-12(%rbp), %rdx
	callq	_pci_read_config_dword
	andl	$14, -12(%rbp)
	movq	_amd64_aperture_sizes@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_A_SIZE_32
	movq	_agp_bridge@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	24(%rcx), %rdx
	movl	(%rdx), %edx
	testl	%edx, %edx
	jle	LBB0_7
## %bb.2:
	movl	-12(%rbp), %edi
	xorl	%esi, %esi
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	cmpl	(%rax), %edi
	je	LBB0_4
## %bb.5:                               ##   in Loop: Header=BB0_3 Depth=1
	incq	%rsi
	addq	$8, %rax
	cmpq	%rsi, %rdx
	jne	LBB0_3
## %bb.6:
	xorl	%ebx, %ebx
	jmp	LBB0_7
LBB0_4:
	movq	%rax, 8(%rcx)
	movq	%rax, 16(%rcx)
	movl	%esi, (%rcx)
	movl	4(%rax), %ebx
LBB0_7:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AMD64_GARTAPERTURECTL,4,2      ## @AMD64_GARTAPERTURECTL
	.comm	_amd64_aperture_sizes,4,2       ## @amd64_aperture_sizes
	.comm	_agp_bridge,8,3                 ## @agp_bridge
	.no_dead_strip	_amd64_fetch_size
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function amd64_fetch_size
_amd64_fetch_size:                      ; @amd64_fetch_size
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #32
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	mov	w0, #0
	bl	_node_to_amd_nb
	ldr	x0, [x0]
	cbz	x0, LBB0_7
; %bb.1:
Lloh0:
	adrp	x8, _AMD64_GARTAPERTURECTL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _AMD64_GARTAPERTURECTL@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	sub	x2, x29, #4
	bl	_pci_read_config_dword
	ldur	w8, [x29, #-4]
	and	w8, w8, #0xe
	stur	w8, [x29, #-4]
Lloh3:
	adrp	x8, _amd64_aperture_sizes@GOTPAGE
Lloh4:
	ldr	x8, [x8, _amd64_aperture_sizes@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
	bl	_A_SIZE_32
Lloh6:
	adrp	x8, _agp_bridge@GOTPAGE
Lloh7:
	ldr	x8, [x8, _agp_bridge@GOTPAGEOFF]
Lloh8:
	ldr	x8, [x8]
	ldr	x9, [x8, #24]
	ldr	w9, [x9]
	cmp	w9, #1
	b.lt	LBB0_5
; %bb.2:
	mov	x10, #0
	ldur	w11, [x29, #-4]
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w12, [x0]
	cmp	w11, w12
	b.eq	LBB0_6
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	add	x10, x10, #1
	add	x0, x0, #8
	cmp	x9, x10
	b.ne	LBB0_3
LBB0_5:
	mov	w0, #0
	b	LBB0_7
LBB0_6:
	stp	x0, x0, [x8, #8]
	str	w10, [x8]
	ldr	w0, [x0, #4]
LBB0_7:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #32
	ret
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_AMD64_GARTAPERTURECTL,4,2      ; @AMD64_GARTAPERTURECTL
	.comm	_amd64_aperture_sizes,4,2       ; @amd64_aperture_sizes
	.comm	_agp_bridge,8,3                 ; @agp_bridge
	.no_dead_strip	_amd64_fetch_size
.subsections_via_symbols
