	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_test_word_hashes               ## -- Begin function test_word_hashes
	.p2align	4, 0x90
_test_word_hashes:                      ## @test_word_hashes
	.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	_dyn_cur@GOTPCREL(%rip), %rax
	movq	(%rax), %r15
	addq	$8, %r15
	movq	_PRIME@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	movq	%r15, %rbx
	testl	%eax, %eax
	jle	LBB0_6
## %bb.1:
	xorl	%r12d, %r12d
	movq	_dyn_top@GOTPCREL(%rip), %r14
	movq	%r15, %rbx
	jmp	LBB0_2
	.p2align	4, 0x90
LBB0_5:                                 ##   in Loop: Header=BB0_2 Depth=1
	incq	%r12
	movslq	%eax, %rcx
	cmpq	%rcx, %r12
	jge	LBB0_6
LBB0_2:                                 ## =>This Loop Header: Depth=1
                                        ##     Child Loop BB0_3 Depth 2
	movq	_Words@GOTPCREL(%rip), %rcx
	movq	(%rcx), %rcx
	movq	(%rcx,%r12,8), %r13
	testq	%r13, %r13
	je	LBB0_5
	.p2align	4, 0x90
LBB0_3:                                 ##   Parent Loop BB0_2 Depth=1
                                        ## =>  This Inner Loop Header: Depth=2
	leaq	16(%rbx), %rax
	xorl	%edi, %edi
	cmpq	%rax, (%r14)
	setae	%dil
	callq	_assert
	movl	(%r13), %esi
	movl	4(%r13), %edi
	callq	_crc64
	cltq
	movq	%rax, (%rbx)
	addq	$8, %rbx
	movq	8(%r13), %r13
	testq	%r13, %r13
	jne	LBB0_3
## %bb.4:                               ##   in Loop: Header=BB0_2 Depth=1
	movq	_PRIME@GOTPCREL(%rip), %rax
	movl	(%rax), %eax
	jmp	LBB0_5
LBB0_6:
	subq	%r15, %rbx
	shrq	$3, %rbx
	testl	%ebx, %ebx
	je	LBB0_24
## %bb.7:
	leal	-1(%rbx), %esi
	movq	%r15, %rdi
	callq	_ull_sort
	movl	$1, %r14d
	cmpl	$2, %ebx
	jl	LBB0_19
## %bb.8:
	movl	%ebx, %ecx
	leaq	-1(%rcx), %rax
	cmpq	$2, %rcx
	jne	LBB0_10
## %bb.9:
	movl	$1, %r14d
	movl	$1, %ecx
LBB0_16:
	testb	$1, %al
	je	LBB0_19
## %bb.17:
	movq	(%r15,%rcx,8), %rax
	cmpq	-8(%r15,%rcx,8), %rax
	je	LBB0_19
## %bb.18:
	movslq	%r14d, %rcx
	incl	%r14d
	movq	%rax, (%r15,%rcx,8)
LBB0_19:
	movl	%ebx, %eax
	subl	%r14d, %eax
	movq	_hash_conflicts@GOTPCREL(%rip), %rcx
	movl	%eax, (%rcx)
	movq	_stderr@GOTPCREL(%rip), %r12
	movl	(%r12), %edi
	movslq	%ebx, %rdx
	cvtsi2sd	%r14d, %xmm0
	movslq	%eax, %rcx
	leaq	L_.str(%rip), %rsi
	movsd	%xmm0, -48(%rbp)                ## 8-byte Spill
	movb	$1, %al
	callq	_fprintf
	movq	$-1, -8(%r15)
	movslq	%r14d, %rax
	movq	$0, (%r15,%rax,8)
	testl	%eax, %eax
	jle	LBB0_20
## %bb.21:
	movl	%r14d, %eax
	movq	(%r15), %rdx
	xorl	%ecx, %ecx
	xorl	%ebx, %ebx
	.p2align	4, 0x90
