	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function pix_median_abs16_c
_pix_median_abs16_c:                    ## @pix_median_abs16_c
	.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	$56, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rsi, %r11
	movl	(%rsi), %esi
	movl	(%rdx), %r10d
	movl	4(%rdx), %ebx
	leal	(%rsi,%rbx), %r9d
	movdqu	4(%r11), %xmm8
	movl	4(%r11), %edi
	addl	%r10d, %edi
	movdqu	8(%rdx), %xmm2
	pshufd	$249, %xmm8, %xmm3              ## xmm3 = xmm8[1,2,3,3]
	paddd	%xmm2, %xmm8
	movq	20(%r11), %rax
	movq	%rax, %xmm1
	movd	%ebx, %xmm4
	pshufd	$80, %xmm2, %xmm5               ## xmm5 = xmm2[0,0,1,1]
	pblendw	$3, %xmm4, %xmm5                ## xmm5 = xmm4[0,1],xmm5[2,3,4,5,6,7]
	pshufd	$0, %xmm1, %xmm4                ## xmm4 = xmm1[0,0,0,0]
	pblendw	$63, %xmm5, %xmm4               ## xmm4 = xmm5[0,1,2,3,4,5],xmm4[6,7]
	pshufd	$170, %xmm2, %xmm2              ## xmm2 = xmm2[2,2,2,2]
	pblendw	$63, %xmm3, %xmm2               ## xmm2 = xmm3[0,1,2,3,4,5],xmm2[6,7]
	paddd	%xmm4, %xmm2
	shrq	$32, %rax
	addl	20(%rdx), %eax
	movq	24(%rdx), %rbx
	movq	%rbx, %xmm3
	paddd	%xmm3, %xmm1
	movdqu	28(%r11), %xmm5
	movdqu	44(%r11), %xmm6
	addl	28(%r11), %ebx
	movdqu	48(%rdx), %xmm9
	movdqu	32(%rdx), %xmm0
	pshufd	$144, %xmm0, %xmm4              ## xmm4 = xmm0[0,0,1,2]
	pshufd	$85, %xmm3, %xmm7               ## xmm7 = xmm3[1,1,1,1]
	pblendw	$252, %xmm4, %xmm7              ## xmm7 = xmm7[0,1],xmm4[2,3,4,5,6,7]
	movdqa	%xmm6, %xmm3
	palignr	$4, %xmm5, %xmm3                ## xmm3 = xmm5[4,5,6,7,8,9,10,11,12,13,14,15],xmm3[0,1,2,3]
	paddd	%xmm7, %xmm3
	pshufd	$249, %xmm6, %xmm4              ## xmm4 = xmm6[1,2,3,3]
	paddd	%xmm9, %xmm6
	palignr	$12, %xmm0, %xmm9               ## xmm9 = xmm0[12,13,14,15],xmm9[0,1,2,3,4,5,6,7,8,9,10,11]
	pinsrd	$3, 60(%r11), %xmm4
	paddd	%xmm9, %xmm4
	psubd	%xmm6, %xmm4
	paddd	%xmm0, %xmm5
	psubd	%xmm5, %xmm3
	movd	%edi, %xmm0
	pinsrd	$1, %esi, %xmm0
	punpcklqdq	%xmm2, %xmm0            ## xmm0 = xmm0[0],xmm2[0]
	pshufd	$238, %xmm2, %xmm2              ## xmm2 = xmm2[2,3,2,3]
	pinsrd	$2, %eax, %xmm2
	pinsrd	$3, %ebx, %xmm2
	movd	%r9d, %xmm5
	pinsrd	$1, %r10d, %xmm5
	punpcklqdq	%xmm8, %xmm5            ## xmm5 = xmm5[0],xmm8[0]
	psubd	%xmm5, %xmm0
	palignr	$8, %xmm8, %xmm1                ## xmm1 = xmm8[8,9,10,11,12,13,14,15],xmm1[0,1,2,3,4,5,6,7]
	psubd	%xmm1, %xmm2
	pabsd	%xmm2, %xmm1
	pabsd	%xmm0, %xmm0
	pabsd	%xmm4, %xmm2
	paddd	%xmm1, %xmm2
	pabsd	%xmm3, %xmm1
	paddd	%xmm0, %xmm1
	paddd	%xmm2, %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, %eax
	movl	%r8d, -44(%rbp)                 ## 4-byte Spill
	cmpl	$2, %r8d
	jl	LBB0_6
