	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function asv2_encode_block
_asv2_encode_block:                     ## @asv2_encode_block
	.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	%rsi, %rbx
	movq	_ff_asv_scantab@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rdi, -48(%rbp)                 ## 8-byte Spill
	movq	(%rdi), %rcx
	movl	$61, %edx
	.p2align	4, 0x90
LBB0_1:                                 ## =>This Inner Loop Header: Depth=1
	leal	2(%rdx), %r14d
	movslq	(%rax,%r14,4), %rsi
	movl	(%rcx,%rsi,4), %edi
	imull	(%rbx,%rsi,4), %edi
	movswl	%di, %esi
	cmpl	%edi, %esi
	jne	LBB0_7
## %bb.2:                               ##   in Loop: Header=BB0_1 Depth=1
	leal	1(%rdx), %r14d
	movslq	(%rax,%r14,4), %rsi
	movl	(%rcx,%rsi,4), %edi
	imull	(%rbx,%rsi,4), %edi
	movswl	%di, %esi
	cmpl	%edi, %esi
	jne	LBB0_7
## %bb.3:                               ##   in Loop: Header=BB0_1 Depth=1
	movl	%edx, %esi
	movslq	(%rax,%rsi,4), %rsi
	movl	(%rcx,%rsi,4), %edi
	imull	(%rbx,%rsi,4), %edi
	movswl	%di, %esi
	cmpl	%edi, %esi
	jne	LBB0_4
## %bb.5:                               ##   in Loop: Header=BB0_1 Depth=1
	leal	-3(%rdx), %esi
	cmpl	$4, %edx
	movl	%esi, %edx
	ja	LBB0_1
## %bb.6:
	movl	$3, %r14d
	jmp	LBB0_7
LBB0_4:
	movl	%edx, %r14d
LBB0_7:
	movl	%r14d, %edx
	sarl	$2, %edx
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	leaq	8(%rax), %r12
	movq	%r12, %rdi
	movl	$4, %esi
	movq	%rdx, %r15
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_asv2_put_bits
	movl	(%rbx), %edx
	addl	$32, %edx
	sarl	$6, %edx
	movq	%r12, -72(%rbp)                 ## 8-byte Spill
	movq	%r12, %rdi
	movl	$8, %esi
	callq	_asv2_put_bits
	movl	$0, (%rbx)
	testl	%r14d, %r14d
	js	LBB0_21
## %bb.8:
	xorl	%r13d, %r13d
	testl	%r15d, %r15d
	cmovlel	%r13d, %r15d
	shlq	$4, %r15
	addq	$16, %r15
	movq	%r15, -64(%rbp)                 ## 8-byte Spill
	movq	%rbx, -56(%rbp)                 ## 8-byte Spill
	jmp	LBB0_9
	.p2align	4, 0x90
LBB0_20:                                ##   in Loop: Header=BB0_9 Depth=1
	addq	$16, %r13
	cmpq	%r13, -64(%rbp)                 ## 8-byte Folded Reload
	movq	-56(%rbp), %rbx                 ## 8-byte Reload
	je	LBB0_21
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	movq	_ff_asv_scantab@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movslq	(%rax,%r13), %r15
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movq	(%rax), %rax
	movl	(%rax,%r15,4), %ecx
	imull	(%rbx,%r15,4), %ecx
	movswl	%cx, %edx
	xorl	%esi, %esi
	cmpl	%ecx, %edx
	setne	%sil
	addl	$32768, %ecx                    ## imm = 0x8000
	sarl	$16, %ecx
	movl	%ecx, (%rbx,%r15,4)
	movl	32(%rax,%r15,4), %ecx
	imull	32(%rbx,%r15,4), %ecx
	leal	32768(%rcx), %edx
	sarl	$16, %edx
	movswl	%cx, %edi
	cmpl	%ecx, %edi
	leal	(,%rsi,8), %ecx
	leal	4(,%rsi,8), %esi
	cmovel	%ecx, %esi
	movl	%edx, 32(%rbx,%r15,4)
	movl	4(%rax,%r15,4), %ecx
	imull	4(%rbx,%r15,4), %ecx
	leal	32768(%rcx), %edx
	sarl	$16, %edx
	movswl	%cx, %edi
	cmpl	%ecx, %edi
	leal	2(%rsi), %r12d
	cmovel	%esi, %r12d
	movl	%edx, 4(%rbx,%r15,4)
	movl	36(%rax,%r15,4), %eax
	imull	36(%rbx,%r15,4), %eax
	leal	32768(%rax), %ecx
	sarl	$16, %ecx
	movl	%ecx, 36(%rbx,%r15,4)
	movswl	%ax, %ecx
	xorl	%r14d, %r14d
	cmpl	%eax, %ecx
	setne	%r14b
	orl	%r12d, %r14d
	cmpl	$8, %r14d
	setb	%al
	movq	_ff_asv_dc_ccp_tab@GOTPCREL(%rip), %rbx
	testq	%r13, %r13
	setne	%cl
	je	LBB0_11
