	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function fbdev_write_packet
_fbdev_write_packet:                    ## @fbdev_write_packet
	.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
	subq	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, -72(%rbp)                 ## 8-byte Spill
	movq	%rdi, %r15
	movq	(%rdi), %rax
	movq	8(%rdi), %r12
	movq	(%rax), %rax
	movq	(%rax), %rax
	movl	(%rax), %r14d
	movl	4(%rax), %ecx
	movq	%rcx, -56(%rbp)                 ## 8-byte Spill
	movl	8(%rax), %ecx
	movq	%rcx, -48(%rbp)                 ## 8-byte Spill
	movl	12(%rax), %r13d
	movl	40(%r12), %edi
	movq	_FBIOGET_VSCREENINFO@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	12(%r12), %rbx
	movq	%rbx, %rdx
	callq	_ioctl
	testq	%rax, %rax
	jns	LBB0_2
## %bb.1:
	movq	_AV_LOG_WARNING@GOTPCREL(%rip), %rax
	movq	%rbx, -64(%rbp)                 ## 8-byte Spill
	movl	(%rax), %ebx
	movq	_errno@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_AVERROR
	movl	%eax, %edi
	callq	_av_err2str
	leaq	L_.str(%rip), %rdx
	movq	%r15, %rdi
	movl	%ebx, %esi
	movq	-64(%rbp), %rbx                 ## 8-byte Reload
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_av_log
LBB0_2:
	movq	%rbx, %rdi
	callq	_ff_get_pixfmt_from_fb_varinfo
	cmpl	%r14d, %eax
	jne	LBB0_24
