	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_cik_dma_vm_flush               ## -- Begin function cik_dma_vm_flush
	.p2align	4, 0x90
_cik_dma_vm_flush:                      ## @cik_dma_vm_flush
	.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	%ecx, %r13d
	movl	%edx, %r15d
	movq	%rsi, %rbx
	movq	%rdi, -56(%rbp)                 ## 8-byte Spill
	xorl	%edi, %edi
	callq	_SDMA_POLL_REG_MEM_EXTRA_OP
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	xorl	%edi, %edi
	callq	_SDMA_POLL_REG_MEM_EXTRA_FUNC
	movl	%eax, %r12d
	movq	_SDMA_OPCODE_SRBM_WRITE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	xorl	%esi, %esi
	movl	$61440, %edx                    ## imm = 0xF000
	callq	_SDMA_PACKET
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_radeon_ring_write
	movq	%r15, %r14
	cmpl	$7, %r15d
	ja	LBB0_2
## %bb.1:
	movq	_VM_CONTEXT0_PAGE_TABLE_BASE_ADDR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	shrl	$2, %esi
	addl	%r14d, %esi
	andl	$1073741823, %esi               ## imm = 0x3FFFFFFF
	jmp	LBB0_3
LBB0_2:
	movq	_VM_CONTEXT8_PAGE_TABLE_BASE_ADDR@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	leal	(%rax,%r14,4), %esi
	addl	$-32, %esi
	shrl	$2, %esi
