	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal16,16byte_literals
	.p2align	4                               ## -- Begin function moea64_mid_bootstrap
LCPI0_0:
	.quad	1                               ## 0x1
	.quad	2                               ## 0x2
LCPI0_1:
	.quad	3                               ## 0x3
	.quad	4                               ## 0x4
LCPI0_2:
	.quad	5                               ## 0x5
	.quad	6                               ## 0x6
LCPI0_3:
	.quad	7                               ## 0x7
	.quad	8                               ## 0x8
LCPI0_4:
	.quad	9                               ## 0x9
	.quad	10                              ## 0xa
LCPI0_5:
	.quad	11                              ## 0xb
	.quad	12                              ## 0xc
LCPI0_6:
	.quad	13                              ## 0xd
	.quad	14                              ## 0xe
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_moea64_mid_bootstrap
	.p2align	4, 0x90
_moea64_mid_bootstrap:                  ## @moea64_mid_bootstrap
	.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
	movl	%edx, -52(%rbp)                 ## 4-byte Spill
	movl	%esi, -48(%rbp)                 ## 4-byte Spill
	movl	%edi, -44(%rbp)                 ## 4-byte Spill
	movq	_moea64_pteg_count@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	decq	%rax
	movq	_moea64_pteg_mask@GOTPCREL(%rip), %rcx
	movq	%rax, (%rcx)
	movq	_MTX_DEF@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	_moea64_slb_mutex@GOTPCREL(%rip), %rdi
	leaq	L_.str(%rip), %rsi
	xorl	%edx, %edx
	callq	_mtx_init
	movq	_PV_LOCK_COUNT@GOTPCREL(%rip), %r14
	cmpl	$0, (%r14)
	jle	LBB0_3
## %bb.1:
	xorl	%r15d, %r15d
	movq	_pv_lock@GOTPCREL(%rip), %r12
	leaq	L_.str.1(%rip), %rbx
	xorl	%r13d, %r13d
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r12), %rdi
	addq	%r15, %rdi
	movq	_MTX_DEF@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movq	%rbx, %rsi
	xorl	%edx, %edx
	callq	_mtx_init
	incq	%r13
	movslq	(%r14), %rax
	addq	$4, %r15
	cmpq	%rax, %r13
	jl	LBB0_2
LBB0_3:
	movq	_moea64_bpvo_pool_size@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	shll	$2, %edi
	movq	_PAGE_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	callq	_moea64_bootstrap_alloc
	movq	_moea64_bpvo_pool@GOTPCREL(%rip), %rbx
	movq	%rax, (%rbx)
	movq	_moea64_bpvo_pool_index@GOTPCREL(%rip), %rcx
	movq	$0, (%rcx)
	movq	_hw_direct_map@GOTPCREL(%rip), %rcx
	cmpq	$0, (%rcx)
	je	LBB0_5
## %bb.4:
	movq	%rax, %rdi
	callq	_PHYS_TO_DMAP
	movq	%rax, (%rbx)
