	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function videotoolbox_retrieve_data
_videotoolbox_retrieve_data:            ## @videotoolbox_retrieve_data
	.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	$72, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %r15
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	8(%rdi), %rax
	movq	(%rax), %r13
	movq	16(%rsi), %rax
	movl	12(%rax), %r12d
	movl	%r12d, %edi
	callq	_CVPixelBufferGetPixelFormatType
	movl	%eax, %ebx
	xorps	%xmm0, %xmm0
	movaps	%xmm0, -64(%rbp)
	movaps	%xmm0, -80(%rbp)
	movaps	%xmm0, -96(%rbp)
	movq	(%r13), %rdi
	callq	_av_frame_unref
	cmpl	$134, %ebx
	je	LBB0_7
## %bb.1:
	cmpl	$129, %ebx
	je	LBB0_2
## %bb.3:
	cmpl	$128, %ebx
	jne	LBB0_5
## %bb.4:
	movq	_AV_PIX_FMT_UYVY422@GOTPCREL(%rip), %rax
	jmp	LBB0_8
LBB0_2:
	movq	_AV_PIX_FMT_YUV420P@GOTPCREL(%rip), %rax
	jmp	LBB0_8
LBB0_7:
	movq	_AV_PIX_FMT_BGRA@GOTPCREL(%rip), %rax
LBB0_8:
	movl	(%rax), %eax
	movq	(%r13), %rdi
	movl	%eax, 8(%rdi)
	movl	4(%r14), %eax
	movl	%eax, 4(%rdi)
	movl	(%r14), %eax
	movl	%eax, (%rdi)
	movl	$32, %esi
	callq	_av_frame_get_buffer
	testl	%eax, %eax
	js	LBB0_9
## %bb.10:
	movq	_kCVPixelBufferLock_ReadOnly@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%r12d, %edi
	callq	_CVPixelBufferLockBaseAddress
	movq	_kCVReturnSuccess@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_11
## %bb.12:
	movl	%r12d, %edi
	callq	_CVPixelBufferIsPlanar
	movl	%r12d, %edi
	testq	%rax, %rax
	je	LBB0_16
## %bb.13:
	callq	_CVPixelBufferGetPlaneCount
	testl	%eax, %eax
	jle	LBB0_17
## %bb.14:
	movl	%eax, %r15d
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_15:                                ## =>This Inner Loop Header: Depth=1
	movl	%r12d, %edi
	movl	%ebx, %esi
	callq	_CVPixelBufferGetBaseAddressOfPlane
	movq	%rax, -80(%rbp,%rbx,8)
	movl	%r12d, %edi
	movl	%ebx, %esi
	callq	_CVPixelBufferGetBytesPerRowOfPlane
	movl	%eax, -96(%rbp,%rbx,4)
	incq	%rbx
	cmpq	%rbx, %r15
	jne	LBB0_15
	jmp	LBB0_17
LBB0_9:
	movl	%eax, %ebx
	jmp	LBB0_19
LBB0_5:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	movl	(%r15), %edi
	callq	_av_fourcc2str
	movq	_videotoolbox_pixfmt@GOTPCREL(%rip), %rcx
	movl	(%rcx), %r8d
	leaq	L_.str(%rip), %rdx
	xorl	%edi, %edi
	movl	%ebx, %esi
	movl	%eax, %ecx
	xorl	%eax, %eax
	callq	_av_log
	movq	_ENOSYS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_21
## %bb.6:
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_AVERROR                        ## TAILCALL
LBB0_11:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.1(%rip), %rdx
	xorl	%edi, %edi
	xorl	%eax, %eax
	callq	_av_log
	movq	_AVERROR_UNKNOWN@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	jmp	LBB0_19
LBB0_16:
	callq	_CVPixelBufferGetBaseAddress
	movq	%rax, -80(%rbp)
	movl	%r12d, %edi
	callq	_CVPixelBufferGetBytesPerRow
	movl	%eax, -96(%rbp)
LBB0_17:
	movq	(%r13), %rax
	movq	16(%rax), %rdi
	movl	8(%rax), %r8d
	movl	12(%rax), %esi
	movl	(%r14), %eax
	movl	4(%r14), %r9d
	movl	%eax, (%rsp)
	leaq	-80(%rbp), %rdx
	leaq	-96(%rbp), %rcx
	callq	_av_image_copy
	movq	(%r13), %rdi
	movq	%r14, %rsi
	callq	_av_frame_copy_props
	movl	%eax, %ebx
	movq	_kCVPixelBufferLock_ReadOnly@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	movl	%r12d, %edi
	callq	_CVPixelBufferUnlockBaseAddress
	testl	%ebx, %ebx
	js	LBB0_19
## %bb.18:
	movq	%r14, %rdi
	callq	_av_frame_unref
	movq	(%r13), %rsi
	movq	%r14, %rdi
	callq	_av_frame_move_ref
	xorl	%ebx, %ebx
