	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal16,16byte_literals
	.p2align	4                               ## -- Begin function eedi2_filter_dir_map_2x
LCPI0_0:
	.long	1                               ## 0x1
	.long	1                               ## 0x1
	.long	1                               ## 0x1
	.long	1                               ## 0x1
LCPI0_2:
	.space	16,255
	.section	__TEXT,__literal4,4byte_literals
	.p2align	2
LCPI0_1:
	.long	0x3f000000                      ## float 0.5
	.section	__TEXT,__text,regular,pure_instructions
	.globl	_eedi2_filter_dir_map_2x
	.p2align	4, 0x90
_eedi2_filter_dir_map_2x:               ## @eedi2_filter_dir_map_2x
	.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	$152, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%r9d, %r13d
	movq	%r8, %rbx
	movl	%ecx, %r12d
                                        ## kill: def $esi killed $esi def $rsi
	movq	%rsi, -120(%rbp)                ## 8-byte Spill
	movq	%rdi, -104(%rbp)                ## 8-byte Spill
	movl	32(%rbp), %r8d
	movl	24(%rbp), %r15d
	movl	16(%rbp), %r14d
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	%rax, -48(%rbp)
	movq	%rbx, -128(%rbp)                ## 8-byte Spill
	movq	%rbx, %rdi
	movq	%rdx, %rbx
	movl	%r9d, %esi
                                        ## kill: def $r8d killed $r8d killed $r8
	movl	%r15d, %r9d
	callq	_eedi2_bit_blit
	movl	$2, %esi
	subl	%r14d, %esi
	leal	-1(%r15), %eax
	movl	%eax, -132(%rbp)                ## 4-byte Spill
	cmpl	%eax, %esi
	jge	LBB0_44
## %bb.1:
	movl	%r14d, %r8d
	movq	%r15, %r9
	leal	(%r12,%r12), %eax
	movslq	%eax, %rcx
	movq	-120(%rbp), %r14                ## 8-byte Reload
	leal	(%r14,%r14), %eax
	movslq	%eax, %rdi
	movl	%esi, %eax
	imull	%r13d, %eax
	cltq
	movq	-128(%rbp), %rdx                ## 8-byte Reload
	leaq	(%rdx,%rax,4), %r10
	movl	$1, %eax
	subl	%r8d, %eax
	imull	%r14d, %eax
	cltq
	movq	-104(%rbp), %rdx                ## 8-byte Reload
	leaq	(%rdx,%rax,4), %rdx
	movq	%rdi, -184(%rbp)                ## 8-byte Spill
	leaq	(%rdx,%rdi,4), %rax
	movq	%rax, -120(%rbp)                ## 8-byte Spill
	imull	%esi, %r12d
	movslq	%r12d, %rax
	leaq	(%rbx,%rax,4), %r11
	leaq	(%r11,%rcx,4), %r12
	movq	%rcx, -192(%rbp)                ## 8-byte Spill
	leaq	(,%rcx,4), %rax
	movq	%r11, %rcx
	subq	%rax, %rcx
	movq	%rcx, -104(%rbp)                ## 8-byte Spill
	movl	32(%rbp), %eax
	decl	%eax
	movq	%rax, -128(%rbp)                ## 8-byte Spill
	addl	$-2, %r9d
	addl	%r13d, %r13d
	movslq	%r13d, %rax
	movq	%rax, -176(%rbp)                ## 8-byte Spill
	xorl	%r15d, %r15d
	movq	%r9, -144(%rbp)                 ## 8-byte Spill
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_43:                                ##   in Loop: Header=BB0_2 Depth=1
	movq	-184(%rbp), %rax                ## 8-byte Reload
	leaq	(%rdx,%rax,4), %rdx
	addq	%rax, -120(%rbp)                ## 8-byte Folded Spill
	movq	-192(%rbp), %rax                ## 8-byte Reload
	addq	%rax, -104(%rbp)                ## 8-byte Folded Spill
	leaq	(%r11,%rax,4), %r11
	addq	%rax, %r12
	movq	-176(%rbp), %rax                ## 8-byte Reload
	leaq	(%r10,%rax,4), %r10
	addl	$2, %esi
	cmpl	-132(%rbp), %esi                ## 4-byte Folded Reload
	jge	LBB0_44