LBB0_5:
	movq	_KERNEL_VSIDBITS@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movq	_VSID_NBPW@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	%esi, %eax
	cltd
	idivl	%edi
	movl	%edx, %ecx
	movl	$1, %ebx
                                        ## kill: def $cl killed $cl killed $ecx
	shll	%cl, %ebx
	movq	_moea64_vsid_bitmap@GOTPCREL(%rip), %rax
	movq	(%rax), %rcx
	movq	_NVSIDS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	decl	%eax
	andl	%esi, %eax
	cltd
	idivl	%edi
	cltq
	orl	%ebx, (%rcx,%rax,4)
	orb	$1, (%rcx)
	movq	_kernel_pmap@GOTPCREL(%rip), %rbx
	movq	(%rbx), %rdi
	movq	16(%rdi), %rax
	movq	_EMPTY_SEGMENT@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rdx
	movq	%rdx, (%rax)
	movq	(%rcx), %rcx
	movq	%rcx, %xmm0
	pshufd	$68, %xmm0, %xmm0               ## xmm0 = xmm0[0,1,0,1]
	movdqa	LCPI0_0(%rip), %xmm1            ## xmm1 = [1,2]
	paddq	%xmm0, %xmm1
	movdqu	%xmm1, 8(%rax)
	movdqa	LCPI0_1(%rip), %xmm1            ## xmm1 = [3,4]
	paddq	%xmm0, %xmm1
	movdqu	%xmm1, 24(%rax)
	movdqa	LCPI0_2(%rip), %xmm1            ## xmm1 = [5,6]
	paddq	%xmm0, %xmm1
	movdqu	%xmm1, 40(%rax)
	movdqa	LCPI0_3(%rip), %xmm1            ## xmm1 = [7,8]
	paddq	%xmm0, %xmm1
	movdqu	%xmm1, 56(%rax)
	movdqa	LCPI0_4(%rip), %xmm1            ## xmm1 = [9,10]
	paddq	%xmm0, %xmm1
	movdqu	%xmm1, 72(%rax)
	movdqa	LCPI0_5(%rip), %xmm1            ## xmm1 = [11,12]
	paddq	%xmm0, %xmm1
	movdqu	%xmm1, 88(%rax)
	paddq	LCPI0_6(%rip), %xmm0
	movdqu	%xmm0, 104(%rax)
	addq	$15, %rcx
	movq	%rcx, 120(%rax)
	movq	%rdi, 8(%rdi)
	addq	$4, %rdi
	callq	_CPU_FILL
	movq	(%rbx), %rdi
	callq	_RB_INIT
	movq	(%rbx), %rdi
	callq	_PMAP_LOCK_INIT
	movl	-44(%rbp), %edi                 ## 4-byte Reload
	movl	-48(%rbp), %esi                 ## 4-byte Reload
	movl	-52(%rbp), %edx                 ## 4-byte Reload
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_moea64_setup_direct_map        ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_moea64_pteg_count,8,3          ## @moea64_pteg_count
	.comm	_moea64_pteg_mask,8,3           ## @moea64_pteg_mask
	.comm	_moea64_slb_mutex,4,2           ## @moea64_slb_mutex
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"SLB table"

	.comm	_MTX_DEF,4,2                    ## @MTX_DEF
	.comm	_PV_LOCK_COUNT,4,2              ## @PV_LOCK_COUNT
	.comm	_pv_lock,8,3                    ## @pv_lock
L_.str.1:                               ## @.str.1
	.asciz	"page pv"

	.comm	_moea64_bpvo_pool_size,4,2      ## @moea64_bpvo_pool_size
	.comm	_PAGE_SIZE,4,2                  ## @PAGE_SIZE
	.comm	_moea64_bpvo_pool,8,3           ## @moea64_bpvo_pool
	.comm	_moea64_bpvo_pool_index,8,3     ## @moea64_bpvo_pool_index
	.comm	_hw_direct_map,8,3              ## @hw_direct_map
	.comm	_KERNEL_VSIDBITS,4,2            ## @KERNEL_VSIDBITS
	.comm	_VSID_NBPW,4,2                  ## @VSID_NBPW
	.comm	_moea64_vsid_bitmap,8,3         ## @moea64_vsid_bitmap
	.comm	_NVSIDS,4,2                     ## @NVSIDS
	.comm	_EMPTY_SEGMENT,8,3              ## @EMPTY_SEGMENT
	.comm	_kernel_pmap,8,3                ## @kernel_pmap
	.comm	_pcpup,8,3                      ## @pcpup
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal16,16byte_literals
	.p2align	4                               ; -- Begin function moea64_mid_bootstrap
lCPI0_0:
	.quad	1                               ; 0x1
	.quad	2                               ; 0x2
lCPI0_1:
	.quad	3                               ; 0x3
	.quad	4                               ; 0x4
