	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	4, 0x90                         ## -- Begin function rbt_populate
_rbt_populate:                          ## @rbt_populate
	.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
	subq	$24, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movl	%edx, %ebx
	movl	%esi, %r12d
	movq	%rdi, %r15
	movl	%esi, %edi
	callq	_GetPermutation
	movq	%rax, %r14
	testl	%r12d, %r12d
	jle	LBB0_7
## %bb.1:
	movl	%r12d, %r12d
	xorl	%r13d, %r13d
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_4:                                 ##   in Loop: Header=BB0_2 Depth=1
	incq	%r13
	cmpq	%r13, %r12
	je	LBB0_5
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	movl	(%r14,%r13,4), %eax
	imull	%ebx, %eax
	movl	%eax, -48(%rbp)
	movq	%r15, %rdi
	leaq	-48(%rbp), %rsi
	leaq	-52(%rbp), %rdx
	callq	_rbt_insert
	cmpl	$0, -52(%rbp)
	jne	LBB0_4
## %bb.3:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	callq	_elog
	jmp	LBB0_4
LBB0_5:
	imull	(%r14), %ebx
	movl	%ebx, -48(%rbp)
	leaq	-48(%rbp), %rsi
	leaq	-52(%rbp), %rdx
	movq	%r15, %rdi
	callq	_rbt_insert
	cmpl	$0, -52(%rbp)
	je	LBB0_7
## %bb.6:
	movq	_ERROR@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.1(%rip), %rsi
	callq	_elog
LBB0_7:
	movq	%r14, %rdi
	callq	_pfree
	addq	$24, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_ERROR,4,2                      ## @ERROR
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"unexpected !isNew result from rbt_insert"

L_.str.1:                               ## @.str.1
	.asciz	"unexpected isNew result from rbt_insert"

	.no_dead_strip	_rbt_populate
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.p2align	2                               ; -- Begin function rbt_populate
_rbt_populate:                          ; @rbt_populate
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #96
	.cfi_def_cfa_offset 96
	stp	x26, x25, [sp, #16]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #32]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #48]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #64]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #80]             ; 16-byte Folded Spill
	add	x29, sp, #80
	.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	x21, x2
	mov	x22, x1
	mov	x20, x0
	mov	x0, x1
	bl	_GetPermutation
	mov	x19, x0
	cmp	w22, #1
	b.lt	LBB0_7
; %bb.1:
	mov	x24, #0
	mov	w8, w22
	lsl	x25, x8, #2
Lloh0:
	adrp	x23, _ERROR@GOTPAGE
Lloh1:
	ldr	x23, [x23, _ERROR@GOTPAGEOFF]
Lloh2:
	adrp	x22, l_.str@PAGE
Lloh3:
	add	x22, x22, l_.str@PAGEOFF
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	x24, x24, #4
	cmp	x25, x24
	b.eq	LBB0_5
LBB0_3:                                 ; =>This Inner Loop Header: Depth=1
	ldr	w8, [x19, x24]
	mul	w8, w8, w21
	str	w8, [sp, #8]
	add	x1, sp, #8
	add	x2, sp, #4
	mov	x0, x20
	bl	_rbt_insert
	ldr	w8, [sp, #4]
	cbnz	w8, LBB0_2
; %bb.4:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w0, [x23]
	mov	x1, x22
	bl	_elog
	b	LBB0_2
LBB0_5:
	ldr	w8, [x19]
	mul	w8, w8, w21
	str	w8, [sp, #8]
	add	x1, sp, #8
	add	x2, sp, #4
	mov	x0, x20
	bl	_rbt_insert
	ldr	w8, [sp, #4]
	cbz	w8, LBB0_7
; %bb.6:
	ldr	w0, [x23]
Lloh4:
	adrp	x1, l_.str.1@PAGE
Lloh5:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_elog
LBB0_7:
	mov	x0, x19
	bl	_pfree
	ldp	x29, x30, [sp, #80]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #64]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #48]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #32]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #16]             ; 16-byte Folded Reload
	add	sp, sp, #96
	ret
	.loh AdrpAdd	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpAdd	Lloh4, Lloh5
	.cfi_endproc
                                        ; -- End function
	.comm	_ERROR,4,2                      ; @ERROR
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"unexpected !isNew result from rbt_insert"

l_.str.1:                               ; @.str.1
	.asciz	"unexpected isNew result from rbt_insert"

	.no_dead_strip	_rbt_populate
.subsections_via_symbols
