	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function spdif_get_offset_and_codec
_spdif_get_offset_and_codec:            ## @spdif_get_offset_and_codec
	.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	%r12
	pushq	%rbx
	subq	$16, %rsp
	.cfi_offset %rbx, -48
	.cfi_offset %r12, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rcx, %r15
	movl	%esi, %eax
	movq	%rdi, %r12
	leal	-128(%rax), %ecx
	cmpb	$10, %cl
	ja	LBB0_21
## %bb.1:
	movq	%r8, %r14
	movzbl	%cl, %eax
	leaq	LJTI0_0(%rip), %rcx
	movslq	(%rcx,%rax,4), %rax
	addq	%rcx, %rax
	jmpq	*%rax
LBB0_16:
	movq	_spdif_mpeg_pkt_offset@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	(%rax), %rax
	movl	8(%rax), %eax
	jmp	LBB0_6
LBB0_21:
	testq	%r12, %r12
	je	LBB0_23
## %bb.22:
	leaq	L_.str.1(%rip), %rsi
	movq	%r12, %rdi
	movl	%eax, %edx
	callq	_avpriv_request_sample
LBB0_23:
	movq	_AVERROR_PATCHWELCOME@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	jmp	LBB0_24
LBB0_15:
	movq	_spdif_mpeg_pkt_offset@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	(%rax), %rax
	movl	4(%rax), %eax
	movl	%eax, (%r15)
	movq	_AV_CODEC_ID_MP2@GOTPCREL(%rip), %rax
	jmp	LBB0_8
LBB0_14:
	movq	_spdif_mpeg_pkt_offset@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	(%rax), %rax
	jmp	LBB0_4
LBB0_9:
	movl	$4608, (%r15)                   ## imm = 0x1200
	jmp	LBB0_7
LBB0_10:
	leaq	-36(%rbp), %rsi
	leaq	-40(%rbp), %rax
	movq	%rdx, %rdi
	movq	%rax, %rdx
	callq	_av_adts_header_parse
	testl	%eax, %eax
	js	LBB0_11
## %bb.13:
	movl	-36(%rbp), %eax
	shll	$2, %eax
	movl	%eax, (%r15)
	movq	_AV_CODEC_ID_AAC@GOTPCREL(%rip), %rax
	jmp	LBB0_8
LBB0_5:
	movq	_spdif_mpeg_pkt_offset@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	8(%rax), %rax
	movl	(%rax), %eax
LBB0_6:
	movl	%eax, (%r15)
LBB0_7:
	movq	_AV_CODEC_ID_MP3@GOTPCREL(%rip), %rax
	jmp	LBB0_8
LBB0_3:
	movq	_spdif_mpeg_pkt_offset@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	8(%rax), %rax
LBB0_4:
	movl	(%rax), %eax
	movl	%eax, (%r15)
	movq	_AV_CODEC_ID_MP1@GOTPCREL(%rip), %rax
	jmp	LBB0_8
LBB0_20:
	movl	$8192, (%r15)                   ## imm = 0x2000
	movq	_AV_CODEC_ID_DTS@GOTPCREL(%rip), %rax
	jmp	LBB0_8
LBB0_19:
	movl	$4096, (%r15)                   ## imm = 0x1000
	movq	_AV_CODEC_ID_DTS@GOTPCREL(%rip), %rax
	jmp	LBB0_8
LBB0_17:
	movl	$2048, (%r15)                   ## imm = 0x800
	movq	_AV_CODEC_ID_DTS@GOTPCREL(%rip), %rax
	jmp	LBB0_8
LBB0_2:
	movq	_AC3_FRAME_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	shll	$2, %eax
	movl	%eax, (%r15)
	movq	_AV_CODEC_ID_AC3@GOTPCREL(%rip), %rax
LBB0_8:
	movl	(%rax), %eax
	movl	%eax, (%r14)
	xorl	%ebx, %ebx
