	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_bi_load64                      ## -- Begin function bi_load64
	.p2align	4, 0x90
_bi_load64:                             ## @bi_load64
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%r8d, %r12d
	movq	%rcx, %r14
	movq	%rdx, %r15
	movq	%rsi, %rbx
	movq	%rdi, %r13
	xorl	%eax, %eax
	callq	_bi_checkcpu
	testl	%eax, %eax
	je	LBB0_1
## %bb.3:
	movq	%r13, %rdi
	callq	_bi_getboothowto
	movl	%eax, -52(%rbp)
	leaq	L_.str.1(%rip), %rdi
	callq	_getenv
	leaq	-80(%rbp), %rdi
	movq	%rax, %rsi
	xorl	%edx, %edx
	callq	_i386_getdev
	movq	-80(%rbp), %rdi
	testq	%rdi, %rdi
	je	LBB0_4
## %bb.5:
	callq	_i386_fmtdev
	movl	%eax, %edi
	callq	_getrootmount
	testq	%rbx, %rbx
	jne	LBB0_9
## %bb.6:
	xorl	%ebx, %ebx
	xorl	%edi, %edi
	xorl	%esi, %esi
	callq	_file_findfile
	testq	%rax, %rax
	je	LBB0_9
## %bb.7:
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_8:                                 ## =>This Inner Loop Header: Depth=1
	movq	8(%rax), %rcx
	addq	(%rax), %rcx
	movq	16(%rax), %rdx
	cmpq	%rcx, %rbx
	cmovleq	%rcx, %rbx
	movq	%rdx, %rax
	testq	%rdx, %rdx
	jne	LBB0_8
LBB0_9:
	movq	%r14, -72(%rbp)                 ## 8-byte Spill
	movq	_PAGE_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_roundup
	movq	%rax, %r13
	movq	%rax, (%r15)
	movl	%r13d, -56(%rbp)
	leaq	L_.str.3(%rip), %rsi
	xorl	%edi, %edi
	callq	_file_findfile
	movq	%rax, %rbx
	testq	%rax, %rax
	jne	LBB0_12
## %bb.10:
	leaq	L_.str.4(%rip), %rsi
	xorl	%edi, %edi
	callq	_file_findfile
	movq	%rax, %rbx
	testq	%rax, %rax
	jne	LBB0_12
## %bb.11:
	leaq	L_.str.5(%rip), %rdi
	callq	_panic
	xorl	%ebx, %ebx
LBB0_12:
	movq	%r15, -64(%rbp)                 ## 8-byte Spill
	movl	$0, -44(%rbp)
	movq	_MODINFOMD_HOWTO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-52(%rbp), %rcx
	movq	%rbx, %rdi
	movl	$4, %edx
	callq	_file_addmetadata
	movq	_MODINFOMD_ENVP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-48(%rbp), %rcx
	movq	%rbx, %rdi
	movl	$4, %edx
	callq	_file_addmetadata
	movq	_MODINFOMD_KERNEND@GOTPCREL(%rip), %r14
	movl	(%r14), %esi
	leaq	-44(%rbp), %rcx
	movq	%rbx, %rdi
	movl	$4, %edx
	callq	_file_addmetadata
	movq	_MODINFOMD_MODULEP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	-56(%rbp), %rcx
	movq	%rbx, %rdi
	movl	$4, %edx
	callq	_file_addmetadata
	testl	%r12d, %r12d
	je	LBB0_14
## %bb.13:
	movq	%rbx, %rdi
	callq	_bios_addsmapdata
LBB0_14:
	xorl	%r12d, %r12d
	xorl	%edi, %edi
	callq	_bi_copymodules64
	addq	%rax, %r13
	movq	_PAGE_SIZE@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	movq	%r13, %rdi
	callq	_roundup
	movl	%eax, -48(%rbp)
	movl	%eax, %edi
	callq	_bi_copyenv
	movl	(%r15), %esi
	movq	%rax, %rdi
	callq	_roundup
	movl	%eax, -44(%rbp)
	cltq
	movq	-72(%rbp), %rcx                 ## 8-byte Reload
	movq	%rax, (%rcx)
	movl	(%r14), %esi
	movq	%rbx, %rdi
	callq	_file_findmetadata
	movl	(%rax), %esi
	leaq	-44(%rbp), %rdi
	movl	$4, %edx
	callq	_bcopy
	movq	_MODINFOMD_ENVP@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	%rbx, %rdi
	callq	_file_findmetadata
	movl	(%rax), %esi
	leaq	-48(%rbp), %rdi
	movl	$4, %edx
	callq	_bcopy
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %rdi
	callq	_bi_copymodules64
	jmp	LBB0_15
