	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.section	__TEXT,__literal16,16byte_literals
	.p2align	4                               ## -- Begin function png_setup_avg_row_only
LCPI0_0:
	.byte	255                             ## 0xff
	.byte	0                               ## 0x0
	.byte	0                               ## 0x0
	.byte	0                               ## 0x0
	.byte	255                             ## 0xff
	.byte	0                               ## 0x0
	.byte	0                               ## 0x0
	.byte	0                               ## 0x0
	.byte	255                             ## 0xff
	.byte	0                               ## 0x0
	.byte	0                               ## 0x0
	.byte	0                               ## 0x0
	.byte	255                             ## 0xff
	.byte	0                               ## 0x0
	.byte	0                               ## 0x0
	.byte	0                               ## 0x0
	.section	__TEXT,__text,regular,pure_instructions
	.p2align	4, 0x90
_png_setup_avg_row_only:                ## @png_setup_avg_row_only
	.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
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	_PNG_FILTER_VALUE_AVG@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	16(%rdi), %rbx
	movl	%eax, (%rbx)
	movq	(%rdi), %r8
	movq	8(%rdi), %rax
	leaq	4(%rbx), %r11
	leaq	4(%rax), %r13
	leaq	4(%r8), %r15
	testq	%rsi, %rsi
	je	LBB0_14
## %bb.1:
	cmpq	$8, %rsi
	jae	LBB0_3
## %bb.2:
	xorl	%r9d, %r9d
LBB0_8:
	movq	%r9, %rax
	notq	%rax
	testb	$1, %sil
	je	LBB0_10
## %bb.9:
	movl	(%r15), %edi
	movl	(%r13), %r10d
	movl	%r10d, %ebx
	shrl	$31, %ebx
	addl	%r10d, %ebx
	shrl	%ebx
	subl	%ebx, %edi
	movzbl	%dil, %edi
	movl	%edi, (%r11)
	orq	$1, %r9
	addq	$4, %r11
	addq	$4, %r13
	addq	$4, %r15
LBB0_10:
	addq	%rsi, %rax
	je	LBB0_14
## %bb.11:
	movq	%rsi, %r10
	subq	%r9, %r10
	xorl	%edi, %edi
	xorl	%r9d, %r9d
	.p2align	4, 0x90
LBB0_12:                                ## =>This Inner Loop Header: Depth=1
	movl	(%r15,%rdi,4), %ecx
	movl	(%r13,%rdi,4), %eax
	movl	%eax, %ebx
	shrl	$31, %ebx
	addl	%eax, %ebx
	shrl	%ebx
	subl	%ebx, %ecx
	movzbl	%cl, %eax
	movl	%eax, (%r11,%rdi,4)
	movl	4(%r15,%rdi,4), %eax
	movl	4(%r13,%rdi,4), %ecx
	movl	%ecx, %ebx
	shrl	$31, %ebx
	addl	%ecx, %ebx
	shrl	%ebx
	subl	%ebx, %eax
	movzbl	%al, %eax
	movl	%eax, 4(%r11,%rdi,4)
	addq	$-8, %r9
	addq	$2, %rdi
	cmpq	%rdi, %r10
	jne	LBB0_12
## %bb.13:
	subq	%r9, %r15
	subq	%r9, %r13
	subq	%r9, %r11
	jmp	LBB0_14
LBB0_3:
	leaq	4(%rbx), %r10
	movq	%r10, %rdi
	subq	%r8, %rdi
	addq	$-4, %rdi
	xorl	%r9d, %r9d
	cmpq	$32, %rdi
	jb	LBB0_8
## %bb.4:
	subq	%rax, %r10
	addq	$-4, %r10
	cmpq	$32, %r10
	jb	LBB0_8
