	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function cenc_decrypt
_cenc_decrypt:                          ## @cenc_decrypt
	.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
	movl	%r8d, %r12d
	movq	%rcx, -56(%rbp)                 ## 8-byte Spill
	movq	%rdx, %r15
	movq	%rsi, %r13
	movq	%rdi, %r14
	movq	(%rdx), %rbx
	movl	$99, %edi
	movl	$101, %esi
	movl	$110, %edx
	movl	$99, %ecx
	callq	_MKBETAG
	cmpq	%rax, %rbx
	jne	LBB0_3
## %bb.1:
	cmpq	$0, 8(%r15)
	jne	LBB0_3
## %bb.2:
	cmpq	$0, 16(%r15)
	je	LBB0_4
LBB0_3:
	movl	(%r14), %edi
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str(%rip), %rdx
	callq	_av_log
	movq	_AVERROR_PATCHWELCOME@GOTPCREL(%rip), %rax
LBB0_18:
	movl	(%rax), %eax
LBB0_19:
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_4:
	movq	(%r13), %rdi
	testq	%rdi, %rdi
	je	LBB0_5
LBB0_8:
	movl	40(%r15), %esi
	callq	_av_aes_ctr_set_full_iv
	cmpl	$0, 24(%r15)
	je	LBB0_21
## %bb.9:
	movq	%r14, -48(%rbp)                 ## 8-byte Spill
	jle	LBB0_14
## %bb.10:
	movq	%r13, -64(%rbp)                 ## 8-byte Spill
	movq	32(%r15), %rax
	xorl	%r14d, %r14d
	movq	-56(%rbp), %rdx                 ## 8-byte Reload
	.p2align	4, 0x90
LBB0_11:                                ## =>This Inner Loop Header: Depth=1
	movslq	(%rax,%r14,8), %r13
	movl	4(%rax,%r14,8), %ecx
	leal	(%rcx,%r13), %eax
	cmpl	%r12d, %eax
	jg	LBB0_12
## %bb.13:                              ##   in Loop: Header=BB0_11 Depth=1
	leaq	(%rdx,%r13,4), %rbx
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %rdi
	movq	%rbx, %rsi
	movq	%rbx, %rdx
                                        ## kill: def $ecx killed $ecx killed $rcx
	callq	_av_aes_ctr_crypt
	movq	32(%r15), %rax
	movslq	4(%rax,%r14,8), %rcx
	leaq	(%rbx,%rcx,4), %rdx
	addl	%r13d, %ecx
	subl	%ecx, %r12d
	incq	%r14
	movslq	24(%r15), %rcx
	cmpq	%rcx, %r14
	jl	LBB0_11
LBB0_14:
	testl	%r12d, %r12d
	jle	LBB0_15
## %bb.16:
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edi
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.2(%rip), %rdx
	jmp	LBB0_17
LBB0_5:
	xorl	%eax, %eax
	callq	_av_aes_ctr_alloc
	movq	%rax, (%r13)
	testq	%rax, %rax
	je	LBB0_20
## %bb.6:
	movl	4(%r14), %esi
	movq	%rax, %rdi
	callq	_av_aes_ctr_init
	testl	%eax, %eax
	js	LBB0_19
## %bb.7:
	movq	(%r13), %rdi
	jmp	LBB0_8
LBB0_21:
	movq	(%r13), %rdi
	movq	-56(%rbp), %rdx                 ## 8-byte Reload
	movq	%rdx, %rsi
	movl	%r12d, %ecx
	callq	_av_aes_ctr_crypt
	xorl	%eax, %eax
	jmp	LBB0_19
LBB0_12:
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax), %edi
	movq	_AV_LOG_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %esi
	leaq	L_.str.1(%rip), %rdx
LBB0_17:
	callq	_av_log
	movq	_AVERROR_INVALIDDATA@GOTPCREL(%rip), %rax
	jmp	LBB0_18
LBB0_20:
	movq	_ENOMEM@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_AVERROR                        ## TAILCALL
LBB0_15:
	xorl	%eax, %eax
	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	"Only the 'cenc' encryption scheme is supported\n"

	.comm	_AVERROR_PATCHWELCOME,4,2       ## @AVERROR_PATCHWELCOME
	.comm	_ENOMEM,4,2                     ## @ENOMEM
L_.str.1:                               ## @.str.1
	.asciz	"subsample size exceeds the packet size left\n"

	.comm	_AVERROR_INVALIDDATA,4,2        ## @AVERROR_INVALIDDATA
L_.str.2:                               ## @.str.2
	.asciz	"leftover packet bytes after subsample processing\n"

	.no_dead_strip	_cenc_decrypt
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function cenc_decrypt
_cenc_decrypt:                          ; @cenc_decrypt
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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, x4
	mov	x23, x3
	mov	x22, x2
	mov	x21, x1
	mov	x20, x0
	ldr	x24, [x2]
	mov	w0, #99
	mov	w1, #101
	mov	w2, #110
	mov	w3, #99
	bl	_MKBETAG
	cmp	x24, x0
	b.ne	LBB0_3