LBB0_24:
	movl	%ebx, %eax
	addq	$16, %rsp
	popq	%rbx
	popq	%r12
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_11:
	movl	%eax, %ebx
	testq	%r12, %r12
	je	LBB0_24
## %bb.12:
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	movq	%r12, %rdi
	callq	_av_log
	jmp	LBB0_24
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_16, LBB0_16-LJTI0_0
.set L0_0_set_15, LBB0_15-LJTI0_0
.set L0_0_set_14, LBB0_14-LJTI0_0
.set L0_0_set_9, LBB0_9-LJTI0_0
.set L0_0_set_10, LBB0_10-LJTI0_0
.set L0_0_set_5, LBB0_5-LJTI0_0
.set L0_0_set_3, LBB0_3-LJTI0_0
.set L0_0_set_20, LBB0_20-LJTI0_0
.set L0_0_set_19, LBB0_19-LJTI0_0
.set L0_0_set_17, LBB0_17-LJTI0_0
.set L0_0_set_2, LBB0_2-LJTI0_0
LJTI0_0:
	.long	L0_0_set_16
	.long	L0_0_set_15
	.long	L0_0_set_14
	.long	L0_0_set_9
	.long	L0_0_set_10
	.long	L0_0_set_5
	.long	L0_0_set_3
	.long	L0_0_set_20
	.long	L0_0_set_19
	.long	L0_0_set_17
	.long	L0_0_set_2
	.end_data_region
                                        ## -- End function
	.comm	_AC3_FRAME_SIZE,4,2             ## @AC3_FRAME_SIZE
	.comm	_AV_CODEC_ID_AC3,4,2            ## @AV_CODEC_ID_AC3
	.comm	_spdif_mpeg_pkt_offset,8,3      ## @spdif_mpeg_pkt_offset
	.comm	_AV_CODEC_ID_MP1,4,2            ## @AV_CODEC_ID_MP1
	.comm	_AV_CODEC_ID_MP3,4,2            ## @AV_CODEC_ID_MP3
	.comm	_AV_LOG_ERROR,4,2               ## @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Invalid AAC packet in IEC 61937\n"

	.comm	_AV_CODEC_ID_AAC,4,2            ## @AV_CODEC_ID_AAC
	.comm	_AV_CODEC_ID_MP2,4,2            ## @AV_CODEC_ID_MP2
	.comm	_AV_CODEC_ID_DTS,4,2            ## @AV_CODEC_ID_DTS
L_.str.1:                               ## @.str.1
	.asciz	"Data type 0x%04x in IEC 61937"

	.comm	_AVERROR_PATCHWELCOME,4,2       ## @AVERROR_PATCHWELCOME
	.no_dead_strip	_spdif_get_offset_and_codec
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function spdif_get_offset_and_codec
_spdif_get_offset_and_codec:            ; @spdif_get_offset_and_codec
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #64
	.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
	mov	x22, x0
	and	w9, w1, #0xff
	sub	w9, w9, #128
	cmp	w9, #10
	b.hi	LBB0_3
; %bb.1:
	mov	x20, x4
	mov	x21, x3
Lloh0:
	adrp	x10, lJTI0_0@PAGE
Lloh1:
	add	x10, x10, lJTI0_0@PAGEOFF
	adr	x11, LBB0_2
	ldrb	w12, [x10, x9]
	add	x11, x11, x12, lsl #2
	br	x11
LBB0_2:
	mov	w19, #0
Lloh2:
	adrp	x8, _spdif_mpeg_pkt_offset@GOTPAGE
Lloh3:
	ldr	x8, [x8, _spdif_mpeg_pkt_offset@GOTPAGEOFF]