## %bb.10:                              ##   in Loop: Header=BB0_9 Depth=1
	movq	_ff_asv_ac_ccp_tab@GOTPCREL(%rip), %rbx
LBB0_11:                                ##   in Loop: Header=BB0_9 Depth=1
	orb	%al, %cl
	movzbl	%cl, %edi
	callq	_av_assert2
	movq	(%rbx), %rax
	movq	(%rax,%r14,8), %rax
	movl	(%rax), %edx
	movl	4(%rax), %esi
	movq	-72(%rbp), %rbx                 ## 8-byte Reload
	movq	%rbx, %rdi
	callq	_put_bits
	testl	%r14d, %r14d
	je	LBB0_20
## %bb.12:                              ##   in Loop: Header=BB0_9 Depth=1
	testb	$8, %r12b
	jne	LBB0_13
## %bb.14:                              ##   in Loop: Header=BB0_9 Depth=1
	testb	$4, %r12b
	jne	LBB0_15
LBB0_16:                                ##   in Loop: Header=BB0_9 Depth=1
	testb	$2, %r12b
	jne	LBB0_17
LBB0_18:                                ##   in Loop: Header=BB0_9 Depth=1
	testb	$1, %r14b
	je	LBB0_20
	jmp	LBB0_19
	.p2align	4, 0x90
LBB0_13:                                ##   in Loop: Header=BB0_9 Depth=1
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	(%rax,%r15,4), %edx
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movq	%rbx, %rsi
	callq	_asv2_put_level
	testb	$4, %r12b
	je	LBB0_16
LBB0_15:                                ##   in Loop: Header=BB0_9 Depth=1
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	32(%rax,%r15,4), %edx
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movq	%rbx, %rsi
	callq	_asv2_put_level
	testb	$2, %r12b
	je	LBB0_18
LBB0_17:                                ##   in Loop: Header=BB0_9 Depth=1
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	4(%rax,%r15,4), %edx
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movq	%rbx, %rsi
	callq	_asv2_put_level
	testb	$1, %r14b
	je	LBB0_20
LBB0_19:                                ##   in Loop: Header=BB0_9 Depth=1
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	movl	36(%rax,%r15,4), %edx
	movq	-48(%rbp), %rdi                 ## 8-byte Reload
	movq	%rbx, %rsi
	callq	_asv2_put_level
	jmp	LBB0_20
LBB0_21:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ff_asv_scantab,8,3             ## @ff_asv_scantab
	.comm	_ff_asv_ac_ccp_tab,8,3          ## @ff_asv_ac_ccp_tab
	.comm	_ff_asv_dc_ccp_tab,8,3          ## @ff_asv_dc_ccp_tab
	.no_dead_strip	_asv2_encode_block
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function asv2_encode_block
_asv2_encode_block:                     ; @asv2_encode_block
	.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	x19, x1
	mov	x20, x0
Lloh0:
	adrp	x8, _ff_asv_scantab@GOTPAGE
