	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pcm_dvd_decode_frame
_pcm_dvd_decode_frame:                  ## @pcm_dvd_decode_frame
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, %r13
	movl	(%rcx), %r12d
	cmpl	$2, %r12d
	jg	LBB0_2
## %bb.1:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	movq	%r13, %rdi
	xorl	%eax, %eax
	callq	_av_log
	movq	_AVERROR_INVALIDDATA@GOTPCREL(%rip), %rax
LBB0_19:
	movl	(%rax), %eax
	jmp	LBB0_20
LBB0_2:
	movq	%rsi, -56(%rbp)                 ## 8-byte Spill
	movq	%rdx, -72(%rbp)                 ## 8-byte Spill
	movq	8(%rcx), %r15
	movq	(%r13), %rbx
	movq	%r13, %rdi
	movq	%r15, %rsi
	movq	%rcx, %r14
	callq	_pcm_dvd_parse_header
	testl	%eax, %eax
	je	LBB0_3
LBB0_20:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_3:
	movq	%r14, -64(%rbp)                 ## 8-byte Spill
	movl	(%rbx), %ecx
	testl	%ecx, %ecx
	je	LBB0_6
## %bb.4:
	movl	4(%rbx), %r8d
	cmpl	%r8d, %ecx
	je	LBB0_6
## %bb.5:
	movq	_AV_LOG_WARNING@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.1(%rip), %rdx
	movq	%r13, %rdi
	xorl	%eax, %eax
	callq	_av_log
	movl	$0, 8(%rbx)
LBB0_6:
	movl	4(%rbx), %ecx
	movl	%ecx, (%rbx)
	addl	$-3, %r12d
	movl	8(%rbx), %eax
	addl	%r12d, %eax
	cltd
	idivl	%ecx
	movl	12(%rbx), %ecx
	movl	%eax, -44(%rbp)                 ## 4-byte Spill
	imull	%eax, %ecx
	movq	-56(%rbp), %r14                 ## 8-byte Reload
	movl	%ecx, (%r14)
	movq	%r13, %rdi
	movq	%r14, %rsi
	xorl	%edx, %edx
	callq	_ff_get_buffer
	testl	%eax, %eax
	js	LBB0_20
## %bb.7:
	addq	$12, %r15
	movq	8(%r14), %rax
	movq	(%rax), %rdx
	movslq	8(%rbx), %rdi
	testq	%rdi, %rdi
	movq	%rbx, %r8
	je	LBB0_8
## %bb.9:
	movslq	4(%r8), %r14
	subq	%rdi, %r14
	shlq	$2, %rdi
	addq	16(%r8), %rdi
	movl	%r12d, %eax
	subl	%r14d, %eax
	jge	LBB0_11
## %bb.10:
	movq	%r15, %rsi
	movl	%r12d, %edx
	movq	%r8, %rbx
	callq	_memcpy
	addl	%r12d, 8(%rbx)
	jmp	LBB0_18
LBB0_8:
	movl	-44(%rbp), %ebx                 ## 4-byte Reload
	testl	%ebx, %ebx
	jne	LBB0_14
LBB0_13:
	movq	%r15, %r14
	jmp	LBB0_15
LBB0_11:
	movq	%r15, %rsi
	movq	%rdx, %r12
	movl	%r14d, %edx
	movq	%r8, %rbx
	movl	%eax, -56(%rbp)                 ## 4-byte Spill
	callq	_memcpy
	movq	16(%rbx), %rsi
	movq	%r13, %rdi
	movq	%r12, %rdx
	movl	$1, %ecx
	callq	_pcm_dvd_decode_samples
	movq	%rbx, %r8
	movq	%rax, %rdx
	leaq	(%r15,%r14,4), %r15
	movl	$0, 8(%rbx)
	movl	-44(%rbp), %ebx                 ## 4-byte Reload
	decl	%ebx
	movl	-56(%rbp), %r12d                ## 4-byte Reload
	testl	%ebx, %ebx
	je	LBB0_13
LBB0_14:
	movq	%r13, %rdi
	movq	%r15, %r14
	movq	%r15, %rsi
	movl	%ebx, %ecx
	movq	%r8, %r15
	callq	_pcm_dvd_decode_samples
	movq	%r15, %r8
	movl	4(%r15), %eax
	imull	%ebx, %eax
	subl	%eax, %r12d
LBB0_15:
	testl	%r12d, %r12d
	je	LBB0_17
## %bb.16:
	movslq	4(%r8), %rax
	movslq	%ebx, %rcx
	imulq	%rax, %rcx
	leaq	(%r14,%rcx,4), %rsi
	movq	16(%r8), %rdi
	movl	%r12d, %edx
	movq	%r8, %rbx
	callq	_memcpy
	movl	%r12d, 8(%rbx)
LBB0_17:
	movq	-72(%rbp), %rax                 ## 8-byte Reload
	movl	$1, (%rax)
LBB0_18:
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	jmp	LBB0_19
	.cfi_endproc
                                        ## -- End function
	.comm	_AV_LOG_ERROR,4,2               ## @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"PCM packet too small\n"

	.comm	_AVERROR_INVALIDDATA,4,2        ## @AVERROR_INVALIDDATA
	.comm	_AV_LOG_WARNING,4,2             ## @AV_LOG_WARNING
