	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function qsv_transfer_data_from
_qsv_transfer_data_from:                ## @qsv_transfer_data_from
	.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	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r12
	movq	%rsi, %rbx
	movq	%rdi, -48(%rbp)                 ## 8-byte Spill
	movq	(%rdi), %rax
	movq	(%rax), %r14
	movq	$0, -64(%rbp)
	movq	(%rdx), %rax
	movq	24(%rax), %r15
	movq	$0, -56(%rbp)
	cmpl	$0, (%r14)
	jne	LBB0_8
## %bb.1:
	leaq	8(%r14), %r13
	cmpq	$0, 8(%r14)
	sete	%cl
	xorl	%eax, %eax
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	testb	$1, %cl
	je	LBB0_7
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	testl	%eax, %eax
	jne	LBB0_7
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movq	%r13, %rsi
	xorl	%edx, %edx
	callq	_qsv_init_internal_session
	cmpq	$0, (%r13)
	jne	LBB0_5
## %bb.6:                               ##   in Loop: Header=BB0_2 Depth=1
	movb	$1, %cl
	cmpl	$0, (%r14)
	je	LBB0_2
LBB0_7:
	testl	%eax, %eax
	jns	LBB0_8
	jmp	LBB0_23
LBB0_5:
	movl	$1, (%r14)
	testl	%eax, %eax
	js	LBB0_23
LBB0_8:
	cmpq	$0, 8(%r14)
	je	LBB0_9
## %bb.11:
	movl	(%r15), %eax
	movl	%eax, -64(%rbp)
	leaq	-64(%rbp), %rsi
	movq	%rbx, %rdi
	callq	_map_frame_to_surface
	leaq	-56(%rbp), %r13
	movq	_MFX_WRN_DEVICE_BUSY@GOTPCREL(%rip), %r12
	jmp	LBB0_12
	.p2align	4, 0x90
LBB0_14:                                ##   in Loop: Header=BB0_12 Depth=1
	cmpq	%rax, %rbx
	jne	LBB0_15
LBB0_12:                                ## =>This Inner Loop Header: Depth=1
	movq	8(%r14), %rdi
	movq	%r15, %rsi
	leaq	-64(%rbp), %rdx
	xorl	%ecx, %ecx
	movq	%r13, %r8
	callq	_MFXVideoVPP_RunFrameVPPAsync
	movq	%rax, %rbx
	movq	(%r12), %rax
	cmpq	%rax, %rbx
	jne	LBB0_14
## %bb.13:                              ##   in Loop: Header=BB0_12 Depth=1
	movl	$1, %edi
	callq	_av_usleep
	movq	(%r12), %rax
	jmp	LBB0_14
LBB0_15:
	testq	%rbx, %rbx
	js	LBB0_25
## %bb.16:
	movq	-56(%rbp), %rsi
	testq	%rsi, %rsi
	je	LBB0_25
## %bb.17:
	movq	8(%r14), %rdi
	movl	$1000, %edx                     ## imm = 0x3E8
	callq	_MFXVideoCORE_SyncOperation
	movq	%rax, %rcx
	movq	_MFX_WRN_IN_EXECUTION@GOTPCREL(%rip), %rbx
	cmpq	(%rbx), %rax
	jne	LBB0_20
	.p2align	4, 0x90
LBB0_18:                                ## =>This Inner Loop Header: Depth=1
	movq	-56(%rbp), %rsi
	movq	8(%r14), %rdi
	movl	$1000, %edx                     ## imm = 0x3E8
	callq	_MFXVideoCORE_SyncOperation
	cmpq	(%rbx), %rax
	je	LBB0_18
## %bb.19:
	movq	%rax, %rcx
LBB0_20:
	xorl	%eax, %eax
	testq	%rcx, %rcx
	jns	LBB0_23
## %bb.21:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.2(%rip), %rdx
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	xorl	%eax, %eax
	callq	_av_log
	jmp	LBB0_22
LBB0_9:
	cmpq	$0, 16(%r14)
	je	LBB0_10
## %bb.24:
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movq	%rbx, %rsi
	movq	%r12, %rdx
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_qsv_transfer_data_child        ## TAILCALL
LBB0_25:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.1(%rip), %rdx
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	xorl	%eax, %eax
	callq	_av_log
LBB0_22:
	movq	_AVERROR_UNKNOWN@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
LBB0_23:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_10:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	xorl	%eax, %eax
	callq	_av_log
	movq	_ENOSYS@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_AVERROR                        ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_AV_LOG_ERROR,4,2               ## @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Surface download not possible\n"

	.comm	_ENOSYS,4,2                     ## @ENOSYS
	.comm	_MFX_WRN_DEVICE_BUSY,8,3        ## @MFX_WRN_DEVICE_BUSY
L_.str.1:                               ## @.str.1
	.asciz	"Error downloading the surface\n"

	.comm	_AVERROR_UNKNOWN,4,2            ## @AVERROR_UNKNOWN
	.comm	_MFX_WRN_IN_EXECUTION,8,3       ## @MFX_WRN_IN_EXECUTION
