	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function asf_read_timestamp
_asf_read_timestamp:                    ## @asf_read_timestamp
	.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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%esi, -52(%rbp)                 ## 4-byte Spill
	movq	%rdi, %r13
	movq	16(%rdi), %r15
	movq	_AV_NOPTS_VALUE@GOTPCREL(%rip), %rax
	movl	(%rax), %r12d
	movl	4(%r15), %r14d
	addl	(%r15), %r14d
	movl	8(%r15), %eax
	movl	12(%r15), %esi
	movl	%r14d, %ecx
	subl	%eax, %ecx
	notl	%eax
	movq	%rdx, -96(%rbp)                 ## 8-byte Spill
	addl	(%rdx), %eax
	addl	%esi, %eax
	cltd
	idivl	%esi
	movl	%eax, %edi
	movl	%ecx, %eax
	cltd
	idivl	%esi
                                        ## kill: def $eax killed $eax def $rax
	leal	-1(%rax), %edx
	xorl	%esi, %esi
	callq	_av_clip
	movl	%eax, %esi
	imull	12(%r15), %esi
	addl	8(%r15), %esi
	movl	8(%r13), %edi
	movq	_SEEK_SET@GOTPCREL(%rip), %rax
	movl	(%rax), %edx
	movl	%esi, -44(%rbp)                 ## 4-byte Spill
	callq	_avio_seek
	movq	%r13, %rdi
	callq	_reset_packet_state
	movl	8(%r13), %edi
	callq	_avio_tell
	movl	%r14d, -48(%rbp)                ## 4-byte Spill
	cmpl	%r14d, %eax
	jge	LBB0_13
## %bb.1:
	leaq	-88(%rbp), %rbx
	movq	%r13, -64(%rbp)                 ## 8-byte Spill
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_12:                                ##   in Loop: Header=BB0_2 Depth=1
	leaq	-88(%rbp), %rbx
	movq	%rbx, %rdi
	callq	_av_packet_unref
	movq	-64(%rbp), %r13                 ## 8-byte Reload
	movl	8(%r13), %edi
	callq	_avio_tell
	cmpl	-48(%rbp), %eax                 ## 4-byte Folded Reload
	jge	LBB0_13
LBB0_2:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_6 Depth 2
	movq	%rbx, %rdi
	callq	_av_init_packet
	movl	8(%r13), %edi
	callq	_avio_tell
	movl	%eax, %r14d
	movq	%r13, %rdi
	movq	%rbx, %rsi
	callq	_asf_read_packet
	testl	%eax, %eax
	js	LBB0_3
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	12(%r15), %eax
	movl	-44(%rbp), %r13d                ## 4-byte Reload
	addl	%r13d, %eax
	cmpl	%eax, %r14d
	cmovgel	%eax, %r13d
	movl	16(%r15), %eax
	testl	%eax, %eax
	movl	%r13d, -44(%rbp)                ## 4-byte Spill
	jle	LBB0_12
## %bb.5:                               ##   in Loop: Header=BB0_2 Depth=1
	xorl	%ebx, %ebx
	movq	_AV_PKT_FLAG_KEY@GOTPCREL(%rip), %rdx
	jmp	LBB0_6
	.p2align	4, 0x90
LBB0_8:                                 ##   in Loop: Header=BB0_6 Depth=2
	xorl	%r12d, %r12d
LBB0_11:                                ##   in Loop: Header=BB0_6 Depth=2
	incq	%rbx
	movslq	%eax, %rcx
	cmpq	%rcx, %rbx
	jge	LBB0_12
LBB0_6:                                 ##   Parent Loop BB0_2 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	movl	(%rdx), %ecx
	testl	%ecx, -88(%rbp)
	je	LBB0_11
## %bb.7:                               ##   in Loop: Header=BB0_6 Depth=2
	movl	-84(%rbp), %r12d
	testl	%r12d, %r12d
	je	LBB0_8
## %bb.9:                               ##   in Loop: Header=BB0_6 Depth=2
	movq	24(%r15), %rax
	movq	(%rax,%rbx,8), %r14
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %rax
	movq	-80(%rbp), %rcx
	movl	(%rax,%rcx,4), %edi
	movl	-72(%rbp), %ecx
	movq	_AVINDEX_KEYFRAME@GOTPCREL(%rip), %rax
	movl	(%rax), %r9d
	movl	%r13d, %esi
	movl	%r12d, %edx
	xorl	%r8d, %r8d
	callq	_av_add_index_entry
	movl	-52(%rbp), %eax                 ## 4-byte Reload
	cmpl	%eax, (%r14)
	je	LBB0_13
## %bb.10:                              ##   in Loop: Header=BB0_6 Depth=2
	movl	16(%r15), %eax
	movq	_AV_PKT_FLAG_KEY@GOTPCREL(%rip), %rdx
	jmp	LBB0_11
LBB0_13:
	movq	-96(%rbp), %rax                 ## 8-byte Reload
	movl	-44(%rbp), %ecx                 ## 4-byte Reload
	movl	%ecx, (%rax)
	leaq	-88(%rbp), %rdi
	callq	_av_packet_unref
