	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function i915_get_vblank_counter
_i915_get_vblank_counter:               ## @i915_get_vblank_counter
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, %ebx
	callq	_i915_pipe_enabled
	testl	%eax, %eax
	je	LBB0_1
## %bb.2:
	movl	%ebx, %edi
	callq	_PIPEFRAME
	movq	%rax, %r14
	movl	%ebx, %edi
	callq	_PIPEFRAMEPIXEL
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movq	_PIPE_FRAME_HIGH_MASK@GOTPCREL(%rip), %r15
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movq	%r14, %rdi
	callq	_I915_READ
	movl	%eax, %ebx
	andl	(%r15), %ebx
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	callq	_I915_READ
	movl	%eax, %r12d
	movq	_PIPE_FRAME_LOW_MASK@GOTPCREL(%rip), %rax
	movl	(%rax), %r13d
	movq	%r14, %rdi
	callq	_I915_READ
	andl	(%r15), %eax
	cmpl	%eax, %ebx
	jne	LBB0_3
## %bb.4:
	andl	%r12d, %r13d
	movq	_PIPE_FRAME_HIGH_SHIFT@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	sarl	%cl, %ebx
	movq	_PIPE_FRAME_LOW_SHIFT@GOTPCREL(%rip), %rax
	movb	(%rax), %cl
	sarl	%cl, %r13d
	shll	$8, %ebx
	orl	%r13d, %ebx
	jmp	LBB0_5
LBB0_1:
	movl	%ebx, %edi
	callq	_pipe_name
	leaq	L_.str(%rip), %rdi
	movl	%eax, %esi
	callq	_DRM_DEBUG_DRIVER
	xorl	%ebx, %ebx
LBB0_5:
	movl	%ebx, %eax
	addq	$8, %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	"trying to get vblank count for disabled pipe %c\n"

	.comm	_PIPE_FRAME_HIGH_MASK,4,2       ## @PIPE_FRAME_HIGH_MASK
	.comm	_PIPE_FRAME_LOW_MASK,4,2        ## @PIPE_FRAME_LOW_MASK
	.comm	_PIPE_FRAME_HIGH_SHIFT,4,2      ## @PIPE_FRAME_HIGH_SHIFT
	.comm	_PIPE_FRAME_LOW_SHIFT,4,2       ## @PIPE_FRAME_LOW_SHIFT
	.no_dead_strip	_i915_get_vblank_counter
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function i915_get_vblank_counter
_i915_get_vblank_counter:               ; @i915_get_vblank_counter
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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	x20, x1
	bl	_i915_pipe_enabled
	cbz	w0, LBB0_4
; %bb.1:
	mov	x0, x20
	bl	_PIPEFRAME
	mov	x19, x0
	mov	x0, x20
	bl	_PIPEFRAMEPIXEL
	mov	x20, x0
Lloh0:
	adrp	x22, _PIPE_FRAME_HIGH_MASK@GOTPAGE
Lloh1:
	ldr	x22, [x22, _PIPE_FRAME_HIGH_MASK@GOTPAGEOFF]
Lloh2:
	adrp	x23, _PIPE_FRAME_LOW_MASK@GOTPAGE
Lloh3:
	ldr	x23, [x23, _PIPE_FRAME_LOW_MASK@GOTPAGEOFF]
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x19
	bl	_I915_READ
	ldr	w8, [x22]
	and	w24, w8, w0
	mov	x0, x20
	bl	_I915_READ
	mov	x21, x0
	ldr	w25, [x23]
	mov	x0, x19
	bl	_I915_READ
	ldr	w8, [x22]
	and	w8, w8, w0
	cmp	w24, w8
	b.ne	LBB0_2
; %bb.3:
	and	w8, w25, w21
Lloh4:
	adrp	x9, _PIPE_FRAME_HIGH_SHIFT@GOTPAGE
Lloh5:
	ldr	x9, [x9, _PIPE_FRAME_HIGH_SHIFT@GOTPAGEOFF]
Lloh6:
	ldr	w9, [x9]
	asr	w9, w24, w9
Lloh7:
	adrp	x10, _PIPE_FRAME_LOW_SHIFT@GOTPAGE
Lloh8:
	ldr	x10, [x10, _PIPE_FRAME_LOW_SHIFT@GOTPAGEOFF]
Lloh9:
	ldr	w10, [x10]
	asr	w8, w8, w10
	orr	w0, w8, w9, lsl #8
	b	LBB0_5
LBB0_4:
	mov	x0, x20
	bl	_pipe_name
	mov	x1, x0
Lloh10:
	adrp	x0, l_.str@PAGE
Lloh11:
	add	x0, x0, l_.str@PAGEOFF
	bl	_DRM_DEBUG_DRIVER
	mov	w0, #0
LBB0_5:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpAdd	Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"trying to get vblank count for disabled pipe %c\n"

	.comm	_PIPE_FRAME_HIGH_MASK,4,2       ; @PIPE_FRAME_HIGH_MASK
	.comm	_PIPE_FRAME_LOW_MASK,4,2        ; @PIPE_FRAME_LOW_MASK
	.comm	_PIPE_FRAME_HIGH_SHIFT,4,2      ; @PIPE_FRAME_HIGH_SHIFT
	.comm	_PIPE_FRAME_LOW_SHIFT,4,2       ; @PIPE_FRAME_LOW_SHIFT
	.no_dead_strip	_i915_get_vblank_counter
.subsections_via_symbols
