	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function qsv_init_opaque_alloc
_qsv_init_opaque_alloc:                 ## @qsv_init_opaque_alloc
	.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	%r12
	pushq	%rbx
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r12
	movq	(%rdi), %r15
	movl	(%rsi), %r14d
	addl	(%r15), %r14d
	leal	(,%r14,4), %edi
	callq	_av_buffer_allocz
	movq	%rax, 16(%r12)
	testq	%rax, %rax
	je	LBB0_11
## %bb.1:
	movl	%r14d, %edi
	movl	$8, %esi
	callq	_av_malloc_array
	movq	%rax, 64(%r12)
	testq	%rax, %rax
	je	LBB0_11
## %bb.2:
	testl	%r14d, %r14d
	jle	LBB0_10
## %bb.3:
	movq	16(%r12), %rcx
	movq	(%rcx), %rcx
	movl	8(%r12), %r9d
	movl	%r14d, %r8d
	leaq	-1(%r8), %rdi
	movl	%r8d, %esi
	andl	$3, %esi
	cmpq	$3, %rdi
	jae	LBB0_5
## %bb.4:
	xorl	%edi, %edi
	jmp	LBB0_7
LBB0_11:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_AVERROR                        ## TAILCALL
LBB0_5:
	andl	$-4, %r8d
	xorl	%ebx, %ebx
	xorl	%edi, %edi
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	leaq	(%rcx,%rbx), %rdx
	movl	%r9d, (%rcx,%rbx)
	movq	%rdx, (%rax,%rbx,2)
	movq	64(%r12), %rax
	leaq	(%rcx,%rbx), %rdx
	addq	$4, %rdx
	movl	%r9d, 4(%rcx,%rbx)
	movq	%rdx, 8(%rax,%rbx,2)
	movq	64(%r12), %rax
	leaq	8(%rcx,%rbx), %rdx
	movl	%r9d, 8(%rcx,%rbx)
	movq	%rdx, 16(%rax,%rbx,2)
	movq	64(%r12), %rax
	leaq	(%rcx,%rbx), %rdx
	addq	$12, %rdx
	movl	%r9d, 12(%rcx,%rbx)
	movq	%rdx, 24(%rax,%rbx,2)
	addq	$4, %rdi
	movq	64(%r12), %rax
	addq	$16, %rbx
	cmpq	%rdi, %r8
	jne	LBB0_6
LBB0_7:
	testq	%rsi, %rsi
	je	LBB0_10
## %bb.8:
	shlq	$2, %rdi
	.p2align	4, 0x90
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	leaq	(%rcx,%rdi), %rdx
	movl	%r9d, (%rcx,%rdi)
	movq	%rdx, (%rax,%rdi,2)
	movq	64(%r12), %rax
	addq	$4, %rdi
	decq	%rsi
	jne	LBB0_9
LBB0_10:
	movq	_MFX_EXTBUFF_OPAQUE_SURFACE_ALLOCATION@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	leaq	24(%r12), %rdx
	movl	%ecx, 44(%r12)
	movl	$24, 40(%r12)
	movq	%rax, 32(%r12)
	movl	%r14d, 24(%r12)
	movl	4(%r12), %eax
	movl	%eax, 28(%r12)
	movq	56(%r12), %rcx
	movslq	48(%r12), %rsi
	leal	1(%rsi), %edi
	movl	%edi, 48(%r12)
	movq	%rdx, (%rcx,%rsi,8)
	movl	%r14d, (%r15)
	movq	16(%r12), %rcx
	movq	%rcx, 8(%r15)
	movl	%eax, 4(%r15)
	xorl	%eax, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_MFX_EXTBUFF_OPAQUE_SURFACE_ALLOCATION,4,2 ## @MFX_EXTBUFF_OPAQUE_SURFACE_ALLOCATION
	.no_dead_strip	_qsv_init_opaque_alloc
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function qsv_init_opaque_alloc
_qsv_init_opaque_alloc:                 ; @qsv_init_opaque_alloc
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
	mov	x19, x1
	ldr	x21, [x0]
	ldr	w8, [x21]
	ldr	w9, [x1]
	add	w20, w9, w8
	lsl	w0, w20, #2
	bl	_av_buffer_allocz
	str	x0, [x19, #16]
	cbz	x0, LBB0_6
; %bb.1:
	mov	x0, x20
	mov	w1, #8
	bl	_av_malloc_array
	str	x0, [x19, #64]
	cbz	x0, LBB0_6
; %bb.2:
	cmp	w20, #1
	b.lt	LBB0_5
; %bb.3:
	mov	x8, #0
	ldr	x9, [x19, #16]
	ldr	x10, [x9]
	ldr	w9, [x19, #8]
	mov	x11, x10
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	str	w9, [x11], #4
	str	x10, [x0, x8, lsl #3]
	add	x8, x8, #1
	ldr	x0, [x19, #64]
	mov	x10, x11
	cmp	x20, x8
	b.ne	LBB0_4
LBB0_5:
Lloh0:
	adrp	x8, _MFX_EXTBUFF_OPAQUE_SURFACE_ALLOCATION@GOTPAGE
Lloh1:
	ldr	x8, [x8, _MFX_EXTBUFF_OPAQUE_SURFACE_ALLOCATION@GOTPAGEOFF]
	str	w20, [x19, #24]!
Lloh2:
	ldr	w8, [x8]
	mov	w9, #24
	stp	w9, w8, [x19, #16]
	str	x0, [x19, #8]
	ldur	w8, [x19, #-20]
	str	w8, [x19, #4]
	ldr	x9, [x19, #32]
	ldrsw	x10, [x19, #24]
	add	w11, w10, #1
	str	x19, [x9, x10, lsl #3]
	str	w11, [x19, #24]
	ldur	x9, [x19, #-8]
	str	x9, [x21, #8]
	stp	w20, w8, [x21]
	mov	w0, #0
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
LBB0_6:
Lloh3:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh5:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	b	_AVERROR
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_MFX_EXTBUFF_OPAQUE_SURFACE_ALLOCATION,4,2 ; @MFX_EXTBUFF_OPAQUE_SURFACE_ALLOCATION
	.no_dead_strip	_qsv_init_opaque_alloc
.subsections_via_symbols