## %bb.3:
	movq	%rbx, -64(%rbp)                 ## 8-byte Spill
	movl	%r13d, %r14d
	addl	$7, %r14d
	sarl	$3, %r14d
	movl	12(%r12), %edi
	movq	-48(%rbp), %rsi                 ## 8-byte Reload
                                        ## kill: def $esi killed $esi killed $rsi
	callq	_FFMIN
	movl	%eax, %r15d
	movl	16(%r12), %edi
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
                                        ## kill: def $esi killed $esi killed $rsi
	callq	_FFMIN
	movl	%eax, %edx
	imull	%r14d, %edx
	movq	-72(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %r13
	movslq	20(%r12), %rax
	movslq	%r14d, %rcx
	imulq	%rax, %rcx
	shlq	$2, %rcx
	addq	32(%r12), %rcx
	movslq	24(%r12), %rsi
	movslq	8(%r12), %rax
	imulq	%rax, %rsi
	leaq	(%rcx,%rsi,4), %rbx
	movl	(%r12), %ecx
	testl	%ecx, %ecx
	je	LBB0_4
## %bb.5:
	js	LBB0_6
## %bb.8:
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	leal	(%rcx,%rdi), %esi
	subl	16(%r12), %esi
	testl	%esi, %esi
	movq	-48(%rbp), %r8                  ## 8-byte Reload
	jle	LBB0_11
## %bb.9:
	cmpl	%edi, %esi
	jge	LBB0_23
## %bb.10:
	imull	%r14d, %esi
	subl	%esi, %edx
LBB0_11:
	imull	%r14d, %ecx
	movslq	%ecx, %rcx
	leaq	(%rbx,%rcx,4), %rbx
	jmp	LBB0_12
LBB0_24:
	movl	%eax, %ebx
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	movl	%r14d, %edi
	callq	_av_get_pix_fmt_name
	movl	%eax, %r14d
	movl	%ebx, %edi
	callq	_av_get_pix_fmt_name
	leaq	L_.str.1(%rip), %rdx
	movq	%r15, %rdi
	movl	%r12d, %esi
	movl	%r14d, %ecx
	movl	%eax, %r8d
	xorl	%eax, %eax
	callq	_av_log
	movq	_EINVAL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_AVERROR                        ## TAILCALL
LBB0_4:
	movq	-48(%rbp), %r8                  ## 8-byte Reload
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	jmp	LBB0_12
LBB0_6:
	movl	%ecx, %esi
	negl	%esi
	movq	-56(%rbp), %rdi                 ## 8-byte Reload
	cmpl	%esi, %edi
	movq	-48(%rbp), %r8                  ## 8-byte Reload
	jle	LBB0_23
## %bb.7:
	imull	%r14d, %ecx
	addl	%ecx, %edx
	movslq	%ecx, %rcx
	shlq	$2, %rcx
	subq	%rcx, %r13
LBB0_12:
	imull	%edi, %r14d
	movslq	4(%r12), %rcx
	testq	%rcx, %rcx
	je	LBB0_20
## %bb.13:
	testl	%ecx, %ecx
	js	LBB0_14
## %bb.16:
	leal	(%rcx,%r8), %esi
	movq	-64(%rbp), %rdi                 ## 8-byte Reload
	subl	(%rdi), %esi
	testl	%esi, %esi
	jle	LBB0_19
## %bb.17:
	cmpl	%r8d, %esi
	jge	LBB0_23
## %bb.18:
	subl	%esi, %r15d
LBB0_19:
	imulq	%rax, %rcx
	leaq	(%rbx,%rcx,4), %rbx
LBB0_20:
	testl	%r15d, %r15d
	jle	LBB0_23
LBB0_21:
	movslq	%r14d, %rax
	shlq	$2, %rax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	.p2align	4, 0x90
LBB0_22:                                ## =>This Inner Loop Header: Depth=1
	movq	%rbx, %rdi
	movq	%r13, %rsi
	movq	%r12, %r14
	movl	%edx, %r12d
	callq	_memcpy
	movl	%r12d, %edx
	movq	%r14, %r12
	movslq	8(%r14), %rax
	leaq	(%rbx,%rax,4), %rbx
	addq	-48(%rbp), %r13                 ## 8-byte Folded Reload
	decl	%r15d
	jne	LBB0_22
LBB0_23:
	xorl	%eax, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_14:
	movl	%ecx, %eax
	negl	%eax
	cmpl	%eax, %r8d
	jle	LBB0_23
## %bb.15:
	addl	%ecx, %r15d
	imull	%r14d, %ecx
	movslq	%ecx, %rax
	shlq	$2, %rax
	subq	%rax, %r13
	testl	%r15d, %r15d
	jg	LBB0_21
	jmp	LBB0_23
	.cfi_endproc
                                        ## -- End function
	.comm	_FBIOGET_VSCREENINFO,4,2        ## @FBIOGET_VSCREENINFO
	.comm	_AV_LOG_WARNING,4,2             ## @AV_LOG_WARNING
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Error refreshing variable info: %s\n"

	.comm	_errno,4,2                      ## @errno
	.comm	_AV_LOG_ERROR,4,2               ## @AV_LOG_ERROR
L_.str.1:                               ## @.str.1
	.asciz	"Pixel format %s is not supported, use %s\n"

	.comm	_EINVAL,4,2                     ## @EINVAL
	.no_dead_strip	_fbdev_write_packet
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function fbdev_write_packet
_fbdev_write_packet:                    ; @fbdev_write_packet
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x22, x1
	mov	x19, x0
	ldp	x8, x26, [x0]
	ldr	x8, [x8]
	ldr	x8, [x8]
	ldp	w21, w25, [x8]
	ldp	w20, w27, [x8, #8]
	ldr	w0, [x26, #40]
Lloh0:
	adrp	x8, _FBIOGET_VSCREENINFO@GOTPAGE
Lloh1:
	ldr	x8, [x8, _FBIOGET_VSCREENINFO@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
	add	x24, x26, #12
	mov	x2, x24
	bl	_ioctl
	tbz	x0, #63, LBB0_2
; %bb.1:
Lloh3:
	adrp	x8, _AV_LOG_WARNING@GOTPAGE
Lloh4:
	ldr	x8, [x8, _AV_LOG_WARNING@GOTPAGEOFF]
Lloh5:
	ldr	w23, [x8]
Lloh6:
	adrp	x8, _errno@GOTPAGE
Lloh7:
	ldr	x8, [x8, _errno@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
	bl	_AVERROR
	bl	_av_err2str
	mov	x3, x0
Lloh9:
	adrp	x2, l_.str@PAGE
Lloh10:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x19
	mov	x1, x23
	bl	_av_log
LBB0_2:
	mov	x0, x24
	bl	_ff_get_pixfmt_from_fb_varinfo
	cmp	w0, w21
	b.ne	LBB0_9
; %bb.3:
	add	w8, w27, #7
	asr	w27, w8, #3
	ldr	w0, [x26, #12]
	mov	x1, x20
	bl	_FFMIN
	mov	x19, x0
	ldr	w0, [x26, #16]
	mov	x1, x25
	bl	_FFMIN
	mul	w21, w0, w27
	ldr	x22, [x22]
	ldr	x8, [x26, #32]
	ldp	w9, w10, [x26, #20]
	mul	w9, w9, w27
	add	x9, x8, w9, sxtw #2
	ldr	w8, [x26, #8]
	mul	w10, w8, w10
	add	x23, x9, w10, sxtw #2
	ldr	w9, [x26]
	cbz	w9, LBB0_12
; %bb.4:
	tbnz	w9, #31, LBB0_10
; %bb.5:
	ldr	w10, [x26, #16]
	add	w11, w9, w25
	sub	w10, w11, w10
	cmp	w10, #1
	b.lt	LBB0_8
; %bb.6:
	cmp	w10, w25
	b.ge	LBB0_21
; %bb.7:
	msub	w21, w10, w27, w21
LBB0_8:
	mul	w9, w9, w27
	add	x23, x23, w9, sxtw #2
	b	LBB0_12
LBB0_9:
	mov	x23, x0
Lloh11:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh12:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh13:
	ldr	w20, [x8]
	mov	x0, x21
	bl	_av_get_pix_fmt_name
	mov	x21, x0
	mov	x0, x23
	bl	_av_get_pix_fmt_name
                                        ; kill: def $w0 killed $w0 def $x0
	str	x0, [sp]
Lloh14:
	adrp	x2, l_.str.1@PAGE
Lloh15:
	add	x2, x2, l_.str.1@PAGEOFF
	mov	x0, x19
	mov	x1, x20
	mov	x3, x21
	bl	_av_log
Lloh16:
	adrp	x8, _EINVAL@GOTPAGE
Lloh17:
	ldr	x8, [x8, _EINVAL@GOTPAGEOFF]
Lloh18:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	b	_AVERROR
LBB0_10:
	neg	w10, w9
	cmp	w25, w10
	b.le	LBB0_21
; %bb.11:
	mul	w9, w9, w27
	add	w21, w9, w21
	sub	x22, x22, w9, sxtw #2
LBB0_12:
	mul	w9, w27, w25
	ldr	w10, [x26, #4]
	cbz	w10, LBB0_18
; %bb.13:
	tbnz	w10, #31, LBB0_22
; %bb.14:
	ldr	w11, [x24]
	add	w12, w10, w20
	sub	w11, w12, w11
	cmp	w11, #1
	b.lt	LBB0_17
; %bb.15:
	cmp	w11, w20
	b.ge	LBB0_21
; %bb.16:
	sub	w19, w19, w11
LBB0_17:
	mul	w8, w10, w8
	add	x23, x23, w8, sxtw #2
LBB0_18:
	cmp	w19, #1
	b.lt	LBB0_21
LBB0_19:
	sbfiz	x20, x9, #2, #32
LBB0_20:                                ; =>This Inner Loop Header: Depth=1
	mov	x0, x23
	mov	x1, x22
	mov	x2, x21
	bl	_memcpy
	ldrsw	x8, [x26, #8]
	add	x23, x23, x8, lsl #2
	add	x22, x22, x20
	subs	w19, w19, #1
	b.ne	LBB0_20
LBB0_21:
	mov	w0, #0
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
LBB0_22:
	neg	w8, w10
	cmp	w20, w8
	b.le	LBB0_21
; %bb.23:
	add	w19, w10, w19
	mul	w8, w10, w9
	sub	x22, x22, w8, sxtw #2
	cmp	w19, #1
	b.ge	LBB0_19
	b	LBB0_21
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh16, Lloh17, Lloh18
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.cfi_endproc
                                        ; -- End function
	.comm	_FBIOGET_VSCREENINFO,4,2        ; @FBIOGET_VSCREENINFO
	.comm	_AV_LOG_WARNING,4,2             ; @AV_LOG_WARNING
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Error refreshing variable info: %s\n"

	.comm	_errno,4,2                      ; @errno
	.comm	_AV_LOG_ERROR,4,2               ; @AV_LOG_ERROR
l_.str.1:                               ; @.str.1
	.asciz	"Pixel format %s is not supported, use %s\n"

	.comm	_EINVAL,4,2                     ; @EINVAL
	.no_dead_strip	_fbdev_write_packet
.subsections_via_symbols