LBB0_2:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_4 Depth 2
                                        ##       Child Loop BB0_35 Depth 3
	movl	32(%rbp), %eax
	cmpl	$3, %eax
	jl	LBB0_43
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	$1, %r13d
	movl	%esi, -108(%rbp)                ## 4-byte Spill
	movq	%r10, -168(%rbp)                ## 8-byte Spill
	movq	%rdx, -160(%rbp)                ## 8-byte Spill
	movq	%r12, -152(%rbp)                ## 8-byte Spill
	jmp	LBB0_4
LBB0_37:                                ##   in Loop: Header=BB0_4 Depth=2
	movq	-144(%rbp), %r9                 ## 8-byte Reload
	movl	-108(%rbp), %esi                ## 4-byte Reload
	movq	-168(%rbp), %r10                ## 8-byte Reload
	movq	-160(%rbp), %rdx                ## 8-byte Reload
	movl	$255, %eax
LBB0_41:                                ##   in Loop: Header=BB0_4 Depth=2
	movl	%eax, (%r10,%r13,4)
	movq	%r14, %r13
	cmpq	-128(%rbp), %r14                ## 8-byte Folded Reload
	je	LBB0_43
LBB0_4:                                 ##   Parent Loop BB0_2 Depth=1
                                        ## =>  This Loop Header: Depth=2
                                        ##       Child Loop BB0_35 Depth 3
	cmpl	$255, (%rdx,%r13,4)
	je	LBB0_7
## %bb.5:                               ##   in Loop: Header=BB0_4 Depth=2
	movq	-120(%rbp), %rax                ## 8-byte Reload
	cmpb	$-1, (%rax,%r13)
	je	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_4 Depth=2
	incq	%r13
	movq	%r13, %r14
	cmpq	-128(%rbp), %r14                ## 8-byte Folded Reload
	jne	LBB0_4
	jmp	LBB0_43
	.p2align	4, 0x90
LBB0_7:                                 ##   in Loop: Header=BB0_4 Depth=2
	xorl	%ebx, %ebx
	cmpl	$2, %esi
	jl	LBB0_15
## %bb.8:                               ##   in Loop: Header=BB0_4 Depth=2
	movq	-104(%rbp), %rax                ## 8-byte Reload
	movzbl	-1(%rax,%r13), %eax
	cmpl	$255, %eax
	je	LBB0_9
## %bb.10:                              ##   in Loop: Header=BB0_4 Depth=2
	movl	%eax, -96(%rbp)
	movl	$1, %ebx
	jmp	LBB0_11
LBB0_9:                                 ##   in Loop: Header=BB0_4 Depth=2
	xorl	%ebx, %ebx
LBB0_11:                                ##   in Loop: Header=BB0_4 Depth=2
	movq	-104(%rbp), %rax                ## 8-byte Reload
	movzbl	(%rax,%r13), %eax
	cmpl	$255, %eax
	je	LBB0_13
## %bb.12:                              ##   in Loop: Header=BB0_4 Depth=2
	movl	%ebx, %ecx
	incl	%ebx
	movl	%eax, -96(%rbp,%rcx,4)
LBB0_13:                                ##   in Loop: Header=BB0_4 Depth=2
	movq	-104(%rbp), %rax                ## 8-byte Reload
	movzbl	1(%r13,%rax), %eax
	cmpl	$255, %eax
	je	LBB0_15
## %bb.14:                              ##   in Loop: Header=BB0_4 Depth=2
	movl	%ebx, %ecx
	incl	%ebx
	movl	%eax, -96(%rbp,%rcx,4)
LBB0_15:                                ##   in Loop: Header=BB0_4 Depth=2
	movl	-4(%r11,%r13,4), %eax
	cmpl	$255, %eax
	je	LBB0_17
