	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_cik_sdma_vm_set_pages          ## -- Begin function cik_sdma_vm_set_pages
	.p2align	4, 0x90
_cik_sdma_vm_set_pages:                 ## @cik_sdma_vm_set_pages
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	testl	%r8d, %r8d
	je	LBB0_3
## %bb.1:
	movl	%r8d, %r12d
	movl	%edx, %r13d
	movq	%rsi, %rbx
	movl	%r9d, -44(%rbp)                 ## 4-byte Spill
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	%ecx, -48(%rbp)                 ## 4-byte Spill
	cmpl	$524287, %r12d                  ## imm = 0x7FFFF
	movl	$524287, %r15d                  ## imm = 0x7FFFF
	cmovbl	%r12d, %r15d
	movq	_R600_PTE_VALID@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	movl	16(%rbp), %eax
	andl	%eax, %r14d
	cmovnel	%ecx, %r14d
	movq	_SDMA_OPCODE_GENERATE_PTE_PDE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	xorl	%esi, %esi
	xorl	%edx, %edx
	callq	_SDMA_PACKET
	movq	(%rbx), %rcx
	movslq	8(%rbx), %rdx
	leal	1(%rdx), %esi
	movl	%esi, 8(%rbx)
	movl	%eax, (%rcx,%rdx,4)
	movslq	8(%rbx), %rax
	leal	1(%rax), %edx
	movl	%edx, 8(%rbx)
	movl	%r13d, (%rcx,%rax,4)
	movl	%r13d, %edi
	callq	_upper_32_bits
	movq	(%rbx), %rcx
	movslq	8(%rbx), %rdx
	leal	1(%rdx), %esi
	movl	%esi, 8(%rbx)
	movl	%eax, (%rcx,%rdx,4)
	movslq	8(%rbx), %rax
	leal	1(%rax), %edx
	movl	%edx, 8(%rbx)
	movl	16(%rbp), %edx
	movl	%edx, (%rcx,%rax,4)
	movslq	8(%rbx), %rax
	leal	1(%rax), %edx
	movl	%edx, 8(%rbx)
	movl	$0, (%rcx,%rax,4)
	movslq	8(%rbx), %rax
	leal	1(%rax), %edx
	movl	%edx, 8(%rbx)
	movl	%r14d, (%rcx,%rax,4)
	movl	%r14d, %edi
	callq	_upper_32_bits
	movl	-44(%rbp), %r9d                 ## 4-byte Reload
	movq	(%rbx), %rcx
	movslq	8(%rbx), %rdx
	leal	1(%rdx), %esi
	movl	%esi, 8(%rbx)
	movl	%eax, (%rcx,%rdx,4)
	movslq	8(%rbx), %rax
	leal	1(%rax), %edx
	movl	%edx, 8(%rbx)
	movl	%r9d, (%rcx,%rax,4)
	movslq	8(%rbx), %rax
	leal	1(%rax), %edx
	movl	%edx, 8(%rbx)
	movl	$0, (%rcx,%rax,4)
	movslq	8(%rbx), %rax
	leal	1(%rax), %edx
	movl	%edx, 8(%rbx)
	movl	%r15d, (%rcx,%rax,4)
	movl	-48(%rbp), %ecx                 ## 4-byte Reload
	leal	(%r13,%r15,8), %r13d
	movl	%r15d, %eax
	imull	%r9d, %eax
	addl	%eax, %ecx
	subl	%r15d, %r12d
	jne	LBB0_2
LBB0_3:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_R600_PTE_VALID,4,2             ## @R600_PTE_VALID
	.comm	_SDMA_OPCODE_GENERATE_PTE_PDE,4,2 ## @SDMA_OPCODE_GENERATE_PTE_PDE
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_cik_sdma_vm_set_pages          ; -- Begin function cik_sdma_vm_set_pages
	.p2align	2
_cik_sdma_vm_set_pages:                 ; @cik_sdma_vm_set_pages
	.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
	cbz	w4, LBB0_3
; %bb.1:
	mov	x19, x6
	mov	x20, x5
	mov	x21, x4
	mov	x22, x3
	mov	x23, x2
	mov	x24, x1
	mov	w26, #524287
Lloh0:
	adrp	x28, _SDMA_OPCODE_GENERATE_PTE_PDE@GOTPAGE
Lloh1:
	ldr	x28, [x28, _SDMA_OPCODE_GENERATE_PTE_PDE@GOTPAGEOFF]
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	cmp	w21, w26
	csel	w27, w21, w26, lo
Lloh2:
	adrp	x8, _R600_PTE_VALID@GOTPAGE
Lloh3:
	ldr	x8, [x8, _R600_PTE_VALID@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	tst	w8, w19
	csel	w25, wzr, w22, eq
	ldr	w0, [x28]
	mov	w1, #0
	mov	w2, #0
	bl	_SDMA_PACKET
	ldr	x8, [x24]
	ldrsw	x9, [x24, #8]
	add	w10, w9, #1
	str	w10, [x24, #8]
	str	w0, [x8, x9, lsl #2]
	ldrsw	x9, [x24, #8]
	add	w10, w9, #1
	str	w10, [x24, #8]
	str	w23, [x8, x9, lsl #2]
	mov	x0, x23
	bl	_upper_32_bits
	ldr	x8, [x24]
	ldrsw	x9, [x24, #8]
	add	w10, w9, #1
	str	w10, [x24, #8]
	str	w0, [x8, x9, lsl #2]
	ldrsw	x9, [x24, #8]
	add	w10, w9, #1
	str	w10, [x24, #8]
	str	w19, [x8, x9, lsl #2]
	ldrsw	x9, [x24, #8]
	add	w10, w9, #1
	str	w10, [x24, #8]
	str	wzr, [x8, x9, lsl #2]
	ldrsw	x9, [x24, #8]
	add	w10, w9, #1
	str	w10, [x24, #8]
	str	w25, [x8, x9, lsl #2]
	mov	x0, x25
	bl	_upper_32_bits
	ldr	x8, [x24]
	ldrsw	x9, [x24, #8]
	add	w10, w9, #1
	str	w10, [x24, #8]
	str	w0, [x8, x9, lsl #2]
	ldrsw	x9, [x24, #8]
	add	w10, w9, #1
	str	w10, [x24, #8]
	str	w20, [x8, x9, lsl #2]
	ldrsw	x9, [x24, #8]
	add	w10, w9, #1
	str	w10, [x24, #8]
	str	wzr, [x8, x9, lsl #2]
	ldrsw	x9, [x24, #8]
	add	w10, w9, #1
	str	w10, [x24, #8]
	str	w27, [x8, x9, lsl #2]
	add	w23, w23, w27, lsl #3
	madd	w22, w27, w20, w22
	subs	w21, w21, w27
	b.ne	LBB0_2
LBB0_3:
	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
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_R600_PTE_VALID,4,2             ; @R600_PTE_VALID
	.comm	_SDMA_OPCODE_GENERATE_PTE_PDE,4,2 ; @SDMA_OPCODE_GENERATE_PTE_PDE
.subsections_via_symbols
