	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_omap_vout_vrfb_buffer_setup    ## -- Begin function omap_vout_vrfb_buffer_setup
	.p2align	4, 0x90
_omap_vout_vrfb_buffer_setup:           ## @omap_vout_vrfb_buffer_setup
	.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	%edx, %r12d
	movq	%rsi, %r15
	movq	%rdi, %r13
	callq	_is_rotation_enabled
	xorl	%ebx, %ebx
	testl	%eax, %eax
	je	LBB0_8
## %bb.1:
	movl	(%r15), %ecx
	movq	_VRFB_NUM_BUFS@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	cmpl	%eax, %ecx
	cmovbl	%ecx, %eax
	movl	%eax, (%r15)
	cmpl	$0, 40(%r13)
	je	LBB0_2
LBB0_4:
	movq	(%r13), %rdx
	movq	_OMAP_DSS_COLOR_YUV2@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rdx
	sete	%cl
	movq	_OMAP_DSS_COLOR_UYVY@GOTPCREL(%rip), %rsi
	cmpq	(%rsi), %rdx
	sete	%dl
	testl	%eax, %eax
	je	LBB0_8
## %bb.5:
	orb	%dl, %cl
	movzbl	%cl, %r12d
	xorl	%ebx, %ebx
	xorl	%r14d, %r14d
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movq	32(%r13), %rdi
	addq	%rbx, %rdi
	movq	24(%r13), %rax
	movl	(%rax,%rbx), %esi
	movl	16(%r13), %edx
	movl	8(%r13), %r8d
	movl	12(%r13), %ecx
	movl	%r12d, %r9d
	callq	_omap_vrfb_setup
	incq	%r14
	movl	(%r15), %eax
	addq	$4, %rbx
	cmpq	%rax, %r14
	jb	LBB0_6
## %bb.7:
	xorl	%ebx, %ebx
	jmp	LBB0_8
LBB0_2:
	movq	%r13, %rdi
	movq	%r15, %rsi
	movl	%r12d, %edx
	callq	_omap_vout_allocate_vrfb_buffers
	testq	%rax, %rax
	je	LBB0_3
## %bb.9:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	xorl	%ebx, %ebx
	subl	(%rax), %ebx
LBB0_8:
	movl	%ebx, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	movl	(%r15), %eax
	jmp	LBB0_4
	.cfi_endproc
                                        ## -- End function
	.comm	_VRFB_NUM_BUFS,4,2              ## @VRFB_NUM_BUFS
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_OMAP_DSS_COLOR_YUV2,8,3        ## @OMAP_DSS_COLOR_YUV2
	.comm	_OMAP_DSS_COLOR_UYVY,8,3        ## @OMAP_DSS_COLOR_UYVY
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_omap_vout_vrfb_buffer_setup    ; -- Begin function omap_vout_vrfb_buffer_setup
	.p2align	2
_omap_vout_vrfb_buffer_setup:           ; @omap_vout_vrfb_buffer_setup
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x21, x2
	mov	x19, x1
	mov	x20, x0
	bl	_is_rotation_enabled
	cbz	w0, LBB0_8
; %bb.1:
Lloh0:
	adrp	x8, _VRFB_NUM_BUFS@GOTPAGE
Lloh1:
	ldr	x8, [x8, _VRFB_NUM_BUFS@GOTPAGEOFF]
	ldr	w9, [x19]
Lloh2:
	ldr	w8, [x8]
	cmp	w9, w8
	csel	w8, w9, w8, lo
	str	w8, [x19]
	ldr	w9, [x20, #40]
	cbz	w9, LBB0_6
LBB0_2:
	ldr	x9, [x20]
Lloh3:
	adrp	x10, _OMAP_DSS_COLOR_YUV2@GOTPAGE
Lloh4:
	ldr	x10, [x10, _OMAP_DSS_COLOR_YUV2@GOTPAGEOFF]
Lloh5:
	ldr	x10, [x10]
	cmp	x9, x10
Lloh6:
	adrp	x10, _OMAP_DSS_COLOR_UYVY@GOTPAGE
Lloh7:
	ldr	x10, [x10, _OMAP_DSS_COLOR_UYVY@GOTPAGEOFF]
Lloh8:
	ldr	x10, [x10]
	ccmp	x9, x10, #4, ne
	cset	w21, eq
	cbz	w8, LBB0_5
; %bb.3:
	mov	x22, #0
	mov	x23, #0
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldp	x9, x8, [x20, #24]
	add	x0, x8, x22
	ldr	w1, [x9, x22]
	ldp	w3, w2, [x20, #12]
	ldr	w4, [x20, #8]
	mov	x5, x21
	bl	_omap_vrfb_setup
	add	x23, x23, #1
	ldr	w8, [x19]
	add	x22, x22, #4
	cmp	x23, x8
	b.lo	LBB0_4
LBB0_5:
	mov	w0, #0
	b	LBB0_8
LBB0_6:
	mov	x0, x20
	mov	x1, x19
	mov	x2, x21
	bl	_omap_vout_allocate_vrfb_buffers
	cbz	x0, LBB0_9
; %bb.7:
Lloh9:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh10:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh11:
	ldr	w8, [x8]
	neg	w0, w8
LBB0_8:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
LBB0_9:
	ldr	w8, [x19]
	b	LBB0_2
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_VRFB_NUM_BUFS,4,2              ; @VRFB_NUM_BUFS
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_OMAP_DSS_COLOR_YUV2,8,3        ; @OMAP_DSS_COLOR_YUV2
	.comm	_OMAP_DSS_COLOR_UYVY,8,3        ; @OMAP_DSS_COLOR_UYVY
.subsections_via_symbols
