	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_trie_encode                    ## -- Begin function trie_encode
	.p2align	4, 0x90
_trie_encode:                           ## @trie_encode
	.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
	movl	%edx, %r14d
	movq	%rsi, %r15
	movq	%rdi, %rbx
	xorl	%r13d, %r13d
	xorl	%edi, %edi
	callq	_assert
	testq	%rbx, %rbx
	je	LBB0_10
## %bb.1:
	movq	%rbx, %rax
	.p2align	4, 0x90
LBB0_2:                                 ## =>This Inner Loop Header: Depth=1
	cmpq	$1, 24(%rax)
	movq	8(%rax), %rcx
	sbbl	$-1, %r13d
	movq	%rcx, %rax
	testq	%rcx, %rcx
	jne	LBB0_2
## %bb.3:
	movl	%r13d, %eax
	leaq	(%r15,%rax,8), %r12
	addq	$12, %r12
	testq	%rbx, %rbx
	je	LBB0_9
## %bb.4:
	movl	%r14d, -44(%rbp)                ## 4-byte Spill
	xorl	%r14d, %r14d
	jmp	LBB0_5
	.p2align	4, 0x90
LBB0_7:                                 ##   in Loop: Header=BB0_5 Depth=1
	movq	8(%rbx), %rbx
	testq	%rbx, %rbx
	je	LBB0_8
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	cmpq	$0, 24(%rbx)
	je	LBB0_7
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	movl	(%rbx), %eax
	movq	(%r15), %rcx
	leal	(%r14,%r14), %edx
	leal	(%r14,%r14), %esi
	incl	%esi
	movslq	%esi, %rsi
	movl	%eax, (%rcx,%rsi,4)
	movl	%r12d, %eax
	subl	%r15d, %eax
	movslq	%edx, %rdx
	movl	%eax, (%rcx,%rdx,4)
	movq	16(%rbx), %rdi
	movl	4(%rbx), %edx
	movq	%r12, %rsi
	callq	_trie_encode
	addq	%rax, %r12
	incl	%r14d
	jmp	LBB0_7
LBB0_10:
	leaq	12(%r15), %r12
	xorl	%r13d, %r13d
	jmp	LBB0_9
LBB0_8:
	movl	-44(%rbp), %r14d                ## 4-byte Reload
LBB0_9:
	movq	(%r15), %rdi
	movq	_cmp_tx@GOTPCREL(%rip), %rax
	movl	(%rax), %ecx
	movl	%r13d, %esi
	movl	$8, %edx
	callq	_qsort
	movl	%r13d, 8(%r15)
	movl	%r14d, 12(%r15)
	subq	%r15, %r12
	movq	%r12, %rax
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_cmp_tx,4,2                     ## @cmp_tx
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_trie_encode                    ; -- Begin function trie_encode
	.p2align	2
_trie_encode:                           ; @trie_encode
	.cfi_startproc
; %bb.0:
	stp	x24, x23, [sp, #-64]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 64
	stp	x22, x21, [sp, #16]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #32]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #48]             ; 16-byte Folded Spill
	add	x29, sp, #48
	.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
	mov	x20, x2
	mov	x19, x1
	mov	x23, x0
	mov	w0, #0
	bl	_assert
	mov	w21, #0
	cbz	x23, LBB0_8
; %bb.1:
	mov	x8, x23
LBB0_2:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x9, [x8, #24]
	cmp	x9, #0
	cinc	w21, w21, ne
	ldr	x8, [x8, #8]
	cbnz	x8, LBB0_2
; %bb.3:
	add	x8, x19, w21, uxtw #3
	add	x22, x8, #12
	cbz	x23, LBB0_9
; %bb.4:
	mov	w24, #0
	b	LBB0_6
LBB0_5:                                 ;   in Loop: Header=BB0_6 Depth=1
	ldr	x23, [x23, #8]
	cbz	x23, LBB0_9
LBB0_6:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x23, #24]
	cbz	x8, LBB0_5
; %bb.7:                                ;   in Loop: Header=BB0_6 Depth=1
	ldr	w8, [x23]
	ldr	x9, [x19]
	lsl	w10, w24, #1
	add	x10, x9, w10, sxtw #2
	str	w8, [x10, #4]
	sub	w8, w22, w19
	sbfiz	x10, x24, #3, #32
	str	w8, [x9, x10]
	ldr	x0, [x23, #16]
	ldr	w2, [x23, #4]
	mov	x1, x22
	bl	_trie_encode
	add	x22, x22, x0
	add	w24, w24, #1
	b	LBB0_5
LBB0_8:
	add	x22, x19, #12
LBB0_9:
	ldr	x0, [x19]
Lloh0:
	adrp	x8, _cmp_tx@GOTPAGE
Lloh1:
	ldr	x8, [x8, _cmp_tx@GOTPAGEOFF]
Lloh2:
	ldr	w3, [x8]
	mov	x1, x21
	mov	w2, #8
	bl	_qsort
	stp	w21, w20, [x19, #8]
	sub	x0, x22, x19
	ldp	x29, x30, [sp, #48]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #32]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #16]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp], #64             ; 16-byte Folded Reload
	ret
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.cfi_endproc
                                        ; -- End function
	.comm	_cmp_tx,4,2                     ; @cmp_tx
.subsections_via_symbols
