	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function s337m_read_packet
_s337m_read_packet:                     ## @s337m_read_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	%r13
	pushq	%r12
	pushq	%rbx
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r14
	movq	%rdi, %r15
	movq	8(%rdi), %r12
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_1:                                 ## =>This Inner Loop Header: Depth=1
	movl	%ebx, %edi
	callq	_IS_LE_MARKER
	testl	%eax, %eax
	jne	LBB0_4
## %bb.2:                               ##   in Loop: Header=BB0_1 Depth=1
	shll	$8, %ebx
	movq	%r12, %rdi
	callq	_avio_r8
	orl	%eax, %ebx
	movq	%r12, %rdi
	callq	_avio_feof
	testq	%rax, %rax
	je	LBB0_1
LBB0_3:
	movq	_AVERROR_EOF@GOTPCREL(%rip), %rax
	movl	(%rax), %r13d
	jmp	LBB0_21
LBB0_4:
	movq	%r14, -64(%rbp)                 ## 8-byte Spill
	movl	%ebx, %edi
	callq	_IS_16LE_MARKER
	movq	%r12, %rdi
	testq	%rax, %rax
	je	LBB0_6
## %bb.5:
	callq	_avio_rl16
	movl	%eax, %r13d
	movq	%r12, %rdi
	callq	_avio_rl16
	jmp	LBB0_7
LBB0_6:
	callq	_avio_rl24
	movl	%eax, %r13d
	movq	%r12, %rdi
	callq	_avio_rl24
LBB0_7:
	movl	%eax, %r14d
	movq	%r12, %rdi
	callq	_avio_tell
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	leaq	-52(%rbp), %r8
	leaq	-48(%rbp), %r9
	movq	%r15, %rdi
	movl	%ebx, %esi
	movl	%r13d, %edx
	movl	%r14d, %ecx
	callq	_s337m_get_offset_and_codec
	testl	%eax, %eax
	js	LBB0_20
## %bb.8:
	movl	-52(%rbp), %esi
	movq	-64(%rbp), %r14                 ## 8-byte Reload
	movq	%r14, %rdi
	callq	_av_new_packet
	testl	%eax, %eax
	js	LBB0_20
## %bb.9:
	movl	-44(%rbp), %eax                 ## 4-byte Reload
	movl	%eax, 16(%r14)
	movq	8(%r14), %rsi
	movl	(%r14), %edx
	movq	%r12, %rdi
	callq	_avio_read
	cmpl	(%r14), %eax
	jge	LBB0_13
## %bb.10:
	movq	%r14, %rdi
	callq	_av_packet_unref
	jmp	LBB0_3
LBB0_13:
	movl	%ebx, %edi
	callq	_IS_16LE_MARKER
	movq	8(%r14), %rdi
	testq	%rax, %rax
	je	LBB0_15
## %bb.14:
	movl	(%r14), %edx
	sarl	%edx
	movq	%rdi, %rsi
	callq	_ff_spdif_bswap_buf16
	jmp	LBB0_16
LBB0_15:
	movl	(%r14), %esi
	callq	_bswap_buf24
LBB0_16:
	xorl	%r13d, %r13d
	cmpl	$0, (%r15)
	jne	LBB0_21
## %bb.17:
	xorl	%r13d, %r13d
	movq	%r15, %rdi
	xorl	%esi, %esi
	callq	_avformat_new_stream
	testq	%rax, %rax
	je	LBB0_19
## %bb.18:
	movq	_AVMEDIA_TYPE_AUDIO@GOTPCREL(%rip), %rcx
	movl	(%rcx), %ecx
	movq	(%rax), %rax
	movl	%ecx, 4(%rax)
	movl	-48(%rbp), %ecx
	movl	%ecx, (%rax)
	jmp	LBB0_21
LBB0_19:
	movq	%r14, %rdi
	callq	_av_packet_unref
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_AVERROR
LBB0_20:
	movl	%eax, %r13d