Lloh1:
	ldr	x8, [x8, _ff_asv_scantab@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	ldr	x9, [x0]
	mov	w23, #64
LBB0_1:                                 ; =>This Inner Loop Header: Depth=1
	sub	w23, w23, #1
	ldrsw	x10, [x8, w23, uxtw #2]
	lsl	x10, x10, #2
	ldr	w11, [x19, x10]
	ldr	w10, [x9, x10]
	mul	w10, w10, w11
	cmp	w10, w10, sxth
	b.ne	LBB0_4
; %bb.2:                                ;   in Loop: Header=BB0_1 Depth=1
	cmp	w23, #4
	b.hi	LBB0_1
; %bb.3:
	mov	w23, #3
LBB0_4:
	asr	w22, w23, #2
	add	x27, x20, #8
	mov	x0, x27
	mov	w1, #4
	mov	x2, x22
	bl	_asv2_put_bits
	ldr	w8, [x19]
	add	w8, w8, #32
	asr	w2, w8, #6
	mov	x0, x27
	mov	w1, #8
	bl	_asv2_put_bits
	str	wzr, [x19]
	tbnz	w23, #31, LBB0_16
; %bb.5:
	mov	x24, #0
	cmp	w22, #0
	csel	w8, w22, wzr, gt
	lsl	x8, x8, #4
	add	x8, x8, #16
	str	x8, [sp]                        ; 8-byte Folded Spill
	b	LBB0_7
LBB0_6:                                 ;   in Loop: Header=BB0_7 Depth=1
	add	x24, x24, #16
	ldr	x8, [sp]                        ; 8-byte Folded Reload
	cmp	x8, x24
	b.eq	LBB0_16
LBB0_7:                                 ; =>This Inner Loop Header: Depth=1
Lloh3:
	adrp	x8, _ff_asv_scantab@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ff_asv_scantab@GOTPAGEOFF]
Lloh5:
	ldr	x8, [x8]
	ldrsw	x28, [x8, x24]
	lsl	x8, x28, #2
	ldr	w9, [x19, x8]
	ldr	x10, [x20]
	ldr	w11, [x10, x8]
	mul	w9, w11, w9
	add	w11, w9, #8, lsl #12            ; =32768
	asr	w11, w11, #16
	str	w11, [x19, x8]
	cmp	w9, w9, sxth
	cset	w8, ne
	lsl	w9, w8, #3
	add	x23, x28, #8
	lsl	x11, x23, #2
	ldr	w12, [x19, x11]
	ldr	w13, [x10, x11]
	mul	w12, w13, w12
	add	w13, w12, #8, lsl #12           ; =32768
	asr	w13, w13, #16
	str	w13, [x19, x11]
	mov	w11, #4
	bfi	w11, w8, #3, #1
	cmp	w12, w12, sxth
	add	x25, x28, #1
	lsl	x8, x25, #2
	ldr	w12, [x19, x8]
	csel	w9, w9, w11, eq
	ldr	w11, [x10, x8]
	mul	w11, w11, w12
	add	w12, w11, #8, lsl #12           ; =32768
	asr	w12, w12, #16
	str	w12, [x19, x8]
	orr	w8, w9, #0x2
	cmp	w11, w11, sxth
	csel	w22, w9, w8, eq
	add	x8, x28, #9
	str	x8, [sp, #8]                    ; 8-byte Folded Spill
	lsl	x8, x8, #2
	ldr	w9, [x19, x8]
	ldr	w10, [x10, x8]
	mul	w9, w10, w9
	add	w10, w9, #8, lsl #12            ; =32768
	asr	w10, w10, #16
	str	w10, [x19, x8]
	cmp	w9, w9, sxth
	cset	w8, ne
	orr	w26, w22, w8
	cmp	w26, #8
	cset	w8, lo
	cmp	x24, #0
	cset	w9, ne
	orr	w0, w9, w8
	mov	x21, x20
Lloh6:
	adrp	x8, _ff_asv_ac_ccp_tab@GOTPAGE
Lloh7:
	ldr	x8, [x8, _ff_asv_ac_ccp_tab@GOTPAGEOFF]
Lloh8:
	adrp	x9, _ff_asv_dc_ccp_tab@GOTPAGE
Lloh9:
	ldr	x9, [x9, _ff_asv_dc_ccp_tab@GOTPAGEOFF]
	csel	x20, x8, x9, ne
	bl	_av_assert2
	ldr	x8, [x20]
	mov	x20, x21
	ldr	x8, [x8, w26, uxtw #3]
	ldp	w2, w1, [x8]
	mov	x0, x27
	bl	_put_bits
	cbz	w26, LBB0_6
; %bb.8:                                ;   in Loop: Header=BB0_7 Depth=1
	tbnz	w22, #3, LBB0_12
; %bb.9:                                ;   in Loop: Header=BB0_7 Depth=1
	tbnz	w22, #2, LBB0_13
LBB0_10:                                ;   in Loop: Header=BB0_7 Depth=1
	tbnz	w22, #1, LBB0_14
LBB0_11:                                ;   in Loop: Header=BB0_7 Depth=1
	tbz	w26, #0, LBB0_6
	b	LBB0_15
LBB0_12:                                ;   in Loop: Header=BB0_7 Depth=1
	ldr	w2, [x19, x28, lsl #2]
	mov	x0, x20
	mov	x1, x27
	bl	_asv2_put_level
	tbz	w22, #2, LBB0_10
LBB0_13:                                ;   in Loop: Header=BB0_7 Depth=1
	ldr	w2, [x19, x23, lsl #2]
	mov	x0, x20
	mov	x1, x27
	bl	_asv2_put_level
	tbz	w22, #1, LBB0_11
LBB0_14:                                ;   in Loop: Header=BB0_7 Depth=1
	ldr	w2, [x19, x25, lsl #2]
	mov	x0, x20
	mov	x1, x27
	bl	_asv2_put_level
	tbz	w26, #0, LBB0_6
LBB0_15:                                ;   in Loop: Header=BB0_7 Depth=1
	ldr	x8, [sp, #8]                    ; 8-byte Folded Reload
	ldr	w2, [x19, x8, lsl #2]
	mov	x0, x20
	mov	x1, x27
	bl	_asv2_put_level
	b	LBB0_6
LBB0_16:
	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	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_ff_asv_scantab,8,3             ; @ff_asv_scantab
	.comm	_ff_asv_ac_ccp_tab,8,3          ; @ff_asv_ac_ccp_tab
	.comm	_ff_asv_dc_ccp_tab,8,3          ; @ff_asv_dc_ccp_tab
	.no_dead_strip	_asv2_encode_block
.subsections_via_symbols