## %bb.1:
	movslq	%ecx, %rcx
	leaq	(,%rcx,4), %rsi
	leaq	(%rdx,%rcx,4), %r13
	addq	$4, %r13
	leaq	(%r11,%rcx,4), %r10
	addq	$4, %r10
                                        ## kill: def $ecx killed $ecx killed $rcx
	negl	%ecx
	movslq	%ecx, %rcx
	movq	%rcx, -64(%rbp)                 ## 8-byte Spill
	movl	$1, %ecx
	movq	%rdx, %r8
	movq	%rsi, -72(%rbp)                 ## 8-byte Spill
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	-48(%rbp), %ecx                 ## 4-byte Reload
	incl	%ecx
	movq	-72(%rbp), %rsi                 ## 8-byte Reload
	addq	%rsi, %r13
	addq	%rsi, %rbx
	movq	-80(%rbp), %r11                 ## 8-byte Reload
	movq	-88(%rbp), %r8                  ## 8-byte Reload
	cmpl	-44(%rbp), %ecx                 ## 4-byte Folded Reload
	movq	%rbx, %r10
	je	LBB0_6
LBB0_2:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_3 Depth 2
	movl	%ecx, -48(%rbp)                 ## 4-byte Spill
	leaq	(%r11,%rsi), %rdi
	leaq	(%r8,%rsi), %r14
	movl	(%r11,%rsi), %ecx
	movl	(%r8,%rsi), %edx
	movq	-64(%rbp), %rbx                 ## 8-byte Reload
	movq	%rdi, -80(%rbp)                 ## 8-byte Spill
	movl	(%rdi,%rbx,4), %esi
	addl	%edx, %esi
	movl	%ecx, %edi
	subl	%esi, %edi
	movq	%r14, -88(%rbp)                 ## 8-byte Spill
	addl	(%r14,%rbx,4), %edi
	movl	%edi, %esi
	negl	%esi
	cmovsl	%edi, %esi
	addl	%eax, %esi
	xorl	%r12d, %r12d
	movl	%esi, %eax
	movq	%r11, -96(%rbp)                 ## 8-byte Spill
	.p2align	4, 0x90
LBB0_3:                                 ##   Parent Loop BB0_2 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	subl	%edx, %ecx
	movslq	(%r10,%r12), %r15
	movslq	(%r13,%r12), %rdx
	movslq	4(%r11,%r12), %rdi
	movslq	4(%r8,%r12), %rsi
	subq	%rsi, %rdi
	movslq	%ecx, %rsi
	leal	(%rsi,%rdi), %ecx
	subl	(%r11,%r12), %ecx
	subq	%rdx, %r15
                                        ## kill: def $eax killed $eax killed $rax
	movl	%eax, -52(%rbp)                 ## 4-byte Spill
	movq	%r8, %r14
	addl	(%r8,%r12), %ecx
	movslq	%ecx, %rdx
	movq	%r10, %rbx
	callq	_mid_pred
	subq	%rax, %r15
	movq	%r15, %rax
	negq	%rax
	cmovsq	%r15, %rax
	addl	-52(%rbp), %eax                 ## 4-byte Folded Reload
	cmpq	$56, %r12
	je	LBB0_5
## %bb.4:                               ##   in Loop: Header=BB0_3 Depth=2
	movl	(%rbx,%r12), %ecx
	movl	(%r13,%r12), %edx
	addq	$4, %r12
	movq	-96(%rbp), %r11                 ## 8-byte Reload
	movq	%r14, %r8
	movq	%rbx, %r10
	jmp	LBB0_3
