	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_av_packet_ref                  ## -- Begin function av_packet_ref
	.p2align	4, 0x90
_av_packet_ref:                         ## @av_packet_ref
	.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, %r14
	callq	_av_packet_copy_props
	testl	%eax, %eax
	js	LBB0_1
## %bb.2:
	movq	8(%r12), %rdi
	testq	%rdi, %rdi
	je	LBB0_3
## %bb.10:
	callq	_av_buffer_ref
	movq	%rax, 8(%r14)
	testq	%rax, %rax
	je	LBB0_11
## %bb.13:
	leaq	4(%r12), %rax
	jmp	LBB0_14
LBB0_1:
	movl	%eax, %ebx
	jmp	LBB0_15
LBB0_3:
	leaq	8(%r14), %r15
	movl	(%r12), %esi
	movq	%r15, %rdi
	callq	_packet_alloc
	testl	%eax, %eax
	js	LBB0_12
## %bb.4:
	cmpl	$0, (%r12)
	je	LBB0_5
## %bb.6:
	xorl	%edi, %edi
	cmpl	$0, 4(%r12)
	setne	%dil
	jmp	LBB0_7
LBB0_11:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_AVERROR
LBB0_12:
	movl	%eax, %ebx
	movq	%r14, %rdi
	callq	_av_packet_free_side_data
	jmp	LBB0_15
LBB0_5:
	movl	$1, %edi
LBB0_7:
	callq	_av_assert1
	movl	(%r12), %edx
	testl	%edx, %edx
	je	LBB0_9
## %bb.8:
	movq	(%r15), %rax
	movl	(%rax), %edi
	movl	4(%r12), %esi
	callq	_memcpy
LBB0_9:
	movq	(%r15), %rax
LBB0_14:
	movl	(%rax), %eax
	movl	%eax, 4(%r14)
	movl	(%r12), %eax
	movl	%eax, (%r14)
	xorl	%ebx, %ebx
LBB0_15:
	movl	%ebx, %eax
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOMEM,4,2                     ## @ENOMEM
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_av_packet_ref                  ; -- Begin function av_packet_ref
	.p2align	2
_av_packet_ref:                         ; @av_packet_ref
	.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	x20, x1
	mov	x19, x0
	bl	_av_packet_copy_props
	tbnz	w0, #31, LBB0_4
; %bb.1:
	ldr	x0, [x20, #8]
	cbz	x0, LBB0_5
; %bb.2:
	bl	_av_buffer_ref
	str	x0, [x19, #8]
	cbz	x0, LBB0_8
; %bb.3:
	add	x8, x20, #4
	b	LBB0_14
LBB0_4:
	mov	x22, x0
	b	LBB0_15
LBB0_5:
	add	x21, x19, #8
	ldr	w1, [x20]
	mov	x0, x21
	bl	_packet_alloc
	tbnz	w0, #31, LBB0_9
; %bb.6:
	ldr	w8, [x20]
	cbz	w8, LBB0_10
; %bb.7:
	ldr	w8, [x20, #4]
	cmp	w8, #0
	cset	w0, ne
	b	LBB0_11
LBB0_8:
Lloh0:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	bl	_AVERROR
LBB0_9:
	mov	x22, x0
	mov	x0, x19
	bl	_av_packet_free_side_data
	b	LBB0_15
LBB0_10:
	mov	w0, #1
LBB0_11:
	bl	_av_assert1
	ldr	w2, [x20]
	cbz	w2, LBB0_13
; %bb.12:
	ldr	x8, [x21]
	ldr	w0, [x8]
	ldr	w1, [x20, #4]
	bl	_memcpy
LBB0_13:
	ldr	x8, [x21]
LBB0_14:
	mov	w22, #0
	ldr	w8, [x8]
	ldr	w9, [x20]
	stp	w9, w8, [x19]
LBB0_15:
	mov	x0, x22
	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
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOMEM,4,2                     ; @ENOMEM
.subsections_via_symbols