LBB0_1:
	leaq	L_str(%rip), %rdi
	jmp	LBB0_2
LBB0_4:
	leaq	L_str.6(%rip), %rdi
LBB0_2:
	callq	_puts
	movq	_EINVAL@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
LBB0_15:
	movl	%r12d, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.section	__TEXT,__cstring,cstring_literals
L_.str.1:                               ## @.str.1
	.asciz	"rootdev"

	.comm	_PAGE_SIZE,4,2                  ## @PAGE_SIZE
L_.str.3:                               ## @.str.3
	.asciz	"elf kernel"

L_.str.4:                               ## @.str.4
	.asciz	"elf64 kernel"

L_.str.5:                               ## @.str.5
	.asciz	"can't find kernel file"

	.comm	_MODINFOMD_HOWTO,4,2            ## @MODINFOMD_HOWTO
	.comm	_MODINFOMD_ENVP,4,2             ## @MODINFOMD_ENVP
	.comm	_MODINFOMD_KERNEND,4,2          ## @MODINFOMD_KERNEND
	.comm	_MODINFOMD_MODULEP,4,2          ## @MODINFOMD_MODULEP
L_str:                                  ## @str
	.asciz	"CPU doesn't support long mode"

L_str.6:                                ## @str.6
	.asciz	"can't determine root device"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_bi_load64                      ; -- Begin function bi_load64
	.p2align	2
_bi_load64:                             ; @bi_load64
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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	x20, x3
	mov	x19, x2
	mov	x22, x1
	mov	x23, x0
	bl	_bi_checkcpu
	cbz	w0, LBB0_11
