	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function adjust_dual
_adjust_dual:                           ## @adjust_dual
	.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	%rbx
	.cfi_offset %rbx, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	xorl	%eax, %eax
	cmpq	%rdx, %rdi
	je	LBB0_13
## %bb.1:
	movl	(%rdi), %r11d
	movslq	%esi, %r9
	leaq	(%rdi,%r9,4), %rbx
	cmpq	%rdx, %rbx
	je	LBB0_2
## %bb.3:
	movl	(%rbx), %r10d
	leaq	(,%r9,4), %r14
	movl	%r11d, %esi
	.p2align	4, 0x90
LBB0_4:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%rbx), %r15d
	cmpl	%r10d, %r15d
	cmovll	%r15d, %r10d
	cmpl	%esi, %r15d
	cmovgel	%esi, %r15d
	cmovll	%esi, %r10d
	addq	%r14, %rbx
	movl	%r15d, %esi
	cmpq	%rdx, %rbx
	jne	LBB0_4
	jmp	LBB0_5
LBB0_2:
	leal	1(%r11), %r10d
	movl	%r11d, %r15d
LBB0_5:
	leal	(%r10,%r15), %esi
	addl	$2, %esi
	cmpl	$3, %esi
	jb	LBB0_13
## %bb.6:
	leal	(%r10,%r15), %esi
	leal	(%r10,%r15), %ebx
	incl	%ebx
	shrl	$31, %ebx
	addl	%esi, %ebx
	incl	%ebx
	sarl	%ebx
	cmpl	%r8d, %ebx
	jle	LBB0_9
## %bb.7:
	testl	%ecx, %ecx
	je	LBB0_13
## %bb.8:
	testl	%r8d, %r8d
	jg	LBB0_13
LBB0_9:
	testl	%r10d, %r10d
	sets	%al
	testl	%r8d, %r8d
	setle	%cl
	andb	%al, %cl
	shll	%cl, %ebx
	subl	%ebx, %r11d
	movl	%r11d, (%rdi)
	leaq	(%rdi,%r9,4), %rax
	cmpq	%rdx, %rax
	je	LBB0_12
## %bb.10:
	shlq	$2, %r9
	.p2align	4, 0x90
LBB0_11:                                ## =>This Inner Loop Header: Depth=1
	subl	%ebx, (%rax)
	addq	%r9, %rax
	cmpq	%rdx, %rax
	jne	LBB0_11
LBB0_12:
	cmpl	%r10d, %ebx
	setl	%al
	testl	%r10d, %r10d
	setle	%cl
	andb	%al, %cl
	testl	%r15d, %r15d
	setns	%al
	cmpl	%ebx, %r15d
	setl	%dl
	andb	%al, %dl
	orb	%cl, %dl
	movzbl	%dl, %eax
LBB0_13:
	popq	%rbx
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_adjust_dual
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function adjust_dual
_adjust_dual:                           ; @adjust_dual
	.cfi_startproc
; %bb.0:
                                        ; kill: def $w1 killed $w1 def $x1
	cmp	x0, x2
	b.eq	LBB0_6
; %bb.1:
	ldr	w11, [x0]
	sxtw	x10, w1
	add	x8, x0, w1, sxtw #2
	cmp	x8, x2
	b.eq	LBB0_4
; %bb.2:
	ldr	w9, [x8]
	lsl	x13, x10, #2
	mov	x14, x11
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w12, [x8]
	cmp	w12, w9
	csel	w9, w12, w9, lt
	cmp	w12, w14
	csel	w12, w12, w14, lt
	csel	w9, w14, w9, lt
	add	x8, x8, x13
	cmp	x8, x2
	mov	x14, x12
	b.ne	LBB0_3
	b	LBB0_5
LBB0_4:
	add	w9, w11, #1
	mov	x12, x11
LBB0_5:
	add	w8, w9, w12
	add	w13, w8, #1
	cmp	w13, #0
	add	w13, w8, #2
	csinc	w8, w13, w8, lt
	cmp	w13, #3
	b.hs	LBB0_7
LBB0_6:
	mov	w0, #0
	ret
LBB0_7:
	asr	w13, w8, #1
	cmp	w13, w4
	b.le	LBB0_10
; %bb.8:
	mov	w8, #0
	cbz	w3, LBB0_14
; %bb.9:
	cmp	w4, #0
	b.gt	LBB0_14
LBB0_10:
	cmp	w4, #1
	ccmp	w9, #0, #0, lt
	cset	w8, lt
	lsl	w8, w13, w8
	sub	w11, w11, w8
	str	w11, [x0]
	add	x11, x0, x10, lsl #2
	cmp	x11, x2
	b.eq	LBB0_13
; %bb.11:
	lsl	x10, x10, #2
LBB0_12:                                ; =>This Inner Loop Header: Depth=1
	ldr	w13, [x11]
	sub	w13, w13, w8
	str	w13, [x11]
	add	x11, x11, x10
	cmp	x11, x2
	b.ne	LBB0_12
LBB0_13:
	cmp	w9, #1
	ccmp	w8, w9, #0, lt
	cset	w9, lt
	cmp	w12, #0
	ccmp	w12, w8, #0, ge
	cset	w8, lt
	orr	w8, w9, w8
LBB0_14:
	mov	x0, x8
	ret
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_adjust_dual
.subsections_via_symbols