LBB0_6:
                                        ## kill: def $eax killed $eax killed $rax
	addq	$56, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_pix_median_abs16_c
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function pix_median_abs16_c
_pix_median_abs16_c:                    ; @pix_median_abs16_c
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #128
	.cfi_def_cfa_offset 128
	stp	x28, x27, [sp, #32]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #48]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #64]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #80]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #96]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #112]            ; 16-byte Folded Spill
	add	x29, sp, #112
	.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
                                        ; kill: def $w3 killed $w3 def $x3
	ldp	w8, w9, [x1]
	ldp	w10, w11, [x2]
	subs	w12, w8, w10
	cneg	w12, w12, mi
	add	w10, w10, w9
	add	w8, w8, w11
	subs	w8, w10, w8
	cneg	w8, w8, mi
	ldp	w10, w13, [x1, #8]
	add	w11, w11, w10
	ldp	w14, w15, [x2, #8]
	add	w9, w9, w14
	subs	w9, w11, w9
	cneg	w9, w9, mi
	add	w8, w8, w12
	add	w8, w8, w9
	add	w9, w14, w13
	add	w10, w10, w15
	subs	w9, w9, w10
	cneg	w9, w9, mi
	ldp	w10, w11, [x1, #16]
	add	w12, w15, w10
	ldp	w14, w15, [x2, #16]
	add	w13, w13, w14
	subs	w12, w12, w13
	cneg	w12, w12, mi
	add	w8, w8, w9
	add	w8, w8, w12
	add	w9, w14, w11
	add	w10, w10, w15
	subs	w9, w9, w10
	cneg	w9, w9, mi
	ldp	w10, w12, [x1, #24]
	add	w13, w15, w10
	ldp	w14, w15, [x2, #24]
	add	w11, w11, w14
	subs	w11, w13, w11
	cneg	w11, w11, mi
	add	w8, w8, w9
	add	w8, w8, w11
	add	w9, w14, w12
	add	w10, w10, w15
	subs	w9, w9, w10
	cneg	w9, w9, mi
	ldp	w10, w11, [x1, #32]
	add	w13, w15, w10
	ldp	w14, w15, [x2, #32]
	add	w12, w12, w14
	subs	w12, w13, w12
	cneg	w12, w12, mi
	add	w8, w8, w9
	add	w8, w8, w12
	add	w9, w14, w11
	add	w10, w10, w15
	subs	w9, w9, w10
	cneg	w9, w9, mi
	ldp	w10, w12, [x1, #40]
	add	w13, w15, w10
	ldp	w14, w15, [x2, #40]
	add	w11, w11, w14
	subs	w11, w13, w11
	cneg	w11, w11, mi
	add	w8, w8, w9
	add	w8, w8, w11
	add	w9, w14, w12
	add	w10, w10, w15
	subs	w9, w9, w10
	cneg	w9, w9, mi
	ldp	w10, w11, [x1, #48]
	add	w13, w15, w10
	ldp	w14, w15, [x2, #48]
	add	w12, w12, w14
	subs	w12, w13, w12
	cneg	w12, w12, mi
	add	w8, w8, w9
	add	w8, w8, w12
	add	w9, w14, w11
	add	w10, w10, w15
	subs	w9, w9, w10
	cneg	w9, w9, mi
	ldp	w10, w12, [x1, #56]
	add	w13, w15, w10
	ldp	w14, w15, [x2, #56]
	add	w11, w11, w14
	subs	w11, w13, w11
	cneg	w11, w11, mi
	add	w8, w8, w9
	add	w8, w8, w11
	add	w9, w14, w12
	add	w10, w10, w15
	subs	w9, w9, w10
	cneg	w9, w9, mi
	add	w22, w8, w9
	str	w4, [sp, #28]                   ; 4-byte Folded Spill
	cmp	w4, #2
	b.lt	LBB0_6
; %bb.1:
	mov	x21, x2
	mov	x20, x1
	sxtw	x8, w3
	neg	w9, w3
	sxtw	x9, w9
	lsl	x10, x8, #2
	add	x8, x10, #4
	add	x24, x1, x8
	add	x25, x2, x8
	mov	w26, #1
	lsl	x8, x9, #2
	stp	x8, x10, [sp, #8]               ; 16-byte Folded Spill
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	w26, w26, #1
	ldr	x10, [sp, #16]                  ; 8-byte Folded Reload
	add	x24, x24, x10
	add	x25, x25, x10
	mov	x20, x28
	mov	x21, x19
	ldr	w8, [sp, #28]                   ; 4-byte Folded Reload
	cmp	w26, w8
	b.eq	LBB0_6
LBB0_3:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_4 Depth 2
	mov	x27, #0
	add	x28, x20, x10
	add	x19, x21, x10
	ldr	w8, [x28]
	ldr	x9, [sp, #8]                    ; 8-byte Folded Reload
	ldr	w10, [x28, x9]
	ldr	w11, [x19, x9]
	ldr	w9, [x19]
	add	w10, w9, w10
	sub	w10, w8, w10
	adds	w10, w10, w11
	cneg	w10, w10, mi
	add	w22, w10, w22
LBB0_4:                                 ;   Parent Loop BB0_3 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	ldrsw	x10, [x24, x27]
	ldrsw	x11, [x25, x27]
	sub	x23, x10, x11
	add	x10, x20, x27
	add	x11, x21, x27
	ldp	w10, w12, [x10]
                                        ; kill: def $w12 killed $w12 def $x12
	sxtw	x12, w12
	ldp	w11, w13, [x11]
                                        ; kill: def $w13 killed $w13 def $x13
	sxtw	x13, w13
	sub	x0, x12, x13
	sub	w8, w8, w9
	add	w9, w8, w0
	sxtw	x1, w8
	sub	w8, w9, w10
	add	w8, w8, w11
	sxtw	x2, w8
	bl	_mid_pred
	subs	x8, x23, x0
	cneg	x8, x8, mi
	add	w22, w22, w8
	cmp	x27, #56
	b.eq	LBB0_2
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=2
	ldr	w8, [x24, x27]
	ldr	w9, [x25, x27]
	add	x27, x27, #4
	b	LBB0_4
LBB0_6:
	mov	x0, x22
	ldp	x29, x30, [sp, #112]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #96]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #80]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #64]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #48]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #32]             ; 16-byte Folded Reload
	add	sp, sp, #128
	ret
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_pix_median_abs16_c
.subsections_via_symbols