LBB0_22:                                ## =>This Inner Loop Header: Depth=1
	movq	-8(%r15,%rcx,8), %rsi
	xorq	%rdx, %rsi
	movq	8(%r15,%rcx,8), %rdi
	incq	%rcx
	xorq	%rdi, %rdx
	cmpq	%rdx, %rsi
	cmovbq	%rsi, %rdx
	bsrq	%rdx, %rdx
	xorq	$63, %rdx
	addq	%rdx, %rbx
	incq	%rbx
	movq	%rdi, %rdx
	cmpq	%rcx, %rax
	jne	LBB0_22
	jmp	LBB0_23
LBB0_24:
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
LBB0_20:
	xorl	%ebx, %ebx
LBB0_23:
	movq	%r15, %rdi
	movl	%r14d, %esi
	callq	_estimate_opt_pfx_size
	movl	(%r12), %edi
	xorps	%xmm0, %xmm0
	cvtsi2sd	%rbx, %xmm0
	cvtsi2sd	%rax, %xmm1
	movsd	-48(%rbp), %xmm2                ## 8-byte Reload
                                        ## xmm2 = mem[0],zero
	divsd	%xmm2, %xmm0
	divsd	%xmm2, %xmm1
	leaq	L_.str.1(%rip), %rsi
	movq	%rbx, %rdx
	movq	%rax, %rcx
	movb	$2, %al
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_fprintf                        ## TAILCALL
LBB0_10:
	movq	%rax, %rdx
	andq	$-2, %rdx
	negq	%rdx
	movl	$1, %r14d
	movl	$1, %ecx
	jmp	LBB0_11
	.p2align	4, 0x90
LBB0_15:                                ##   in Loop: Header=BB0_11 Depth=1
	leaq	(%rdx,%rcx), %rsi
	addq	$2, %rsi
	addq	$2, %rcx
	cmpq	$1, %rsi
	je	LBB0_16
LBB0_11:                                ## =>This Inner Loop Header: Depth=1
	movq	(%r15,%rcx,8), %rsi
	cmpq	-8(%r15,%rcx,8), %rsi
	je	LBB0_13
## %bb.12:                              ##   in Loop: Header=BB0_11 Depth=1
	movslq	%r14d, %rdi
	incl	%r14d
	movq	%rsi, (%r15,%rdi,8)
LBB0_13:                                ##   in Loop: Header=BB0_11 Depth=1
	movq	8(%r15,%rcx,8), %rsi
	cmpq	(%r15,%rcx,8), %rsi
	je	LBB0_15
## %bb.14:                              ##   in Loop: Header=BB0_11 Depth=1
	movslq	%r14d, %rdi
	incl	%r14d
	movq	%rsi, (%r15,%rdi,8)
	jmp	LBB0_15
	.cfi_endproc
                                        ## -- End function
	.comm	_dyn_cur,8,3                    ## @dyn_cur
	.comm	_PRIME,4,2                      ## @PRIME
	.comm	_Words,8,3                      ## @Words
	.comm	_dyn_top,8,3                    ## @dyn_top
	.comm	_hash_conflicts,4,2             ## @hash_conflicts
	.comm	_stderr,4,2                     ## @stderr
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"%d distinct words, %d distinct word hashes (%d conflicts)\n"

L_.str.1:                               ## @.str.1
	.asciz	"total word hash prefix size %lld, %.3f average; optimal total size %lld, %.3f average\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_test_word_hashes               ; -- Begin function test_word_hashes
	.p2align	2