; %bb.1:
	ldr	x8, [x22, #8]
	cbnz	x8, LBB0_3
; %bb.2:
	ldr	x8, [x22, #16]
	cbz	x8, LBB0_6
LBB0_3:
	ldr	w0, [x20]
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
	bl	_av_log
Lloh5:
	adrp	x8, _AVERROR_PATCHWELCOME@GOTPAGE
Lloh6:
	ldr	x8, [x8, _AVERROR_PATCHWELCOME@GOTPAGEOFF]
LBB0_4:
	ldr	w0, [x8]
LBB0_5:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
LBB0_6:
	ldr	x0, [x21]
	cbz	x0, LBB0_14
LBB0_7:
	ldr	w1, [x22, #40]
	bl	_av_aes_ctr_set_full_iv
	ldr	w8, [x22, #24]
	cbz	w8, LBB0_17
; %bb.8:
	cmp	w8, #1
	b.lt	LBB0_12
; %bb.9:
	mov	x24, #0
	mov	x25, #0
	ldr	x8, [x22, #32]
LBB0_10:                                ; =>This Inner Loop Header: Depth=1
	add	x8, x8, x24
	ldp	w26, w3, [x8]
                                        ; kill: def $w26 killed $w26 def $x26
	sxtw	x26, w26
	add	w8, w3, w26
	cmp	w8, w19
	b.gt	LBB0_18
; %bb.11:                               ;   in Loop: Header=BB0_10 Depth=1
	add	x23, x23, x26, lsl #2
	ldr	x0, [x21]
	mov	x1, x23
	mov	x2, x23
	bl	_av_aes_ctr_crypt
	ldr	x8, [x22, #32]
	add	x9, x8, x24
	ldrsw	x9, [x9, #4]
	add	x23, x23, x9, lsl #2
	add	w9, w26, w9
	sub	w19, w19, w9
	add	x25, x25, #1
	ldrsw	x9, [x22, #24]
	add	x24, x24, #8
	cmp	x25, x9
	b.lt	LBB0_10
LBB0_12:
	cmp	w19, #1
	b.lt	LBB0_21
; %bb.13:
	ldr	w0, [x20]
Lloh7:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh8:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh9:
	ldr	w1, [x8]
Lloh10:
	adrp	x2, l_.str.2@PAGE
Lloh11:
	add	x2, x2, l_.str.2@PAGEOFF
	b	LBB0_19
LBB0_14:
	bl	_av_aes_ctr_alloc
	str	x0, [x21]
	cbz	x0, LBB0_20
; %bb.15:
	ldr	w1, [x20, #4]
	bl	_av_aes_ctr_init
	tbnz	w0, #31, LBB0_5
; %bb.16:
	ldr	x0, [x21]
	b	LBB0_7
LBB0_17:
	ldr	x0, [x21]
	mov	x1, x23
	mov	x2, x23
	mov	x3, x19
	bl	_av_aes_ctr_crypt
	mov	w0, #0
	b	LBB0_5
LBB0_18:
	ldr	w0, [x20]
Lloh12:
	adrp	x8, _AV_LOG_ERROR@GOTPAGE
Lloh13:
	ldr	x8, [x8, _AV_LOG_ERROR@GOTPAGEOFF]
Lloh14:
	ldr	w1, [x8]
Lloh15:
	adrp	x2, l_.str.1@PAGE
Lloh16:
	add	x2, x2, l_.str.1@PAGEOFF
LBB0_19:
	bl	_av_log
Lloh17:
	adrp	x8, _AVERROR_INVALIDDATA@GOTPAGE
Lloh18:
	ldr	x8, [x8, _AVERROR_INVALIDDATA@GOTPAGEOFF]
	b	LBB0_4
LBB0_20:
Lloh19:
	adrp	x8, _ENOMEM@GOTPAGE
Lloh20:
	ldr	x8, [x8, _ENOMEM@GOTPAGEOFF]
Lloh21:
	ldr	w0, [x8]
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	b	_AVERROR
LBB0_21:
	mov	w0, #0
	b	LBB0_5
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpAdd	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpAdd	Lloh10, Lloh11
	.loh AdrpLdrGotLdr	Lloh7, Lloh8, Lloh9
	.loh AdrpAdd	Lloh15, Lloh16
	.loh AdrpLdrGotLdr	Lloh12, Lloh13, Lloh14
	.loh AdrpLdrGot	Lloh17, Lloh18
	.loh AdrpLdrGotLdr	Lloh19, Lloh20, Lloh21
	.cfi_endproc
                                        ; -- End function
	.comm	_AV_LOG_ERROR,4,2               ; @AV_LOG_ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Only the 'cenc' encryption scheme is supported\n"

	.comm	_AVERROR_PATCHWELCOME,4,2       ; @AVERROR_PATCHWELCOME
	.comm	_ENOMEM,4,2                     ; @ENOMEM
l_.str.1:                               ; @.str.1
	.asciz	"subsample size exceeds the packet size left\n"

	.comm	_AVERROR_INVALIDDATA,4,2        ; @AVERROR_INVALIDDATA
l_.str.2:                               ; @.str.2
	.asciz	"leftover packet bytes after subsample processing\n"

	.no_dead_strip	_cenc_decrypt
.subsections_via_symbols
