	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function gmc_v8_0_process_interrupt
_gmc_v8_0_process_interrupt:            ## @gmc_v8_0_process_interrupt
	.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
	movq	%rdx, %rbx
	movq	%rdi, %r12
	callq	_amdgpu_sriov_vf
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movl	16(%r12), %edi
	movl	16(%rbx), %edx
	movq	8(%rbx), %rax
	movl	(%rax), %ecx
	leaq	L_.str(%rip), %rsi
	xorl	%eax, %eax
	callq	_dev_err
	movl	16(%r12), %edi
	leaq	L_.str.1(%rip), %rsi
	xorl	%eax, %eax
	callq	_dev_err
	jmp	LBB0_10
LBB0_2:
	movq	_mmVM_CONTEXT1_PROTECTION_FAULT_ADDR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_RREG32
	movl	%eax, %r14d
	movq	_mmVM_CONTEXT1_PROTECTION_FAULT_STATUS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_RREG32
	movl	%eax, %r15d
	movq	_mmVM_CONTEXT1_PROTECTION_FAULT_MCCLIENT@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_RREG32
	movl	%eax, %r13d
	movq	_mmVM_CONTEXT1_CNTL2@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	$1, %esi
	movl	$-2, %edx
	callq	_WREG32_P
	movl	%r14d, %eax
	orl	%r15d, %eax
	je	LBB0_10
## %bb.3:
	movq	_amdgpu_vm_fault_stop@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_AMDGPU_VM_FAULT_STOP_FIRST@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_5
## %bb.4:
	movq	%r12, %rdi
	xorl	%esi, %esi
	callq	_gmc_v8_0_set_fault_enable_default
LBB0_5:
	xorl	%eax, %eax
	callq	_printk_ratelimit
	testq	%rax, %rax
	je	LBB0_7
## %bb.6:
	movl	%r13d, -44(%rbp)                ## 4-byte Spill
	leaq	-64(%rbp), %r13
	movq	%r13, %rdi
	xorl	%esi, %esi
	movl	$16, %edx
	callq	_memset
	movl	(%rbx), %esi
	movq	%r12, %rdi
	movq	%r13, %rdx
	callq	_amdgpu_vm_get_task_info
	movl	16(%r12), %edi
	movl	16(%rbx), %edx
	movq	8(%rbx), %rax
	movl	(%rax), %ecx
	movl	-52(%rbp), %r8d
	movl	-56(%rbp), %r9d
	movl	-64(%rbp), %r10d
	movl	-60(%rbp), %r11d
	leaq	L_.str.2(%rip), %rsi
	xorl	%eax, %eax
	pushq	%r10
	pushq	%r11
	callq	_dev_err
	addq	$16, %rsp
	movl	16(%r12), %edi
	leaq	L_.str.3(%rip), %rsi
	movl	%r14d, %edx
	xorl	%eax, %eax
	callq	_dev_err
	movl	16(%r12), %edi
	leaq	L_.str.4(%rip), %rsi
	movl	%r15d, %edx
	xorl	%eax, %eax
	callq	_dev_err
	movl	(%rbx), %r8d
	movq	%r12, %rdi
	movl	%r15d, %esi
	movl	%r14d, %edx
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
	callq	_gmc_v8_0_vm_decode_fault
LBB0_7:
	movq	_VM_CONTEXT1_PROTECTION_FAULT_STATUS@GOTPCREL(%rip), %r13
	movl	(%r13), %esi
	movq	_VMID@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	%r15d, %edi
	callq	_REG_GET_FIELD
	movq	%rax, %rbx
	movq	%r12, %rdi
	movl	%ebx, %esi
	callq	_amdgpu_amdkfd_is_kfd_vmid
	testq	%rax, %rax
	je	LBB0_10
## %bb.8:
	movq	%r12, %rdi
	callq	_atomic_read
	testl	%eax, %eax
	jne	LBB0_10