LBB0_19:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_21
## %bb.20:
	movl	%ebx, %eax
	addq	$72, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_21:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_AV_PIX_FMT_YUV420P,4,2         ## @AV_PIX_FMT_YUV420P
	.comm	_AV_PIX_FMT_UYVY422,4,2         ## @AV_PIX_FMT_UYVY422
	.comm	_AV_PIX_FMT_BGRA,4,2            ## @AV_PIX_FMT_BGRA
	.comm	_AV_LOG_ERROR,4,2               ## @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%s: Unsupported pixel format: %s\n"

	.comm	_videotoolbox_pixfmt,4,2        ## @videotoolbox_pixfmt
	.comm	_ENOSYS,4,2                     ## @ENOSYS
	.comm	_kCVPixelBufferLock_ReadOnly,4,2 ## @kCVPixelBufferLock_ReadOnly
	.comm	_kCVReturnSuccess,8,3           ## @kCVReturnSuccess
L_.str.1:                               ## @.str.1
	.asciz	"Error locking the pixel buffer.\n"

	.comm	_AVERROR_UNKNOWN,4,2            ## @AVERROR_UNKNOWN
	.comm	_AV_PIX_FMT_NV12,4,2            ## @AV_PIX_FMT_NV12
	.comm	_AV_PIX_FMT_P010,4,2            ## @AV_PIX_FMT_P010
	.no_dead_strip	_videotoolbox_retrieve_data
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function videotoolbox_retrieve_data
_videotoolbox_retrieve_data:            ; @videotoolbox_retrieve_data
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #160
	.cfi_def_cfa_offset 160
	stp	x26, x25, [sp, #80]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #96]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #112]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #128]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #144]            ; 16-byte Folded Spill
	add	x29, sp, #144
	.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	x19, x1
	mov	x21, x0
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #72]
	ldr	x8, [x0, #8]
	ldr	x23, [x8]
	ldr	x8, [x1, #16]
	ldr	w20, [x8, #12]
	mov	x0, x20
	bl	_CVPixelBufferGetPixelFormatType
	mov	x22, x0
	movi.2d	v0, #0000000000000000
	stp	q0, q0, [sp, #32]
	stp	xzr, xzr, [sp, #16]
	ldr	x0, [x23]
	bl	_av_frame_unref
	cmp	w22, #134
	b.eq	LBB0_5
; %bb.1:
	cmp	w22, #129
	b.eq	LBB0_4
; %bb.2:
	cmp	w22, #128
	b.ne	LBB0_13
; %bb.3:
Lloh3:
	adrp	x8, _AV_PIX_FMT_UYVY422@GOTPAGE
Lloh4:
	ldr	x8, [x8, _AV_PIX_FMT_UYVY422@GOTPAGEOFF]
	b	LBB0_6
LBB0_4:
Lloh5:
	adrp	x8, _AV_PIX_FMT_YUV420P@GOTPAGE
Lloh6:
	ldr	x8, [x8, _AV_PIX_FMT_YUV420P@GOTPAGEOFF]
	b	LBB0_6
LBB0_5:
Lloh7:
	adrp	x8, _AV_PIX_FMT_BGRA@GOTPAGE
Lloh8:
	ldr	x8, [x8, _AV_PIX_FMT_BGRA@GOTPAGEOFF]
LBB0_6:
	ldr	w8, [x8]
	ldr	x0, [x23]
	str	w8, [x0, #8]
	ldr	d0, [x19]
	str	d0, [x0]
	mov	w1, #32
	bl	_av_frame_get_buffer
	tbnz	w0, #31, LBB0_12
; %bb.7:
Lloh9:
	adrp	x22, _kCVPixelBufferLock_ReadOnly@GOTPAGE
Lloh10:
	ldr	x22, [x22, _kCVPixelBufferLock_ReadOnly@GOTPAGEOFF]
	ldr	w1, [x22]
	mov	x0, x20
	bl	_CVPixelBufferLockBaseAddress
Lloh11:
	adrp	x8, _kCVReturnSuccess@GOTPAGE
Lloh12:
	ldr	x8, [x8, _kCVReturnSuccess@GOTPAGEOFF]
Lloh13:
	ldr	x8, [x8]
	cmp	x0, x8
	b.ne	LBB0_15
; %bb.8:
	mov	x0, x20
	bl	_CVPixelBufferIsPlanar
	cbz	x0, LBB0_16
; %bb.9:
	mov	x0, x20
	bl	_CVPixelBufferGetPlaneCount
	cmp	w0, #1
	b.lt	LBB0_17
; %bb.10:
	mov	x21, #0
	add	x24, sp, #32
	add	x25, sp, #16
	mov	w26, w0
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	mov	x0, x20
	mov	x1, x21
	bl	_CVPixelBufferGetBaseAddressOfPlane
	str	x0, [x24, x21, lsl #3]
	mov	x0, x20
	mov	x1, x21
	bl	_CVPixelBufferGetBytesPerRowOfPlane
	str	w0, [x25, x21, lsl #2]
	add	x21, x21, #1
	cmp	x26, x21
	b.ne	LBB0_11
	b	LBB0_17
LBB0_12:
	mov	x21, x0
	b	LBB0_19
LBB0_13:
Lloh14:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh15:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh16:
	ldr	w19, [x8]
	ldr	w0, [x21]
	bl	_av_fourcc2str
                                        ; kill: def $w0 killed $w0 def $x0
Lloh17:
	adrp	x8, _videotoolbox_pixfmt@GOTPAGE
Lloh18:
	ldr	x8, [x8, _videotoolbox_pixfmt@GOTPAGEOFF]
Lloh19:
	ldr	w8, [x8]
	stp	x0, x8, [sp]
Lloh20:
	adrp	x2, l_.str@PAGE
Lloh21:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, #0
	mov	x1, x19
	bl	_av_log
Lloh22:
	adrp	x8, _ENOSYS@GOTPAGE
Lloh23:
	ldr	x8, [x8, _ENOSYS@GOTPAGEOFF]
Lloh24:
	ldr	w0, [x8]
	ldr	x8, [sp, #72]
Lloh25:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh26:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh27:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_21
; %bb.14:
	ldp	x29, x30, [sp, #144]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #128]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #112]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #96]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #80]             ; 16-byte Folded Reload
	add	sp, sp, #160
	b	_AVERROR
LBB0_15:
Lloh28:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh29:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh30:
	ldr	w1, [x8]
Lloh31:
	adrp	x2, l_.str.1@PAGE
Lloh32:
	add	x2, x2, l_.str.1@PAGEOFF
	mov	x0, #0
	bl	_av_log
Lloh33:
	adrp	x8, _AVERROR_UNKNOWN@GOTPAGE
Lloh34:
	ldr	x8, [x8, _AVERROR_UNKNOWN@GOTPAGEOFF]
Lloh35:
	ldr	w21, [x8]
	b	LBB0_19
LBB0_16:
	mov	x0, x20
	bl	_CVPixelBufferGetBaseAddress
	str	x0, [sp, #32]
	mov	x0, x20
	bl	_CVPixelBufferGetBytesPerRow
	str	w0, [sp, #16]
LBB0_17:
	ldr	x8, [x23]
	ldr	x0, [x8, #16]
	ldp	w4, w1, [x8, #8]
	ldp	w6, w5, [x19]
	add	x2, sp, #32
	add	x3, sp, #16
	bl	_av_image_copy
	ldr	x0, [x23]
	mov	x1, x19
	bl	_av_frame_copy_props
	mov	x21, x0
	ldr	w1, [x22]
	mov	x0, x20
	bl	_CVPixelBufferUnlockBaseAddress
	tbnz	w21, #31, LBB0_19
; %bb.18:
	mov	x0, x19
	bl	_av_frame_unref
	ldr	x1, [x23]
	mov	x0, x19
	bl	_av_frame_move_ref
	mov	w21, #0
LBB0_19:
	ldr	x8, [sp, #72]
Lloh36:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh37:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh38:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_21
; %bb.20:
	mov	x0, x21
	ldp	x29, x30, [sp, #144]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #128]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #112]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #96]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #80]             ; 16-byte Folded Reload
	add	sp, sp, #160
	ret
LBB0_21:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGot	Lloh9, Lloh10
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh33, Lloh34, Lloh35
	.loh AdrpAdd	Lloh31, Lloh32
	.loh AdrpLdrGotLdr	Lloh28, Lloh29, Lloh30
	.loh AdrpLdrGotLdr	Lloh36, Lloh37, Lloh38
	.cfi_endproc
                                        ; -- End function
	.comm	_AV_PIX_FMT_YUV420P,4,2         ; @AV_PIX_FMT_YUV420P
	.comm	_AV_PIX_FMT_UYVY422,4,2         ; @AV_PIX_FMT_UYVY422
	.comm	_AV_PIX_FMT_BGRA,4,2            ; @AV_PIX_FMT_BGRA
	.comm	_AV_LOG_ERROR,4,2               ; @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%s: Unsupported pixel format: %s\n"

	.comm	_videotoolbox_pixfmt,4,2        ; @videotoolbox_pixfmt
	.comm	_ENOSYS,4,2                     ; @ENOSYS
	.comm	_kCVPixelBufferLock_ReadOnly,4,2 ; @kCVPixelBufferLock_ReadOnly
	.comm	_kCVReturnSuccess,8,3           ; @kCVReturnSuccess
l_.str.1:                               ; @.str.1
	.asciz	"Error locking the pixel buffer.\n"

	.comm	_AVERROR_UNKNOWN,4,2            ; @AVERROR_UNKNOWN
	.comm	_AV_PIX_FMT_NV12,4,2            ; @AV_PIX_FMT_NV12
	.comm	_AV_PIX_FMT_P010,4,2            ; @AV_PIX_FMT_P010
	.no_dead_strip	_videotoolbox_retrieve_data
.subsections_via_symbols