_test_word_hashes:                      ; @test_word_hashes
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #112
	.cfi_def_cfa_offset 112
	stp	d9, d8, [sp, #16]               ; 16-byte Folded Spill
	stp	x26, x25, [sp, #32]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #48]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #64]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #80]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #96]             ; 16-byte Folded Spill
	add	x29, sp, #96
	.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
	.cfi_offset b8, -88
	.cfi_offset b9, -96
Lloh0:
	adrp	x8, _dyn_cur@GOTPAGE
Lloh1:
	ldr	x8, [x8, _dyn_cur@GOTPAGEOFF]
Lloh2:
	ldr	x8, [x8]
	add	x19, x8, #8
Lloh3:
	adrp	x20, _PRIME@GOTPAGE
Lloh4:
	ldr	x20, [x20, _PRIME@GOTPAGEOFF]
	ldr	w8, [x20]
	cmp	w8, #1
	b.lt	LBB0_6
; %bb.1:
	mov	x21, #0
Lloh5:
	adrp	x22, _Words@GOTPAGE
Lloh6:
	ldr	x22, [x22, _Words@GOTPAGEOFF]
Lloh7:
	adrp	x24, _dyn_top@GOTPAGE
Lloh8:
	ldr	x24, [x24, _dyn_top@GOTPAGEOFF]
	mov	x23, x19
	b	LBB0_3
LBB0_2:                                 ;   in Loop: Header=BB0_3 Depth=1
	add	x21, x21, #1
	cmp	x21, w8, sxtw
	b.ge	LBB0_7
LBB0_3:                                 ; =>This Loop Header: Depth=1
                                        ;     Child Loop BB0_4 Depth 2
	ldr	x9, [x22]
	ldr	x25, [x9, x21, lsl #3]
	cbz	x25, LBB0_2
LBB0_4:                                 ;   Parent Loop BB0_3 Depth=1
                                        ; =>  This Inner Loop Header: Depth=2
	add	x8, x23, #16
	ldr	x9, [x24]
	cmp	x9, x8
	cset	w0, hs
	bl	_assert
	ldp	w1, w0, [x25]
	bl	_crc64
                                        ; kill: def $w0 killed $w0 def $x0
	sxtw	x8, w0
	str	x8, [x23], #8
	ldr	x25, [x25, #8]
	cbnz	x25, LBB0_4
; %bb.5:                                ;   in Loop: Header=BB0_3 Depth=1
	ldr	w8, [x20]
	b	LBB0_2
LBB0_6:
	mov	x23, x19
LBB0_7:
	sub	x21, x23, x19
	lsr	x22, x21, #3
	cbz	w22, LBB0_25
; %bb.8:
	sub	w1, w22, #1
	mov	x0, x19
	bl	_ull_sort
	cmp	w22, #1
	b.le	LBB0_13
; %bb.9:
	add	x8, x19, #8
	mov	w20, #1
	sub	x9, x20, w22, uxtw
	b	LBB0_11
LBB0_10:                                ;   in Loop: Header=BB0_11 Depth=1
	add	x8, x8, #8
	adds	x9, x9, #1
	b.hs	LBB0_14
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	ldp	x11, x10, [x8, #-8]
	cmp	x10, x11
	b.eq	LBB0_10
; %bb.12:                               ;   in Loop: Header=BB0_11 Depth=1
	str	x10, [x19, w20, sxtw #3]
	add	w10, w20, #1
	mov	x20, x10
	b	LBB0_10
LBB0_13:
	mov	w20, #1
LBB0_14:
	sub	w8, w22, w20
Lloh9:
	adrp	x9, _hash_conflicts@GOTPAGE
Lloh10:
	ldr	x9, [x9, _hash_conflicts@GOTPAGEOFF]
Lloh11:
	adrp	x22, _stderr@GOTPAGE
Lloh12:
	ldr	x22, [x22, _stderr@GOTPAGEOFF]
Lloh13:
	str	w8, [x9]
	ldr	w0, [x22]
	sbfx	x2, x21, #3, #32
	scvtf	d8, w20
	sxtw	x3, w8
Lloh14:
	adrp	x1, l_.str@PAGE
Lloh15:
	add	x1, x1, l_.str@PAGEOFF
	fmov	d0, d8
	bl	_fprintf
	mov	x8, #-1
	stur	x8, [x19, #-8]
	str	xzr, [x19, w20, sxtw #3]
	cmp	w20, #1
	b.lt	LBB0_17
; %bb.15:
	mov	w8, w20
	ldr	x10, [x19]
	cmp	w20, #8
	b.hs	LBB0_18
; %bb.16:
	mov	x9, #0
	mov	x21, #0
	b	LBB0_22
LBB0_17:
	mov	x21, #0
	b	LBB0_24
LBB0_18:
	and	x9, x8, #0xfffffff8
	dup.2d	v0, x10
	add	x10, x19, #24
	movi.2d	v1, #0000000000000000
	mov	x11, x9
	movi.2d	v2, #0000000000000000
	movi.2d	v3, #0000000000000000
	movi.2d	v4, #0000000000000000
LBB0_19:                                ; =>This Inner Loop Header: Depth=1
	ldp	q5, q6, [x10, #-32]
	ldp	q7, q16, [x10]
	ext.16b	v17, v0, v6, #8
	ldr	q0, [x10, #32]
	ext.16b	v18, v6, v7, #8
	ext.16b	v19, v7, v16, #8
	ext.16b	v20, v16, v0, #8
	eor.16b	v5, v5, v17
	eor.16b	v21, v6, v18
	eor.16b	v22, v7, v19
	eor.16b	v23, v16, v20
	eor.16b	v6, v6, v17
	eor.16b	v7, v7, v18
	eor.16b	v16, v16, v19
	eor.16b	v17, v0, v20
	cmhi.2d	v18, v6, v5
	bif.16b	v5, v6, v18
	cmhi.2d	v6, v7, v21
	bsl.16b	v6, v21, v7
	cmhi.2d	v7, v16, v22
	bsl.16b	v7, v22, v16
	cmhi.2d	v16, v17, v23
	bsl.16b	v16, v23, v17
	ushr.2d	v17, v5, #1
	orr.16b	v5, v5, v17
	ushr.2d	v17, v5, #2
	orr.16b	v5, v5, v17
	ushr.2d	v17, v5, #4
	orr.16b	v5, v5, v17
	ushr.2d	v17, v5, #8
	orr.16b	v5, v5, v17
	ushr.2d	v17, v5, #16
	orr.16b	v5, v5, v17
	ushr.2d	v17, v5, #32
	orr.16b	v5, v5, v17
	mvn.16b	v5, v5
	ushr.2d	v17, v6, #1
	orr.16b	v6, v6, v17
	ushr.2d	v17, v6, #2
	orr.16b	v6, v6, v17
	cnt.16b	v5, v5
	ushr.2d	v17, v6, #4
	orr.16b	v6, v6, v17
	ushr.2d	v17, v6, #8
	orr.16b	v6, v6, v17
	ushr.2d	v17, v6, #16
	uaddlp.8h	v5, v5
	orr.16b	v6, v6, v17
	ushr.2d	v17, v6, #32
	orr.16b	v6, v6, v17
	mvn.16b	v6, v6
	cnt.16b	v6, v6
	uaddlp.8h	v6, v6
	ushr.2d	v17, v7, #1
	orr.16b	v7, v7, v17
	ushr.2d	v17, v7, #2
	orr.16b	v7, v7, v17
	ushr.2d	v17, v7, #4
	uaddlp.4s	v5, v5
	orr.16b	v7, v7, v17
	ushr.2d	v17, v7, #8
	orr.16b	v7, v7, v17
	ushr.2d	v17, v7, #16
	orr.16b	v7, v7, v17
	uaddlp.4s	v6, v6
	ushr.2d	v17, v7, #32
	orr.16b	v7, v7, v17
	mvn.16b	v7, v7
	cnt.16b	v7, v7
	uaddlp.8h	v7, v7
	uaddlp.4s	v7, v7
	ushr.2d	v17, v16, #1
	orr.16b	v16, v16, v17
	ushr.2d	v17, v16, #2
	orr.16b	v16, v16, v17
	ushr.2d	v17, v16, #4
	uaddlp.2d	v5, v5
	orr.16b	v16, v16, v17
	ushr.2d	v17, v16, #8
	orr.16b	v16, v16, v17
	ushr.2d	v17, v16, #16
	orr.16b	v16, v16, v17
	uaddlp.2d	v6, v6
	ushr.2d	v17, v16, #32
	orr.16b	v16, v16, v17
	mvn.16b	v16, v16
	cnt.16b	v16, v16
	uaddlp.8h	v16, v16
	uaddlp.2d	v7, v7
	uaddlp.4s	v16, v16
	mvn.16b	v1, v1
	sub.2d	v1, v5, v1
	mvn.16b	v2, v2
	sub.2d	v2, v6, v2
	uaddlp.2d	v5, v16
	mvn.16b	v3, v3
	sub.2d	v3, v7, v3
	mvn.16b	v4, v4
	sub.2d	v4, v5, v4
	add	x10, x10, #64
	subs	x11, x11, #8
	b.ne	LBB0_19
; %bb.20:
	add.2d	v1, v2, v1
	add.2d	v1, v3, v1
	add.2d	v1, v4, v1
	addp.2d	d1, v1
	fmov	x21, d1
	cmp	x9, x8
	b.eq	LBB0_24
; %bb.21:
	mov.d	x10, v0[1]
LBB0_22:
	add	x11, x19, x9, lsl #3
	add	x11, x11, #8
	sub	x8, x8, x9
LBB0_23:                                ; =>This Inner Loop Header: Depth=1
	ldur	x9, [x11, #-16]
	eor	x9, x9, x10
	ldr	x12, [x11], #8
	eor	x10, x12, x10
	cmp	x9, x10
	csel	x9, x9, x10, lo
	clz	x9, x9
	add	x9, x21, x9
	add	x21, x9, #1
	mov	x10, x12
	subs	x8, x8, #1
	b.ne	LBB0_23
LBB0_24:
	mov	x0, x19
	mov	x1, x20
	bl	_estimate_opt_pfx_size
	mov	x3, x0
	ldr	w0, [x22]
	scvtf	d0, x21
	fdiv	d0, d0, d8
	scvtf	d1, x3
	fdiv	d1, d1, d8
Lloh16:
	adrp	x1, l_.str.1@PAGE
Lloh17:
	add	x1, x1, l_.str.1@PAGEOFF
	str	d1, [sp]
	mov	x2, x21
	bl	_fprintf
LBB0_25:
	ldp	x29, x30, [sp, #96]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #80]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #64]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #48]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #32]             ; 16-byte Folded Reload
	ldp	d9, d8, [sp, #16]               ; 16-byte Folded Reload
	add	sp, sp, #112
	ret
	.loh AdrpLdrGot	Lloh3, Lloh4
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh7, Lloh8
	.loh AdrpLdrGot	Lloh5, Lloh6
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh11, Lloh12
	.loh AdrpLdrGotStr	Lloh9, Lloh10, Lloh13
	.loh AdrpAdd	Lloh16, Lloh17
	.cfi_endproc
                                        ; -- End function
	.comm	_dyn_cur,8,3                    ; @dyn_cur
	.comm	_PRIME,4,2                      ; @PRIME
	.comm	_Words,8,3                      ; @Words
	.comm	_dyn_top,8,3                    ; @dyn_top
	.comm	_hash_conflicts,4,2             ; @hash_conflicts
	.comm	_stderr,4,2                     ; @stderr
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"%d distinct words, %d distinct word hashes (%d conflicts)\n"

l_.str.1:                               ; @.str.1
	.asciz	"total word hash prefix size %lld, %.3f average; optimal total size %lld, %.3f average\n"

.subsections_via_symbols