## %bb.5:
	movq	%rsi, %r9
	andq	$-8, %r9
	leaq	(%r15,%r9,4), %r15
	leaq	(%r13,%r9,4), %r13
	leaq	(%r11,%r9,4), %r11
	xorl	%edi, %edi
	movdqa	LCPI0_0(%rip), %xmm0            ## xmm0 = [255,0,0,0,255,0,0,0,255,0,0,0,255,0,0,0]
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	movdqu	4(%r8,%rdi,4), %xmm1
	movdqu	20(%r8,%rdi,4), %xmm2
	movdqu	4(%rax,%rdi,4), %xmm3
	movdqu	20(%rax,%rdi,4), %xmm4
	movdqa	%xmm3, %xmm5
	psrld	$31, %xmm5
	paddd	%xmm3, %xmm5
	psrld	$1, %xmm5
	psubd	%xmm5, %xmm1
	movdqa	%xmm4, %xmm3
	psrld	$31, %xmm3
	paddd	%xmm4, %xmm3
	psrld	$1, %xmm3
	psubd	%xmm3, %xmm2
	pand	%xmm0, %xmm1
	pand	%xmm0, %xmm2
	movdqu	%xmm1, 4(%rbx,%rdi,4)
	movdqu	%xmm2, 20(%rbx,%rdi,4)
	addq	$8, %rdi
	cmpq	%rdi, %r9
	jne	LBB0_6
## %bb.7:
	cmpq	%rsi, %r9
	jne	LBB0_8
LBB0_14:
	movq	%rdx, %rcx
	subq	%rsi, %rcx
	jbe	LBB0_28
## %bb.15:
	cmpq	$8, %rcx
	jb	LBB0_16
## %bb.17:
	movq	%r11, %rax
	subq	%r8, %rax
	addq	$-4, %rax
	cmpq	$32, %rax
	jb	LBB0_16
## %bb.18:
	movq	%r11, %rax
	subq	%r15, %rax
	cmpq	$32, %rax
	jb	LBB0_16
## %bb.19:
	movq	%r11, %rax
	subq	%r13, %rax
	cmpq	$32, %rax
	jb	LBB0_16
## %bb.20:
	movq	%rcx, %r12
	andq	$-8, %r12
	addq	%r12, %rsi
	leaq	(%r8,%r12,4), %r9
	leaq	(,%r12,4), %r10
	addq	%r13, %r10
	leaq	(%r11,%r12,4), %r14
	leaq	(%r15,%r12,4), %rbx
	xorl	%eax, %eax
	movdqa	LCPI0_0(%rip), %xmm0            ## xmm0 = [255,0,0,0,255,0,0,0,255,0,0,0,255,0,0,0]
	.p2align	4, 0x90
LBB0_21:                                ## =>This Inner Loop Header: Depth=1
	movdqu	(%r15,%rax,4), %xmm1
	movdqu	16(%r15,%rax,4), %xmm2
	movdqu	(%r13,%rax,4), %xmm3
	movdqu	16(%r13,%rax,4), %xmm4
	movdqu	4(%r8,%rax,4), %xmm5
	paddd	%xmm3, %xmm5
	movdqu	20(%r8,%rax,4), %xmm3
	paddd	%xmm4, %xmm3
	movdqa	%xmm5, %xmm4
	psrld	$31, %xmm4
	paddd	%xmm5, %xmm4
	psrld	$1, %xmm4
	psubd	%xmm4, %xmm1
	movdqa	%xmm3, %xmm4
	psrld	$31, %xmm4
	paddd	%xmm3, %xmm4
	psrld	$1, %xmm4
	psubd	%xmm4, %xmm2
	pand	%xmm0, %xmm1
	pand	%xmm0, %xmm2
	movdqu	%xmm1, (%r11,%rax,4)
	movdqu	%xmm2, 16(%r11,%rax,4)
	addq	$8, %rax
	cmpq	%rax, %r12
	jne	LBB0_21
## %bb.22:
	cmpq	%r12, %rcx
	jne	LBB0_23
	jmp	LBB0_28
LBB0_16:
	movq	%r8, %r9
	movq	%r13, %r10
	movq	%r11, %r14
	movq	%r15, %rbx
LBB0_23:
	movl	%edx, %ecx
	subl	%esi, %ecx
	movq	%rsi, %rax
	notq	%rax
	testb	$1, %cl
	je	LBB0_25