LBB0_3:
	movq	%rbx, %rdi
	callq	_radeon_ring_write
	orl	-44(%rbp), %r12d                ## 4-byte Folded Reload
	movl	%r12d, -44(%rbp)                ## 4-byte Spill
	sarl	$12, %r13d
	movq	%rbx, %rdi
	movl	%r13d, %esi
	callq	_radeon_ring_write
	movq	_SDMA_OPCODE_SRBM_WRITE@GOTPCREL(%rip), %r15
	movl	(%r15), %edi
	xorl	%esi, %esi
	movl	$61440, %edx                    ## imm = 0xF000
	callq	_SDMA_PACKET
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_radeon_ring_write
	movq	_SRBM_GFX_CNTL@GOTPCREL(%rip), %r12
	movl	(%r12), %esi
	sarl	$2, %esi
	movq	%rbx, %rdi
	callq	_radeon_ring_write
	movl	%r14d, %edi
	callq	_VMID
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_radeon_ring_write
	movl	(%r15), %edi
	xorl	%esi, %esi
	movl	$61440, %edx                    ## imm = 0xF000
	callq	_SDMA_PACKET
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_radeon_ring_write
	movq	_SH_MEM_BASES@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	sarl	$2, %esi
	movq	%rbx, %rdi
	callq	_radeon_ring_write
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_radeon_ring_write
	movl	(%r15), %edi
	xorl	%esi, %esi
	movl	$61440, %edx                    ## imm = 0xF000
	callq	_SDMA_PACKET
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_radeon_ring_write
	movq	_SH_MEM_CONFIG@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	sarl	$2, %esi
	movq	%rbx, %rdi
	callq	_radeon_ring_write
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_radeon_ring_write
	movl	(%r15), %edi
	xorl	%esi, %esi
	movl	$61440, %edx                    ## imm = 0xF000
	callq	_SDMA_PACKET
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_radeon_ring_write
	movq	_SH_MEM_APE1_BASE@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	sarl	$2, %esi
	movq	%rbx, %rdi
	callq	_radeon_ring_write
	movl	$1, %r13d
	movq	%rbx, %rdi
	movl	$1, %esi
	callq	_radeon_ring_write
	movl	(%r15), %edi
	xorl	%esi, %esi
	movl	$61440, %edx                    ## imm = 0xF000
	callq	_SDMA_PACKET
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_radeon_ring_write
	movq	_SH_MEM_APE1_LIMIT@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	sarl	$2, %esi
	movq	%rbx, %rdi
	callq	_radeon_ring_write
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_radeon_ring_write
	movl	(%r15), %edi
	xorl	%esi, %esi
	movl	$61440, %edx                    ## imm = 0xF000
	callq	_SDMA_PACKET
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_radeon_ring_write
	movl	(%r12), %esi
	sarl	$2, %esi
	movq	%rbx, %rdi
	callq	_radeon_ring_write
	xorl	%edi, %edi
	callq	_VMID
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_radeon_ring_write
	movl	(%rbx), %esi
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	callq	_cik_sdma_hdp_flush_ring_emit
	movl	(%r15), %edi
	xorl	%esi, %esi
	movl	$61440, %edx                    ## imm = 0xF000
	callq	_SDMA_PACKET
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_radeon_ring_write
	movq	_VM_INVALIDATE_REQUEST@GOTPCREL(%rip), %r15
	movl	(%r15), %esi
	sarl	$2, %esi
	movq	%rbx, %rdi
	callq	_radeon_ring_write
	movl	%r14d, %ecx
	shll	%cl, %r13d
	movq	%rbx, %rdi
	movl	%r13d, %esi
	callq	_radeon_ring_write
	movq	_SDMA_OPCODE_POLL_REG_MEM@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	xorl	%esi, %esi
	movl	-44(%rbp), %edx                 ## 4-byte Reload
	callq	_SDMA_PACKET
	movq	%rbx, %rdi
	movl	%eax, %esi
	callq	_radeon_ring_write
	movl	(%r15), %esi
	sarl	$2, %esi
	movq	%rbx, %rdi
	callq	_radeon_ring_write
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_radeon_ring_write
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_radeon_ring_write
	movq	%rbx, %rdi
	xorl	%esi, %esi
	callq	_radeon_ring_write
	movq	%rbx, %rdi
	movl	$268369930, %esi                ## imm = 0xFFF000A
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_radeon_ring_write              ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_SDMA_OPCODE_SRBM_WRITE,4,2     ## @SDMA_OPCODE_SRBM_WRITE
	.comm	_VM_CONTEXT0_PAGE_TABLE_BASE_ADDR,4,2 ## @VM_CONTEXT0_PAGE_TABLE_BASE_ADDR
	.comm	_VM_CONTEXT8_PAGE_TABLE_BASE_ADDR,4,2 ## @VM_CONTEXT8_PAGE_TABLE_BASE_ADDR
	.comm	_SRBM_GFX_CNTL,4,2              ## @SRBM_GFX_CNTL
	.comm	_SH_MEM_BASES,4,2               ## @SH_MEM_BASES
	.comm	_SH_MEM_CONFIG,4,2              ## @SH_MEM_CONFIG
	.comm	_SH_MEM_APE1_BASE,4,2           ## @SH_MEM_APE1_BASE
	.comm	_SH_MEM_APE1_LIMIT,4,2          ## @SH_MEM_APE1_LIMIT
	.comm	_VM_INVALIDATE_REQUEST,4,2      ## @VM_INVALIDATE_REQUEST
	.comm	_SDMA_OPCODE_POLL_REG_MEM,4,2   ## @SDMA_OPCODE_POLL_REG_MEM
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_cik_dma_vm_flush               ; -- Begin function cik_dma_vm_flush
	.p2align	2
_cik_dma_vm_flush:                      ; @cik_dma_vm_flush
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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	x23, x3
	mov	x20, x2
	mov	x19, x1
	mov	x21, x0
	mov	w0, #0
	bl	_SDMA_POLL_REG_MEM_EXTRA_OP
	mov	x22, x0
	mov	w0, #0
	bl	_SDMA_POLL_REG_MEM_EXTRA_FUNC
	mov	x24, x0
Lloh0:
	adrp	x25, _SDMA_OPCODE_SRBM_WRITE@GOTPAGE
Lloh1:
	ldr	x25, [x25, _SDMA_OPCODE_SRBM_WRITE@GOTPAGEOFF]
	ldr	w0, [x25]
	mov	w1, #0
	mov	w2, #61440
	bl	_SDMA_PACKET
	mov	x1, x0
	mov	x0, x19
	bl	_radeon_ring_write
	cmp	w20, #7
	b.hi	LBB0_2