LBB0_21:
	movl	%r13d, %eax
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_AVERROR_EOF,4,2                ## @AVERROR_EOF
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_AVMEDIA_TYPE_AUDIO,4,2         ## @AVMEDIA_TYPE_AUDIO
	.no_dead_strip	_s337m_read_packet
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function s337m_read_packet
_s337m_read_packet:                     ; @s337m_read_packet
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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
	mov	x19, x1
	mov	x20, x0
	mov	w21, #0
	ldr	x22, [x0, #8]
LBB0_1:                                 ; =>This Inner Loop Header: Depth=1
	mov	x0, x21
	bl	_IS_LE_MARKER
	cbnz	w0, LBB0_4
; %bb.2:                                ;   in Loop: Header=BB0_1 Depth=1
	mov	x0, x22
	bl	_avio_r8
	orr	w21, w0, w21, lsl #8
	mov	x0, x22
	bl	_avio_feof
	cbz	x0, LBB0_1
LBB0_3:
Lloh0:
	adrp	x8, _AVERROR_EOF@GOTPAGE
Lloh1:
	ldr	x8, [x8, _AVERROR_EOF@GOTPAGEOFF]
Lloh2:
	ldr	w0, [x8]
	b	LBB0_18
LBB0_4:
	mov	x0, x21
	bl	_IS_16LE_MARKER
	cbz	x0, LBB0_6
; %bb.5:
	mov	x0, x22
	bl	_avio_rl16
	mov	x23, x0
	mov	x0, x22
	bl	_avio_rl16
	b	LBB0_7
LBB0_6:
	mov	x0, x22
	bl	_avio_rl24
	mov	x23, x0
	mov	x0, x22
	bl	_avio_rl24
LBB0_7:
	mov	x24, x0
	mov	x0, x22
	bl	_avio_tell
	mov	x25, x0
	add	x4, sp, #12
	add	x5, sp, #8
	mov	x0, x20
	mov	x1, x21
	mov	x2, x23
	mov	x3, x24
	bl	_s337m_get_offset_and_codec
	tbnz	w0, #31, LBB0_18
; %bb.8:
	ldr	w1, [sp, #12]
	mov	x0, x19
	bl	_av_new_packet
	tbnz	w0, #31, LBB0_18
; %bb.9:
	str	w25, [x19, #16]
	ldr	x1, [x19, #8]
	ldr	w2, [x19]
	mov	x0, x22
	bl	_avio_read
	ldr	w8, [x19]
	cmp	w0, w8
	b.ge	LBB0_11
; %bb.10:
	mov	x0, x19
	bl	_av_packet_unref
	b	LBB0_3
LBB0_11:
	mov	x0, x21
	bl	_IS_16LE_MARKER
	mov	x8, x0
	ldr	x0, [x19, #8]
	cbz	x8, LBB0_14
; %bb.12:
	ldr	w8, [x19]
	asr	w2, w8, #1
	mov	x1, x0
	bl	_ff_spdif_bswap_buf16
	ldr	w8, [x20]
	cbz	w8, LBB0_15
LBB0_13:
	mov	w0, #0
	b	LBB0_18
LBB0_14:
	ldr	w1, [x19]
	bl	_bswap_buf24
	ldr	w8, [x20]
	cbnz	w8, LBB0_13
LBB0_15:
	mov	x0, x20
	mov	x1, #0
	bl	_avformat_new_stream
	cbz	x0, LBB0_17
; %bb.16:
	mov	x8, x0
	mov	w0, #0
Lloh3:
	adrp	x9, _AVMEDIA_TYPE_AUDIO@GOTPAGE
Lloh4:
	ldr	x9, [x9, _AVMEDIA_TYPE_AUDIO@GOTPAGEOFF]
Lloh5:
	ldr	w9, [x9]
	ldr	x8, [x8]
	ldr	w10, [sp, #8]
	stp	w10, w9, [x8]
	b	LBB0_18
LBB0_17:
	mov	x0, x19
	bl	_av_packet_unref
Lloh6:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh7:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh8:
	ldr	w0, [x8]
	bl	_AVERROR
LBB0_18:
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_AVERROR_EOF,4,2                ; @AVERROR_EOF
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_AVMEDIA_TYPE_AUDIO,4,2         ; @AVMEDIA_TYPE_AUDIO
	.no_dead_strip	_s337m_read_packet
.subsections_via_symbols
