	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function gf100_gr_ctxctl_isr
_gf100_gr_ctxctl_isr:                   ## @gf100_gr_ctxctl_isr
	.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	%rdi, %r15
	leaq	8(%rdi), %r12
	movq	8(%rdi), %r14
	movq	%r14, %rdi
	movl	$4234264, %esi                  ## imm = 0x409C18
	callq	_nvkm_rd32
	movl	%eax, %ebx
	movl	(%r15), %eax
	testl	%eax, %eax
	jne	LBB0_6
## %bb.1:
	movl	%ebx, %ecx
	andl	$1, %ecx
	je	LBB0_6
## %bb.2:
	movq	%r14, %rdi
	movl	$4233236, %esi                  ## imm = 0x409814
	callq	_nvkm_rd32
	movq	_E_BAD_FWMTHD@GOTPCREL(%rip), %rcx
	cmpl	(%rcx), %eax
	jne	LBB0_4
## %bb.3:
	movq	%r14, %rdi
	movl	$4233224, %esi                  ## imm = 0x409808
	callq	_nvkm_rd32
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	movq	%r14, %rdi
	movl	$4233228, %esi                  ## imm = 0x40980C
	callq	_nvkm_rd32
	movq	%r12, -56(%rbp)                 ## 8-byte Spill
	movl	%eax, %r12d
	movl	%eax, %r13d
	shrl	$16, %r13d
	andl	$7, %r13d
	andl	$16380, %r12d                   ## imm = 0x3FFC
	movq	%r14, %rdi
	movl	$4233232, %esi                  ## imm = 0x409810
	callq	_nvkm_rd32
	leaq	L_.str(%rip), %rsi
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	movl	%r13d, %edx
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
	movl	%r12d, %r8d
	movq	-56(%rbp), %r12                 ## 8-byte Reload
	movl	%eax, %r9d
	xorl	%eax, %eax
	callq	_nvkm_error
	jmp	LBB0_5
LBB0_4:
	leaq	L_.str.1(%rip), %rsi
	movq	%r12, %rdi
	movl	%eax, %edx
	xorl	%eax, %eax
	callq	_nvkm_error
LBB0_5:
	movq	%r14, %rdi
	movl	$4234272, %esi                  ## imm = 0x409C20
	movl	$1, %edx
	callq	_nvkm_wr32
	andl	$-2, %ebx
	movl	(%r15), %eax
LBB0_6:
	testl	%eax, %eax
	jne	LBB0_9
## %bb.7:
	movl	%ebx, %eax
	andl	$524288, %eax                   ## imm = 0x80000
	je	LBB0_9
## %bb.8:
	leaq	L_.str.2(%rip), %rsi
	movq	%r12, %rdi
	xorl	%eax, %eax
	callq	_nvkm_error
	movq	%r15, %rdi
	callq	_gf100_gr_ctxctl_debug
	movq	%r14, %rdi
	movl	$4234272, %esi                  ## imm = 0x409C20
	movl	$524288, %edx                   ## imm = 0x80000
	callq	_nvkm_wr32
	andl	$-524289, %ebx                  ## imm = 0xFFF7FFFF
LBB0_9:
	testl	%ebx, %ebx
	je	LBB0_10
## %bb.11:
	leaq	L_.str.3(%rip), %rsi
	movq	%r12, %rdi
	movl	%ebx, %edx
	xorl	%eax, %eax
	callq	_nvkm_error
	movq	%r15, %rdi
	callq	_gf100_gr_ctxctl_debug
	movq	%r14, %rdi
	movl	$4234272, %esi                  ## imm = 0x409C20
	movl	%ebx, %edx
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_nvkm_wr32                      ## TAILCALL
LBB0_10:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_E_BAD_FWMTHD,4,2               ## @E_BAD_FWMTHD
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"FECS MTHD subc %d class %04x mthd %04x data %08x\n"

L_.str.1:                               ## @.str.1
	.asciz	"FECS ucode error %d\n"

L_.str.2:                               ## @.str.2
	.asciz	"FECS watchdog timeout\n"