; %bb.1:
Lloh2:
	adrp	x8, _VM_CONTEXT0_PAGE_TABLE_BASE_ADDR@GOTPAGE
Lloh3:
	ldr	x8, [x8, _VM_CONTEXT0_PAGE_TABLE_BASE_ADDR@GOTPAGEOFF]
Lloh4:
	ldr	w8, [x8]
	add	w8, w20, w8, lsr #2
	and	w1, w8, #0x3fffffff
	b	LBB0_3
LBB0_2:
Lloh5:
	adrp	x8, _VM_CONTEXT8_PAGE_TABLE_BASE_ADDR@GOTPAGE
Lloh6:
	ldr	x8, [x8, _VM_CONTEXT8_PAGE_TABLE_BASE_ADDR@GOTPAGEOFF]
Lloh7:
	ldr	w8, [x8]
	add	w8, w8, w20, lsl #2
	sub	w8, w8, #32
	lsr	w1, w8, #2
LBB0_3:
	mov	x0, x19
	bl	_radeon_ring_write
	orr	w22, w24, w22
	asr	w1, w23, #12
	mov	x0, x19
	bl	_radeon_ring_write
	ldr	w0, [x25]
	mov	w1, #0
	mov	w2, #61440
	bl	_SDMA_PACKET
	mov	x1, x0
	mov	x0, x19
	bl	_radeon_ring_write
Lloh8:
	adrp	x23, _SRBM_GFX_CNTL@GOTPAGE
Lloh9:
	ldr	x23, [x23, _SRBM_GFX_CNTL@GOTPAGEOFF]
	ldr	w8, [x23]
	asr	w1, w8, #2
	mov	x0, x19
	bl	_radeon_ring_write
	mov	x0, x20
	bl	_VMID
	mov	x1, x0
	mov	x0, x19
	bl	_radeon_ring_write
	ldr	w0, [x25]
	mov	w1, #0
	mov	w2, #61440
	bl	_SDMA_PACKET
	mov	x1, x0
	mov	x0, x19
	bl	_radeon_ring_write
Lloh10:
	adrp	x8, _SH_MEM_BASES@GOTPAGE
Lloh11:
	ldr	x8, [x8, _SH_MEM_BASES@GOTPAGEOFF]
Lloh12:
	ldr	w8, [x8]
	asr	w1, w8, #2
	mov	x0, x19
	bl	_radeon_ring_write
	mov	x0, x19
	mov	w1, #0
	bl	_radeon_ring_write
	ldr	w0, [x25]
	mov	w1, #0
	mov	w2, #61440
	bl	_SDMA_PACKET
	mov	x1, x0
	mov	x0, x19
	bl	_radeon_ring_write
Lloh13:
	adrp	x8, _SH_MEM_CONFIG@GOTPAGE
Lloh14:
	ldr	x8, [x8, _SH_MEM_CONFIG@GOTPAGEOFF]
Lloh15:
	ldr	w8, [x8]
	asr	w1, w8, #2
	mov	x0, x19
	bl	_radeon_ring_write
	mov	x0, x19
	mov	w1, #0
	bl	_radeon_ring_write
	ldr	w0, [x25]
	mov	w1, #0
	mov	w2, #61440
	bl	_SDMA_PACKET
	mov	x1, x0
	mov	x0, x19
	bl	_radeon_ring_write
Lloh16:
	adrp	x8, _SH_MEM_APE1_BASE@GOTPAGE
Lloh17:
	ldr	x8, [x8, _SH_MEM_APE1_BASE@GOTPAGEOFF]
Lloh18:
	ldr	w8, [x8]
	asr	w1, w8, #2
	mov	x0, x19
	bl	_radeon_ring_write
	mov	w24, #1
	mov	x0, x19
	mov	w1, #1
	bl	_radeon_ring_write
	ldr	w0, [x25]
	mov	w1, #0
	mov	w2, #61440
	bl	_SDMA_PACKET
	mov	x1, x0
	mov	x0, x19
	bl	_radeon_ring_write
