	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function Rgb16ToPlanarRgb16Wrapper
_Rgb16ToPlanarRgb16Wrapper:             ## @Rgb16ToPlanarRgb16Wrapper
	.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	$168, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%r8d, -116(%rbp)                ## 4-byte Spill
	movl	%ecx, %r15d
	movq	%rdx, -136(%rbp)                ## 8-byte Spill
	movq	%rsi, -128(%rbp)                ## 8-byte Spill
	movq	%rdi, %r12
	movq	16(%rbp), %rax
	movq	___stack_chk_guard@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	%rcx, -48(%rbp)
	movq	16(%r9), %r13
	movq	%r13, -80(%rbp)
	movq	(%r9), %r14
	movq	%r14, -72(%rbp)
	movq	8(%r9), %rcx
	movq	%rcx, -144(%rbp)                ## 8-byte Spill
	movq	24(%r9), %rcx
	movq	%rcx, -152(%rbp)                ## 8-byte Spill
	movdqu	(%rax), %xmm1
	pshufd	$210, %xmm1, %xmm0              ## xmm0 = xmm1[2,0,1,3]
	movdqa	%xmm0, -208(%rbp)
	movdqa	%xmm1, -176(%rbp)               ## 16-byte Spill
	pshufd	$225, %xmm1, %xmm0              ## xmm0 = xmm1[1,0,2,3]
	movdqa	%xmm0, -192(%rbp)
	movl	(%rdi), %edi
	callq	_av_pix_fmt_desc_get
	movq	%rax, %rbx
	movl	4(%r12), %edi
	callq	_av_pix_fmt_desc_get
	movq	%rbx, %r10
	movl	(%rbx), %r9d
	movq	_HAVE_BIGENDIAN@GOTPCREL(%rip), %rcx
	cmpq	$0, (%rcx)
	movq	_AV_PIX_FMT_FLAG_BE@GOTPCREL(%rip), %rcx
	movl	(%rcx), %edx
	je	LBB0_2
## %bb.1:
	xorl	%r11d, %r11d
	testl	%r9d, %edx
	sete	%r11b
	movl	(%rax), %ecx
	testl	%edx, %ecx
	jne	LBB0_4
LBB0_3:
	orl	$2, %r11d
LBB0_4:
	movq	_AV_PIX_FMT_FLAG_PLANAR@GOTPCREL(%rip), %rdx
	movq	_AV_PIX_FMT_FLAG_RGB@GOTPCREL(%rip), %rsi
	movl	(%rsi), %esi
	orl	(%rdx), %esi
	notl	%ecx
	testl	%ecx, %esi
	jne	LBB0_9
## %bb.5:
	movq	8(%rax), %rcx
	movl	(%rcx), %r8d
	cmpl	$9, %r8d
	jl	LBB0_9
## %bb.6:
	movq	_AV_PIX_FMT_FLAG_ALPHA@GOTPCREL(%rip), %rdx
	andl	(%rdx), %r9d
	movdqa	-176(%rbp), %xmm0               ## 16-byte Reload
	pextrd	$2, %xmm0, %edx
	imull	%r15d, %edx
	movl	%edx, %esi
	shrl	$31, %esi
	addl	%edx, %esi
	sarl	%esi
	movslq	%esi, %rdx
	leaq	(,%rdx,4), %rdx
	addq	%r13, %rdx
	pextrd	$1, %xmm0, %esi
	movq	%rdx, -80(%rbp)
	imull	%r15d, %esi
	movl	%esi, %edi
	shrl	$31, %edi
	addl	%esi, %edi
	sarl	%edi
	movslq	%edi, %rsi
	movq	-144(%rbp), %rcx                ## 8-byte Reload
	leaq	(%rcx,%rsi,4), %rsi
	movq	%rsi, -112(%rbp)
	movd	%xmm0, %ecx
	imull	%r15d, %ecx
	movl	%ecx, %edi
	shrl	$31, %edi
	addl	%ecx, %edi
	sarl	%edi
	movslq	%edi, %rcx
	leaq	(%r14,%rcx,4), %rcx
	movq	%rcx, -72(%rbp)
	movq	%rcx, -104(%rbp)
	movq	%rsi, -64(%rbp)
	pextrd	$3, %xmm0, %ecx
	movq	%rdx, -96(%rbp)
	imull	%r15d, %ecx
	movl	%ecx, %edx
	shrl	$31, %edx
	addl	%ecx, %edx
	sarl	%edx
	movslq	%edx, %rcx
	movq	-152(%rbp), %rdx                ## 8-byte Reload
	leaq	(%rdx,%rcx,4), %rcx
	movq	%rcx, -56(%rbp)
	movq	%rcx, -88(%rbp)
	movl	(%r12), %edx
	leal	-128(%rdx), %ecx
	cmpl	$4, %ecx
	jb	LBB0_10