## %bb.16:                              ##   in Loop: Header=BB0_4 Depth=2
	movl	%ebx, %ecx
	incl	%ebx
	movl	%eax, -96(%rbp,%rcx,4)
LBB0_17:                                ##   in Loop: Header=BB0_4 Depth=2
	movl	(%r11,%r13,4), %eax
	cmpl	$255, %eax
	je	LBB0_19
## %bb.18:                              ##   in Loop: Header=BB0_4 Depth=2
	movl	%ebx, %ecx
	incl	%ebx
	movl	%eax, -96(%rbp,%rcx,4)
LBB0_19:                                ##   in Loop: Header=BB0_4 Depth=2
	movl	4(%r11,%r13,4), %eax
	cmpl	$255, %eax
	je	LBB0_21
## %bb.20:                              ##   in Loop: Header=BB0_4 Depth=2
	movl	%ebx, %ecx
	incl	%ebx
	movl	%eax, -96(%rbp,%rcx,4)
LBB0_21:                                ##   in Loop: Header=BB0_4 Depth=2
	leaq	1(%r13), %r14
	cmpl	%r9d, %esi
	jge	LBB0_28
## %bb.22:                              ##   in Loop: Header=BB0_4 Depth=2
	movzbl	-1(%r12,%r13), %eax
	cmpl	$255, %eax
	je	LBB0_24
## %bb.23:                              ##   in Loop: Header=BB0_4 Depth=2
	movl	%ebx, %ecx
	incl	%ebx
	movl	%eax, -96(%rbp,%rcx,4)
LBB0_24:                                ##   in Loop: Header=BB0_4 Depth=2
	movzbl	(%r12,%r13), %eax
	cmpl	$255, %eax
	je	LBB0_26
## %bb.25:                              ##   in Loop: Header=BB0_4 Depth=2
	movl	%ebx, %ecx
	incl	%ebx
	movl	%eax, -96(%rbp,%rcx,4)
LBB0_26:                                ##   in Loop: Header=BB0_4 Depth=2
	movzbl	(%r12,%r14), %eax
	cmpl	$255, %eax
	je	LBB0_28
## %bb.27:                              ##   in Loop: Header=BB0_4 Depth=2
	movl	%ebx, %ecx
	incl	%ebx
	movl	%eax, -96(%rbp,%rcx,4)
LBB0_28:                                ##   in Loop: Header=BB0_4 Depth=2
	movl	$255, %eax
	cmpl	$4, %ebx
	jb	LBB0_41
## %bb.29:                              ##   in Loop: Header=BB0_4 Depth=2
	movq	%r11, %r12
	leaq	-96(%rbp), %rdi
	movl	%ebx, %esi
	callq	_eedi2_sort_metrics
	testb	$1, %bl
	jne	LBB0_30
## %bb.31:                              ##   in Loop: Header=BB0_4 Depth=2
	leal	-1(%rbx), %eax
	shrl	%eax
	movl	-96(%rbp,%rax,4), %eax
	movl	%ebx, %ecx
	shrl	%ecx
	movl	-96(%rbp,%rcx,4), %ecx
	leal	(%rax,%rcx), %r8d
	incl	%r8d
	sarl	%r8d
	jmp	LBB0_32
LBB0_30:                                ##   in Loop: Header=BB0_4 Depth=2
	movl	%ebx, %eax
	shrl	%eax
	movl	-96(%rbp,%rax,4), %r8d
LBB0_32:                                ##   in Loop: Header=BB0_4 Depth=2
	leal	-128(%r8), %ecx
	leal	-128(%r8), %edx
	negl	%edx
	cmpl	$128, %r8d
	movq	_eedi2_limlut@GOTPCREL(%rip), %rax
	movq	(%rax), %rsi
	cmovgel	%ecx, %edx
	sarl	$2, %edx
	movslq	%edx, %rcx
	movl	(%rsi,%rcx,4), %r9d
	movl	%ebx, %r10d
	cmpl	$8, %ebx
	movq	%r12, %r11
	jae	LBB0_34