; %bb.1:
	mov	x0, x23
	bl	_bi_getboothowto
	str	w0, [sp, #8]
Lloh0:
	adrp	x0, l_.str.1@PAGE
Lloh1:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_getenv
	mov	x1, x0
	add	x0, sp, #24
	mov	x2, #0
	bl	_i386_getdev
	ldr	x0, [sp, #24]
	cbz	x0, LBB0_12
; %bb.2:
	bl	_i386_fmtdev
	bl	_getrootmount
	cbnz	x22, LBB0_5
; %bb.3:
	mov	x0, #0
	mov	x1, #0
	bl	_file_findfile
	mov	x22, #0
	cbz	x0, LBB0_5
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldp	x8, x9, [x0]
	add	x8, x9, x8
	cmp	x22, x8
	csel	x22, x22, x8, gt
	ldr	x0, [x0, #16]
	cbnz	x0, LBB0_4
LBB0_5:
Lloh2:
	adrp	x24, _PAGE_SIZE@GOTPAGE
Lloh3:
	ldr	x24, [x24, _PAGE_SIZE@GOTPAGEOFF]
	ldr	w1, [x24]
	mov	x0, x22
	bl	_roundup
	mov	x23, x0
	str	x0, [x19]
	str	w23, [sp, #12]
Lloh4:
	adrp	x1, l_.str.3@PAGE
Lloh5:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, #0
	bl	_file_findfile
	mov	x22, x0
	cbnz	x0, LBB0_8
; %bb.6:
Lloh6:
	adrp	x1, l_.str.4@PAGE
Lloh7:
	add	x1, x1, l_.str.4@PAGEOFF
	bl	_file_findfile
	mov	x22, x0
	cbnz	x0, LBB0_8
; %bb.7:
Lloh8:
	adrp	x0, l_.str.5@PAGE
Lloh9:
	add	x0, x0, l_.str.5@PAGEOFF
	bl	_panic
LBB0_8:
	str	wzr, [sp, #20]
Lloh10:
	adrp	x8, _MODINFOMD_HOWTO@GOTPAGE
Lloh11:
	ldr	x8, [x8, _MODINFOMD_HOWTO@GOTPAGEOFF]
Lloh12:
	ldr	w1, [x8]
	add	x3, sp, #8
	mov	x0, x22
	mov	w2, #4
	bl	_file_addmetadata
Lloh13:
	adrp	x25, _MODINFOMD_ENVP@GOTPAGE
Lloh14:
	ldr	x25, [x25, _MODINFOMD_ENVP@GOTPAGEOFF]
	ldr	w1, [x25]
	add	x3, sp, #16
	mov	x0, x22
	mov	w2, #4
	bl	_file_addmetadata
Lloh15:
	adrp	x26, _MODINFOMD_KERNEND@GOTPAGE
Lloh16:
	ldr	x26, [x26, _MODINFOMD_KERNEND@GOTPAGEOFF]
	ldr	w1, [x26]
	add	x3, sp, #20
	mov	x0, x22
	mov	w2, #4
	bl	_file_addmetadata
Lloh17:
	adrp	x8, _MODINFOMD_MODULEP@GOTPAGE
Lloh18:
	ldr	x8, [x8, _MODINFOMD_MODULEP@GOTPAGEOFF]
Lloh19:
	ldr	w1, [x8]
	add	x3, sp, #12
	mov	x0, x22
	mov	w2, #4
	bl	_file_addmetadata
	cbz	w21, LBB0_10
; %bb.9:
	mov	x0, x22
	bl	_bios_addsmapdata
LBB0_10:
	mov	x0, #0
	bl	_bi_copymodules64
	add	x0, x0, x23
	ldr	w1, [x24]
	bl	_roundup
	str	w0, [sp, #16]
                                        ; kill: def $w0 killed $w0 killed $x0
	bl	_bi_copyenv
	ldr	w1, [x24]
	bl	_roundup
	str	w0, [sp, #20]
	sxtw	x8, w0
	str	x8, [x20]
	ldr	w1, [x26]
	mov	x0, x22
	bl	_file_findmetadata
	ldr	w1, [x0]
	add	x0, sp, #20
	mov	w2, #4
	bl	_bcopy
	ldr	w1, [x25]
	mov	x0, x22
	bl	_file_findmetadata
	ldr	w1, [x0]
	add	x0, sp, #16
	mov	w2, #4
	bl	_bcopy
	ldr	x0, [x19]
	bl	_bi_copymodules64
	mov	w0, #0
	b	LBB0_14
LBB0_11:
Lloh20:
	adrp	x0, l_str@PAGE
Lloh21:
	add	x0, x0, l_str@PAGEOFF
	b	LBB0_13
LBB0_12:
Lloh22:
	adrp	x0, l_str.6@PAGE
Lloh23:
	add	x0, x0, l_str.6@PAGEOFF
LBB0_13:
	bl	_puts
Lloh24:
	adrp	x8, _EINVAL@GOTPAGE
Lloh25:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh26:
	ldr	w0, [x8]
LBB0_14:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpAdd	Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.section	__TEXT,__cstring,cstring_literals
l_.str.1:                               ; @.str.1
	.asciz	"rootdev"

	.comm	_PAGE_SIZE,4,2                  ; @PAGE_SIZE
l_.str.3:                               ; @.str.3
	.asciz	"elf kernel"

l_.str.4:                               ; @.str.4
	.asciz	"elf64 kernel"

l_.str.5:                               ; @.str.5
	.asciz	"can't find kernel file"

	.comm	_MODINFOMD_HOWTO,4,2            ; @MODINFOMD_HOWTO
	.comm	_MODINFOMD_ENVP,4,2             ; @MODINFOMD_ENVP
	.comm	_MODINFOMD_KERNEND,4,2          ; @MODINFOMD_KERNEND
	.comm	_MODINFOMD_MODULEP,4,2          ; @MODINFOMD_MODULEP
l_str:                                  ; @str
	.asciz	"CPU doesn't support long mode"

l_str.6:                                ; @str.6
	.asciz	"can't determine root device"

.subsections_via_symbols
