	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function gmc_v9_0_flush_gpu_tlb
_gmc_v9_0_flush_gpu_tlb:                ## @gmc_v9_0_flush_gpu_tlb
	.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
	movq	%rcx, %r15
	movq	%rdx, %r13
	movq	%rsi, %rbx
	movq	%rdi, %r14
	xorl	%edi, %edi
	cmpq	%rdx, (%r14)
	setbe	%dil
	callq	_BUG_ON
	movq	32(%r14), %rax
	movq	%r13, %r12
	shlq	$4, %r12
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	addq	%r12, %rax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	movq	%rbx, %rdi
	movq	%r15, %rsi
	callq	_gmc_v9_0_get_invalidate_req
	movq	%rax, %rbx
	cmpq	$0, 24(%r14)
	je	LBB0_4
## %bb.1:
	movq	%r14, %rdi
	callq	_amdgpu_sriov_runtime
	testq	%rax, %rax
	je	LBB0_2
LBB0_3:
	cmpl	$0, 20(%r14)
	jne	LBB0_4
## %bb.13:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %rsi
	addq	$17, %rsi
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movq	8(%rax,%r12), %rdx
	addq	$17, %rdx
	movl	$1, %r8d
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
                                        ## kill: def $cl killed $cl killed $rcx
	shll	%cl, %r8d
	movq	%r14, %rdi
	movq	%rbx, %rcx
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_amdgpu_virt_kiq_reg_write_reg_wait ## TAILCALL
LBB0_2:
	movq	%r14, %rdi
	callq	_amdgpu_sriov_vf
	testl	%eax, %eax
	je	LBB0_3
LBB0_4:
	movq	%r13, -72(%rbp)                 ## 8-byte Spill
	leaq	16(%r14), %r13
	movq	%r13, %rdi
	callq	_spin_lock
	movq	-64(%rbp), %r15                 ## 8-byte Reload
	movq	(%r15), %rdi
	addq	$17, %rdi
	movq	%rbx, %rsi
	callq	_WREG32_NO_KIQ
	movq	_AMDGPU_GFXHUB_0@GOTPCREL(%rip), %rax
	movq	-72(%rbp), %rcx                 ## 8-byte Reload
	cmpq	%rcx, (%rax)
	jne	LBB0_6
## %bb.5:
	movq	(%r15), %rdi
	addq	$17, %rdi
	callq	_RREG32_NO_KIQ
LBB0_6:
	cmpq	$0, 8(%r14)
	jle	LBB0_7
## %bb.8:
	movl	$1, %eax
	movq	-56(%rbp), %rcx                 ## 8-byte Reload
                                        ## kill: def $cl killed $cl killed $rcx
	shll	%cl, %eax
	movq	-48(%rbp), %rcx                 ## 8-byte Reload
	leaq	(%rcx,%r12), %r15
	addq	$8, %r15
	movslq	%eax, %r12
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r15), %rdi
	addq	$17, %rdi
	callq	_RREG32_NO_KIQ
	testq	%r12, %rax
	jne	LBB0_11
## %bb.10:                              ##   in Loop: Header=BB0_9 Depth=1
	movl	$1, %edi
	callq	_udelay
	incq	%rbx
	cmpq	8(%r14), %rbx
	jl	LBB0_9
	jmp	LBB0_11
LBB0_7:
	xorl	%ebx, %ebx
LBB0_11:
	movq	%r13, %rdi
	callq	_spin_unlock
	cmpq	8(%r14), %rbx
	jge	LBB0_14
## %bb.12:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_14:
	leaq	L_.str(%rip), %rdi
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_DRM_ERROR                      ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_AMDGPU_GFXHUB_0,8,3            ## @AMDGPU_GFXHUB_0
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Timeout waiting for VM flush ACK!\n"

	.no_dead_strip	_gmc_v9_0_flush_gpu_tlb
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function gmc_v9_0_flush_gpu_tlb
_gmc_v9_0_flush_gpu_tlb:                ; @gmc_v9_0_flush_gpu_tlb
	.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	x22, x3
	mov	x21, x2
	mov	x20, x1
	mov	x19, x0
	ldr	x8, [x0]
	cmp	x8, x2
	cset	w0, ls
	bl	_BUG_ON
	ldr	x24, [x19, #32]
	add	x25, x24, x21, lsl #4
	mov	x0, x20
	mov	x1, x22
	bl	_gmc_v9_0_get_invalidate_req
	mov	x23, x0
	ldr	x8, [x19, #24]
	cbz	x8, LBB0_5
; %bb.1:
	mov	x0, x19
	bl	_amdgpu_sriov_runtime
	cbz	x0, LBB0_4
LBB0_2:
	ldr	w8, [x19, #20]
	cbnz	w8, LBB0_5
; %bb.3:
	ldr	x8, [x25]
	add	x1, x8, #17
	add	x8, x24, x21, lsl #4
	ldr	x8, [x8, #8]
	add	x2, x8, #17
	mov	w8, #1
	lsl	w4, w8, w20
	mov	x0, x19
	mov	x3, x23
	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	_amdgpu_virt_kiq_reg_write_reg_wait
LBB0_4:
	mov	x0, x19
	bl	_amdgpu_sriov_vf
	cbz	w0, LBB0_2
LBB0_5:
	add	x22, x19, #16
	mov	x0, x22
	bl	_spin_lock
	ldr	x8, [x25]
	add	x0, x8, #17
	mov	x1, x23
	bl	_WREG32_NO_KIQ
Lloh0:
	adrp	x8, _AMDGPU_GFXHUB_0@GOTPAGE
Lloh1:
	ldr	x8, [x8, _AMDGPU_GFXHUB_0@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	cmp	x8, x21
	b.ne	LBB0_7
; %bb.6:
	ldr	x8, [x25]
	add	x0, x8, #17
	bl	_RREG32_NO_KIQ
LBB0_7:
	ldr	x8, [x19, #8]
	cmp	x8, #1
	b.lt	LBB0_11
; %bb.8:
	mov	x23, #0
	add	x8, x24, x21, lsl #4
	add	x21, x8, #8
	mov	w8, #1
	lsl	w8, w8, w20
	sxtw	x20, w8
LBB0_9:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x21]
	add	x0, x8, #17
	bl	_RREG32_NO_KIQ
	tst	x0, x20
	b.ne	LBB0_12
; %bb.10:                               ;   in Loop: Header=BB0_9 Depth=1
	mov	w0, #1
	bl	_udelay
	add	x23, x23, #1
	ldr	x8, [x19, #8]
	cmp	x23, x8
	b.lt	LBB0_9
	b	LBB0_12
LBB0_11:
	mov	x23, #0
LBB0_12:
	mov	x0, x22
	bl	_spin_unlock
	ldr	x8, [x19, #8]
	cmp	x23, x8
	b.ge	LBB0_14
; %bb.13:
	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
	ret
LBB0_14:
Lloh3:
	adrp	x0, l_.str@PAGE
Lloh4:
	add	x0, x0, l_.str@PAGEOFF
	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	_DRM_ERROR
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_AMDGPU_GFXHUB_0,8,3            ; @AMDGPU_GFXHUB_0
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Timeout waiting for VM flush ACK!\n"

	.no_dead_strip	_gmc_v9_0_flush_gpu_tlb
.subsections_via_symbols
