	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function estimate_timings_from_bit_rate
_estimate_timings_from_bit_rate:        ## @estimate_timings_from_bit_rate
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r14
	movl	(%rdi), %eax
	testl	%eax, %eax
	jg	LBB0_15
## %bb.1:
	movl	4(%r14), %ecx
	testl	%ecx, %ecx
	jle	LBB0_13
## %bb.2:
	movq	16(%r14), %r10
	movq	_INT64_MAX@GOTPCREL(%rip), %rax
	movslq	(%rax), %r9
	movq	_AVMEDIA_TYPE_VIDEO@GOTPCREL(%rip), %r8
	xorl	%ebx, %ebx
	xorl	%eax, %eax
	jmp	LBB0_7
	.p2align	4, 0x90
LBB0_3:                                 ##   in Loop: Header=BB0_7 Depth=1
	movq	%rdi, (%rdx)
LBB0_4:                                 ##   in Loop: Header=BB0_7 Depth=1
	movq	%r9, %rdx
	subq	%rdi, %rdx
	cmpq	%rax, %rdx
	jl	LBB0_13
## %bb.5:                               ##   in Loop: Header=BB0_7 Depth=1
	addq	%rdi, %rax
LBB0_6:                                 ##   in Loop: Header=BB0_7 Depth=1
	incq	%rbx
	cmpq	%rbx, %rcx
	je	LBB0_14
LBB0_7:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%r10,%rbx,8), %rsi
	movq	24(%rsi), %rdx
	movq	(%rdx), %rdi
	testq	%rdi, %rdi
	jg	LBB0_4
## %bb.8:                               ##   in Loop: Header=BB0_7 Depth=1
	movq	32(%rsi), %rdi
	movq	(%rdi), %rdi
	movq	(%rdi), %rdi
	testq	%rdi, %rdi
	jg	LBB0_3
## %bb.9:                               ##   in Loop: Header=BB0_7 Depth=1
	movq	8(%rdx), %rdx
	cmpq	(%r8), %rdx
	jne	LBB0_6
## %bb.10:                              ##   in Loop: Header=BB0_7 Depth=1
	cmpl	$1, (%rsi)
	jle	LBB0_6
LBB0_13:
	xorl	%eax, %eax
LBB0_14:
	movl	%eax, (%r14)
LBB0_15:
	movq	8(%r14), %rcx
	movq	_AV_NOPTS_VALUE@GOTPCREL(%rip), %r9
	cmpq	(%r9), %rcx
	jne	LBB0_29
## %bb.16:
	testl	%eax, %eax
	je	LBB0_29
## %bb.17:
	movq	32(%r14), %rdi
	testq	%rdi, %rdi
	je	LBB0_19
## %bb.18:
	movq	%r9, %rbx
	callq	_avio_size
	movq	%rbx, %r9
	movq	%rax, %r13
	jmp	LBB0_20
LBB0_19:
	xorl	%r13d, %r13d
LBB0_20:
	movq	24(%r14), %rax
	movq	(%rax), %rax
	cmpq	%rax, %r13
	jle	LBB0_29
## %bb.21:
	movl	4(%r14), %esi
	testl	%esi, %esi
	jle	LBB0_29
## %bb.22:
	subl	%eax, %r13d
	shll	$3, %r13d
	xorl	%ebx, %ebx
	movq	_INT64_MAX@GOTPCREL(%rip), %r12
	xorl	%r8d, %r8d
	movq	%r14, -48(%rbp)                 ## 8-byte Spill
	jmp	LBB0_24
	.p2align	4, 0x90
LBB0_23:                                ##   in Loop: Header=BB0_24 Depth=1
	incq	%rbx
	movslq	%esi, %rax
	cmpq	%rax, %rbx
	jge	LBB0_27
LBB0_24:                                ## =>This Inner Loop Header: Depth=1
	movq	16(%r14), %rax
	movq	(%rax,%rbx,8), %r15
	movslq	16(%r15), %r10
	movl	(%r12), %eax
	movslq	(%r14), %rcx
	cltd
	idivl	%ecx
	cmpl	%eax, %r10d
	jg	LBB0_23
## %bb.25:                              ##   in Loop: Header=BB0_24 Depth=1
	movq	8(%r15), %rax
	cmpq	(%r9), %rax
	jne	LBB0_23
## %bb.26:                              ##   in Loop: Header=BB0_24 Depth=1
	movl	20(%r15), %esi
	imulq	%r10, %rcx
	movl	%r13d, %edi
	movq	%rcx, %rdx
	movq	%r9, %r14
	callq	_av_rescale
	movq	%r14, %r9
	movq	-48(%rbp), %r14                 ## 8-byte Reload
	movq	%rax, 8(%r15)
	movl	4(%r14), %esi
	movl	$1, %r8d
	jmp	LBB0_23
LBB0_27:
	testl	%r8d, %r8d
	je	LBB0_29
## %bb.28:
	movq	_AV_LOG_WARNING@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	movq	%r14, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_av_log                         ## TAILCALL
LBB0_29:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_INT64_MAX,4,2                  ## @INT64_MAX
	.comm	_AVMEDIA_TYPE_VIDEO,8,3         ## @AVMEDIA_TYPE_VIDEO
	.comm	_AV_NOPTS_VALUE,8,3             ## @AV_NOPTS_VALUE
	.comm	_AV_LOG_WARNING,4,2             ## @AV_LOG_WARNING
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Estimating duration from bitrate, this may be inaccurate\n"

	.no_dead_strip	_estimate_timings_from_bit_rate
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function estimate_timings_from_bit_rate
_estimate_timings_from_bit_rate:        ; @estimate_timings_from_bit_rate
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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	x19, x0
	ldr	w8, [x0]
	cmp	w8, #0
	b.gt	LBB0_13
