	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function insert_into_history
_insert_into_history:                   ## @insert_into_history
	.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	_mips_relax@GOTPCREL(%rip), %rax
	cmpl	$2, (%rax)
	je	LBB0_7
## %bb.1:
	movq	%rdx, %r13
	movl	%esi, %r14d
	movl	%edi, %r15d
	movq	_history@GOTPCREL(%rip), %r12
	movq	(%r12), %rdi
	callq	_ARRAY_SIZE
	movl	%eax, %edi
	subl	%r15d, %edi
	jbe	LBB0_7
## %bb.2:
	leal	(%r14,%r15), %ecx
	movq	(%r12), %rdx
	movl	%eax, %esi
	leal	1(%r15), %r8d
	testb	$1, %dil
	je	LBB0_4
## %bb.3:
	decq	%rsi
	movl	%esi, %edi
	subl	%r14d, %edi
	cmpl	%esi, %ecx
	leaq	(%rdx,%rdi,4), %rdi
	cmovaq	%r13, %rdi
	movl	%esi, %r9d
	movl	(%rdi), %edi
	movl	%edi, (%rdx,%r9,4)
LBB0_4:
	cmpl	%r8d, %eax
	je	LBB0_7
## %bb.5:
	addq	$-2, %rsi
	movl	$-2, %r8d
	subl	%r14d, %r8d
	notl	%r14d
	movq	%rsi, %rdi
	.p2align	4, 0x90
LBB0_6:                                 ## =>This Inner Loop Header: Depth=1
	leal	1(%rsi), %eax
	cmpl	%eax, %ecx
	leal	2(%r14,%rsi), %ebx
	leaq	(%rdx,%rbx,4), %rbx
	cmovaq	%r13, %rbx
	movl	(%rbx), %ebx
	movl	%ebx, (%rdx,%rax,4)
	addq	$-2, %rdi
	leal	2(%rdi), %eax
	cmpl	%eax, %ecx
	leal	2(%r8,%rsi), %ebx
	leaq	(%rdx,%rbx,4), %rbx
	cmovaq	%r13, %rbx
	movl	%esi, %esi
	movl	(%rbx), %ebx
	movl	%ebx, (%rdx,%rsi,4)
	movq	%rdi, %rsi
	cmpl	%r15d, %eax
	ja	LBB0_6
LBB0_7:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_mips_relax,4,2                 ## @mips_relax
	.comm	_history,8,3                    ## @history
	.no_dead_strip	_insert_into_history
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function insert_into_history
_insert_into_history:                   ; @insert_into_history
	.cfi_startproc
; %bb.0:
	stp	x22, x21, [sp, #-48]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 48
	stp	x20, x19, [sp, #16]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #32]             ; 16-byte Folded Spill
	add	x29, sp, #32
	.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
Lloh0:
	adrp	x8, _mips_relax@GOTPAGE
Lloh1:
	ldr	x8, [x8, _mips_relax@GOTPAGEOFF]
Lloh2:
	ldr	w8, [x8]
	cmp	w8, #2
	b.eq	LBB0_4
; %bb.1:
	mov	x19, x2
	mov	x21, x1
	mov	x20, x0
Lloh3:
	adrp	x22, _history@GOTPAGE
Lloh4:
	ldr	x22, [x22, _history@GOTPAGEOFF]
	ldr	x0, [x22]
	bl	_ARRAY_SIZE
	cmp	w0, w20
	b.ls	LBB0_4
; %bb.2:
	add	w8, w21, w20
	ldr	x9, [x22]
	sub	w10, w0, #1
	add	x10, x9, w10, uxtw #2
	mvn	w11, w21
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	add	w12, w11, w0
	sub	w13, w0, #1
	add	x12, x9, w12, uxtw #2
	cmp	w8, w13
	csel	x12, x19, x12, hi
	ldr	w12, [x12]
	str	w12, [x10], #-4
	mov	x0, x13
	cmp	w13, w20
	b.hi	LBB0_3
LBB0_4:
	ldp	x29, x30, [sp, #32]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #16]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp], #48             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh3, Lloh4
	.cfi_endproc
                                        ; -- End function
	.comm	_mips_relax,4,2                 ; @mips_relax
	.comm	_history,8,3                    ; @history
	.no_dead_strip	_insert_into_history
.subsections_via_symbols