## %bb.7:
	movq	-136(%rbp), %rcx                ## 8-byte Reload
	addl	$-132, %edx
	cmpl	$4, %edx
	movl	-116(%rbp), %ebx                ## 4-byte Reload
	jae	LBB0_12
## %bb.8:
	movq	-128(%rbp), %rax                ## 8-byte Reload
	movq	(%rax), %rdi
	movl	(%rcx), %esi
	movl	$16, %eax
	subl	%r8d, %eax
	movl	8(%r12), %r10d
	subq	$8, %rsp
	leaq	-112(%rbp), %rdx
	leaq	-192(%rbp), %rcx
	jmp	LBB0_11
LBB0_9:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movl	4(%r10), %ecx
	movl	4(%rax), %r8d
	leaq	L_.str(%rip), %rdx
	movq	%r12, %rdi
	callq	_av_log
	movl	-116(%rbp), %ebx                ## 4-byte Reload
	jmp	LBB0_13
LBB0_2:
	xorl	%r11d, %r11d
	testl	%r9d, %edx
	setne	%r11b
	movl	(%rax), %ecx
	testl	%edx, %ecx
	jne	LBB0_3
	jmp	LBB0_4
LBB0_10:
	movq	-128(%rbp), %rax                ## 8-byte Reload
	movq	(%rax), %rdi
	movq	-136(%rbp), %rax                ## 8-byte Reload
	movl	(%rax), %esi
	movl	$16, %eax
	subl	%r8d, %eax
	movl	8(%r12), %r10d
	subq	$8, %rsp
	leaq	-80(%rbp), %rdx
	leaq	-208(%rbp), %rcx
	movl	-116(%rbp), %ebx                ## 4-byte Reload
LBB0_11:
	movl	%ebx, %r8d
	pushq	%r10
	pushq	%rax
	pushq	%r11
	callq	_packed16togbra16
	addq	$32, %rsp
LBB0_13:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_15
## %bb.14:
	movl	%ebx, %eax
	addq	$168, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_12:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rcx
	movl	(%rcx), %esi
	movl	4(%r10), %ecx
	movl	4(%rax), %r8d
	leaq	L_.str(%rip), %rdx
	movq	%r12, %rdi
	callq	_av_log
	jmp	LBB0_13