lCPI0_2:
	.quad	5                               ; 0x5
	.quad	6                               ; 0x6
lCPI0_3:
	.quad	7                               ; 0x7
	.quad	8                               ; 0x8
lCPI0_4:
	.quad	9                               ; 0x9
	.quad	10                              ; 0xa
lCPI0_5:
	.quad	11                              ; 0xb
	.quad	12                              ; 0xc
lCPI0_6:
	.quad	13                              ; 0xd
	.quad	14                              ; 0xe
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_moea64_mid_bootstrap
	.p2align	2
_moea64_mid_bootstrap:                  ; @moea64_mid_bootstrap
	.cfi_startproc
; %bb.0:
	stp	x28, x27, [sp, #-96]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x19, x2
	mov	x20, x1
	mov	x21, x0
Lloh0:
	adrp	x8, _moea64_pteg_count@GOTPAGE
Lloh1:
	ldr	x8, [x8, _moea64_pteg_count@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	sub	x8, x8, #1
Lloh3:
	adrp	x9, _moea64_pteg_mask@GOTPAGE
Lloh4:
	ldr	x9, [x9, _moea64_pteg_mask@GOTPAGEOFF]
Lloh5:
	str	x8, [x9]
Lloh6:
	adrp	x23, _MTX_DEF@GOTPAGE
Lloh7:
	ldr	x23, [x23, _MTX_DEF@GOTPAGEOFF]
	ldr	w3, [x23]
Lloh8:
	adrp	x0, _moea64_slb_mutex@GOTPAGE
Lloh9:
	ldr	x0, [x0, _moea64_slb_mutex@GOTPAGEOFF]
Lloh10:
	adrp	x1, l_.str@PAGE
Lloh11:
	add	x1, x1, l_.str@PAGEOFF
	mov	x2, #0
	bl	_mtx_init
Lloh12:
	adrp	x24, _PV_LOCK_COUNT@GOTPAGE
Lloh13:
	ldr	x24, [x24, _PV_LOCK_COUNT@GOTPAGEOFF]
	ldr	w8, [x24]
	cmp	w8, #1
	b.lt	LBB0_3
; %bb.1:
	mov	x25, #0
	mov	x26, #0
Lloh14:
	adrp	x27, _pv_lock@GOTPAGE
Lloh15:
	ldr	x27, [x27, _pv_lock@GOTPAGEOFF]
Lloh16:
	adrp	x22, l_.str.1@PAGE
Lloh17:
	add	x22, x22, l_.str.1@PAGEOFF
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x27]
	add	x0, x8, x25
	ldr	w3, [x23]
	mov	x1, x22
	mov	x2, #0
	bl	_mtx_init
	add	x26, x26, #1
	ldrsw	x8, [x24]
	add	x25, x25, #4
	cmp	x26, x8
	b.lt	LBB0_2
LBB0_3:
Lloh18:
	adrp	x8, _moea64_bpvo_pool_size@GOTPAGE
Lloh19:
	ldr	x8, [x8, _moea64_bpvo_pool_size@GOTPAGEOFF]
Lloh20:
	ldr	w8, [x8]
	lsl	w0, w8, #2
Lloh21:
	adrp	x8, _PAGE_SIZE@GOTPAGE
Lloh22:
	ldr	x8, [x8, _PAGE_SIZE@GOTPAGEOFF]
Lloh23:
	ldr	w1, [x8]
	bl	_moea64_bootstrap_alloc
Lloh24:
	adrp	x22, _moea64_bpvo_pool@GOTPAGE
Lloh25:
	ldr	x22, [x22, _moea64_bpvo_pool@GOTPAGEOFF]
	str	x0, [x22]
Lloh26:
	adrp	x8, _moea64_bpvo_pool_index@GOTPAGE
Lloh27:
	ldr	x8, [x8, _moea64_bpvo_pool_index@GOTPAGEOFF]
Lloh28:
	str	xzr, [x8]
Lloh29:
	adrp	x8, _hw_direct_map@GOTPAGE
Lloh30:
	ldr	x8, [x8, _hw_direct_map@GOTPAGEOFF]
Lloh31:
	ldr	x8, [x8]
	cbz	x8, LBB0_5
; %bb.4:
	bl	_PHYS_TO_DMAP
	str	x0, [x22]
LBB0_5:
Lloh32:
	adrp	x8, _KERNEL_VSIDBITS@GOTPAGE
Lloh33:
	ldr	x8, [x8, _KERNEL_VSIDBITS@GOTPAGEOFF]
Lloh34:
	ldr	w8, [x8]
Lloh35:
	adrp	x9, _VSID_NBPW@GOTPAGE
Lloh36:
	ldr	x9, [x9, _VSID_NBPW@GOTPAGEOFF]
Lloh37:
	ldr	w9, [x9]
	sdiv	w10, w8, w9
	msub	w10, w10, w9, w8
	mov	w11, #1
Lloh38:
	adrp	x12, _moea64_vsid_bitmap@GOTPAGE
Lloh39:
	ldr	x12, [x12, _moea64_vsid_bitmap@GOTPAGEOFF]
	lsl	w10, w11, w10
Lloh40:
	ldr	x11, [x12]
Lloh41:
	adrp	x12, _NVSIDS@GOTPAGE
Lloh42:
	ldr	x12, [x12, _NVSIDS@GOTPAGEOFF]
Lloh43:
	ldr	w12, [x12]
	sub	w12, w12, #1
	and	w8, w12, w8
	sdiv	w8, w8, w9
	sbfiz	x8, x8, #2, #32
	ldr	w9, [x11, x8]
	orr	w9, w9, w10
	str	w9, [x11, x8]
	ldr	w8, [x11]
	orr	w8, w8, #0x1
Lloh44:
	adrp	x22, _kernel_pmap@GOTPAGE
Lloh45:
	ldr	x22, [x22, _kernel_pmap@GOTPAGEOFF]
	str	w8, [x11]
	ldr	x8, [x22]
	ldr	x9, [x8, #16]
Lloh46:
	adrp	x10, _EMPTY_SEGMENT@GOTPAGE
Lloh47:
	ldr	x10, [x10, _EMPTY_SEGMENT@GOTPAGEOFF]
	ldr	x11, [x10]
	str	x11, [x9]
	ldr	x10, [x10]
	dup.2d	v0, x10
Lloh48:
	adrp	x11, lCPI0_0@PAGE
Lloh49:
	ldr	q1, [x11, lCPI0_0@PAGEOFF]
	add.2d	v1, v0, v1
	stur	q1, [x9, #8]
Lloh50:
	adrp	x11, lCPI0_1@PAGE
Lloh51:
	ldr	q1, [x11, lCPI0_1@PAGEOFF]
	add.2d	v1, v0, v1
	stur	q1, [x9, #24]
Lloh52:
	adrp	x11, lCPI0_2@PAGE
Lloh53:
	ldr	q1, [x11, lCPI0_2@PAGEOFF]
	add.2d	v1, v0, v1
	stur	q1, [x9, #40]
Lloh54:
	adrp	x11, lCPI0_3@PAGE
Lloh55:
	ldr	q1, [x11, lCPI0_3@PAGEOFF]
	add.2d	v1, v0, v1
	stur	q1, [x9, #56]
Lloh56:
	adrp	x11, lCPI0_4@PAGE
Lloh57:
	ldr	q1, [x11, lCPI0_4@PAGEOFF]
	add.2d	v1, v0, v1
	stur	q1, [x9, #72]
Lloh58:
	adrp	x11, lCPI0_5@PAGE
Lloh59:
	ldr	q1, [x11, lCPI0_5@PAGEOFF]
	add.2d	v1, v0, v1
	stur	q1, [x9, #88]
Lloh60:
	adrp	x11, lCPI0_6@PAGE
Lloh61:
	ldr	q1, [x11, lCPI0_6@PAGEOFF]
	add.2d	v0, v0, v1
	stur	q0, [x9, #104]
	add	x10, x10, #15
	str	x10, [x9, #120]
	str	x8, [x8, #8]
	add	x0, x8, #4
	bl	_CPU_FILL
	ldr	x0, [x22]
	bl	_RB_INIT
	ldr	x0, [x22]
	bl	_PMAP_LOCK_INIT
	mov	x0, x21
	mov	x1, x20
	mov	x2, x19
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp], #96             ; 16-byte Folded Reload
	b	_moea64_setup_direct_map
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotStr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh29, Lloh30, Lloh31
	.loh AdrpLdrGotStr	Lloh26, Lloh27, Lloh28
	.loh AdrpLdrGot	Lloh24, Lloh25
	.loh AdrpLdrGotLdr	Lloh21, Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdr	Lloh60, Lloh61
	.loh AdrpAdrp	Lloh58, Lloh60
	.loh AdrpLdr	Lloh58, Lloh59
	.loh AdrpAdrp	Lloh56, Lloh58
	.loh AdrpLdr	Lloh56, Lloh57
	.loh AdrpAdrp	Lloh54, Lloh56
	.loh AdrpLdr	Lloh54, Lloh55
	.loh AdrpAdrp	Lloh52, Lloh54
	.loh AdrpLdr	Lloh52, Lloh53
	.loh AdrpAdrp	Lloh50, Lloh52
	.loh AdrpLdr	Lloh50, Lloh51
	.loh AdrpAdrp	Lloh48, Lloh50
	.loh AdrpLdr	Lloh48, Lloh49
	.loh AdrpLdrGot	Lloh46, Lloh47
	.loh AdrpLdrGot	Lloh44, Lloh45
	.loh AdrpLdrGotLdr	Lloh41, Lloh42, Lloh43
	.loh AdrpLdrGotLdr	Lloh38, Lloh39, Lloh40
	.loh AdrpLdrGotLdr	Lloh35, Lloh36, Lloh37
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.cfi_endproc
                                        ; -- End function
	.comm	_moea64_pteg_count,8,3          ; @moea64_pteg_count
	.comm	_moea64_pteg_mask,8,3           ; @moea64_pteg_mask
	.comm	_moea64_slb_mutex,4,2           ; @moea64_slb_mutex
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"SLB table"

	.comm	_MTX_DEF,4,2                    ; @MTX_DEF
	.comm	_PV_LOCK_COUNT,4,2              ; @PV_LOCK_COUNT
	.comm	_pv_lock,8,3                    ; @pv_lock
l_.str.1:                               ; @.str.1
	.asciz	"page pv"

	.comm	_moea64_bpvo_pool_size,4,2      ; @moea64_bpvo_pool_size
	.comm	_PAGE_SIZE,4,2                  ; @PAGE_SIZE
	.comm	_moea64_bpvo_pool,8,3           ; @moea64_bpvo_pool
	.comm	_moea64_bpvo_pool_index,8,3     ; @moea64_bpvo_pool_index
	.comm	_hw_direct_map,8,3              ; @hw_direct_map
	.comm	_KERNEL_VSIDBITS,4,2            ; @KERNEL_VSIDBITS
	.comm	_VSID_NBPW,4,2                  ; @VSID_NBPW
	.comm	_moea64_vsid_bitmap,8,3         ; @moea64_vsid_bitmap
	.comm	_NVSIDS,4,2                     ; @NVSIDS
	.comm	_EMPTY_SEGMENT,8,3              ; @EMPTY_SEGMENT
	.comm	_kernel_pmap,8,3                ; @kernel_pmap
	.comm	_pcpup,8,3                      ; @pcpup
.subsections_via_symbols