## %bb.9:
	movl	%r14d, -44(%rbp)                ## 4-byte Spill
	movq	8(%r12), %r14
	movl	(%r13), %esi
	movq	_PROTECTIONS@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	%r15d, %edi
	callq	_REG_GET_FIELD
	movq	%r13, %rcx
	movq	%rax, %r13
	movl	%ebx, (%r14)
	movl	(%rcx), %esi
	movq	_MEMORY_CLIENT_ID@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	%r15d, %edi
	callq	_REG_GET_FIELD
	movq	%rax, 32(%r14)
	movl	%r15d, 4(%r14)
	movl	-44(%rbp), %eax                 ## 4-byte Reload
	movl	%eax, 8(%r14)
	xorl	%eax, %eax
	testb	$7, %r13b
	setne	%al
	movl	%eax, 12(%r14)
	movl	%r13d, %eax
	shrl	$3, %eax
	andl	$1, %eax
	movl	%eax, 16(%r14)
	movl	%r13d, %eax
	shrl	$4, %eax
	andl	$1, %eax
	movl	%eax, 20(%r14)
	shrl	$5, %r13d
	andl	$1, %r13d
	movl	%r13d, 24(%r14)
	xorl	%eax, %eax
	callq	_mb
	movq	%r12, %rdi
	movl	$1, %esi
	callq	_atomic_set
LBB0_10:
	xorl	%eax, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"GPU fault detected: %d 0x%08x\n"

L_.str.1:                               ## @.str.1
	.asciz	" Can't decode VM fault info here on SRIOV VF\n"

	.comm	_mmVM_CONTEXT1_PROTECTION_FAULT_ADDR,4,2 ## @mmVM_CONTEXT1_PROTECTION_FAULT_ADDR
	.comm	_mmVM_CONTEXT1_PROTECTION_FAULT_STATUS,4,2 ## @mmVM_CONTEXT1_PROTECTION_FAULT_STATUS
	.comm	_mmVM_CONTEXT1_PROTECTION_FAULT_MCCLIENT,4,2 ## @mmVM_CONTEXT1_PROTECTION_FAULT_MCCLIENT
	.comm	_mmVM_CONTEXT1_CNTL2,4,2        ## @mmVM_CONTEXT1_CNTL2
	.comm	_amdgpu_vm_fault_stop,8,3       ## @amdgpu_vm_fault_stop
	.comm	_AMDGPU_VM_FAULT_STOP_FIRST,8,3 ## @AMDGPU_VM_FAULT_STOP_FIRST
L_.str.2:                               ## @.str.2
	.asciz	"GPU fault detected: %d 0x%08x for process %s pid %d thread %s pid %d\n"

L_.str.3:                               ## @.str.3
	.asciz	"  VM_CONTEXT1_PROTECTION_FAULT_ADDR   0x%08X\n"

L_.str.4:                               ## @.str.4
	.asciz	"  VM_CONTEXT1_PROTECTION_FAULT_STATUS 0x%08X\n"

	.comm	_VM_CONTEXT1_PROTECTION_FAULT_STATUS,4,2 ## @VM_CONTEXT1_PROTECTION_FAULT_STATUS
	.comm	_VMID,4,2                       ## @VMID
	.comm	_PROTECTIONS,4,2                ## @PROTECTIONS
	.comm	_MEMORY_CLIENT_ID,4,2           ## @MEMORY_CLIENT_ID
	.no_dead_strip	_gmc_v8_0_process_interrupt
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal8,8byte_literals
	.p2align	3                               ; -- Begin function gmc_v8_0_process_interrupt
