	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_i915_capture_gpu_state         ## -- Begin function i915_capture_gpu_state
	.p2align	4, 0x90
_i915_capture_gpu_state:                ## @i915_capture_gpu_state
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movl	4(%rdi), %edi
	callq	_READ_ONCE
	movq	%rax, %rbx
	movq	%rax, %rdi
	callq	_IS_ERR
	testq	%rax, %rax
	je	LBB0_1
LBB0_5:
	movq	%rbx, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_1:
	movq	_ALLOW_FAIL@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	$48, %edi
	callq	_kzalloc
	testq	%rax, %rax
	je	LBB0_6
## %bb.2:
	movq	%rax, %rbx
	leaq	-32(%rbp), %rdi
	callq	_compress_init
	testl	%eax, %eax
	je	LBB0_3
## %bb.4:
	movq	%rbx, %rdi
	addq	$40, %rdi
	callq	_kref_init
	movq	%r14, 32(%rbx)
	xorl	%eax, %eax
	callq	_ktime_get_real
	movl	%eax, 24(%rbx)
	xorl	%eax, %eax
	callq	_ktime_get_boottime
	movl	%eax, 20(%rbx)
	xorl	%eax, %eax
	callq	_ktime_get
	movl	(%r14), %esi
	movl	%eax, %edi
	callq	_ktime_sub
	movl	%eax, 16(%rbx)
	movq	_jiffies@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 12(%rbx)
	movq	%rbx, %rdi
	callq	_capture_params
	movq	%rbx, %rdi
	callq	_capture_gen_state
	leaq	-32(%rbp), %r15
	movq	%rbx, %rdi
	movq	%r15, %rsi
	callq	_capture_uc_state
	movq	%rbx, %rdi
	callq	_capture_reg_state
	movq	%rbx, %rdi
	callq	_gem_record_fences
	movq	%rbx, %rdi
	movq	%r15, %rsi
	callq	_gem_record_rings
	movq	%r14, %rdi
	callq	_intel_overlay_capture_error_state
	movl	%eax, 8(%rbx)
	movq	%r14, %rdi
	callq	_intel_display_capture_error_state
	movl	%eax, 4(%rbx)
	movq	%rbx, %rdi
	callq	_capture_find_epoch
	movl	%eax, (%rbx)
	movq	%rbx, %rdi
	callq	_capture_finish
	movq	%r15, %rdi
	callq	_compress_fini
	jmp	LBB0_5
LBB0_6:
	movq	_ENOMEM@GOTPCREL(%rip), %r15
	xorl	%ebx, %ebx
	xorl	%esi, %esi
	subl	(%r15), %esi
	movq	%r14, %rdi
	callq	_i915_disable_error_state
	subl	(%r15), %ebx
	movl	%ebx, %edi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_ERR_PTR                        ## TAILCALL
LBB0_3:
	movq	%rbx, %rdi
	callq	_kfree
	movq	_ENOMEM@GOTPCREL(%rip), %r15
	xorl	%ebx, %ebx
	xorl	%esi, %esi
	subl	(%r15), %esi
	movq	%r14, %rdi
	callq	_i915_disable_error_state
	subl	(%r15), %ebx
	movl	%ebx, %edi
	callq	_ERR_PTR
	movq	%rax, %rbx
	jmp	LBB0_5
	.cfi_endproc
                                        ## -- End function
	.comm	_ALLOW_FAIL,4,2                 ## @ALLOW_FAIL
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_jiffies,4,2                    ## @jiffies
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_i915_capture_gpu_state         ; -- Begin function i915_capture_gpu_state
	.p2align	2
_i915_capture_gpu_state:                ; @i915_capture_gpu_state
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #48
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	ldr	w0, [x0, #4]
	bl	_READ_ONCE
	mov	x20, x0
	bl	_IS_ERR
	cbz	x0, LBB0_2
LBB0_1:
	mov	x0, x20
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	ret
LBB0_2:
Lloh0:
	adrp	x8, _ALLOW_FAIL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ALLOW_FAIL@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	mov	w0, #48
	bl	_kzalloc
	cbz	x0, LBB0_5
; %bb.3:
	mov	x20, x0
	add	x0, sp, #8
	bl	_compress_init
	cbz	w0, LBB0_6
; %bb.4:
	add	x0, x20, #40
	bl	_kref_init
	str	x19, [x20, #32]
	bl	_ktime_get_real
	str	w0, [x20, #24]
	bl	_ktime_get_boottime
	str	w0, [x20, #20]
	bl	_ktime_get
	ldr	w1, [x19]
	bl	_ktime_sub
Lloh3:
	adrp	x8, _jiffies@GOTPAGE
Lloh4:
	ldr	x8, [x8, _jiffies@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	stp	w8, w0, [x20, #12]
	mov	x0, x20
	bl	_capture_params
	mov	x0, x20
	bl	_capture_gen_state
	add	x1, sp, #8
	mov	x0, x20
	bl	_capture_uc_state
	mov	x0, x20
	bl	_capture_reg_state
	mov	x0, x20
	bl	_gem_record_fences
	add	x1, sp, #8
	mov	x0, x20
	bl	_gem_record_rings
	mov	x0, x19
	bl	_intel_overlay_capture_error_state
	str	w0, [x20, #8]
	mov	x0, x19
	bl	_intel_display_capture_error_state
	str	w0, [x20, #4]
	mov	x0, x20
	bl	_capture_find_epoch
	str	w0, [x20]
	mov	x0, x20
	bl	_capture_finish
	add	x0, sp, #8
	bl	_compress_fini
	b	LBB0_1
LBB0_5:
Lloh6:
	adrp	x20, _ENOMEM@GOTPAGE
Lloh7:
	ldr	x20, [x20, _ENOMEM@GOTPAGEOFF]
	ldr	w8, [x20]
	neg	w1, w8
	mov	x0, x19
	bl	_i915_disable_error_state
	ldr	w8, [x20]
	neg	w0, w8
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #48
	b	_ERR_PTR
LBB0_6:
	mov	x0, x20
	bl	_kfree
Lloh8:
	adrp	x20, _ENOMEM@GOTPAGE
Lloh9:
	ldr	x20, [x20, _ENOMEM@GOTPAGEOFF]
	ldr	w8, [x20]
	neg	w1, w8
	mov	x0, x19
	bl	_i915_disable_error_state
	ldr	w8, [x20]
	neg	w0, w8
	bl	_ERR_PTR
	mov	x20, x0
	b	LBB0_1
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh8, Lloh9
	.cfi_endproc
                                        ; -- End function
	.comm	_ALLOW_FAIL,4,2                 ; @ALLOW_FAIL
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_jiffies,4,2                    ; @jiffies
.subsections_via_symbols
