	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_i915_gem_get_tiling_ioctl      ## -- Begin function i915_gem_get_tiling_ioctl
	.p2align	4, 0x90
_i915_gem_get_tiling_ioctl:             ## @i915_gem_get_tiling_ioctl
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r12
	movq	%rsi, %r15
	callq	_to_i915
	movq	%rax, %r14
	movq	_ENOENT@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
	xorl	%eax, %eax
	callq	_rcu_read_lock
	movl	24(%r15), %esi
	movq	%r12, %rdi
	callq	_i915_gem_object_lookup_rcu
	testq	%rax, %rax
	je	LBB0_2
## %bb.1:
	movl	(%rax), %edi
	callq	_READ_ONCE
	movq	_TILING_MASK@GOTPCREL(%rip), %rcx
	andl	(%rcx), %eax
	movl	%eax, (%r15)
	xorl	%ebx, %ebx
LBB0_2:
	xorl	%eax, %eax
	callq	_rcu_read_unlock
	movl	%ebx, %edi
	callq	_unlikely
	testq	%rax, %rax
	jne	LBB0_14
## %bb.3:
	movl	(%r15), %eax
	cmpl	$128, %eax
	je	LBB0_7
## %bb.4:
	cmpl	$129, %eax
	jne	LBB0_5
## %bb.6:
	movq	%r14, %rax
	addq	$8, %rax
	jmp	LBB0_8
LBB0_7:
	movq	%r14, %rax
	addq	$16, %rax
	jmp	LBB0_8
LBB0_5:
	movq	_I915_BIT_6_SWIZZLE_NONE@GOTPCREL(%rip), %rax
LBB0_8:
	movq	(%rax), %rax
	movq	%rax, 8(%r15)
	movq	_QUIRK_PIN_SWIZZLED_PAGES@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	movq	%rax, %rcx
	andl	(%r14), %edx
	je	LBB0_10
## %bb.9:
	movq	_I915_BIT_6_SWIZZLE_UNKNOWN@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
LBB0_10:
	movq	%rcx, 16(%r15)
	movq	_I915_BIT_6_SWIZZLE_9_17@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_12
## %bb.11:
	movq	_I915_BIT_6_SWIZZLE_9@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 8(%r15)
LBB0_12:
	movq	_I915_BIT_6_SWIZZLE_9_10_17@GOTPCREL(%rip), %rcx
	xorl	%ebx, %ebx
	cmpq	(%rcx), %rax
	jne	LBB0_14
## %bb.13:
	movq	_I915_BIT_6_SWIZZLE_9_10@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, 8(%r15)
LBB0_14:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOENT,4,2                     ## @ENOENT
	.comm	_TILING_MASK,4,2                ## @TILING_MASK
	.comm	_I915_BIT_6_SWIZZLE_NONE,8,3    ## @I915_BIT_6_SWIZZLE_NONE
	.comm	_QUIRK_PIN_SWIZZLED_PAGES,4,2   ## @QUIRK_PIN_SWIZZLED_PAGES
	.comm	_I915_BIT_6_SWIZZLE_UNKNOWN,8,3 ## @I915_BIT_6_SWIZZLE_UNKNOWN
	.comm	_I915_BIT_6_SWIZZLE_9_17,8,3    ## @I915_BIT_6_SWIZZLE_9_17
	.comm	_I915_BIT_6_SWIZZLE_9,8,3       ## @I915_BIT_6_SWIZZLE_9
	.comm	_I915_BIT_6_SWIZZLE_9_10_17,8,3 ## @I915_BIT_6_SWIZZLE_9_10_17
	.comm	_I915_BIT_6_SWIZZLE_9_10,8,3    ## @I915_BIT_6_SWIZZLE_9_10
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_i915_gem_get_tiling_ioctl      ; -- Begin function i915_gem_get_tiling_ioctl
	.p2align	2
_i915_gem_get_tiling_ioctl:             ; @i915_gem_get_tiling_ioctl
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.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
	.cfi_offset w21, -40
	.cfi_offset w22, -48
	mov	x21, x2
	mov	x19, x1
	bl	_to_i915
	mov	x20, x0
Lloh0:
	adrp	x8, _ENOENT@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ENOENT@GOTPAGEOFF]