lCPI0_0:
	.long	4294967293                      ; 0xfffffffd
	.long	4294967292                      ; 0xfffffffc
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	2
_gmc_v8_0_process_interrupt:            ; @gmc_v8_0_process_interrupt
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #144
	.cfi_def_cfa_offset 144
	stp	x26, x25, [sp, #64]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #80]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #96]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #112]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #128]            ; 16-byte Folded Spill
	add	x29, sp, #128
	.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, x2
	mov	x19, x0
	bl	_amdgpu_sriov_vf
	cbz	x0, LBB0_2
; %bb.1:
	ldr	w0, [x19, #16]
	ldr	x8, [x22, #8]
	ldr	w9, [x22, #16]
	ldr	w8, [x8]
	stp	x9, x8, [sp]
Lloh0:
	adrp	x1, l_.str@PAGE
Lloh1:
	add	x1, x1, l_.str@PAGEOFF
	bl	_dev_err
	ldr	w0, [x19, #16]
Lloh2:
	adrp	x1, l_.str.1@PAGE
Lloh3:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_dev_err
	b	LBB0_10
LBB0_2:
Lloh4:
	adrp	x8, _mmVM_CONTEXT1_PROTECTION_FAULT_ADDR@GOTPAGE
Lloh5:
	ldr	x8, [x8, _mmVM_CONTEXT1_PROTECTION_FAULT_ADDR@GOTPAGEOFF]
Lloh6:
	ldr	w0, [x8]
	bl	_RREG32
	mov	x20, x0
Lloh7:
	adrp	x8, _mmVM_CONTEXT1_PROTECTION_FAULT_STATUS@GOTPAGE
Lloh8:
	ldr	x8, [x8, _mmVM_CONTEXT1_PROTECTION_FAULT_STATUS@GOTPAGEOFF]
Lloh9:
	ldr	w0, [x8]
	bl	_RREG32
	mov	x21, x0
Lloh10:
	adrp	x8, _mmVM_CONTEXT1_PROTECTION_FAULT_MCCLIENT@GOTPAGE
Lloh11:
	ldr	x8, [x8, _mmVM_CONTEXT1_PROTECTION_FAULT_MCCLIENT@GOTPAGEOFF]
Lloh12:
	ldr	w0, [x8]
	bl	_RREG32
	mov	x23, x0
Lloh13:
	adrp	x8, _mmVM_CONTEXT1_CNTL2@GOTPAGE
Lloh14:
	ldr	x8, [x8, _mmVM_CONTEXT1_CNTL2@GOTPAGEOFF]
Lloh15:
	ldr	w0, [x8]
	mov	w1, #1
	mov	w2, #-2
	bl	_WREG32_P
	orr	w8, w20, w21
	cbz	w8, LBB0_10
; %bb.3:
Lloh16:
	adrp	x8, _amdgpu_vm_fault_stop@GOTPAGE
Lloh17:
	ldr	x8, [x8, _amdgpu_vm_fault_stop@GOTPAGEOFF]
Lloh18:
	ldr	x8, [x8]
Lloh19:
	adrp	x9, _AMDGPU_VM_FAULT_STOP_FIRST@GOTPAGE
Lloh20:
	ldr	x9, [x9, _AMDGPU_VM_FAULT_STOP_FIRST@GOTPAGEOFF]
Lloh21:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_5
; %bb.4:
	mov	x0, x19
	mov	w1, #0
	bl	_gmc_v8_0_set_fault_enable_default
LBB0_5:
	bl	_printk_ratelimit
	cbz	x0, LBB0_7
; %bb.6:
	add	x0, sp, #48
	mov	w1, #0
	mov	w2, #16
	bl	_memset
	ldr	w1, [x22]
	add	x2, sp, #48
	mov	x0, x19
	bl	_amdgpu_vm_get_task_info
	ldr	w0, [x19, #16]
	ldr	x8, [x22, #8]
	ldr	w9, [x22, #16]
	ldr	w8, [x8]
	ldp	w11, w10, [sp, #56]
	ldp	w13, w12, [sp, #48]
	stp	x12, x13, [sp, #32]
	stp	x10, x11, [sp, #16]
	stp	x9, x8, [sp]
Lloh22:
	adrp	x1, l_.str.2@PAGE
Lloh23:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_dev_err
	ldr	w0, [x19, #16]
	str	x20, [sp]
Lloh24:
	adrp	x1, l_.str.3@PAGE
Lloh25:
	add	x1, x1, l_.str.3@PAGEOFF
	bl	_dev_err
	ldr	w0, [x19, #16]
	str	x21, [sp]
Lloh26:
	adrp	x1, l_.str.4@PAGE
Lloh27:
	add	x1, x1, l_.str.4@PAGEOFF
	bl	_dev_err
	ldr	w4, [x22]
	mov	x0, x19
	mov	x1, x21
	mov	x2, x20
	mov	x3, x23
	bl	_gmc_v8_0_vm_decode_fault
LBB0_7:
Lloh28:
	adrp	x24, _VM_CONTEXT1_PROTECTION_FAULT_STATUS@GOTPAGE
Lloh29:
	ldr	x24, [x24, _VM_CONTEXT1_PROTECTION_FAULT_STATUS@GOTPAGEOFF]
	ldr	w1, [x24]
Lloh30:
	adrp	x8, _VMID@GOTPAGE
Lloh31:
	ldr	x8, [x8, _VMID@GOTPAGEOFF]
Lloh32:
	ldr	w2, [x8]
	mov	x0, x21
	bl	_REG_GET_FIELD
	mov	x22, x0
	mov	x0, x19
	mov	x1, x22
	bl	_amdgpu_amdkfd_is_kfd_vmid
	cbz	x0, LBB0_10
; %bb.8:
	mov	x0, x19
	bl	_atomic_read
	cbnz	w0, LBB0_10
; %bb.9:
	ldr	x25, [x19, #8]
	ldr	w1, [x24]
Lloh33:
	adrp	x8, _PROTECTIONS@GOTPAGE
Lloh34:
	ldr	x8, [x8, _PROTECTIONS@GOTPAGEOFF]
Lloh35:
	ldr	w2, [x8]
	mov	x0, x21
	bl	_REG_GET_FIELD
	mov	x23, x0
	str	w22, [x25]
	ldr	w1, [x24]
Lloh36:
	adrp	x8, _MEMORY_CLIENT_ID@GOTPAGE
Lloh37:
	ldr	x8, [x8, _MEMORY_CLIENT_ID@GOTPAGEOFF]
Lloh38:
	ldr	w2, [x8]
	mov	x0, x21
	bl	_REG_GET_FIELD
	str	x0, [x25, #32]
	stp	w21, w20, [x25, #4]
	tst	w23, #0x7
	cset	w8, ne
	str	w8, [x25, #12]
	dup.2s	v0, w23
Lloh39:
	adrp	x8, lCPI0_0@PAGE
Lloh40:
	ldr	d1, [x8, lCPI0_0@PAGEOFF]
	ushl.2s	v0, v0, v1
	movi.2s	v1, #1
	and.8b	v0, v0, v1
	str	d0, [x25, #16]
	ubfx	w8, w23, #5, #1
	str	w8, [x25, #24]
	bl	_mb
	mov	x0, x19
	mov	w1, #1
	bl	_atomic_set
LBB0_10:
	mov	w0, #0
	ldp	x29, x30, [sp, #128]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #112]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #96]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #80]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #64]             ; 16-byte Folded Reload
	add	sp, sp, #144
	ret
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh13, Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpAdd	Lloh26, Lloh27
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpAdd	Lloh22, Lloh23
	.loh AdrpLdrGotLdr	Lloh30, Lloh31, Lloh32
	.loh AdrpLdrGot	Lloh28, Lloh29
	.loh AdrpLdr	Lloh39, Lloh40
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"GPU fault detected: %d 0x%08x\n"

l_.str.1:                               ; @.str.1
	.asciz	" Can't decode VM fault info here on SRIOV VF\n"

	.comm	_mmVM_CONTEXT1_PROTECTION_FAULT_ADDR,4,2 ; @mmVM_CONTEXT1_PROTECTION_FAULT_ADDR
	.comm	_mmVM_CONTEXT1_PROTECTION_FAULT_STATUS,4,2 ; @mmVM_CONTEXT1_PROTECTION_FAULT_STATUS
	.comm	_mmVM_CONTEXT1_PROTECTION_FAULT_MCCLIENT,4,2 ; @mmVM_CONTEXT1_PROTECTION_FAULT_MCCLIENT
	.comm	_mmVM_CONTEXT1_CNTL2,4,2        ; @mmVM_CONTEXT1_CNTL2
	.comm	_amdgpu_vm_fault_stop,8,3       ; @amdgpu_vm_fault_stop
	.comm	_AMDGPU_VM_FAULT_STOP_FIRST,8,3 ; @AMDGPU_VM_FAULT_STOP_FIRST
l_.str.2:                               ; @.str.2
	.asciz	"GPU fault detected: %d 0x%08x for process %s pid %d thread %s pid %d\n"

l_.str.3:                               ; @.str.3
	.asciz	"  VM_CONTEXT1_PROTECTION_FAULT_ADDR   0x%08X\n"

l_.str.4:                               ; @.str.4
	.asciz	"  VM_CONTEXT1_PROTECTION_FAULT_STATUS 0x%08X\n"

	.comm	_VM_CONTEXT1_PROTECTION_FAULT_STATUS,4,2 ; @VM_CONTEXT1_PROTECTION_FAULT_STATUS
	.comm	_VMID,4,2                       ; @VMID
	.comm	_PROTECTIONS,4,2                ; @PROTECTIONS
	.comm	_MEMORY_CLIENT_ID,4,2           ; @MEMORY_CLIENT_ID
	.no_dead_strip	_gmc_v8_0_process_interrupt
.subsections_via_symbols
