	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function ivtvfb_pan_display
_ivtvfb_pan_display:                    ## @ivtvfb_pan_display
	.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
	movslq	(%rdi), %rax
	movq	(%rsi), %rcx
	addq	%rax, %rcx
	cmpq	8(%rsi), %rcx
	jg	LBB0_2
## %bb.1:
	movq	%rdi, %r14
	movslq	4(%rdi), %rcx
	movq	16(%rsi), %rdx
	addq	%rcx, %rdx
	cmpq	24(%rsi), %rdx
	jle	LBB0_3
LBB0_2:
	movq	_EINVAL@GOTPCREL(%rip), %rcx
	xorl	%eax, %eax
	subl	(%rcx), %eax
	jmp	LBB0_4
LBB0_3:
	movq	48(%rsi), %r15
	imull	40(%rsi), %eax
	imull	32(%rsi), %ecx
	leal	7(%rcx), %ebx
	testl	%ecx, %ecx
	cmovnsl	%ecx, %ebx
	sarl	$3, %ebx
	addl	%eax, %ebx
	movl	%ebx, %edi
	movl	$10764, %esi                    ## imm = 0x2A0C
	callq	_write_reg
	movl	4(%r14), %eax
	movl	%eax, 8(%r15)
	movl	(%r14), %eax
	movl	%eax, 12(%r15)
	movl	$1, 16(%r15)
	movq	(%r15), %rax
	movl	%ebx, (%rax)
	xorl	%eax, %eax
LBB0_4:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_ivtvfb_pan_display
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function ivtvfb_pan_display
_ivtvfb_pan_display:                    ; @ivtvfb_pan_display
	.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
	ldrsw	x8, [x0]
	ldp	x9, x10, [x1]
	add	x9, x9, x8
	cmp	x9, x10
	b.gt	LBB0_2
; %bb.1:
	mov	x19, x0
	ldrsw	x9, [x0, #4]
	ldp	x10, x11, [x1, #16]
	add	x10, x10, x9
	cmp	x10, x11
	b.le	LBB0_3
LBB0_2:
Lloh0:
	adrp	x8, _EINVAL@GOTPAGE
Lloh1:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	neg	w0, w8
	b	LBB0_4
LBB0_3:
	ldr	x21, [x1, #48]
	ldr	w10, [x1, #40]
	mul	w8, w10, w8
	ldr	w10, [x1, #32]
	mul	w9, w10, w9
	add	w10, w9, #7
	cmp	w9, #0
	csel	w9, w10, w9, lt
	add	w20, w8, w9, asr #3
	mov	x0, x20
	mov	w1, #10764
	bl	_write_reg
	mov	w0, #0
	ldr	d0, [x19]
	rev64.2s	v0, v0
	str	d0, [x21, #8]
	mov	w8, #1
	str	w8, [x21, #16]
	ldr	x8, [x21]
	str	w20, [x8]
LBB0_4:
	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
	.cfi_endproc
                                        ; -- End function
	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_ivtvfb_pan_display
.subsections_via_symbols
