	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function intel_alloc_context_page
_intel_alloc_context_page:              ## @intel_alloc_context_page
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movq	%rdi, %rbx
	callq	_mutex_is_locked
	xorl	%edi, %edi
	testl	%eax, %eax
	sete	%dil
	callq	_WARN_ON
	movq	%rbx, %rdi
	movl	$4096, %esi                     ## imm = 0x1000
	callq	_i915_gem_alloc_object
	testq	%rax, %rax
	je	LBB0_1
## %bb.2:
	movq	%rax, %rbx
	movq	%rax, %rdi
	movl	$4096, %esi                     ## imm = 0x1000
	movl	$1, %edx
	xorl	%ecx, %ecx
	callq	_i915_gem_object_pin
	testl	%eax, %eax
	je	LBB0_4
## %bb.3:
	leaq	L_.str.1(%rip), %rdi
	movl	%eax, %esi
	callq	_DRM_ERROR
	jmp	LBB0_6
LBB0_1:
	leaq	L_.str(%rip), %rdi
	callq	_DRM_DEBUG
	jmp	LBB0_7
LBB0_4:
	movq	%rbx, %rdi
	movl	$1, %esi
	callq	_i915_gem_object_set_to_gtt_domain
	testl	%eax, %eax
	je	LBB0_8
## %bb.5:
	leaq	L_.str.2(%rip), %rdi
	movl	%eax, %esi
	callq	_DRM_ERROR
	movq	%rbx, %rdi
	callq	_i915_gem_object_unpin
LBB0_6:
	movq	%rbx, %rdi
	callq	_drm_gem_object_unreference
LBB0_7:
	xorl	%ebx, %ebx
LBB0_8:
	movq	%rbx, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"failed to alloc power context, RC6 disabled\n"

L_.str.1:                               ## @.str.1
	.asciz	"failed to pin power context: %d\n"

L_.str.2:                               ## @.str.2
	.asciz	"failed to set-domain on power context: %d\n"

	.no_dead_strip	_intel_alloc_context_page
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function intel_alloc_context_page
_intel_alloc_context_page:              ; @intel_alloc_context_page
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	mov	x19, x0
	bl	_mutex_is_locked
	cmp	w0, #0
	cset	w0, eq
	bl	_WARN_ON
	mov	x0, x19
	mov	w1, #4096
	bl	_i915_gem_alloc_object
	mov	x19, x0
	cbz	x0, LBB0_3
; %bb.1:
	mov	x0, x19
	mov	w1, #4096
	mov	w2, #1
	mov	w3, #0
	bl	_i915_gem_object_pin
	cbz	w0, LBB0_4
; %bb.2:
	mov	x1, x0
Lloh0:
	adrp	x0, l_.str.1@PAGE
Lloh1:
	add	x0, x0, l_.str.1@PAGEOFF
	bl	_DRM_ERROR
	b	LBB0_6
LBB0_3:
Lloh2:
	adrp	x0, l_.str@PAGE
Lloh3:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DRM_DEBUG
	b	LBB0_7
LBB0_4:
	mov	x0, x19
	mov	w1, #1
	bl	_i915_gem_object_set_to_gtt_domain
	cbz	w0, LBB0_7
; %bb.5:
	mov	x1, x0
Lloh4:
	adrp	x0, l_.str.2@PAGE
Lloh5:
	add	x0, x0, l_.str.2@PAGEOFF
	bl	_DRM_ERROR
	mov	x0, x19
	bl	_i915_gem_object_unpin
LBB0_6:
	mov	x0, x19
	bl	_drm_gem_object_unreference
	mov	x19, #0
LBB0_7:
	mov	x0, x19
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpAdd	Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"failed to alloc power context, RC6 disabled\n"

l_.str.1:                               ; @.str.1
	.asciz	"failed to pin power context: %d\n"

l_.str.2:                               ; @.str.2
	.asciz	"failed to set-domain on power context: %d\n"

	.no_dead_strip	_intel_alloc_context_page
.subsections_via_symbols