Lloh19:
	adrp	x8, _SH_MEM_APE1_LIMIT@GOTPAGE
Lloh20:
	ldr	x8, [x8, _SH_MEM_APE1_LIMIT@GOTPAGEOFF]
Lloh21:
	ldr	w8, [x8]
	asr	w1, w8, #2
	mov	x0, x19
	bl	_radeon_ring_write
	mov	x0, x19
	mov	w1, #0
	bl	_radeon_ring_write
	ldr	w0, [x25]
	mov	w1, #0
	mov	w2, #61440
	bl	_SDMA_PACKET
	mov	x1, x0
	mov	x0, x19
	bl	_radeon_ring_write
	ldr	w8, [x23]
	asr	w1, w8, #2
	mov	x0, x19
	bl	_radeon_ring_write
	mov	w0, #0
	bl	_VMID
	mov	x1, x0
	mov	x0, x19
	bl	_radeon_ring_write
	ldr	w1, [x19]
	mov	x0, x21
	bl	_cik_sdma_hdp_flush_ring_emit
	ldr	w0, [x25]
	mov	w1, #0
	mov	w2, #61440
	bl	_SDMA_PACKET
	mov	x1, x0
	mov	x0, x19
	bl	_radeon_ring_write
Lloh22:
	adrp	x21, _VM_INVALIDATE_REQUEST@GOTPAGE
Lloh23:
	ldr	x21, [x21, _VM_INVALIDATE_REQUEST@GOTPAGEOFF]
	ldr	w8, [x21]
	asr	w1, w8, #2
	mov	x0, x19
	bl	_radeon_ring_write
	lsl	w1, w24, w20
	mov	x0, x19
	bl	_radeon_ring_write
Lloh24:
	adrp	x8, _SDMA_OPCODE_POLL_REG_MEM@GOTPAGE
Lloh25:
	ldr	x8, [x8, _SDMA_OPCODE_POLL_REG_MEM@GOTPAGEOFF]
Lloh26:
	ldr	w0, [x8]
	mov	w1, #0
	mov	x2, x22
	bl	_SDMA_PACKET
	mov	x1, x0
	mov	x0, x19
	bl	_radeon_ring_write
	ldr	w8, [x21]
	asr	w1, w8, #2
	mov	x0, x19
	bl	_radeon_ring_write
	mov	x0, x19
	mov	w1, #0
	bl	_radeon_ring_write
	mov	x0, x19
	mov	w1, #0
	bl	_radeon_ring_write
	mov	x0, x19
	mov	w1, #0
	bl	_radeon_ring_write
	mov	x0, x19
	mov	w1, #10
	movk	w1, #4095, lsl #16
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	b	_radeon_ring_write
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh24, Lloh25, Lloh26
	.loh AdrpLdrGot	Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGot	Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_SDMA_OPCODE_SRBM_WRITE,4,2     ; @SDMA_OPCODE_SRBM_WRITE
	.comm	_VM_CONTEXT0_PAGE_TABLE_BASE_ADDR,4,2 ; @VM_CONTEXT0_PAGE_TABLE_BASE_ADDR
	.comm	_VM_CONTEXT8_PAGE_TABLE_BASE_ADDR,4,2 ; @VM_CONTEXT8_PAGE_TABLE_BASE_ADDR
	.comm	_SRBM_GFX_CNTL,4,2              ; @SRBM_GFX_CNTL
	.comm	_SH_MEM_BASES,4,2               ; @SH_MEM_BASES
	.comm	_SH_MEM_CONFIG,4,2              ; @SH_MEM_CONFIG
	.comm	_SH_MEM_APE1_BASE,4,2           ; @SH_MEM_APE1_BASE
	.comm	_SH_MEM_APE1_LIMIT,4,2          ; @SH_MEM_APE1_LIMIT
	.comm	_VM_INVALIDATE_REQUEST,4,2      ; @VM_INVALIDATE_REQUEST
	.comm	_SDMA_OPCODE_POLL_REG_MEM,4,2   ; @SDMA_OPCODE_POLL_REG_MEM
.subsections_via_symbols
