	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function mxf_compute_edit_units_per_packet
_mxf_compute_edit_units_per_packet:     ## @mxf_compute_edit_units_per_packet
	.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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	8(%rsi), %r15
	testq	%r15, %r15
	je	LBB0_8
## %bb.1:
	movl	$1, (%r15)
	movq	8(%r15), %rax
	movq	_ClipWrapped@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jne	LBB0_8
## %bb.2:
	movq	%rsi, %rbx
	movl	24(%r15), %esi
	callq	_mxf_find_index_table
	movq	%rax, %r14
	movq	(%rbx), %rax
	movq	(%rax), %rcx
	movq	_AVMEDIA_TYPE_AUDIO@GOTPCREL(%rip), %rdx
	cmpq	(%rdx), %rcx
	jne	LBB0_8
## %bb.3:
	movl	8(%rax), %edi
	callq	_is_pcm
	testl	%eax, %eax
	je	LBB0_8
## %bb.4:
	testq	%r14, %r14
	je	LBB0_8
## %bb.5:
	cmpl	$1, (%r14)
	jne	LBB0_8
## %bb.6:
	movq	8(%r14), %rax
	movq	(%rax), %rax
	cmpl	$31, (%rax)
	jg	LBB0_8
## %bb.7:
	movl	16(%r15), %eax
	cltd
	idivl	20(%r15)
	cltq
	imulq	$1374389535, %rax, %rsi         ## imm = 0x51EB851F
	movq	%rsi, %rax
	shrq	$63, %rax
	sarq	$35, %rsi
	addl	%eax, %esi
	movl	$1, %edi
                                        ## kill: def $esi killed $esi killed $rsi
	callq	_FFMAX
	movl	%eax, (%r15)
LBB0_8:
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ClipWrapped,8,3                ## @ClipWrapped
	.comm	_AVMEDIA_TYPE_AUDIO,8,3         ## @AVMEDIA_TYPE_AUDIO
	.no_dead_strip	_mxf_compute_edit_units_per_packet
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function mxf_compute_edit_units_per_packet
_mxf_compute_edit_units_per_packet:     ; @mxf_compute_edit_units_per_packet
	.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
	ldr	x21, [x1, #8]
	cbz	x21, LBB0_7
; %bb.1:
	mov	w8, #1
	str	w8, [x21]
	ldr	x8, [x21, #8]
Lloh0:
	adrp	x9, _ClipWrapped@GOTPAGE
Lloh1:
	ldr	x9, [x9, _ClipWrapped@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x9]
	cmp	x8, x9
	b.ne	LBB0_7
; %bb.2:
	mov	x20, x1
	ldr	w1, [x21, #24]
	bl	_mxf_find_index_table
	ldr	x8, [x20]
	ldr	x9, [x8]
Lloh3:
	adrp	x10, _AVMEDIA_TYPE_AUDIO@GOTPAGE
Lloh4:
	ldr	x10, [x10, _AVMEDIA_TYPE_AUDIO@GOTPAGEOFF]
Lloh5:
	ldr	x10, [x10]
	cmp	x9, x10
	b.ne	LBB0_7
; %bb.3:
	mov	x19, x0
	ldr	w0, [x8, #8]
	bl	_is_pcm
	cmp	w0, #0
	ccmp	x19, #0, #4, ne
	b.eq	LBB0_7
; %bb.4:
	ldr	w8, [x19]
	cmp	w8, #1
	b.ne	LBB0_7
; %bb.5:
	ldr	x8, [x19, #8]
	ldr	x8, [x8]
	ldr	w8, [x8]
	cmp	w8, #31
	b.gt	LBB0_7
; %bb.6:
	ldp	w8, w9, [x21, #16]
	sdiv	w8, w8, w9
	mov	w9, #34079
	movk	w9, #20971, lsl #16
	smull	x8, w8, w9
	lsr	x9, x8, #63
	asr	x8, x8, #35
	add	w1, w8, w9
	mov	w0, #1
	bl	_FFMAX
	str	w0, [x21]
LBB0_7:
	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
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_ClipWrapped,8,3                ; @ClipWrapped
	.comm	_AVMEDIA_TYPE_AUDIO,8,3         ; @AVMEDIA_TYPE_AUDIO
	.no_dead_strip	_mxf_compute_edit_units_per_packet
.subsections_via_symbols