L_.str.2:                               ## @.str.2
	.asciz	"Error synchronizing the operation: %d\n"

	.no_dead_strip	_qsv_transfer_data_from
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function qsv_transfer_data_from
_qsv_transfer_data_from:                ; @qsv_transfer_data_from
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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	x22, x2
	mov	x21, x1
	mov	x19, x0
	ldr	x8, [x0]
	ldr	x24, [x8]
	stp	xzr, xzr, [sp, #16]
	ldr	x8, [x2]
	ldr	x20, [x8, #24]
	ldr	w8, [x24]
	cbnz	w8, LBB0_8
; %bb.1:
	mov	w0, #0
	mov	x23, x24
	ldr	x8, [x23, #8]!
	cmp	x8, #0
	cset	w8, eq
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	tbz	w8, #0, LBB0_6
; %bb.3:                                ;   in Loop: Header=BB0_2 Depth=1
	cbnz	w0, LBB0_6
; %bb.4:                                ;   in Loop: Header=BB0_2 Depth=1
	mov	x0, x19
	mov	x1, x23
	mov	w2, #0
	bl	_qsv_init_internal_session
	ldr	x8, [x23]
	cbnz	x8, LBB0_7
; %bb.5:                                ;   in Loop: Header=BB0_2 Depth=1
	ldr	w9, [x24]
	mov	w8, #1
	cbz	w9, LBB0_2
LBB0_6:
	tbz	w0, #31, LBB0_8
	b	LBB0_26
LBB0_7:
	mov	w8, #1
	str	w8, [x24]
	tbnz	w0, #31, LBB0_26
LBB0_8:
	ldr	x8, [x24, #8]
	cbz	x8, LBB0_18
; %bb.9:
	ldr	w8, [x20]
	str	w8, [sp, #24]
	add	x1, sp, #24
	mov	x0, x21
	bl	_map_frame_to_surface
Lloh0:
	adrp	x22, _MFX_WRN_DEVICE_BUSY@GOTPAGE
Lloh1:
	ldr	x22, [x22, _MFX_WRN_DEVICE_BUSY@GOTPAGEOFF]
	b	LBB0_11
LBB0_10:                                ;   in Loop: Header=BB0_11 Depth=1
	cmp	x21, x8
	b.ne	LBB0_13
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	ldr	x0, [x24, #8]
	add	x2, sp, #24
	add	x4, sp, #16
	mov	x1, x20
	mov	x3, #0
	bl	_MFXVideoVPP_RunFrameVPPAsync
	mov	x21, x0
	ldr	x8, [x22]
	cmp	x0, x8
	b.ne	LBB0_10
; %bb.12:                               ;   in Loop: Header=BB0_11 Depth=1
	mov	w0, #1
	bl	_av_usleep
	ldr	x8, [x22]
	b	LBB0_10
LBB0_13:
	tbnz	x21, #63, LBB0_20
; %bb.14:
	ldr	x1, [sp, #16]
	cbz	x1, LBB0_20
; %bb.15:
	ldr	x0, [x24, #8]
	mov	w2, #1000
	bl	_MFXVideoCORE_SyncOperation
Lloh2:
	adrp	x20, _MFX_WRN_IN_EXECUTION@GOTPAGE
Lloh3:
	ldr	x20, [x20, _MFX_WRN_IN_EXECUTION@GOTPAGEOFF]
LBB0_16:                                ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x20]
	cmp	x0, x8
	b.ne	LBB0_21
; %bb.17:                               ;   in Loop: Header=BB0_16 Depth=1
	ldr	x1, [sp, #16]
	ldr	x0, [x24, #8]
	mov	w2, #1000
	bl	_MFXVideoCORE_SyncOperation
	b	LBB0_16
LBB0_18:
	ldr	x8, [x24, #16]
	cbz	x8, LBB0_23
; %bb.19:
	mov	x0, x19
	mov	x1, x21
	mov	x2, x22
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #96
	b	_qsv_transfer_data_child
LBB0_20:
Lloh4:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh5:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh6:
	ldr	w1, [x8]
Lloh7:
	adrp	x2, l_.str.1@PAGE
Lloh8:
	add	x2, x2, l_.str.1@PAGEOFF
	b	LBB0_25
LBB0_21:
	tbnz	x0, #63, LBB0_24
; %bb.22:
	mov	w0, #0
	b	LBB0_26
LBB0_23:
Lloh9:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh10:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
Lloh12:
	adrp	x2, l_.str@PAGE
Lloh13:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x19
	bl	_av_log
Lloh14:
	adrp	x8, _ENOSYS@GOTPAGE
Lloh15:
	ldr	x8, [x8, _ENOSYS@GOTPAGEOFF]
Lloh16:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #96
	b	_AVERROR
LBB0_24:
Lloh17:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh18:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh19:
	ldr	w1, [x8]
	str	x0, [sp]
Lloh20:
	adrp	x2, l_.str.2@PAGE
Lloh21:
	add	x2, x2, l_.str.2@PAGEOFF
LBB0_25:
	mov	x0, x19
	bl	_av_log
Lloh22:
	adrp	x8, _AVERROR_UNKNOWN@GOTPAGE
Lloh23:
	ldr	x8, [x8, _AVERROR_UNKNOWN@GOTPAGEOFF]
Lloh24:
	ldr	w0, [x8]
LBB0_26:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpAdd	Lloh7, Lloh8
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh14, Lloh15, Lloh16
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.loh AdrpAdd	Lloh20, Lloh21
	.loh AdrpLdrGotLdr	Lloh17, Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh22, Lloh23, Lloh24
	.cfi_endproc
                                        ; -- End function
	.comm	_AV_LOG_ERROR,4,2               ; @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Surface download not possible\n"

	.comm	_ENOSYS,4,2                     ; @ENOSYS
	.comm	_MFX_WRN_DEVICE_BUSY,8,3        ; @MFX_WRN_DEVICE_BUSY
l_.str.1:                               ; @.str.1
	.asciz	"Error downloading the surface\n"

	.comm	_AVERROR_UNKNOWN,4,2            ; @AVERROR_UNKNOWN
	.comm	_MFX_WRN_IN_EXECUTION,8,3       ; @MFX_WRN_IN_EXECUTION
l_.str.2:                               ; @.str.2
	.asciz	"Error synchronizing the operation: %d\n"

	.no_dead_strip	_qsv_transfer_data_from
.subsections_via_symbols