L_.str.3:                               ## @.str.3
	.asciz	"FECS %08x\n"

	.no_dead_strip	_gf100_gr_ctxctl_isr
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function gf100_gr_ctxctl_isr
_gf100_gr_ctxctl_isr:                   ; @gf100_gr_ctxctl_isr
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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	x19, x0
	mov	w24, #39968
	movk	w24, #64, lsl #16
	mov	x21, x0
	ldr	x20, [x21, #8]!
	sub	w1, w24, #8
	mov	x0, x20
	bl	_nvkm_rd32
	mov	x22, x0
	ldr	w8, [x19]
	and	w9, w0, #0x1
	cmp	w8, #0
	ccmp	w9, #0, #4, eq
	b.eq	LBB0_5
; %bb.1:
	sub	w1, w24, #1036
	mov	x0, x20
	bl	_nvkm_rd32
                                        ; kill: def $w0 killed $w0 def $x0
Lloh0:
	adrp	x8, _E_BAD_FWMTHD@GOTPAGE
Lloh1:
	ldr	x8, [x8, _E_BAD_FWMTHD@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w0, w8
	b.ne	LBB0_3
; %bb.2:
	sub	w1, w24, #1048
	mov	x0, x20
	bl	_nvkm_rd32
	mov	x23, x0
	sub	w1, w24, #1044
	mov	x0, x20
	bl	_nvkm_rd32
	ubfx	w25, w0, #16, #3
	and	w26, w0, #0x3ffc
	sub	w1, w24, #1040
	mov	x0, x20
	bl	_nvkm_rd32
                                        ; kill: def $w0 killed $w0 def $x0
	stp	x26, x0, [sp, #16]
	stp	x25, x23, [sp]
Lloh3:
	adrp	x1, l_.str@PAGE
Lloh4:
	add	x1, x1, l_.str@PAGEOFF
	b	LBB0_4
LBB0_3:
	str	x0, [sp]
Lloh5:
	adrp	x1, l_.str.1@PAGE
Lloh6:
	add	x1, x1, l_.str.1@PAGEOFF
LBB0_4:
	mov	x0, x21
	bl	_nvkm_error
	mov	x0, x20
	mov	w1, #39968
	movk	w1, #64, lsl #16
	mov	w2, #1
	bl	_nvkm_wr32
	and	w22, w22, #0xfffffffe
	ldr	w8, [x19]
LBB0_5:
	and	w9, w22, #0x80000
	cmp	w8, #0
	ccmp	w9, #0, #4, eq
	b.eq	LBB0_7
; %bb.6:
Lloh7:
	adrp	x1, l_.str.2@PAGE
Lloh8:
	add	x1, x1, l_.str.2@PAGEOFF
	mov	x0, x21
	bl	_nvkm_error
	mov	x0, x19
	bl	_gf100_gr_ctxctl_debug
	mov	x0, x20
	mov	w1, #39968
	movk	w1, #64, lsl #16
	mov	w2, #524288
	bl	_nvkm_wr32
	and	w22, w22, #0xfff7ffff
LBB0_7:
	cbz	w22, LBB0_9
; %bb.8:
	str	x22, [sp]
Lloh9:
	adrp	x1, l_.str.3@PAGE
Lloh10:
	add	x1, x1, l_.str.3@PAGEOFF
	mov	x0, x21
	bl	_nvkm_error
	mov	x0, x19
	bl	_gf100_gr_ctxctl_debug
	mov	x0, x20
	mov	w1, #39968
	movk	w1, #64, lsl #16
	mov	x2, x22
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #112
	b	_nvkm_wr32
LBB0_9:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpAdd	Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_E_BAD_FWMTHD,4,2               ; @E_BAD_FWMTHD
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"FECS MTHD subc %d class %04x mthd %04x data %08x\n"

l_.str.1:                               ; @.str.1
	.asciz	"FECS ucode error %d\n"

l_.str.2:                               ; @.str.2
	.asciz	"FECS watchdog timeout\n"

l_.str.3:                               ; @.str.3
	.asciz	"FECS %08x\n"

	.no_dead_strip	_gf100_gr_ctxctl_isr
.subsections_via_symbols