LBB0_15:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_AV_PIX_FMT_FLAG_ALPHA,4,2      ## @AV_PIX_FMT_FLAG_ALPHA
	.comm	_HAVE_BIGENDIAN,8,3             ## @HAVE_BIGENDIAN
	.comm	_AV_PIX_FMT_FLAG_BE,4,2         ## @AV_PIX_FMT_FLAG_BE
	.comm	_AV_PIX_FMT_FLAG_PLANAR,4,2     ## @AV_PIX_FMT_FLAG_PLANAR
	.comm	_AV_PIX_FMT_FLAG_RGB,4,2        ## @AV_PIX_FMT_FLAG_RGB
	.comm	_AV_LOG_ERROR,4,2               ## @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"unsupported conversion to planar RGB %s -> %s\n"

	.no_dead_strip	_Rgb16ToPlanarRgb16Wrapper
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function Rgb16ToPlanarRgb16Wrapper
_Rgb16ToPlanarRgb16Wrapper:             ; @Rgb16ToPlanarRgb16Wrapper
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #240
	.cfi_def_cfa_offset 240
	stp	x28, x27, [sp, #144]            ; 16-byte Folded Spill
	stp	x26, x25, [sp, #160]            ; 16-byte Folded Spill
	stp	x24, x23, [sp, #176]            ; 16-byte Folded Spill
	stp	x22, x21, [sp, #192]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #208]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #224]            ; 16-byte Folded Spill
	add	x29, sp, #224
	.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
	str	w4, [sp, #36]                   ; 4-byte Folded Spill
	mov	x23, x3
	stp	x1, x2, [sp, #8]                ; 16-byte Folded Spill
	mov	x20, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	stur	x8, [x29, #-88]
	ldp	x26, x28, [x5]
	ldp	x22, x8, [x5, #16]
	str	x8, [sp, #24]                   ; 8-byte Folded Spill
	stp	x22, x26, [sp, #104]
	ldp	w21, w19, [x6]
	ldp	w25, w27, [x6, #8]
	stp	w25, w21, [sp, #56]
	stp	w19, w27, [sp, #64]
	stp	w19, w21, [sp, #40]
	stp	w25, w27, [sp, #48]
	ldr	w0, [x0]
	bl	_av_pix_fmt_desc_get
	mov	x24, x0
	ldr	w0, [x20, #4]
	bl	_av_pix_fmt_desc_get
Lloh3:
	adrp	x9, _HAVE_BIGENDIAN@GOTPAGE
Lloh4:
	ldr	x9, [x9, _HAVE_BIGENDIAN@GOTPAGEOFF]
	ldr	w8, [x24]
Lloh5:
	ldr	x11, [x9]
Lloh6:
	adrp	x9, _AV_PIX_FMT_FLAG_BE@GOTPAGE
Lloh7:
	ldr	x9, [x9, _AV_PIX_FMT_FLAG_BE@GOTPAGEOFF]
Lloh8:
	ldr	w10, [x9]
	and	w9, w10, w8
	cmp	w9, #0
	cbz	x11, LBB0_9
; %bb.1:
	cset	w6, eq
	ldr	w9, [x0]
	tst	w9, w10
	b.ne	LBB0_3
LBB0_2:
	orr	w6, w6, #0x2
LBB0_3:
Lloh9:
	adrp	x10, _AV_PIX_FMT_FLAG_PLANAR@GOTPAGE
Lloh10:
	ldr	x10, [x10, _AV_PIX_FMT_FLAG_PLANAR@GOTPAGEOFF]
Lloh11:
	ldr	w10, [x10]
Lloh12:
	adrp	x11, _AV_PIX_FMT_FLAG_RGB@GOTPAGE
Lloh13:
	ldr	x11, [x11, _AV_PIX_FMT_FLAG_RGB@GOTPAGEOFF]
Lloh14:
	ldr	w11, [x11]
	orr	w10, w11, w10
	bics	wzr, w10, w9
	b.ne	LBB0_8
; %bb.4:
	ldr	x9, [x0, #8]
	ldr	w9, [x9]
	cmp	w9, #9
	b.lt	LBB0_8
; %bb.5:
Lloh15:
	adrp	x10, _AV_PIX_FMT_FLAG_ALPHA@GOTPAGE
Lloh16:
	ldr	x10, [x10, _AV_PIX_FMT_FLAG_ALPHA@GOTPAGEOFF]
Lloh17:
	ldr	w10, [x10]
	and	w5, w10, w8
	mul	w8, w25, w23
	cmp	w8, #0
	cinc	w8, w8, lt
	asr	w8, w8, #1
	add	x8, x22, w8, sxtw #2
	mul	w10, w19, w23
	cmp	w10, #0
	cinc	w10, w10, lt
	asr	w10, w10, #1
	add	x10, x28, w10, sxtw #2
	mul	w11, w21, w23
	cmp	w11, #0
	cinc	w11, w11, lt
	asr	w11, w11, #1
	add	x11, x26, w11, sxtw #2
	stp	x8, x11, [sp, #104]
	stp	x10, x11, [sp, #72]
	mul	w11, w27, w23
	cmp	w11, #0
	cinc	w11, w11, lt
	asr	w11, w11, #1
	ldr	x12, [sp, #24]                  ; 8-byte Folded Reload
	add	x11, x12, w11, sxtw #2
	stp	x10, x11, [sp, #120]
	stp	x8, x11, [sp, #88]
	ldr	w8, [x20]
	sub	w10, w8, #128
	cmp	w10, #4
	b.lo	LBB0_10
; %bb.6:
	sub	w8, w8, #132
	cmp	w8, #4
	ldr	w19, [sp, #36]                  ; 4-byte Folded Reload
	b.hs	LBB0_14
; %bb.7:
	ldr	x8, [sp, #8]                    ; 8-byte Folded Reload
	ldr	x0, [x8]
	ldr	x8, [sp, #16]                   ; 8-byte Folded Reload
	ldr	w1, [x8]
	mov	w8, #16
	sub	w7, w8, w9
	ldr	w8, [x20, #8]
	str	w8, [sp]
	add	x2, sp, #72
	add	x3, sp, #40
	b	LBB0_11
LBB0_8:
Lloh18:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh19:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh20:
	ldr	w1, [x8]
	ldr	w3, [x24, #4]
	ldr	w4, [x0, #4]
Lloh21:
	adrp	x2, l_.str@PAGE
Lloh22:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x20
	bl	_av_log
	ldr	w19, [sp, #36]                  ; 4-byte Folded Reload
	b	LBB0_12
LBB0_9:
	cset	w6, ne
	ldr	w9, [x0]
	tst	w9, w10
	b.ne	LBB0_2
	b	LBB0_3
LBB0_10:
	ldr	x8, [sp, #8]                    ; 8-byte Folded Reload
	ldr	x0, [x8]
	ldr	x8, [sp, #16]                   ; 8-byte Folded Reload
	ldr	w1, [x8]
	mov	w8, #16
	sub	w7, w8, w9
	ldr	w8, [x20, #8]
	str	w8, [sp]
	add	x2, sp, #104
	add	x3, sp, #56
	ldr	w19, [sp, #36]                  ; 4-byte Folded Reload
LBB0_11:
	mov	x4, x19
	bl	_packed16togbra16
LBB0_12:
	ldur	x8, [x29, #-88]
Lloh23:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh24:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh25:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_15
; %bb.13:
	mov	x0, x19
	ldp	x29, x30, [sp, #224]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #208]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #192]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #176]            ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #160]            ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #144]            ; 16-byte Folded Reload
	add	sp, sp, #240
	ret
LBB0_14:
Lloh26:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh27:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh28:
	ldr	w1, [x8]
	ldr	w3, [x24, #4]
	ldr	w4, [x0, #4]
Lloh29:
	adrp	x2, l_.str@PAGE
Lloh30:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x20
	bl	_av_log
	b	LBB0_12
LBB0_15:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpAdd	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh18, Lloh19, Lloh20
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.loh AdrpAdd	Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh26, Lloh27, Lloh28
	.cfi_endproc
                                        ; -- End function
	.comm	_AV_PIX_FMT_FLAG_ALPHA,4,2      ; @AV_PIX_FMT_FLAG_ALPHA
	.comm	_HAVE_BIGENDIAN,8,3             ; @HAVE_BIGENDIAN
	.comm	_AV_PIX_FMT_FLAG_BE,4,2         ; @AV_PIX_FMT_FLAG_BE
	.comm	_AV_PIX_FMT_FLAG_PLANAR,4,2     ; @AV_PIX_FMT_FLAG_PLANAR
	.comm	_AV_PIX_FMT_FLAG_RGB,4,2        ; @AV_PIX_FMT_FLAG_RGB
	.comm	_AV_LOG_ERROR,4,2               ; @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"unsupported conversion to planar RGB %s -> %s\n"

	.no_dead_strip	_Rgb16ToPlanarRgb16Wrapper
.subsections_via_symbols
