	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_evergreen_pcie_gart_tlb_flush  ## -- Begin function evergreen_pcie_gart_tlb_flush
	.p2align	4, 0x90
_evergreen_pcie_gart_tlb_flush:         ## @evergreen_pcie_gart_tlb_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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r12
	movq	_HDP_MEM_COHERENCY_FLUSH_CNTL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	$1, %esi
	callq	_WREG32
	movq	_VM_CONTEXT0_REQUEST_RESPONSE@GOTPCREL(%rip), %r15
	movl	(%r15), %r14d
	movl	$1, %edi
	callq	_REQUEST_TYPE
	movl	%r14d, %edi
	movl	%eax, %esi
	callq	_WREG32
	cmpl	$0, (%r12)
	je	LBB0_6
## %bb.1:
	xorl	%ebx, %ebx
	movq	_RESPONSE_TYPE_MASK@GOTPCREL(%rip), %r14
	movq	_RESPONSE_TYPE_SHIFT@GOTPCREL(%rip), %r13
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r15), %edi
	callq	_RREG32
	andl	(%r14), %eax
	movzbl	(%r13), %ecx
	sarl	%cl, %eax
	testl	%eax, %eax
	jne	LBB0_3
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	$1, %edi
	callq	_udelay
	incl	%ebx
	cmpl	(%r12), %ebx
	jb	LBB0_2
	jmp	LBB0_6
LBB0_3:
	cmpl	$2, %eax
	jne	LBB0_6
## %bb.4:
	leaq	L_.str(%rip), %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_pr_warn                        ## TAILCALL
LBB0_6:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_HDP_MEM_COHERENCY_FLUSH_CNTL,4,2 ## @HDP_MEM_COHERENCY_FLUSH_CNTL
	.comm	_VM_CONTEXT0_REQUEST_RESPONSE,4,2 ## @VM_CONTEXT0_REQUEST_RESPONSE
	.comm	_RESPONSE_TYPE_MASK,4,2         ## @RESPONSE_TYPE_MASK
	.comm	_RESPONSE_TYPE_SHIFT,4,2        ## @RESPONSE_TYPE_SHIFT
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"[drm] r600 flush TLB failed\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_evergreen_pcie_gart_tlb_flush  ; -- Begin function evergreen_pcie_gart_tlb_flush
	.p2align	2
_evergreen_pcie_gart_tlb_flush:         ; @evergreen_pcie_gart_tlb_flush
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x19, x0
Lloh0:
	adrp	x8, _HDP_MEM_COHERENCY_FLUSH_CNTL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _HDP_MEM_COHERENCY_FLUSH_CNTL@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	mov	w1, #1
	bl	_WREG32
Lloh3:
	adrp	x21, _VM_CONTEXT0_REQUEST_RESPONSE@GOTPAGE
Lloh4:
	ldr	x21, [x21, _VM_CONTEXT0_REQUEST_RESPONSE@GOTPAGEOFF]
	ldr	w20, [x21]
	mov	w0, #1
	bl	_REQUEST_TYPE
	mov	x1, x0
	mov	x0, x20
	bl	_WREG32
	ldr	w8, [x19]
	cbz	w8, LBB0_6
; %bb.1:
	mov	w20, #0
Lloh5:
	adrp	x22, _RESPONSE_TYPE_MASK@GOTPAGE
Lloh6:
	ldr	x22, [x22, _RESPONSE_TYPE_MASK@GOTPAGEOFF]
Lloh7:
	adrp	x23, _RESPONSE_TYPE_SHIFT@GOTPAGE
Lloh8:
	ldr	x23, [x23, _RESPONSE_TYPE_SHIFT@GOTPAGEOFF]
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w0, [x21]
	bl	_RREG32
	ldr	w8, [x22]
	and	w8, w8, w0
	ldr	w9, [x23]
	asr	w8, w8, w9
	cbnz	w8, LBB0_4
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	mov	w0, #1
	bl	_udelay
	add	w20, w20, #1
	ldr	w8, [x19]
	cmp	w20, w8
	b.lo	LBB0_2
	b	LBB0_6
LBB0_4:
	cmp	w8, #2
	b.ne	LBB0_6
; %bb.5:
Lloh9:
	adrp	x0, l_.str@PAGE
Lloh10:
	add	x0, x0, l_.str@PAGEOFF
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	_pr_warn
LBB0_6:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpAdd	Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_HDP_MEM_COHERENCY_FLUSH_CNTL,4,2 ; @HDP_MEM_COHERENCY_FLUSH_CNTL
	.comm	_VM_CONTEXT0_REQUEST_RESPONSE,4,2 ; @VM_CONTEXT0_REQUEST_RESPONSE
	.comm	_RESPONSE_TYPE_MASK,4,2         ; @RESPONSE_TYPE_MASK
	.comm	_RESPONSE_TYPE_SHIFT,4,2        ; @RESPONSE_TYPE_SHIFT
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"[drm] r600 flush TLB failed\n"

.subsections_via_symbols
