	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function spdif_write_header
_spdif_write_header:                    ## @spdif_write_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	%rbx
	pushq	%rax
	.cfi_offset %rbx, -24
	movq	(%rdi), %rax
	movq	(%rax), %rax
	movq	(%rax), %rax
	movl	(%rax), %edx
	leal	-128(%rdx), %eax
	cmpl	$8, %eax
	ja	LBB0_10
## %bb.1:
	movq	8(%rdi), %rbx
	leaq	LJTI0_0(%rip), %rcx
	movslq	(%rcx,%rax,4), %rax
	addq	%rcx, %rax
	jmpq	*%rax
LBB0_5:
	movq	_spdif_header_mpeg@GOTPCREL(%rip), %rax
	jmp	LBB0_3
LBB0_8:
	movq	_spdif_header_truehd@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movl	%eax, 4(%rbx)
	movq	_MAT_FRAME_SIZE@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_av_malloc
	movl	%eax, %ecx
	movl	%eax, (%rbx)
	xorl	%eax, %eax
	testl	%ecx, %ecx
	jne	LBB0_11
## %bb.9:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	jmp	_AVERROR                        ## TAILCALL
LBB0_10:
	leaq	L_.str(%rip), %rsi
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_avpriv_report_missing_feature
	movq	_AVERROR_PATCHWELCOME@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	jmp	LBB0_11
LBB0_4:
	movq	_spdif_header_eac3@GOTPCREL(%rip), %rax
	jmp	LBB0_3
LBB0_6:
	movq	_spdif_header_dts@GOTPCREL(%rip), %rax
	jmp	LBB0_3
LBB0_2:
	movq	_spdif_header_ac3@GOTPCREL(%rip), %rax
	jmp	LBB0_3
LBB0_7:
	movq	_spdif_header_aac@GOTPCREL(%rip), %rax
LBB0_3:
	movl	(%rax), %eax
	movl	%eax, 4(%rbx)
	xorl	%eax, %eax
LBB0_11:
	addq	$8, %rsp
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
	.p2align	2, 0x90
	.data_region jt32
.set L0_0_set_8, LBB0_8-LJTI0_0
.set L0_0_set_5, LBB0_5-LJTI0_0
.set L0_0_set_4, LBB0_4-LJTI0_0
.set L0_0_set_6, LBB0_6-LJTI0_0
.set L0_0_set_2, LBB0_2-LJTI0_0
.set L0_0_set_7, LBB0_7-LJTI0_0
LJTI0_0:
	.long	L0_0_set_8
	.long	L0_0_set_5
	.long	L0_0_set_5
	.long	L0_0_set_5
	.long	L0_0_set_8
	.long	L0_0_set_4
	.long	L0_0_set_6
	.long	L0_0_set_2
	.long	L0_0_set_7
	.end_data_region
                                        ## -- End function
	.comm	_spdif_header_ac3,4,2           ## @spdif_header_ac3
	.comm	_spdif_header_eac3,4,2          ## @spdif_header_eac3
	.comm	_spdif_header_mpeg,4,2          ## @spdif_header_mpeg
	.comm	_spdif_header_dts,4,2           ## @spdif_header_dts
	.comm	_spdif_header_aac,4,2           ## @spdif_header_aac
	.comm	_spdif_header_truehd,4,2        ## @spdif_header_truehd
	.comm	_MAT_FRAME_SIZE,4,2             ## @MAT_FRAME_SIZE
	.comm	_ENOMEM,4,2                     ## @ENOMEM
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Codec %d"

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

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function spdif_write_header
_spdif_write_header:                    ; @spdif_write_header
	.cfi_startproc