Lloh4:
	ldr	x8, [x8]
	ldr	x8, [x8]
	ldr	w8, [x8, #8]
	b	LBB0_12
LBB0_3:
	cbz	x22, LBB0_5
; %bb.4:
	mov	x2, x1
Lloh5:
	adrp	x1, l_.str.1@PAGE
Lloh6:
	add	x1, x1, l_.str.1@PAGEOFF
	mov	x0, x22
	bl	_avpriv_request_sample
LBB0_5:
Lloh7:
	adrp	x8, _AVERROR_PATCHWELCOME@GOTPAGE
Lloh8:
	ldr	x8, [x8, _AVERROR_PATCHWELCOME@GOTPAGEOFF]
Lloh9:
	ldr	w19, [x8]
	b	LBB0_21
LBB0_6:
	mov	w19, #0
Lloh10:
	adrp	x8, _spdif_mpeg_pkt_offset@GOTPAGE
Lloh11:
	ldr	x8, [x8, _spdif_mpeg_pkt_offset@GOTPAGEOFF]
Lloh12:
	ldr	x8, [x8]
	ldr	x8, [x8]
	ldr	w8, [x8, #4]
	str	w8, [x21]
Lloh13:
	adrp	x8, _AV_CODEC_ID_MP2@GOTPAGE
Lloh14:
	ldr	x8, [x8, _AV_CODEC_ID_MP2@GOTPAGEOFF]
	b	LBB0_20
LBB0_7:
	mov	w19, #0
Lloh15:
	adrp	x8, _spdif_mpeg_pkt_offset@GOTPAGE
Lloh16:
	ldr	x8, [x8, _spdif_mpeg_pkt_offset@GOTPAGEOFF]
Lloh17:
	ldr	x8, [x8]
	ldr	x8, [x8]
	b	LBB0_14
LBB0_8:
	mov	w19, #0
	mov	w8, #4608
	b	LBB0_12
LBB0_9:
	mov	x8, x2
	add	x1, sp, #12
	add	x2, sp, #8
	mov	x0, x8
	bl	_av_adts_header_parse
	tbnz	w0, #31, LBB0_22
; %bb.10:
	mov	w19, #0
	ldr	w8, [sp, #12]
	lsl	w8, w8, #2
	str	w8, [x21]
Lloh18:
	adrp	x8, _AV_CODEC_ID_AAC@GOTPAGE
Lloh19:
	ldr	x8, [x8, _AV_CODEC_ID_AAC@GOTPAGEOFF]
	b	LBB0_20
LBB0_11:
	mov	w19, #0
Lloh20:
	adrp	x8, _spdif_mpeg_pkt_offset@GOTPAGE
Lloh21:
	ldr	x8, [x8, _spdif_mpeg_pkt_offset@GOTPAGEOFF]
Lloh22:
	ldr	x8, [x8]
	ldr	x8, [x8, #8]
	ldr	w8, [x8]
LBB0_12:
	str	w8, [x21]
Lloh23:
	adrp	x8, _AV_CODEC_ID_MP3@GOTPAGE
Lloh24:
	ldr	x8, [x8, _AV_CODEC_ID_MP3@GOTPAGEOFF]
	b	LBB0_20
LBB0_13:
	mov	w19, #0
Lloh25:
	adrp	x8, _spdif_mpeg_pkt_offset@GOTPAGE
Lloh26:
	ldr	x8, [x8, _spdif_mpeg_pkt_offset@GOTPAGEOFF]
Lloh27:
	ldr	x8, [x8]
	ldr	x8, [x8, #8]
LBB0_14:
	ldr	w8, [x8]
	str	w8, [x21]
Lloh28:
	adrp	x8, _AV_CODEC_ID_MP1@GOTPAGE
Lloh29:
	ldr	x8, [x8, _AV_CODEC_ID_MP1@GOTPAGEOFF]
	b	LBB0_20
LBB0_15:
	mov	w19, #0
	mov	w8, #8192
	b	LBB0_18
LBB0_16:
	mov	w19, #0
	mov	w8, #4096
	b	LBB0_18
LBB0_17:
	mov	w19, #0
	mov	w8, #2048
LBB0_18:
	str	w8, [x21]
Lloh30:
	adrp	x8, _AV_CODEC_ID_DTS@GOTPAGE
Lloh31:
	ldr	x8, [x8, _AV_CODEC_ID_DTS@GOTPAGEOFF]
	b	LBB0_20
LBB0_19:
	mov	w19, #0
Lloh32:
	adrp	x8, _AC3_FRAME_SIZE@GOTPAGE
Lloh33:
	ldr	x8, [x8, _AC3_FRAME_SIZE@GOTPAGEOFF]
Lloh34:
	ldr	w8, [x8]
	lsl	w8, w8, #2
	str	w8, [x21]
Lloh35:
	adrp	x8, _AV_CODEC_ID_AC3@GOTPAGE
Lloh36:
	ldr	x8, [x8, _AV_CODEC_ID_AC3@GOTPAGEOFF]
LBB0_20:
	ldr	w8, [x8]
	str	w8, [x20]
LBB0_21:
	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
	add	sp, sp, #64
	ret
LBB0_22:
	mov	x19, x0
	cbz	x22, LBB0_21
; %bb.23:
Lloh37:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh38:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh39:
	ldr	w1, [x8]
Lloh40:
	adrp	x2, l_.str@PAGE
Lloh41:
	add	x2, x2, l_.str@PAGEOFF
	mov	x0, x22
	bl	_av_log
	b	LBB0_21
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh2, Lloh3, Lloh4
	.loh AdrpAdd	Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh13, Lloh14
	.loh AdrpLdrGotLdr	Lloh10, Lloh11, Lloh12
	.loh AdrpLdrGotLdr	Lloh15, Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh18, Lloh19
	.loh AdrpLdrGotLdr	Lloh20, Lloh21, Lloh22
	.loh AdrpLdrGot	Lloh23, Lloh24
	.loh AdrpLdrGotLdr	Lloh25, Lloh26, Lloh27
	.loh AdrpLdrGot	Lloh28, Lloh29
	.loh AdrpLdrGot	Lloh30, Lloh31
	.loh AdrpLdrGot	Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh32, Lloh33, Lloh34
	.loh AdrpAdd	Lloh40, Lloh41
	.loh AdrpLdrGotLdr	Lloh37, Lloh38, Lloh39
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_2-LBB0_2)>>2
	.byte	(LBB0_6-LBB0_2)>>2
	.byte	(LBB0_7-LBB0_2)>>2
	.byte	(LBB0_8-LBB0_2)>>2
	.byte	(LBB0_9-LBB0_2)>>2
	.byte	(LBB0_11-LBB0_2)>>2
	.byte	(LBB0_13-LBB0_2)>>2
	.byte	(LBB0_15-LBB0_2)>>2
	.byte	(LBB0_16-LBB0_2)>>2
	.byte	(LBB0_17-LBB0_2)>>2
	.byte	(LBB0_19-LBB0_2)>>2
                                        ; -- End function
	.comm	_AC3_FRAME_SIZE,4,2             ; @AC3_FRAME_SIZE
	.comm	_AV_CODEC_ID_AC3,4,2            ; @AV_CODEC_ID_AC3
	.comm	_spdif_mpeg_pkt_offset,8,3      ; @spdif_mpeg_pkt_offset
	.comm	_AV_CODEC_ID_MP1,4,2            ; @AV_CODEC_ID_MP1
	.comm	_AV_CODEC_ID_MP3,4,2            ; @AV_CODEC_ID_MP3
	.comm	_AV_LOG_ERROR,4,2               ; @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Invalid AAC packet in IEC 61937\n"

	.comm	_AV_CODEC_ID_AAC,4,2            ; @AV_CODEC_ID_AAC
	.comm	_AV_CODEC_ID_MP2,4,2            ; @AV_CODEC_ID_MP2
	.comm	_AV_CODEC_ID_DTS,4,2            ; @AV_CODEC_ID_DTS
l_.str.1:                               ; @.str.1
	.asciz	"Data type 0x%04x in IEC 61937"

	.comm	_AVERROR_PATCHWELCOME,4,2       ; @AVERROR_PATCHWELCOME
	.no_dead_strip	_spdif_get_offset_and_codec
.subsections_via_symbols