Lloh2:
	ldr	w22, [x8]
	bl	_rcu_read_lock
	ldr	w1, [x19, #24]
	mov	x0, x21
	bl	_i915_gem_object_lookup_rcu
	cbz	x0, LBB0_2
; %bb.1:
	ldr	w0, [x0]
	bl	_READ_ONCE
	mov	w21, #0
Lloh3:
	adrp	x8, _TILING_MASK@GOTPAGE
Lloh4:
	ldr	x8, [x8, _TILING_MASK@GOTPAGEOFF]
Lloh5:
	ldr	w8, [x8]
	and	w8, w8, w0
	str	w8, [x19]
	b	LBB0_3
LBB0_2:
	neg	w21, w22
LBB0_3:
	bl	_rcu_read_unlock
	mov	x0, x21
	bl	_unlikely
	cbnz	x0, LBB0_9
; %bb.4:
	ldr	w8, [x19]
Lloh6:
	adrp	x9, _I915_BIT_6_SWIZZLE_NONE@GOTPAGE
Lloh7:
	ldr	x9, [x9, _I915_BIT_6_SWIZZLE_NONE@GOTPAGEOFF]
	add	x10, x20, #16
	cmp	w8, #129
	add	x11, x20, #8
	csel	x9, x9, x11, ne
	cmp	w8, #128
	csel	x8, x10, x9, eq
	ldr	x8, [x8]
	ldr	w9, [x20]
Lloh8:
	adrp	x10, _QUIRK_PIN_SWIZZLED_PAGES@GOTPAGE
Lloh9:
	ldr	x10, [x10, _QUIRK_PIN_SWIZZLED_PAGES@GOTPAGEOFF]
Lloh10:
	ldr	w10, [x10]
Lloh11:
	adrp	x11, _I915_BIT_6_SWIZZLE_UNKNOWN@GOTPAGE
Lloh12:
	ldr	x11, [x11, _I915_BIT_6_SWIZZLE_UNKNOWN@GOTPAGEOFF]
Lloh13:
	ldr	x11, [x11]
	tst	w10, w9
	csel	x9, x8, x11, eq
	stp	x8, x9, [x19, #8]
Lloh14:
	adrp	x9, _I915_BIT_6_SWIZZLE_9_17@GOTPAGE
Lloh15:
	ldr	x9, [x9, _I915_BIT_6_SWIZZLE_9_17@GOTPAGEOFF]
Lloh16:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_6
; %bb.5:
Lloh17:
	adrp	x8, _I915_BIT_6_SWIZZLE_9@GOTPAGE
Lloh18:
	ldr	x8, [x8, _I915_BIT_6_SWIZZLE_9@GOTPAGEOFF]
Lloh19:
	ldr	x8, [x8]
	str	x8, [x19, #8]
LBB0_6:
Lloh20:
	adrp	x9, _I915_BIT_6_SWIZZLE_9_10_17@GOTPAGE
Lloh21:
	ldr	x9, [x9, _I915_BIT_6_SWIZZLE_9_10_17@GOTPAGEOFF]
Lloh22:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_8
; %bb.7:
	mov	w21, #0
Lloh23:
	adrp	x8, _I915_BIT_6_SWIZZLE_9_10@GOTPAGE
Lloh24:
	ldr	x8, [x8, _I915_BIT_6_SWIZZLE_9_10@GOTPAGEOFF]
Lloh25:
	ldr	x8, [x8]
	str	x8, [x19, #8]
	b	LBB0_9
LBB0_8:
	mov	w21, #0
LBB0_9:
	mov	x0, x21
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOENT,4,2                     ; @ENOENT
	.comm	_TILING_MASK,4,2                ; @TILING_MASK
	.comm	_I915_BIT_6_SWIZZLE_NONE,8,3    ; @I915_BIT_6_SWIZZLE_NONE
	.comm	_QUIRK_PIN_SWIZZLED_PAGES,4,2   ; @QUIRK_PIN_SWIZZLED_PAGES
	.comm	_I915_BIT_6_SWIZZLE_UNKNOWN,8,3 ; @I915_BIT_6_SWIZZLE_UNKNOWN
	.comm	_I915_BIT_6_SWIZZLE_9_17,8,3    ; @I915_BIT_6_SWIZZLE_9_17
	.comm	_I915_BIT_6_SWIZZLE_9,8,3       ; @I915_BIT_6_SWIZZLE_9
	.comm	_I915_BIT_6_SWIZZLE_9_10_17,8,3 ; @I915_BIT_6_SWIZZLE_9_10_17
	.comm	_I915_BIT_6_SWIZZLE_9_10,8,3    ; @I915_BIT_6_SWIZZLE_9_10
.subsections_via_symbols