## %bb.24:
	movl	(%rbx), %r8d
	addq	$4, %rbx
	movl	4(%r9), %ecx
	addq	$4, %r9
	addl	(%r10), %ecx
	addq	$4, %r10
	movl	%ecx, %edi
	shrl	$31, %edi
	addl	%ecx, %edi
	shrl	%edi
	subl	%edi, %r8d
	movzbl	%r8b, %ecx
	movl	%ecx, (%r14)
	addq	$4, %r14
	incq	%rsi
LBB0_25:
	addq	%rdx, %rax
	je	LBB0_28
## %bb.26:
	subq	%rsi, %rdx
	xorl	%eax, %eax
	.p2align	4, 0x90
LBB0_27:                                ## =>This Inner Loop Header: Depth=1
	movl	(%rbx,%rax,4), %ecx
	movl	4(%r9,%rax,4), %esi
	addl	(%r10,%rax,4), %esi
	movl	%esi, %edi
	shrl	$31, %edi
	addl	%esi, %edi
	shrl	%edi
	subl	%edi, %ecx
	movzbl	%cl, %ecx
	movl	%ecx, (%r14,%rax,4)
	movl	4(%rbx,%rax,4), %ecx
	movl	8(%r9,%rax,4), %esi
	addl	4(%r10,%rax,4), %esi
	movl	%esi, %edi
	shrl	$31, %edi
	addl	%esi, %edi
	shrl	%edi
	subl	%edi, %ecx
	movzbl	%cl, %ecx
	movl	%ecx, 4(%r14,%rax,4)
	addq	$2, %rax
	cmpq	%rax, %rdx
	jne	LBB0_27
LBB0_28:
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_PNG_FILTER_VALUE_AVG,4,2       ## @PNG_FILTER_VALUE_AVG
	.no_dead_strip	_png_setup_avg_row_only
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function png_setup_avg_row_only
_png_setup_avg_row_only:                ; @png_setup_avg_row_only
	.cfi_startproc
; %bb.0:
Lloh0:
	adrp	x8, _PNG_FILTER_VALUE_AVG@GOTPAGE
Lloh1:
	ldr	x8, [x8, _PNG_FILTER_VALUE_AVG@GOTPAGEOFF]
