	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function apc_read_header
_apc_read_header:                       ## @apc_read_header
	.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	%rdi, %r15
	movq	(%rdi), %rbx
	movq	%rbx, %rdi
	callq	_avio_rl32
	movq	%rbx, %rdi
	callq	_avio_rl32
	movq	%rbx, %rdi
	callq	_avio_rl32
	movq	%r15, %rdi
	xorl	%esi, %esi
	callq	_avformat_new_stream
	testq	%rax, %rax
	je	LBB0_6
## %bb.1:
	movq	%rax, %r14
	movq	_AVMEDIA_TYPE_AUDIO@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	(%r14), %rcx
	movl	%eax, 28(%rcx)
	movq	_AV_CODEC_ID_ADPCM_IMA_APC@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 24(%rcx)
	movq	%rbx, %rdi
	callq	_avio_rl32
	movq	%rbx, %rdi
	callq	_avio_rl32
	movq	(%r14), %rsi
	movl	%eax, (%rsi)
	movq	%r15, %rdi
	movq	%rbx, %rdx
	movl	$8, %ecx
	callq	_ff_get_extradata
	testq	%rax, %rax
	js	LBB0_6
## %bb.2:
	movq	%rbx, %rdi
	callq	_avio_rl32
	xorl	%edx, %edx
	xorl	%esi, %esi
	movq	(%r14), %rcx
	testl	%eax, %eax
	setne	%al
	sete	%sil
	jne	LBB0_3
## %bb.4:
	movq	_AV_CH_LAYOUT_MONO@GOTPCREL(%rip), %rdi
	jmp	LBB0_5
LBB0_6:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_AVERROR                        ## TAILCALL
LBB0_3:
	movq	_AV_CH_LAYOUT_STEREO@GOTPCREL(%rip), %rdi
LBB0_5:
	movl	$2, %ebx
	subl	%esi, %ebx
	movb	%al, %dl
	leal	4(,%rdx,4), %eax
	movl	%ebx, 4(%rcx)
	movl	(%rdi), %edx
	movl	%edx, 20(%rcx)
	movl	$4, 8(%rcx)
	imull	(%rcx), %eax
	movl	%eax, 12(%rcx)
	movl	$1, 16(%rcx)
	xorl	%eax, %eax
	addq	$8, %rsp
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.comm	_AVMEDIA_TYPE_AUDIO,4,2         ## @AVMEDIA_TYPE_AUDIO
	.comm	_AV_CODEC_ID_ADPCM_IMA_APC,4,2  ## @AV_CODEC_ID_ADPCM_IMA_APC
	.comm	_AV_CH_LAYOUT_STEREO,4,2        ## @AV_CH_LAYOUT_STEREO
	.comm	_AV_CH_LAYOUT_MONO,4,2          ## @AV_CH_LAYOUT_MONO
	.no_dead_strip	_apc_read_header
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function apc_read_header
_apc_read_header:                       ; @apc_read_header
	.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
	mov	x20, x0
	ldr	x19, [x0]
	mov	x0, x19
	bl	_avio_rl32
	mov	x0, x19
	bl	_avio_rl32
	mov	x0, x19
	bl	_avio_rl32
	mov	x0, x20
	mov	x1, #0
	bl	_avformat_new_stream
	cbz	x0, LBB0_3
; %bb.1:
	mov	x21, x0
Lloh0:
	adrp	x8, _AVMEDIA_TYPE_AUDIO@GOTPAGE
Lloh1:
	ldr	x8, [x8, _AVMEDIA_TYPE_AUDIO@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	ldr	x9, [x0]
Lloh3:
	adrp	x10, _AV_CODEC_ID_ADPCM_IMA_APC@GOTPAGE
Lloh4:
	ldr	x10, [x10, _AV_CODEC_ID_ADPCM_IMA_APC@GOTPAGEOFF]
Lloh5:
	ldr	w10, [x10]
	stp	w10, w8, [x9, #24]
	mov	x0, x19
	bl	_avio_rl32
	mov	x0, x19
	bl	_avio_rl32
	ldr	x1, [x21]
	str	w0, [x1]
	mov	w22, #8
	mov	x0, x20
	mov	x2, x19
	mov	w3, #8
	bl	_ff_get_extradata
	tbnz	x0, #63, LBB0_3
; %bb.2:
	mov	x0, x19
	bl	_avio_rl32
	ldr	x8, [x21]
	mov	w9, #1
	mov	w10, #4
	cmp	w0, #0
	csel	w11, w10, w22, eq
	cinc	w12, w9, ne
Lloh6:
	adrp	x13, _AV_CH_LAYOUT_MONO@GOTPAGE
Lloh7:
	ldr	x13, [x13, _AV_CH_LAYOUT_MONO@GOTPAGEOFF]
	str	w12, [x8, #4]
Lloh8:
	adrp	x12, _AV_CH_LAYOUT_STEREO@GOTPAGE
Lloh9:
	ldr	x12, [x12, _AV_CH_LAYOUT_STEREO@GOTPAGEOFF]
	csel	x12, x13, x12, eq
	ldr	w12, [x12]
	ldr	w13, [x8]
	mul	w11, w11, w13
	stp	w10, w11, [x8, #8]
	stp	w9, w12, [x8, #16]
	mov	w0, #0
	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
LBB0_3:
Lloh10:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh11:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh12:
	ldr	w0, [x8]
	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
	b	_AVERROR
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.cfi_endproc
                                        ; -- End function
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.comm	_AVMEDIA_TYPE_AUDIO,4,2         ; @AVMEDIA_TYPE_AUDIO
	.comm	_AV_CODEC_ID_ADPCM_IMA_APC,4,2  ; @AV_CODEC_ID_ADPCM_IMA_APC
	.comm	_AV_CH_LAYOUT_STEREO,4,2        ; @AV_CH_LAYOUT_STEREO
	.comm	_AV_CH_LAYOUT_MONO,4,2          ; @AV_CH_LAYOUT_MONO
	.no_dead_strip	_apc_read_header
.subsections_via_symbols