L_.str.1:                               ## @.str.1
	.asciz	"block_size has changed %d != %d\n"

	.no_dead_strip	_pcm_dvd_decode_frame
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pcm_dvd_decode_frame
_pcm_dvd_decode_frame:                  ; @pcm_dvd_decode_frame
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	x28, x27, [sp, #16]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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, x0
	ldr	w22, [x3]
	cmp	w22, #2
	b.gt	LBB0_2
; %bb.1:
Lloh0:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh1:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh2:
	ldr	w1, [x8]
Lloh3:
	adrp	x2, l_.str@PAGE
Lloh4:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x21
	bl	_av_log
Lloh5:
	adrp	x8, _AVERROR_INVALIDDATA@GOTPAGE
Lloh6:
	ldr	x8, [x8, _AVERROR_INVALIDDATA@GOTPAGEOFF]
Lloh7:
	ldr	w0, [x8]
	b	LBB0_17
LBB0_2:
	mov	x19, x3
	mov	x20, x2
	mov	x25, x1
	ldr	x24, [x3, #8]
	ldr	x27, [x21]
	mov	x0, x21
	mov	x1, x24
	bl	_pcm_dvd_parse_header
	cbnz	w0, LBB0_17
; %bb.3:
	ldr	w8, [x27]
	cbz	w8, LBB0_6
; %bb.4:
	ldr	w9, [x27, #4]
	cmp	w8, w9
	b.eq	LBB0_6
; %bb.5:
Lloh8:
	adrp	x10, _AV_LOG_WARNING@GOTPAGE
Lloh9:
	ldr	x10, [x10, _AV_LOG_WARNING@GOTPAGEOFF]
Lloh10:
	ldr	w1, [x10]
	stp	x8, x9, [sp]
Lloh11:
	adrp	x2, l_.str.1@PAGE
Lloh12:
	add	x2, x2, l_.str.1@PAGEOFF
	mov	x0, x21
	bl	_av_log
	str	wzr, [x27, #8]
LBB0_6:
	ldp	w8, w9, [x27, #4]
	str	w8, [x27]
	sub	w23, w22, #3
	add	w9, w9, w23
	sdiv	w22, w9, w8
	ldr	w8, [x27, #12]
	mul	w8, w8, w22
	str	w8, [x25]
	mov	x0, x21
	mov	x1, x25
	mov	w2, #0
	bl	_ff_get_buffer
	tbnz	w0, #31, LBB0_17
; %bb.7:
	add	x24, x24, #12
	ldr	x8, [x25, #8]
	ldr	x25, [x8]
	ldrsw	x8, [x27, #8]
	cbz	w8, LBB0_11
; %bb.8:
	ldr	w9, [x27, #4]
	ldr	x10, [x27, #16]
	add	x0, x10, x8, lsl #2
	sub	w26, w9, w8
	subs	w28, w23, w26
	b.ge	LBB0_10
; %bb.9:
	mov	x1, x24
	mov	x2, x23
	bl	_memcpy
	ldr	w8, [x27, #8]
	add	w8, w8, w23
	str	w8, [x27, #8]
	b	LBB0_16
LBB0_10:
	mov	x1, x24
	mov	x2, x26
	bl	_memcpy
	ldr	x1, [x27, #16]
	mov	x0, x21
	mov	x2, x25
	mov	w3, #1
	bl	_pcm_dvd_decode_samples
	mov	x25, x0
	str	wzr, [x27, #8]
	sub	w22, w22, #1
	mov	x23, x28
	add	x24, x24, w26, sxtw #2
LBB0_11:
	cbz	w22, LBB0_13
; %bb.12:
	mov	x0, x21
	mov	x1, x24
	mov	x2, x25
	mov	x3, x22
	bl	_pcm_dvd_decode_samples
	ldr	w8, [x27, #4]
	msub	w23, w8, w22, w23
LBB0_13:
	cbz	w23, LBB0_15
; %bb.14:
	ldr	w8, [x27, #4]
	mul	w8, w8, w22
	add	x1, x24, w8, sxtw #2
	ldr	x0, [x27, #16]
	mov	x2, x23
	bl	_memcpy
	str	w23, [x27, #8]
LBB0_15:
	mov	w8, #1
	str	w8, [x20]
LBB0_16:
	ldr	w0, [x19]
LBB0_17:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGotLdr	Lloh5, Lloh6, Lloh7
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.cfi_endproc
                                        ; -- End function
	.comm	_AV_LOG_ERROR,4,2               ; @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"PCM packet too small\n"

	.comm	_AVERROR_INVALIDDATA,4,2        ; @AVERROR_INVALIDDATA
	.comm	_AV_LOG_WARNING,4,2             ; @AV_LOG_WARNING
l_.str.1:                               ; @.str.1
	.asciz	"block_size has changed %d != %d\n"

	.no_dead_strip	_pcm_dvd_decode_frame
.subsections_via_symbols