LBB0_14:
	movl	%r12d, %eax
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	movl	%eax, %r12d
	jmp	LBB0_14
	.cfi_endproc
                                        ## -- End function
	.comm	_AV_NOPTS_VALUE,4,2             ## @AV_NOPTS_VALUE
	.comm	_SEEK_SET,4,2                   ## @SEEK_SET
	.comm	_AV_PKT_FLAG_KEY,4,2            ## @AV_PKT_FLAG_KEY
	.comm	_AVINDEX_KEYFRAME,4,2           ## @AVINDEX_KEYFRAME
	.no_dead_strip	_asf_read_timestamp
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function asf_read_timestamp
_asf_read_timestamp:                    ; @asf_read_timestamp
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x28, x27, [sp, #32]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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
	.cfi_offset w25, -72
	.cfi_offset w26, -80
	.cfi_offset w27, -88
	.cfi_offset w28, -96
	mov	x21, x1
	mov	x22, x0
	ldr	x25, [x0, #16]
	str	x2, [sp]                        ; 8-byte Folded Spill
	ldr	w8, [x2]
Lloh0:
	adrp	x9, _AV_NOPTS_VALUE@GOTPAGE
Lloh1:
	ldr	x9, [x9, _AV_NOPTS_VALUE@GOTPAGEOFF]
Lloh2:
	ldr	w20, [x9]
	ldp	w9, w10, [x25]
	ldp	w11, w12, [x25, #8]
	mvn	w13, w11
	add	w8, w8, w13
	add	w8, w8, w12
	sdiv	w0, w8, w12
	add	w26, w10, w9
	sub	w8, w26, w11
	sdiv	w8, w8, w12
	sub	w2, w8, #1
	mov	w1, #0
	bl	_av_clip
	ldp	w8, w9, [x25, #8]
	madd	w23, w9, w0, w8
	ldr	w0, [x22, #8]
Lloh3:
	adrp	x8, _SEEK_SET@GOTPAGE
Lloh4:
	ldr	x8, [x8, _SEEK_SET@GOTPAGEOFF]
Lloh5:
	ldr	w2, [x8]
	mov	x1, x23
	bl	_avio_seek
	mov	x0, x22
	bl	_reset_packet_state
	ldr	w0, [x22, #8]
	bl	_avio_tell
	cmp	w0, w26
	b.ge	LBB0_11
; %bb.1:
Lloh6:
	adrp	x27, _AV_PKT_FLAG_KEY@GOTPAGE
Lloh7:
	ldr	x27, [x27, _AV_PKT_FLAG_KEY@GOTPAGEOFF]
Lloh8:
	adrp	x28, _AVINDEX_KEYFRAME@GOTPAGE
Lloh9:
	ldr	x28, [x28, _AVINDEX_KEYFRAME@GOTPAGEOFF]
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	x0, sp, #8
	bl	_av_packet_unref
	ldr	w0, [x22, #8]
	bl	_avio_tell
	cmp	w0, w26
	b.ge	LBB0_11
LBB0_3:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_7 Depth 2
	add	x0, sp, #8
	bl	_av_init_packet
	ldr	w0, [x22, #8]
	bl	_avio_tell
	mov	x24, x0
	add	x1, sp, #8
	mov	x0, x22
	bl	_asf_read_packet
	tbnz	w0, #31, LBB0_13
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	ldp	w9, w8, [x25, #12]
	add	w9, w9, w23
	cmp	w24, w9
	csel	w23, w23, w9, lt
	cmp	w8, #1
	b.lt	LBB0_2
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	x24, #0
	b	LBB0_7
LBB0_6:                                 ;   in Loop: Header=BB0_7 Depth=2
	add	x24, x24, #1
	cmp	x24, w8, sxtw
	b.ge	LBB0_2
LBB0_7:                                 ;   Parent Loop BB0_3 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldr	w9, [sp, #8]
	ldr	w10, [x27]
	tst	w10, w9
	b.eq	LBB0_6
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=2
	ldr	w20, [sp, #12]
	cbz	w20, LBB0_6
; %bb.9:                                ;   in Loop: Header=BB0_7 Depth=2
	ldr	x8, [x25, #24]
	ldr	x19, [x8, x24, lsl #3]
	ldr	x8, [x22]
	ldr	x9, [sp, #16]
	ldr	w0, [x8, x9, lsl #2]
	ldr	w3, [sp, #24]
	ldr	w5, [x28]
	mov	x1, x23
	mov	x2, x20
	mov	w4, #0
	bl	_av_add_index_entry
	ldr	w8, [x19]
	cmp	w8, w21
	b.eq	LBB0_11
; %bb.10:                               ;   in Loop: Header=BB0_7 Depth=2
	ldr	w8, [x25, #16]
	b	LBB0_6
LBB0_11:
	ldr	x8, [sp]                        ; 8-byte Folded Reload
	str	w23, [x8]
	add	x0, sp, #8
	bl	_av_packet_unref
LBB0_12:
	mov	x0, x20
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
LBB0_13:
	mov	x20, x0
	b	LBB0_12
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.cfi_endproc
                                        ; -- End function
	.comm	_AV_NOPTS_VALUE,4,2             ; @AV_NOPTS_VALUE
	.comm	_SEEK_SET,4,2                   ; @SEEK_SET
	.comm	_AV_PKT_FLAG_KEY,4,2            ; @AV_PKT_FLAG_KEY
	.comm	_AVINDEX_KEYFRAME,4,2           ; @AVINDEX_KEYFRAME
	.no_dead_strip	_asf_read_timestamp
.subsections_via_symbols
