	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function shift_codebook
_shift_codebook:                        ## @shift_codebook
	.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
	pushq	%rax
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdx, %r14
	movq	%rsi, %r15
	movq	%rdi, %r13
	movq	8(%rdi), %rax
	movslq	8(%rsi), %rcx
	leaq	(%rax,%rcx,8), %rdx
	.p2align	4, 0x90
LBB0_1:                                 ## =>This Inner Loop Header: Depth=1
	movq	%rdx, %rcx
	movq	(%rdx), %rsi
	leaq	8(%rsi), %rdx
	testq	%rsi, %rsi
	jne	LBB0_1
## %bb.2:
	movslq	(%r15), %rdx
	movq	(%rax,%rdx,8), %rax
	movq	%rax, (%rcx)
	movq	8(%r13), %rax
	movq	$0, (%rax,%rdx,8)
	movq	8(%r13), %rax
	movslq	4(%r15), %rcx
	movq	(%rax,%rcx,8), %rbx
	movq	$0, (%rax,%rcx,8)
	testq	%rbx, %rbx
	je	LBB0_4
	.p2align	4, 0x90
LBB0_3:                                 ## =>This Inner Loop Header: Depth=1
	movq	8(%rbx), %rax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	movslq	(%rbx), %rdi
	movslq	(%r13), %rdx
	imulq	%rdx, %rdi
	addq	16(%r13), %rdi
	movq	(%r14), %rsi
	movq	_INT_MAX@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_distance_limited
	movq	%rax, %r12
	movslq	(%rbx), %rdi
	movslq	(%r13), %rdx
	imulq	%rdx, %rdi
	addq	16(%r13), %rdi
	movq	8(%r14), %rsi
	movq	_INT_MAX@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
                                        ## kill: def $edx killed $edx killed $rdx
	callq	_distance_limited
	xorl	%ecx, %ecx
	cmpq	%rax, %r12
	setg	%cl
	movq	8(%r13), %rax
	movslq	(%r15,%rcx,4), %rcx
	movq	(%rax,%rcx,8), %rdx
	movq	%rdx, 8(%rbx)
	movq	%rbx, (%rax,%rcx,8)
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movq	%rax, %rbx
	testq	%rax, %rax
	jne	LBB0_3
LBB0_4:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_INT_MAX,4,2                    ## @INT_MAX
	.no_dead_strip	_shift_codebook
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function shift_codebook
_shift_codebook:                        ; @shift_codebook
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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
	mov	x19, x2
	mov	x20, x1
	mov	x21, x0
	ldr	x8, [x0, #8]
	ldrsw	x9, [x1, #8]
	add	x10, x8, x9, lsl #3
LBB0_1:                                 ; =>This Inner Loop Header: Depth=1
	mov	x9, x10
	ldr	x11, [x10]
	add	x10, x11, #8
	cbnz	x11, LBB0_1
; %bb.2:
	ldpsw	x10, x11, [x20]
	lsl	x10, x10, #3
	ldr	x8, [x8, x10]
	str	x8, [x9]
	ldr	x8, [x21, #8]
	str	xzr, [x8, x10]
	ldr	x8, [x21, #8]
	lsl	x9, x11, #3
	ldr	x23, [x8, x9]
	str	xzr, [x8, x9]
	cbz	x23, LBB0_5
; %bb.3:
Lloh0:
	adrp	x24, _INT_MAX@GOTPAGE
Lloh1:
	ldr	x24, [x24, _INT_MAX@GOTPAGEOFF]
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x25, [x23, #8]
	ldr	x8, [x21, #16]
	ldrsw	x9, [x23]
	ldrsw	x2, [x21]
	madd	x0, x2, x9, x8
	ldr	x1, [x19]
	ldr	w3, [x24]
                                        ; kill: def $w2 killed $w2 killed $x2
	bl	_distance_limited
	mov	x22, x0
	ldr	x8, [x21, #16]
	ldrsw	x9, [x23]
	ldrsw	x2, [x21]
	madd	x0, x2, x9, x8
	ldr	x1, [x19, #8]
	ldr	w3, [x24]
                                        ; kill: def $w2 killed $w2 killed $x2
	bl	_distance_limited
	cmp	x22, x0
	cset	w8, gt
	ldr	x9, [x21, #8]
	ldrsw	x8, [x20, w8, uxtw #2]
	lsl	x8, x8, #3
	ldr	x10, [x9, x8]
	str	x10, [x23, #8]
	str	x23, [x9, x8]
	mov	x23, x25
	cbnz	x25, LBB0_4
LBB0_5:
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGot	Lloh0, Lloh1
	.cfi_endproc
                                        ; -- End function
	.comm	_INT_MAX,4,2                    ; @INT_MAX
	.no_dead_strip	_shift_codebook
.subsections_via_symbols