## %bb.33:                              ##   in Loop: Header=BB0_4 Depth=2
	xorl	%esi, %esi
	xorl	%ebx, %ebx
	xorl	%edi, %edi
	movq	-152(%rbp), %r12                ## 8-byte Reload
	jmp	LBB0_35
LBB0_34:                                ##   in Loop: Header=BB0_4 Depth=2
	movd	%r9d, %xmm0
	pshufd	$0, %xmm0, %xmm0                ## xmm0 = xmm0[0,0,0,0]
	movd	%r8d, %xmm1
	pshufd	$0, %xmm1, %xmm1                ## xmm1 = xmm1[0,0,0,0]
	movl	%r10d, %esi
	andl	$-8, %esi
	movdqa	-96(%rbp), %xmm2
	movdqa	-80(%rbp), %xmm3
	movdqa	%xmm2, %xmm4
	psubd	%xmm1, %xmm4
	movdqa	%xmm3, %xmm5
	psubd	%xmm1, %xmm5
	pabsd	%xmm4, %xmm1
	pabsd	%xmm5, %xmm4
	pcmpgtd	%xmm0, %xmm1
	movdqa	%xmm1, %xmm5
	pandn	%xmm2, %xmm5
	pcmpgtd	%xmm0, %xmm4
	pandn	LCPI0_0(%rip), %xmm1
	paddd	%xmm4, %xmm1
	pandn	%xmm3, %xmm4
	paddd	%xmm5, %xmm4
	pshufd	$238, %xmm4, %xmm0              ## xmm0 = xmm4[2,3,2,3]
	paddd	%xmm4, %xmm0
	pshufd	$85, %xmm0, %xmm2               ## xmm2 = xmm0[1,1,1,1]
	paddd	%xmm0, %xmm2
	movd	%xmm2, %edi
	psubd	LCPI0_2(%rip), %xmm1
	pshufd	$238, %xmm1, %xmm0              ## xmm0 = xmm1[2,3,2,3]
	paddd	%xmm1, %xmm0
	pshufd	$85, %xmm0, %xmm1               ## xmm1 = xmm0[1,1,1,1]
	paddd	%xmm0, %xmm1
	movd	%xmm1, %ebx
	cmpq	%r10, %rsi
	movq	-152(%rbp), %r12                ## 8-byte Reload
	je	LBB0_36
	.p2align	4, 0x90
LBB0_35:                                ##   Parent Loop BB0_2 Depth=1
                                        ##     Parent Loop BB0_4 Depth=2
                                        ## =>    This Inner Loop Header: Depth=3
	movl	-96(%rbp,%rsi,4), %edx
	movl	%edx, %ecx
	subl	%r8d, %ecx
	movl	%ecx, %eax
	negl	%eax
	cmovsl	%ecx, %eax
	xorl	%ecx, %ecx
	cmpl	%r9d, %eax
	setle	%cl
	cmovgl	%r15d, %edx
	addl	%edx, %edi
	addl	%ecx, %ebx
	incq	%rsi
	cmpq	%rsi, %r10
	jne	LBB0_35
LBB0_36:                                ##   in Loop: Header=BB0_4 Depth=2
	cmpl	$4, %ebx
	jb	LBB0_37
## %bb.38:                              ##   in Loop: Header=BB0_4 Depth=2
	movq	-144(%rbp), %r9                 ## 8-byte Reload
	movl	-108(%rbp), %esi                ## 4-byte Reload
	movq	-168(%rbp), %r10                ## 8-byte Reload
	movq	-160(%rbp), %rdx                ## 8-byte Reload
	movl	$255, %eax
	jne	LBB0_40
## %bb.39:                              ##   in Loop: Header=BB0_4 Depth=2
	cmpl	$255, (%r11,%r13,4)
	je	LBB0_41
