	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function heap_sift
_heap_sift:                             ## @heap_sift
	.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
	movl	$1, %r10d
	cmpq	$2, %rsi
	jl	LBB0_8
## %bb.1:
	movq	(%rdi,%rdx,8), %r8
	movl	$1, %r9d
	movl	$2, %eax
	movl	$2, %ebx
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movq	(%rdi,%rbx,8), %rcx
	movq	(%rdi,%rcx,8), %r11
	cmpq	%rsi, %rbx
	jge	LBB0_3
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movl	%eax, %ecx
	orl	$1, %ecx
	movslq	%ecx, %r10
	movq	(%rdi,%r10,8), %rcx
	movq	(%rdi,%rcx,8), %rcx
	cmpq	%r11, %rcx
	cmovgel	%eax, %r10d
	cmovlq	%rcx, %r11
	cmpq	%r8, %r11
	jl	LBB0_7
	jmp	LBB0_6
	.p2align	4, 0x90
LBB0_3:                                 ##   in Loop: Header=BB0_2 Depth=1
	movl	%eax, %r10d
	cmpq	%r8, %r11
	jge	LBB0_6
LBB0_7:                                 ##   in Loop: Header=BB0_2 Depth=1
	movslq	%r10d, %rax
	movq	(%rdi,%rax,8), %rcx
	movslq	%r9d, %rbx
	movq	%rcx, (%rdi,%rbx,8)
	addl	%eax, %eax
	movslq	%eax, %rbx
	movl	%r10d, %r9d
	cmpq	%rsi, %rbx
	jle	LBB0_2
	jmp	LBB0_8
LBB0_6:
	movl	%r9d, %r10d
LBB0_8:
	movslq	%r10d, %rax
	movq	%rdx, (%rdi,%rax,8)
	popq	%rbx
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.no_dead_strip	_heap_sift
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function heap_sift
_heap_sift:                             ; @heap_sift
	.cfi_startproc
; %bb.0:
	cmp	x1, #2
	b.ge	LBB0_2
; %bb.1:
	mov	w10, #1
	str	x2, [x0, w10, sxtw #3]
	ret
LBB0_2:
	ldr	x8, [x0, x2, lsl #3]
	mov	w9, #1
	mov	w13, #2
	mov	x11, x13
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x10, [x0, x13, lsl #3]
	ldr	x12, [x0, x10, lsl #3]
	cmp	x13, x1
	b.ge	LBB0_5
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	orr	w10, w11, #0x1
	ldr	x13, [x0, w10, sxtw #3]
	ldr	x13, [x0, x13, lsl #3]
	cmp	x13, x12
	csel	x12, x13, x12, lt
	csel	w10, w10, w11, lt
	cmp	x12, x8
	b.lt	LBB0_6
	b	LBB0_8
LBB0_5:                                 ;   in Loop: Header=BB0_3 Depth=1
	mov	x10, x11
	cmp	x12, x8
	b.ge	LBB0_8
LBB0_6:                                 ;   in Loop: Header=BB0_3 Depth=1
	ldr	x11, [x0, w10, sxtw #3]
	str	x11, [x0, w9, sxtw #3]
	lsl	w11, w10, #1
	sxtw	x13, w11
	mov	x9, x10
	cmp	x13, x1
	b.le	LBB0_3
; %bb.7:
	str	x2, [x0, w10, sxtw #3]
	ret
LBB0_8:
	str	x2, [x0, w9, sxtw #3]
	ret
	.cfi_endproc
                                        ; -- End function
	.no_dead_strip	_heap_sift
.subsections_via_symbols
