	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function draw_sample_cline_gray
_draw_sample_cline_gray:                ## @draw_sample_cline_gray
	.cfi_startproc
## %bb.0:
	pushq	%rbp
	.cfi_def_cfa_offset 16
	.cfi_offset %rbp, -16
	movq	%rsp, %rbp
	.cfi_def_cfa_register %rbp
	pushq	%rbx
	.cfi_offset %rbx, -24
	testl	%r9d, %r9d
	jle	LBB0_13
## %bb.1:
	subl	%r9d, %esi
	movl	%esi, %eax
	shrl	$31, %eax
	addl	%esi, %eax
	sarl	%eax
	addl	%eax, %r9d
	movslq	%eax, %r11
	movslq	%edx, %rax
	movslq	%r9d, %rcx
	leaq	1(%r11), %rsi
	cmpq	%rcx, %rsi
	movq	%rcx, %r9
	cmovgq	%rsi, %r9
	subq	%r11, %r9
	cmpq	$4, %r9
	jb	LBB0_6
## %bb.2:
	cmpl	$1, %edx
	jne	LBB0_6
## %bb.3:
	leaq	(%rdi,%r11,8), %rdx
	cmpq	%rcx, %rsi
	cmovleq	%rcx, %rsi
	leaq	8(%r8), %rbx
	cmpq	%rbx, %rdx
	jae	LBB0_8
## %bb.4:
	leaq	(%rdi,%rsi,8), %rdx
	cmpq	%r8, %rdx
	jbe	LBB0_8
LBB0_6:
	movq	%r11, %rdx
LBB0_11:
	movq	%rdx, %rsi
	imulq	%rax, %rsi
	leaq	(%rdi,%rsi,8), %rsi
	shlq	$3, %rax
	.p2align	4, 0x90
LBB0_12:                                ## =>This Inner Loop Header: Depth=1
	movq	(%r8), %rdi
	addq	%rdi, (%rsi)
	incq	%rdx
	addq	%rax, %rsi
	cmpq	%rcx, %rdx
	jl	LBB0_12
LBB0_13:
	popq	%rbx
	popq	%rbp
	retq
LBB0_8:
	movq	%r9, %r10
	andq	$-4, %r10
	leaq	(%r10,%r11), %rdx
	movq	(%r8), %xmm0                    ## xmm0 = mem[0],zero
	pshufd	$68, %xmm0, %xmm0               ## xmm0 = xmm0[0,1,0,1]
	imulq	%rax, %r11
	leaq	(%rdi,%r11,8), %rsi
	addq	$16, %rsi
	movq	%rax, %r11
	shlq	$5, %r11
	movq	%r10, %rbx
	.p2align	4, 0x90
LBB0_9:                                 ## =>This Inner Loop Header: Depth=1
	movdqu	-16(%rsi), %xmm1
	movdqu	(%rsi), %xmm2
	paddq	%xmm0, %xmm1
	paddq	%xmm0, %xmm2
	movdqu	%xmm1, -16(%rsi)
	movdqu	%xmm2, (%rsi)
	addq	%r11, %rsi
	addq	$-4, %rbx
	jne	LBB0_9
## %bb.10:
	cmpq	%r10, %r9
	je	LBB0_13
	jmp	LBB0_11
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_draw_sample_cline_gray
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function draw_sample_cline_gray
_draw_sample_cline_gray:                ; @draw_sample_cline_gray
	.cfi_startproc
; %bb.0:
                                        ; kill: def $w2 killed $w2 def $x2
	cmp	w5, #1
	b.lt	LBB0_9
; %bb.1:
	sub	w8, w1, w5
	cmp	w8, #0
	cinc	w8, w8, lt
	add	w11, w5, w8, asr #1
	sbfx	x10, x8, #1, #31
	sxtw	x9, w2
	sxtw	x8, w11
	add	x12, x10, #1
	cmp	x12, x8
	csinc	x11, x8, x10, le
	sub	x11, x11, x10
	cmp	x11, #8
	ccmp	w2, #1, #0, hs
	b.ne	LBB0_7
; %bb.2:
	add	x13, x0, x10, lsl #3
	cmp	x12, x8
	csinc	x12, x8, x10, le
	add	x14, x4, #8
	cmp	x13, x14
	b.hs	LBB0_4
; %bb.3:
	add	x12, x0, x12, lsl #3
	cmp	x12, x4
	b.hi	LBB0_7
LBB0_4:
	and	x12, x11, #0xfffffffffffffff8
	ld1r.2d	{ v0 }, [x4]
	add	x13, x12, x10
	mul	x10, x10, x9
	add	x10, x0, x10, lsl #3
	add	x10, x10, #32
	lsl	x14, x9, #6
	mov	x15, x12
LBB0_5:                                 ; =>This Inner Loop Header: Depth=1
	ldr	d1, [x4]
	dup.2d	v1, v1[0]
	ldp	q2, q3, [x10, #-32]
	ldp	q4, q5, [x10]
	add.2d	v2, v2, v0
	add.2d	v3, v3, v0
	add.2d	v4, v4, v0
	add.2d	v1, v5, v1
	stp	q2, q3, [x10, #-32]
	stp	q4, q1, [x10]
	add	x10, x10, x14
	subs	x15, x15, #8
	b.ne	LBB0_5
; %bb.6:
	mov	x10, x13
	cmp	x11, x12
	b.eq	LBB0_9
LBB0_7:
	mul	x11, x10, x9
	add	x11, x0, x11, lsl #3
	lsl	x9, x9, #3
LBB0_8:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x12, [x4]
	ldr	x13, [x11]
	add	x12, x13, x12
	str	x12, [x11]
	add	x10, x10, #1
	add	x11, x11, x9
	cmp	x10, x8
	b.lt	LBB0_8
LBB0_9:
	ret
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_draw_sample_cline_gray
.subsections_via_symbols