Lloh2:
	ldr	w9, [x8]
	ldr	x13, [x0, #16]
	mov	x8, x13
	str	w9, [x8], #4
	ldp	x10, x15, [x0]
	add	x11, x15, #4
	add	x9, x10, #4
	cbz	x1, LBB0_5
; %bb.1:
	cmp	x1, #16
	b.hs	LBB0_17
; %bb.2:
	mov	x12, #0
LBB0_3:
	sub	x12, x1, x12
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w13, [x9], #4
	ldr	w14, [x11], #4
	cmp	w14, #0
	cinc	w14, w14, lt
	sub	w13, w13, w14, lsr #1
	and	w13, w13, #0xff
	str	w13, [x8], #4
	subs	x12, x12, #1
	b.ne	LBB0_4
LBB0_5:
	subs	x16, x2, x1
	b.ls	LBB0_16
; %bb.6:
	cmp	x16, #16
	b.lo	LBB0_13
; %bb.7:
	sub	x12, x8, x10
	sub	x12, x12, #4
	cmp	x12, #64
	b.lo	LBB0_13
; %bb.8:
	sub	x12, x8, x9
	cmp	x12, #64
	b.lo	LBB0_13
; %bb.9:
	sub	x12, x8, x11
	cmp	x12, #64
	b.lo	LBB0_13
; %bb.10:
	and	x17, x16, #0xfffffffffffffff0
	add	x1, x17, x1
	lsl	x14, x17, #2
	add	x15, x10, x14
	add	x12, x11, x14
	add	x13, x8, x14
	add	x14, x9, x14
	add	x11, x11, #32
	add	x10, x10, #36
	add	x8, x8, #32
	add	x9, x9, #32
	movi.2d	v0, #0x0000ff000000ff
	mov	x0, x17
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	ldp	q1, q2, [x9, #-32]
	ldp	q3, q4, [x9], #64
	ldp	q5, q6, [x11, #-32]
	ldp	q7, q16, [x11], #64
	ldp	q17, q18, [x10, #-32]
	ldp	q19, q20, [x10], #64
	add.4s	v5, v17, v5
	add.4s	v6, v18, v6
	add.4s	v7, v19, v7
	add.4s	v16, v20, v16
	usra.4s	v5, v5, #31
	sshr.4s	v5, v5, #1
	usra.4s	v6, v6, #31
	sshr.4s	v6, v6, #1
	usra.4s	v7, v7, #31
	sshr.4s	v7, v7, #1
	usra.4s	v16, v16, #31
	sshr.4s	v16, v16, #1
	sub.4s	v1, v1, v5
	sub.4s	v2, v2, v6
	sub.4s	v3, v3, v7
	sub.4s	v4, v4, v16
	and.16b	v1, v1, v0
	and.16b	v2, v2, v0
	and.16b	v3, v3, v0
	and.16b	v4, v4, v0
	stp	q1, q2, [x8, #-32]
	stp	q3, q4, [x8], #64
	subs	x0, x0, #16
	b.ne	LBB0_11
; %bb.12:
	cmp	x16, x17
	b.ne	LBB0_14
	b	LBB0_16
LBB0_13:
	mov	x15, x10
	mov	x12, x11
	mov	x13, x8
	mov	x14, x9
LBB0_14:
	sub	x8, x2, x1
	add	x9, x15, #4
LBB0_15:                                ; =>This Inner Loop Header: Depth=1
	ldr	w10, [x14], #4
	ldr	w11, [x12], #4
	ldr	w15, [x9], #4
	add	w11, w15, w11
	cmp	w11, #0
	cinc	w11, w11, lt
	sub	w10, w10, w11, lsr #1
	and	w10, w10, #0xff
	str	w10, [x13], #4
	subs	x8, x8, #1
	b.ne	LBB0_15
LBB0_16:
	ret
LBB0_17:
	mov	x12, #0
	add	x14, x13, #4
	sub	x16, x14, x10
	sub	x16, x16, #4
	cmp	x16, #64
	b.lo	LBB0_3
; %bb.18:
	sub	x14, x14, x15
	sub	x14, x14, #4
	cmp	x14, #64
	b.lo	LBB0_3
; %bb.19:
	and	x12, x1, #0xfffffffffffffff0
	lsl	x14, x12, #2
	add	x9, x9, x14
	add	x11, x11, x14
	add	x8, x8, x14
	add	x13, x13, #36
	add	x14, x10, #36
	add	x15, x15, #36
	movi.2d	v0, #0x0000ff000000ff
	mov	x16, x12
LBB0_20:                                ; =>This Inner Loop Header: Depth=1
	ldp	q1, q2, [x14, #-32]
	ldp	q3, q4, [x14], #64
	ldp	q5, q6, [x15, #-32]
	ldp	q7, q16, [x15], #64
	usra.4s	v5, v5, #31
	sshr.4s	v5, v5, #1
	usra.4s	v6, v6, #31
	sshr.4s	v6, v6, #1
	usra.4s	v7, v7, #31
	sshr.4s	v7, v7, #1
	usra.4s	v16, v16, #31
	sshr.4s	v16, v16, #1
	sub.4s	v1, v1, v5
	sub.4s	v2, v2, v6
	sub.4s	v3, v3, v7
	sub.4s	v4, v4, v16
	and.16b	v1, v1, v0
	and.16b	v2, v2, v0
	and.16b	v3, v3, v0
	and.16b	v4, v4, v0
	stp	q1, q2, [x13, #-32]
	stp	q3, q4, [x13], #64
	subs	x16, x16, #16
	b.ne	LBB0_20
; %bb.21:
	cmp	x12, x1
	b.ne	LBB0_3
	b	LBB0_5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_PNG_FILTER_VALUE_AVG,4,2       ; @PNG_FILTER_VALUE_AVG
	.no_dead_strip	_png_setup_avg_row_only
.subsections_via_symbols