; %bb.1:
	ldr	w9, [x19, #4]
	cmp	w9, #1
	b.lt	LBB0_11
; %bb.2:
	mov	x8, #0
	ldr	x10, [x19, #16]
Lloh0:
	adrp	x11, _INT64_MAX@GOTPAGE
Lloh1:
	ldr	x11, [x11, _INT64_MAX@GOTPAGEOFF]
Lloh2:
	ldrsw	x11, [x11]
Lloh3:
	adrp	x12, _AVMEDIA_TYPE_VIDEO@GOTPAGE
Lloh4:
	ldr	x12, [x12, _AVMEDIA_TYPE_VIDEO@GOTPAGEOFF]
	b	LBB0_7
LBB0_3:                                 ;   in Loop: Header=BB0_7 Depth=1
	str	x14, [x15]
LBB0_4:                                 ;   in Loop: Header=BB0_7 Depth=1
	sub	x13, x11, x14
	cmp	x13, x8
	b.lt	LBB0_11
; %bb.5:                                ;   in Loop: Header=BB0_7 Depth=1
	add	x8, x14, x8
LBB0_6:                                 ;   in Loop: Header=BB0_7 Depth=1
	add	x10, x10, #8
	subs	x9, x9, #1
	b.eq	LBB0_12
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x13, [x10]
	ldr	x15, [x13, #24]
	ldr	x14, [x15]
	cmp	x14, #0
	b.gt	LBB0_4
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	ldr	x14, [x13, #32]
	ldr	x14, [x14]
	ldr	x14, [x14]
	cmp	x14, #1
	b.ge	LBB0_3
; %bb.9:                                ;   in Loop: Header=BB0_7 Depth=1
	ldr	x14, [x15, #8]
	ldr	x15, [x12]
	cmp	x14, x15
	b.ne	LBB0_6
; %bb.10:                               ;   in Loop: Header=BB0_7 Depth=1
	ldr	w13, [x13]
	cmp	w13, #1
	b.le	LBB0_6
LBB0_11:
	mov	x8, #0
LBB0_12:
	str	w8, [x19]
LBB0_13:
	ldr	x9, [x19, #8]
Lloh5:
	adrp	x21, _AV_NOPTS_VALUE@GOTPAGE
Lloh6:
	ldr	x21, [x21, _AV_NOPTS_VALUE@GOTPAGEOFF]
	ldr	x10, [x21]
	cmp	x9, x10
	ccmp	w8, #0, #4, eq
	b.eq	LBB0_25
; %bb.14:
	ldr	x0, [x19, #32]
	cbz	x0, LBB0_16
; %bb.15:
	bl	_avio_size
LBB0_16:
	ldr	x8, [x19, #24]
	ldr	x10, [x8]
	cmp	x0, x10
	b.le	LBB0_25
; %bb.17:
	ldr	w8, [x19, #4]
	cmp	w8, #1
	b.lt	LBB0_25
; %bb.18:
	mov	x22, #0
	mov	w9, #0
	sub	w10, w0, w10
	lsl	w20, w10, #3
Lloh7:
	adrp	x23, _INT64_MAX@GOTPAGE
Lloh8:
	ldr	x23, [x23, _INT64_MAX@GOTPAGEOFF]
	b	LBB0_20
LBB0_19:                                ;   in Loop: Header=BB0_20 Depth=1
	add	x22, x22, #1
	cmp	x22, w8, sxtw
	b.ge	LBB0_23
LBB0_20:                                ; =>This Inner Loop Header: Depth=1
	ldr	x10, [x19, #16]
	ldr	x24, [x10, x22, lsl #3]
	ldrsw	x10, [x24, #16]
	ldr	w12, [x23]
	ldrsw	x11, [x19]
	sdiv	w12, w12, w11
	cmp	w10, w12
	b.gt	LBB0_19
; %bb.21:                               ;   in Loop: Header=BB0_20 Depth=1
	ldr	x12, [x24, #8]
	ldr	x13, [x21]
	cmp	x12, x13
	b.ne	LBB0_19
; %bb.22:                               ;   in Loop: Header=BB0_20 Depth=1
	ldr	w1, [x24, #20]
	mul	x2, x11, x10
	mov	x0, x20
	bl	_av_rescale
	str	x0, [x24, #8]
	ldr	w8, [x19, #4]
	mov	w9, #1
	b	LBB0_19
LBB0_23:
	cbz	w9, LBB0_25
; %bb.24:
Lloh9:
	adrp	x8, _AV_LOG_WARNING@GOTPAGE
Lloh10:
	ldr	x8, [x8, _AV_LOG_WARNING@GOTPAGEOFF]
Lloh11:
	ldr	w1, [x8]
Lloh12:
	adrp	x2, l_.str@PAGE
Lloh13:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x19
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	b	_av_log
LBB0_25:
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpAdd	Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh9, Lloh10, Lloh11
	.cfi_endproc
                                        ; -- End function
	.comm	_INT64_MAX,4,2                  ; @INT64_MAX
	.comm	_AVMEDIA_TYPE_VIDEO,8,3         ; @AVMEDIA_TYPE_VIDEO
	.comm	_AV_NOPTS_VALUE,8,3             ; @AV_NOPTS_VALUE
	.comm	_AV_LOG_WARNING,4,2             ; @AV_LOG_WARNING
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Estimating duration from bitrate, this may be inaccurate\n"

	.no_dead_strip	_estimate_timings_from_bit_rate
.subsections_via_symbols