; %bb.0:
	stp	x20, x19, [sp, #-32]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 32
	stp	x29, x30, [sp, #16]             ; 16-byte Folded Spill
	add	x29, sp, #16
	.cfi_def_cfa w29, 16
	.cfi_offset w30, -8
	.cfi_offset w29, -16
	.cfi_offset w19, -24
	.cfi_offset w20, -32
	ldr	x8, [x0]
	ldr	x8, [x8]
	ldr	x8, [x8]
	ldr	w2, [x8]
	sub	w8, w2, #128
	cmp	w8, #8
	b.hi	LBB0_5
; %bb.1:
	ldr	x19, [x0, #8]
Lloh0:
	adrp	x9, lJTI0_0@PAGE
Lloh1:
	add	x9, x9, lJTI0_0@PAGEOFF
	adr	x10, LBB0_2
	ldrb	w11, [x9, x8]
	add	x10, x10, x11, lsl #2
	br	x10
LBB0_2:
	mov	w0, #0
Lloh2:
	adrp	x8, _spdif_header_mpeg@GOTPAGE
Lloh3:
	ldr	x8, [x8, _spdif_header_mpeg@GOTPAGEOFF]
	b	LBB0_10
LBB0_3:
Lloh4:
	adrp	x8, _spdif_header_truehd@GOTPAGE
Lloh5:
	ldr	x8, [x8, _spdif_header_truehd@GOTPAGEOFF]
Lloh6:
	ldr	w8, [x8]
	str	w8, [x19, #4]
Lloh7:
	adrp	x8, _MAT_FRAME_SIZE@GOTPAGE
Lloh8:
	ldr	x8, [x8, _MAT_FRAME_SIZE@GOTPAGEOFF]
Lloh9:
	ldr	w0, [x8]
	bl	_av_malloc
	str	w0, [x19]
	cbz	w0, LBB0_12
; %bb.4:
	mov	w0, #0
	b	LBB0_11
LBB0_5:
Lloh10:
	adrp	x1, l_.str@PAGE
Lloh11:
	add	x1, x1, l_.str@PAGEOFF
	bl	_avpriv_report_missing_feature
Lloh12:
	adrp	x8, _AVERROR_PATCHWELCOME@GOTPAGE
Lloh13:
	ldr	x8, [x8, _AVERROR_PATCHWELCOME@GOTPAGEOFF]
Lloh14:
	ldr	w0, [x8]
	b	LBB0_11
LBB0_6:
	mov	w0, #0
Lloh15:
	adrp	x8, _spdif_header_eac3@GOTPAGE
Lloh16:
	ldr	x8, [x8, _spdif_header_eac3@GOTPAGEOFF]
	b	LBB0_10
LBB0_7:
	mov	w0, #0
Lloh17:
	adrp	x8, _spdif_header_dts@GOTPAGE
Lloh18:
	ldr	x8, [x8, _spdif_header_dts@GOTPAGEOFF]
	b	LBB0_10
LBB0_8:
	mov	w0, #0
Lloh19:
	adrp	x8, _spdif_header_ac3@GOTPAGE
Lloh20:
	ldr	x8, [x8, _spdif_header_ac3@GOTPAGEOFF]
	b	LBB0_10
LBB0_9:
	mov	w0, #0
Lloh21:
	adrp	x8, _spdif_header_aac@GOTPAGE
Lloh22:
	ldr	x8, [x8, _spdif_header_aac@GOTPAGEOFF]
LBB0_10:
	ldr	w8, [x8]
	str	w8, [x19, #4]
LBB0_11:
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	ret
LBB0_12:
Lloh23:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh24:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh25:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #16]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp], #32             ; 16-byte Folded Reload
	b	_AVERROR
	.loh AdrpAdd	Lloh0, Lloh1
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpLdrGotLdr	Lloh4, Lloh5, Lloh6
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh15, Lloh16
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGot	Lloh19, Lloh20
	.loh AdrpLdrGot	Lloh21, Lloh22
	.loh AdrpLdrGotLdr	Lloh23, Lloh24, Lloh25
	.cfi_endproc
	.section	__TEXT,__const
lJTI0_0:
	.byte	(LBB0_3-LBB0_2)>>2
	.byte	(LBB0_2-LBB0_2)>>2
	.byte	(LBB0_2-LBB0_2)>>2
	.byte	(LBB0_2-LBB0_2)>>2
	.byte	(LBB0_3-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
                                        ; -- End function
	.comm	_spdif_header_ac3,4,2           ; @spdif_header_ac3
	.comm	_spdif_header_eac3,4,2          ; @spdif_header_eac3
	.comm	_spdif_header_mpeg,4,2          ; @spdif_header_mpeg
	.comm	_spdif_header_dts,4,2           ; @spdif_header_dts
	.comm	_spdif_header_aac,4,2           ; @spdif_header_aac
	.comm	_spdif_header_truehd,4,2        ; @spdif_header_truehd
	.comm	_MAT_FRAME_SIZE,4,2             ; @MAT_FRAME_SIZE
	.comm	_ENOMEM,4,2                     ; @ENOMEM
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Codec %d"

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