LBB0_40:                                ##   in Loop: Header=BB0_4 Depth=2
	addl	%r8d, %edi
	xorps	%xmm0, %xmm0
	cvtsi2ss	%edi, %xmm0
	incl	%ebx
	xorps	%xmm1, %xmm1
	cvtsi2ss	%ebx, %xmm1
	divss	%xmm1, %xmm0
	addss	LCPI0_1(%rip), %xmm0
	cvttss2si	%xmm0, %eax
	jmp	LBB0_41
LBB0_44:
	movq	___stack_chk_guard@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	cmpq	-48(%rbp), %rax
	jne	LBB0_46
## %bb.45:
	addq	$152, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_46:
	callq	___stack_chk_fail
	.cfi_endproc
                                        ## -- End function
	.comm	_eedi2_limlut,8,3               ## @eedi2_limlut
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_eedi2_filter_dir_map_2x        ; -- Begin function eedi2_filter_dir_map_2x
	.p2align	2
_eedi2_filter_dir_map_2x:               ; @eedi2_filter_dir_map_2x
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #208
	.cfi_def_cfa_offset 208
	stp	d9, d8, [sp, #96]               ; 16-byte Folded Spill
	stp	x28, x27, [sp, #112]            ; 16-byte Folded Spill
	stp	x26, x25, [sp, #128]            ; 16-byte Folded Spill
	stp	x24, x23, [sp, #144]            ; 16-byte Folded Spill
	stp	x22, x21, [sp, #160]            ; 16-byte Folded Spill
	stp	x20, x19, [sp, #176]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #192]            ; 16-byte Folded Spill
	add	x29, sp, #192
	.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
	.cfi_offset b8, -104
	.cfi_offset b9, -112
	mov	x20, x7
	mov	x24, x6
	mov	x19, x5
	mov	x25, x4
	mov	x23, x3
	mov	x22, x2
	mov	x27, x1
	mov	x21, x0
	ldr	w4, [x29, #16]
Lloh0:
	adrp	x8, ___stack_chk_guard@GOTPAGE
Lloh1:
	ldr	x8, [x8, ___stack_chk_guard@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	str	x8, [sp, #88]
	mov	x0, x25
	mov	x1, x5
	str	w4, [sp, #28]                   ; 4-byte Folded Spill
	mov	x5, x7
	bl	_eedi2_bit_blit
	mov	w8, #2
	sub	w9, w20, #1
	sub	w26, w8, w24
	str	w9, [sp, #24]                   ; 4-byte Folded Spill
	cmp	w26, w9
	b.ge	LBB0_48
; %bb.1:
	lsl	w8, w23, #1
	sxtw	x9, w8
	lsl	w8, w27, #1
	sxtw	x10, w8
	mul	w8, w26, w19
	add	x13, x25, w8, sxtw #2
	msub	w8, w27, w24, w27
	add	x15, x21, w8, sxtw #2
	mul	w8, w26, w23
	add	x22, x22, w8, sxtw #2
	stp	x10, x9, [sp, #8]               ; 16-byte Folded Spill
	lsl	x8, x9, #2
	add	x16, x22, x8
	sub	x17, x22, x8
	ldr	w8, [sp, #28]                   ; 4-byte Folded Reload
	sub	w25, w8, #1
	sub	w24, w20, #2
	lsl	w8, w19, #1
	sxtw	x8, w8
	str	x8, [sp]                        ; 8-byte Folded Spill
	add	x0, sp, #48
	fmov	s8, #0.50000000
	add	x8, x15, x10, lsl #2
	str	x8, [sp, #40]                   ; 8-byte Folded Spill
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	ldr	x8, [sp, #8]                    ; 8-byte Folded Reload
	add	x15, x15, x8, lsl #2
	ldr	x9, [sp, #40]                   ; 8-byte Folded Reload
	add	x9, x9, x8
	str	x9, [sp, #40]                   ; 8-byte Folded Spill
	ldr	x8, [sp, #16]                   ; 8-byte Folded Reload
	add	x17, x17, x8
	add	x22, x22, x8, lsl #2
	add	x16, x16, x8
	add	w26, w26, #2
	ldr	x8, [sp]                        ; 8-byte Folded Reload
	add	x13, x13, x8, lsl #2
	ldr	w8, [sp, #24]                   ; 4-byte Folded Reload
	cmp	w26, w8
	b.ge	LBB0_48
LBB0_3:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_8 Depth 2
                                        ;       Child Loop BB0_41 Depth 3
	ldr	w8, [sp, #28]                   ; 4-byte Folded Reload
	cmp	w8, #3
	b.lt	LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	mov	w28, #1
	str	x17, [sp, #32]                  ; 8-byte Folded Spill
	b	LBB0_8
LBB0_5:                                 ;   in Loop: Header=BB0_8 Depth=2
	mov	w8, #255
LBB0_6:                                 ;   in Loop: Header=BB0_8 Depth=2
	str	w8, [x13, x28, lsl #2]
LBB0_7:                                 ;   in Loop: Header=BB0_8 Depth=2
	mov	x28, x21
	cmp	x21, x25
	b.eq	LBB0_2
LBB0_8:                                 ;   Parent Loop BB0_3 Depth=1
                                        ; =>  This Loop Header: Depth=2
                                        ;       Child Loop BB0_41 Depth 3
	ldr	w8, [x15, x28, lsl #2]
	cmp	w8, #255
	b.eq	LBB0_11
; %bb.9:                                ;   in Loop: Header=BB0_8 Depth=2
	ldr	x8, [sp, #40]                   ; 8-byte Folded Reload
	ldrb	w8, [x8, x28]
	cmp	w8, #255
	b.eq	LBB0_11
; %bb.10:                               ;   in Loop: Header=BB0_8 Depth=2
	add	x21, x28, #1
	b	LBB0_7
LBB0_11:                                ;   in Loop: Header=BB0_8 Depth=2
	sub	x8, x28, #1
	cmp	w26, #2
	b.lt	LBB0_14
; %bb.12:                               ;   in Loop: Header=BB0_8 Depth=2
	ldrb	w9, [x17, x8]
	cmp	w9, #255
	b.eq	LBB0_15
; %bb.13:                               ;   in Loop: Header=BB0_8 Depth=2
	str	w9, [sp, #48]
	mov	w20, #1
	b	LBB0_16
LBB0_14:                                ;   in Loop: Header=BB0_8 Depth=2
	mov	w20, #0
	b	LBB0_20
LBB0_15:                                ;   in Loop: Header=BB0_8 Depth=2
	mov	w20, #0
LBB0_16:                                ;   in Loop: Header=BB0_8 Depth=2
	ldrb	w9, [x17, x28]
	cmp	w9, #255
	b.eq	LBB0_18
; %bb.17:                               ;   in Loop: Header=BB0_8 Depth=2
	mov	w10, w20
	add	w20, w20, #1
	add	x11, sp, #48
	bfi	x11, x10, #2, #1
	str	w9, [x11]
LBB0_18:                                ;   in Loop: Header=BB0_8 Depth=2
	add	x9, x28, x17
	ldrb	w9, [x9, #1]
	cmp	w9, #255
	b.eq	LBB0_20
; %bb.19:                               ;   in Loop: Header=BB0_8 Depth=2
	mov	w10, w20
	add	w20, w20, #1
	add	x11, sp, #48
	bfi	x11, x10, #2, #2
	str	w9, [x11]
LBB0_20:                                ;   in Loop: Header=BB0_8 Depth=2
	ldr	w9, [x22, x8, lsl #2]
	cmp	w9, #255
	b.eq	LBB0_22
; %bb.21:                               ;   in Loop: Header=BB0_8 Depth=2
	str	w9, [x0, w20, uxtw #2]
	add	w20, w20, #1
LBB0_22:                                ;   in Loop: Header=BB0_8 Depth=2
	ldr	w9, [x22, x28, lsl #2]
	cmp	w9, #255
	b.eq	LBB0_24
; %bb.23:                               ;   in Loop: Header=BB0_8 Depth=2
	str	w9, [x0, w20, uxtw #2]
	add	w20, w20, #1
LBB0_24:                                ;   in Loop: Header=BB0_8 Depth=2
	add	x21, x28, #1
	ldr	w9, [x22, x21, lsl #2]
	cmp	w9, #255
	b.eq	LBB0_26
; %bb.25:                               ;   in Loop: Header=BB0_8 Depth=2
	str	w9, [x0, w20, uxtw #2]
	add	w20, w20, #1
LBB0_26:                                ;   in Loop: Header=BB0_8 Depth=2
	cmp	w26, w24
	b.ge	LBB0_33
; %bb.27:                               ;   in Loop: Header=BB0_8 Depth=2
	ldrb	w8, [x16, x8]
	cmp	w8, #255
	b.eq	LBB0_29
; %bb.28:                               ;   in Loop: Header=BB0_8 Depth=2
	str	w8, [x0, w20, uxtw #2]
	add	w20, w20, #1
LBB0_29:                                ;   in Loop: Header=BB0_8 Depth=2
	ldrb	w8, [x16, x28]
	cmp	w8, #255
	b.eq	LBB0_31
; %bb.30:                               ;   in Loop: Header=BB0_8 Depth=2
	str	w8, [x0, w20, uxtw #2]
	add	w20, w20, #1
LBB0_31:                                ;   in Loop: Header=BB0_8 Depth=2
	ldrb	w8, [x16, x21]
	cmp	w8, #255
	b.eq	LBB0_33
; %bb.32:                               ;   in Loop: Header=BB0_8 Depth=2
	str	w8, [x0, w20, uxtw #2]
	add	w20, w20, #1
LBB0_33:                                ;   in Loop: Header=BB0_8 Depth=2
	cmp	w20, #4
	b.lo	LBB0_5
; %bb.34:                               ;   in Loop: Header=BB0_8 Depth=2
	mov	x19, x16
	mov	x23, x15
	mov	x27, x13
	add	x0, sp, #48
	mov	x1, x20
	bl	_eedi2_sort_metrics
	tbnz	w20, #0, LBB0_36
; %bb.35:                               ;   in Loop: Header=BB0_8 Depth=2
	sub	w8, w20, #1
	lsr	w8, w8, #1
	add	x0, sp, #48
	ldr	w8, [x0, w8, uxtw #2]
	lsr	w9, w20, #1
	ldr	w9, [x0, w9, uxtw #2]
	add	w8, w8, w9
	add	w8, w8, #1
	asr	w8, w8, #1
	b	LBB0_37
LBB0_36:                                ;   in Loop: Header=BB0_8 Depth=2
	lsr	w8, w20, #1
	add	x0, sp, #48
	ldr	w8, [x0, w8, uxtw #2]
LBB0_37:                                ;   in Loop: Header=BB0_8 Depth=2
Lloh3:
	adrp	x9, _eedi2_limlut@GOTPAGE
Lloh4:
	ldr	x9, [x9, _eedi2_limlut@GOTPAGEOFF]
Lloh5:
	ldr	x9, [x9]
	mov	w10, #128
	sub	w10, w10, w8
	subs	w11, w8, #128
	csel	w10, w10, w11, lt
	asr	w10, w10, #2
	ldr	w9, [x9, w10, sxtw #2]
	mov	w10, w20
	cmp	w20, #16
	b.hs	LBB0_39
; %bb.38:                               ;   in Loop: Header=BB0_8 Depth=2
	mov	x13, #0
	mov	w12, #0
	mov	w11, #0
	b	LBB0_40
LBB0_39:                                ;   in Loop: Header=BB0_8 Depth=2
	dup.4s	v0, w9
	dup.4s	v1, w8
	and	x13, x10, #0x1f0
	ldp	q2, q3, [sp, #48]
	ldp	q4, q5, [sp, #80]
	sub.4s	v6, v2, v1
	sub.4s	v7, v3, v1
	sub.4s	v16, v4, v1
	sub.4s	v1, v5, v1
	abs.4s	v6, v6
	abs.4s	v7, v7
	abs.4s	v16, v16
	abs.4s	v1, v1
	cmgt.4s	v17, v6, v0
	cmgt.4s	v18, v7, v0
	cmgt.4s	v19, v16, v0
	cmgt.4s	v20, v1, v0
	bic.16b	v2, v2, v17
	bic.16b	v3, v3, v18
	bic.16b	v4, v4, v19
	bic.16b	v5, v5, v20
	cmge.4s	v6, v0, v6
	movi.4s	v17, #1
	and.16b	v6, v6, v17
	cmge.4s	v7, v0, v7
	cmge.4s	v16, v0, v16
	cmge.4s	v0, v0, v1
	add.4s	v1, v3, v2
	add.4s	v1, v4, v1
	add.4s	v1, v5, v1
	addv.4s	s1, v1
	fmov	w11, s1
	sub.4s	v1, v6, v7
	sub.4s	v1, v1, v16
	sub.4s	v0, v1, v0
	addv.4s	s0, v0
	fmov	w12, s0
	cmp	x13, x10
	b.eq	LBB0_42
LBB0_40:                                ;   in Loop: Header=BB0_8 Depth=2
	add	x14, x0, x13, lsl #2
	sub	x10, x10, x13
LBB0_41:                                ;   Parent Loop BB0_3 Depth=1
                                        ;     Parent Loop BB0_8 Depth=2
                                        ; =>    This Inner Loop Header: Depth=3
	ldr	w13, [x14], #4
	subs	w15, w13, w8
	cneg	w15, w15, mi
	cmp	w15, w9
	csel	w13, wzr, w13, gt
	add	w11, w13, w11
	cinc	w12, w12, le
	subs	x10, x10, #1
	b.ne	LBB0_41
LBB0_42:                                ;   in Loop: Header=BB0_8 Depth=2
	cmp	w12, #4
	b.hs	LBB0_44
LBB0_43:                                ;   in Loop: Header=BB0_8 Depth=2
	mov	w8, #255
	b	LBB0_47
LBB0_44:                                ;   in Loop: Header=BB0_8 Depth=2
	b.ne	LBB0_46
; %bb.45:                               ;   in Loop: Header=BB0_8 Depth=2
	ldr	w9, [x22, x28, lsl #2]
	cmp	w9, #255
	b.eq	LBB0_43
LBB0_46:                                ;   in Loop: Header=BB0_8 Depth=2
	add	w8, w11, w8
	scvtf	s0, w8
	add	w8, w12, #1
	scvtf	s1, w8
	fdiv	s0, s0, s1
	fadd	s0, s0, s8
	fcvtzs	w8, s0
LBB0_47:                                ;   in Loop: Header=BB0_8 Depth=2
	mov	x13, x27
	mov	x15, x23
	mov	x16, x19
	ldr	x17, [sp, #32]                  ; 8-byte Folded Reload
	b	LBB0_6
LBB0_48:
	ldr	x8, [sp, #88]
Lloh6:
	adrp	x9, ___stack_chk_guard@GOTPAGE
Lloh7:
	ldr	x9, [x9, ___stack_chk_guard@GOTPAGEOFF]
Lloh8:
	ldr	x9, [x9]
	cmp	x9, x8
	b.ne	LBB0_50
; %bb.49:
	ldp	x29, x30, [sp, #192]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #176]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #160]            ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #144]            ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #128]            ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #112]            ; 16-byte Folded Reload
	ldp	d9, d8, [sp, #96]               ; 16-byte Folded Reload
	add	sp, sp, #208
	ret
LBB0_50:
	bl	___stack_chk_fail
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh6, Lloh7, Lloh8
	.cfi_endproc
                                        ; -- End function
	.comm	_eedi2_limlut,8,3               ; @eedi2_limlut
.subsections_via_symbols
