	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_save_bookmarks                 ## -- Begin function save_bookmarks
	.p2align	4, 0x90
_save_bookmarks:                        ## @save_bookmarks
	.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	$40, %rsp
	.cfi_offset %rbx, -56
	.cfi_offset %r12, -48
	.cfi_offset %r13, -40
	.cfi_offset %r14, -32
	.cfi_offset %r15, -24
	movq	%rdi, -72(%rbp)                 ## 8-byte Spill
	xorl	%eax, %eax
	callq	_clearin
	movq	_index_mode@GOTPCREL(%rip), %rax
	movq	(%rax), %rax
	movq	_ALLOW_OLD_INDEX_MODE@GOTPCREL(%rip), %rcx
	cmpq	(%rcx), %rax
	jle	LBB0_7
## %bb.1:
	movq	_bookmarks_ptr@GOTPCREL(%rip), %rbx
	cmpl	$0, (%rbx)
	je	LBB0_7
## %bb.2:
	sets	%al
	movq	_bookmarks@GOTPCREL(%rip), %r14
	cmpq	$0, (%r14)
	setne	%cl
	andb	%al, %cl
	movzbl	%cl, %edi
	callq	_assert
	movq	_verbosity@GOTPCREL(%rip), %r15
	cmpl	$0, (%r15)
	jle	LBB0_4
## %bb.3:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	xorl	%edx, %edx
	subl	(%rbx), %edx
	leaq	L_.str(%rip), %rsi
	xorl	%eax, %eax
	callq	_fprintf
LBB0_4:
	movslq	(%rbx), %rsi
	movq	%rsi, %rdi
	addq	(%r14), %rdi
	notl	%esi
                                        ## kill: def $esi killed $esi killed $rsi
	callq	_sort_bookmarks
	cmpl	$0, (%r15)
	jle	LBB0_6
## %bb.5:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.1(%rip), %rsi
	xorl	%eax, %eax
	callq	_fprintf
LBB0_6:
	xorl	%eax, %eax
	callq	_build_bookmark_lists
LBB0_7:
	movq	_verbosity@GOTPCREL(%rip), %rax
	cmpl	$0, (%rax)
	jle	LBB0_9
## %bb.8:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.2(%rip), %rsi
	xorl	%eax, %eax
	callq	_fprintf
LBB0_9:
	xorl	%eax, %eax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	xorl	%eax, %eax
	callq	_init_user_iterator
	xorl	%eax, %eax
	callq	_advance_user_iterator
	movl	$0, %ecx
	movq	%rcx, -48(%rbp)                 ## 8-byte Spill
	movl	$0, %r13d
	testq	%rax, %rax
	js	LBB0_17
## %bb.10:
	movl	$1, %ebx
	movq	_MAX_SMALL_BOOKMARK@GOTPCREL(%rip), %r12
	xorl	%r13d, %r13d
	xorl	%eax, %eax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	jmp	LBB0_11
	.p2align	4, 0x90
LBB0_16:                                ##   in Loop: Header=BB0_11 Depth=1
	xorl	%eax, %eax
	callq	_advance_user_iterator
	incl	%ebx
	testq	%rax, %rax
	js	LBB0_17
LBB0_11:                                ## =>This Inner Loop Header: Depth=1
	movq	_user_iterator@GOTPCREL(%rip), %rax
	movl	(%rax), %r14d
	movl	%r14d, %edi
	movl	$-1, %esi
	callq	_get_bookmarks_num
	movl	%eax, %r15d
	movl	%eax, %edi
	notl	%edi
	shrl	$31, %edi
	callq	_assert
	movq	_verbosity@GOTPCREL(%rip), %rax
	cmpl	$4, (%rax)
	jl	LBB0_13
## %bb.12:                              ##   in Loop: Header=BB0_11 Depth=1
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movl	(%r12), %r9d
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	movl	%eax, (%rsp)
	leaq	L_.str.3(%rip), %rsi
	movl	%ebx, %edx
	movl	%r14d, %ecx
	movl	%r15d, %r8d
	xorl	%eax, %eax
	callq	_fprintf
LBB0_13:                                ##   in Loop: Header=BB0_11 Depth=1
	testl	%r15d, %r15d
	je	LBB0_16
## %bb.14:                              ##   in Loop: Header=BB0_11 Depth=1
	setg	%al
	movzbl	%al, %edi
	callq	_assert
	cmpl	(%r12), %r15d
	jg	LBB0_16
## %bb.15:                              ##   in Loop: Header=BB0_11 Depth=1
	movl	%r14d, %edi
	callq	_writeint
	movl	%r13d, %edi
	callq	_writeint
	addl	%r15d, %r13d
	movl	%r13d, %edi
	notl	%edi
	shrl	$31, %edi
	callq	_assert
	movq	-48(%rbp), %rax                 ## 8-byte Reload
	incl	%eax
	movq	%rax, -48(%rbp)                 ## 8-byte Spill
	jmp	LBB0_16
LBB0_17:
	xorl	%edi, %edi
	callq	_writeint
	movl	%r13d, %edi
	callq	_writeint
	xorl	%eax, %eax
	callq	_init_user_iterator
	xorl	%eax, %eax
	callq	_advance_user_iterator
	movl	$0, %r14d
	testq	%rax, %rax
	js	LBB0_25
## %bb.18:
	movq	_user_iterator@GOTPCREL(%rip), %r12
	movq	_MAX_SMALL_BOOKMARK@GOTPCREL(%rip), %r13
	xorl	%r14d, %r14d
	xorl	%eax, %eax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
	jmp	LBB0_19
	.p2align	4, 0x90
LBB0_23:                                ##   in Loop: Header=BB0_19 Depth=1
	movl	%r15d, %edi
	callq	_writeint
	movl	%r14d, %edi
	callq	_writeint
	addl	%ebx, %r14d
	movl	%r14d, %edi
	notl	%edi
	shrl	$31, %edi
	callq	_assert
	movq	-64(%rbp), %rax                 ## 8-byte Reload
	incl	%eax
	movq	%rax, -64(%rbp)                 ## 8-byte Spill
LBB0_24:                                ##   in Loop: Header=BB0_19 Depth=1
	xorl	%eax, %eax
	callq	_advance_user_iterator
	testq	%rax, %rax
	js	LBB0_25
LBB0_19:                                ## =>This Inner Loop Header: Depth=1
	movl	(%r12), %r15d
	movl	%r15d, %edi
	movl	$-1, %esi
	callq	_get_bookmarks_num
	movl	%eax, %ebx
	movl	%eax, %edi
	notl	%edi
	shrl	$31, %edi
	callq	_assert
	testl	%ebx, %ebx
	je	LBB0_24
## %bb.20:                              ##   in Loop: Header=BB0_19 Depth=1
	setg	%al
	movzbl	%al, %edi
	callq	_assert
	cmpl	(%r13), %ebx
	jle	LBB0_24
## %bb.21:                              ##   in Loop: Header=BB0_19 Depth=1
	movq	_ANS_BUFF_SIZE@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ebx
	jle	LBB0_23
## %bb.22:                              ##   in Loop: Header=BB0_19 Depth=1
	movq	_ANS_BUFF_SIZE_SMALLER@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	jmp	LBB0_23
LBB0_25:
	xorl	%eax, %eax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	xorl	%edi, %edi
	callq	_writeint
	movl	%r14d, %edi
	callq	_writeint
	xorl	%eax, %eax
	callq	_init_user_iterator
	xorl	%eax, %eax
	callq	_advance_user_iterator
	testq	%rax, %rax
	js	LBB0_31
## %bb.26:
	movq	_user_iterator@GOTPCREL(%rip), %r12
	movq	_ans_buff@GOTPCREL(%rip), %r15
	movq	_ANS_BUFF_SIZE@GOTPCREL(%rip), %r13
	xorl	%eax, %eax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	jmp	LBB0_27
	.p2align	4, 0x90
LBB0_30:                                ##   in Loop: Header=BB0_27 Depth=1
	xorl	%eax, %eax
	callq	_advance_user_iterator
	testq	%rax, %rax
	js	LBB0_31
LBB0_27:                                ## =>This Inner Loop Header: Depth=1
	movl	(%r12), %r14d
	movl	%r14d, %edi
	movl	$-1, %esi
	callq	_get_bookmarks_num
	movl	%eax, %ebx
	movl	%eax, %edi
	notl	%edi
	shrl	$31, %edi
	callq	_assert
	testl	%ebx, %ebx
	je	LBB0_30
## %bb.28:                              ##   in Loop: Header=BB0_27 Depth=1
	setg	%al
	movzbl	%al, %edi
	callq	_assert
	movq	_MAX_SMALL_BOOKMARK@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ebx
	jg	LBB0_30
## %bb.29:                              ##   in Loop: Header=BB0_27 Depth=1
	movl	(%r15), %esi
	movl	(%r13), %edx
	movl	%r14d, %edi
	callq	_get_bookmarks_packed
	xorl	%edi, %edi
	cmpl	%eax, %ebx
	sete	%dil
	callq	_assert
	xorl	%edi, %edi
	cmpl	(%r13), %ebx
	setle	%dil
	callq	_assert
	movq	-56(%rbp), %rax                 ## 8-byte Reload
	addl	%ebx, %eax
	movq	%rax, -56(%rbp)                 ## 8-byte Spill
	movl	(%r15), %edi
	shll	$3, %ebx
	movl	%ebx, %esi
	callq	_writeout
	jmp	LBB0_30
LBB0_31:
	xorl	%eax, %eax
	callq	_init_user_iterator
	xorl	%eax, %eax
	callq	_advance_user_iterator
	testq	%rax, %rax
	js	LBB0_39
## %bb.32:
	movq	_user_iterator@GOTPCREL(%rip), %r12
	movq	_MAX_SMALL_BOOKMARK@GOTPCREL(%rip), %r15
	movq	_ans_buff@GOTPCREL(%rip), %r14
	jmp	LBB0_33
	.p2align	4, 0x90
LBB0_37:                                ##   in Loop: Header=BB0_33 Depth=1
	movl	(%r14), %esi
	movl	%r13d, %edi
	movl	%ebx, %edx
	callq	_get_bookmarks_packed
	xorl	%edi, %edi
	cmpl	%eax, %ebx
	sete	%dil
	callq	_assert
	xorl	%edi, %edi
	movq	_ANS_BUFF_SIZE@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ebx
	setle	%dil
	callq	_assert
	movl	(%r14), %edi
	shll	$3, %ebx
	movl	%ebx, %esi
	callq	_writeout
LBB0_38:                                ##   in Loop: Header=BB0_33 Depth=1
	xorl	%eax, %eax
	callq	_advance_user_iterator
	testq	%rax, %rax
	js	LBB0_39
LBB0_33:                                ## =>This Inner Loop Header: Depth=1
	movl	(%r12), %r13d
	movl	%r13d, %edi
	movl	$-1, %esi
	callq	_get_bookmarks_num
	movl	%eax, %ebx
	movl	%eax, %edi
	notl	%edi
	shrl	$31, %edi
	callq	_assert
	testl	%ebx, %ebx
	je	LBB0_38
## %bb.34:                              ##   in Loop: Header=BB0_33 Depth=1
	setg	%al
	movzbl	%al, %edi
	callq	_assert
	cmpl	(%r15), %ebx
	jle	LBB0_38
## %bb.35:                              ##   in Loop: Header=BB0_33 Depth=1
	movq	_ANS_BUFF_SIZE@GOTPCREL(%rip), %rax
	cmpl	(%rax), %ebx
	jle	LBB0_37
## %bb.36:                              ##   in Loop: Header=BB0_33 Depth=1
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	movq	_ANS_BUFF_SIZE_SMALLER@GOTPCREL(%rip), %rax
	movl	(%rax), %r8d
	leaq	L_.str.4(%rip), %rsi
	movl	%r13d, %edx
	movl	%ebx, %ecx
	xorl	%eax, %eax
	callq	_fprintf
	movq	_ANS_BUFF_SIZE_SMALLER@GOTPCREL(%rip), %rax
	movl	(%rax), %ebx
	jmp	LBB0_37
LBB0_39:
	xorl	%eax, %eax
	callq	_flushout
	movq	-64(%rbp), %rcx                 ## 8-byte Reload
	movq	-48(%rbp), %rdx                 ## 8-byte Reload
	leal	(%rcx,%rdx), %eax
	leal	8(,%rax,4), %esi
                                        ## kill: def $eax killed $eax killed $rax def $rax
	shll	$2, %eax
	movq	-72(%rbp), %rdi                 ## 8-byte Reload
	movl	%esi, (%rdi)
	movq	-56(%rbp), %rsi                 ## 8-byte Reload
	leal	(%rax,%rsi,8), %eax
	addl	$8, %eax
	movl	%eax, 4(%rdi)
	movl	%edx, 8(%rdi)
	movl	%ecx, 12(%rdi)
	movq	_verbosity@GOTPCREL(%rip), %rax
	cmpl	$0, (%rax)
	je	LBB0_40
## %bb.41:
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str.5(%rip), %rsi
                                        ## kill: def $edx killed $edx killed $rdx
                                        ## kill: def $ecx killed $ecx killed $rcx
	xorl	%eax, %eax
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_fprintf                        ## TAILCALL
LBB0_40:
	addq	$40, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	retq
	.cfi_endproc
                                        ## -- End function
	.comm	_index_mode,8,3                 ## @index_mode
	.comm	_ALLOW_OLD_INDEX_MODE,8,3       ## @ALLOW_OLD_INDEX_MODE
	.comm	_bookmarks_ptr,4,2              ## @bookmarks_ptr
	.comm	_bookmarks,8,3                  ## @bookmarks
	.comm	_verbosity,4,2                  ## @verbosity
	.comm	_stderr,4,2                     ## @stderr
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"sorting %d bookmarks...\n"

L_.str.1:                               ## @.str.1
	.asciz	"building bookmark lists...\n"

L_.str.2:                               ## @.str.2
	.asciz	"writing bookmark lists...\n"

	.comm	_user_iterator,4,2              ## @user_iterator
L_.str.3:                               ## @.str.3
	.asciz	"user #%d: %d, n = %d, max_small = %d, small_cnt = %d\n"

	.comm	_MAX_SMALL_BOOKMARK,4,2         ## @MAX_SMALL_BOOKMARK
	.comm	_ANS_BUFF_SIZE,4,2              ## @ANS_BUFF_SIZE
	.comm	_ANS_BUFF_SIZE_SMALLER,4,2      ## @ANS_BUFF_SIZE_SMALLER
	.comm	_ans_buff,4,2                   ## @ans_buff
L_.str.4:                               ## @.str.4
	.asciz	"user %d: has %d bookmarks, leaving only %d in index\n"

L_.str.5:                               ## @.str.5
	.asciz	"small_users = %d, large_users = %d\n"

.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_save_bookmarks                 ; -- Begin function save_bookmarks
	.p2align	2
_save_bookmarks:                        ; @save_bookmarks
	.cfi_startproc
; %bb.0:
	sub	sp, sp, #144
	.cfi_def_cfa_offset 144
	stp	x28, x27, [sp, #48]             ; 16-byte Folded Spill
	stp	x26, x25, [sp, #64]             ; 16-byte Folded Spill
	stp	x24, x23, [sp, #80]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #96]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #112]            ; 16-byte Folded Spill
	stp	x29, x30, [sp, #128]            ; 16-byte Folded Spill
	add	x29, sp, #128
	.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 w27, -88
	.cfi_offset w28, -96
	str	x0, [sp, #40]                   ; 8-byte Folded Spill
	bl	_clearin
Lloh0:
	adrp	x8, _index_mode@GOTPAGE
Lloh1:
	ldr	x8, [x8, _index_mode@GOTPAGEOFF]
Lloh2:
	ldr	x9, [x8]
Lloh3:
	adrp	x8, _ALLOW_OLD_INDEX_MODE@GOTPAGE
Lloh4:
	ldr	x8, [x8, _ALLOW_OLD_INDEX_MODE@GOTPAGEOFF]
Lloh5:
	ldr	x10, [x8]
Lloh6:
	adrp	x19, _bookmarks_ptr@GOTPAGE
Lloh7:
	ldr	x19, [x19, _bookmarks_ptr@GOTPAGEOFF]
	ldr	w8, [x19]
	cmp	x9, x10
	ccmp	w8, #0, #4, gt
Lloh8:
	adrp	x25, _verbosity@GOTPAGE
Lloh9:
	ldr	x25, [x25, _verbosity@GOTPAGEOFF]
Lloh10:
	adrp	x24, _stderr@GOTPAGE
Lloh11:
	ldr	x24, [x24, _stderr@GOTPAGEOFF]
	b.eq	LBB0_6
; %bb.1:
	cmp	w8, #0
Lloh12:
	adrp	x20, _bookmarks@GOTPAGE
Lloh13:
	ldr	x20, [x20, _bookmarks@GOTPAGEOFF]
	ldr	x8, [x20]
	ccmp	x8, #0, #4, lt
	cset	w0, ne
	bl	_assert
	ldr	w8, [x25]
	cmp	w8, #1
	b.lt	LBB0_3
; %bb.2:
	ldr	w0, [x24]
	ldr	w8, [x19]
	neg	w8, w8
	str	x8, [sp]
Lloh14:
	adrp	x1, l_.str@PAGE
Lloh15:
	add	x1, x1, l_.str@PAGEOFF
	bl	_fprintf
LBB0_3:
	ldr	x8, [x20]
	ldrsw	x9, [x19]
	add	x0, x8, x9
	mvn	w1, w9
	bl	_sort_bookmarks
	ldr	w8, [x25]
	cmp	w8, #1
	b.lt	LBB0_5
; %bb.4:
	ldr	w0, [x24]
Lloh16:
	adrp	x1, l_.str.1@PAGE
Lloh17:
	add	x1, x1, l_.str.1@PAGEOFF
	bl	_fprintf
LBB0_5:
	bl	_build_bookmark_lists
LBB0_6:
	ldr	w8, [x25]
	cmp	w8, #1
	b.lt	LBB0_8
; %bb.7:
	ldr	w0, [x24]
Lloh18:
	adrp	x1, l_.str.2@PAGE
Lloh19:
	add	x1, x1, l_.str.2@PAGEOFF
	bl	_fprintf
LBB0_8:
	bl	_init_user_iterator
	bl	_advance_user_iterator
Lloh20:
	adrp	x27, _user_iterator@GOTPAGE
Lloh21:
	ldr	x27, [x27, _user_iterator@GOTPAGEOFF]
Lloh22:
	adrp	x28, _MAX_SMALL_BOOKMARK@GOTPAGE
Lloh23:
	ldr	x28, [x28, _MAX_SMALL_BOOKMARK@GOTPAGEOFF]
	tbnz	x0, #63, LBB0_16
; %bb.9:
	mov	w20, #0
	mov	w26, #0
	mov	w19, #1
Lloh24:
	adrp	x21, l_.str.3@PAGE
Lloh25:
	add	x21, x21, l_.str.3@PAGEOFF
	b	LBB0_11
LBB0_10:                                ;   in Loop: Header=BB0_11 Depth=1
	bl	_advance_user_iterator
	add	w19, w19, #1
	tbnz	x0, #63, LBB0_17
LBB0_11:                                ; =>This Inner Loop Header: Depth=1
	ldr	w23, [x27]
	mov	x0, x23
	mov	w1, #-1
	bl	_get_bookmarks_num
	mov	x22, x0
	mvn	w8, w0
	lsr	w0, w8, #31
	bl	_assert
	ldr	w8, [x25]
	cmp	w8, #4
	b.lt	LBB0_13
; %bb.12:                               ;   in Loop: Header=BB0_11 Depth=1
	ldr	w0, [x24]
	ldr	w8, [x28]
	stp	x8, x26, [sp, #24]
	stp	x23, x22, [sp, #8]
	str	x19, [sp]
	mov	x1, x21
	bl	_fprintf
LBB0_13:                                ;   in Loop: Header=BB0_11 Depth=1
	cbz	w22, LBB0_10
; %bb.14:                               ;   in Loop: Header=BB0_11 Depth=1
	cmp	w22, #0
	cset	w0, gt
	bl	_assert
	ldr	w8, [x28]
	cmp	w22, w8
	b.gt	LBB0_10
; %bb.15:                               ;   in Loop: Header=BB0_11 Depth=1
	mov	x0, x23
	bl	_writeint
	mov	x0, x20
	bl	_writeint
	add	w20, w22, w20
	mvn	w8, w20
	lsr	w0, w8, #31
	bl	_assert
	add	w26, w26, #1
	b	LBB0_10
LBB0_16:
	mov	w26, #0
	mov	w20, #0
LBB0_17:
	mov	w0, #0
	bl	_writeint
	mov	x0, x20
	bl	_writeint
	bl	_init_user_iterator
	bl	_advance_user_iterator
Lloh26:
	adrp	x19, _ANS_BUFF_SIZE@GOTPAGE
Lloh27:
	ldr	x19, [x19, _ANS_BUFF_SIZE@GOTPAGEOFF]
Lloh28:
	adrp	x24, _ANS_BUFF_SIZE_SMALLER@GOTPAGE
Lloh29:
	ldr	x24, [x24, _ANS_BUFF_SIZE_SMALLER@GOTPAGEOFF]
	tbnz	x0, #63, LBB0_23
; %bb.18:
	mov	w20, #0
	mov	w23, #0
	b	LBB0_20
LBB0_19:                                ;   in Loop: Header=BB0_20 Depth=1
	bl	_advance_user_iterator
	tbnz	x0, #63, LBB0_24
LBB0_20:                                ; =>This Inner Loop Header: Depth=1
	ldr	w21, [x27]
	mov	x0, x21
	mov	w1, #-1
	bl	_get_bookmarks_num
	mov	x22, x0
	mvn	w8, w0
	lsr	w0, w8, #31
	bl	_assert
	cbz	w22, LBB0_19
; %bb.21:                               ;   in Loop: Header=BB0_20 Depth=1
	cmp	w22, #0
	cset	w0, gt
	bl	_assert
	ldr	w8, [x28]
	cmp	w22, w8
	b.le	LBB0_19
; %bb.22:                               ;   in Loop: Header=BB0_20 Depth=1
	ldr	w8, [x19]
	ldr	w9, [x24]
	cmp	w22, w8
	csel	w22, w9, w22, gt
	mov	x0, x21
	bl	_writeint
	mov	x0, x20
	bl	_writeint
	add	w20, w22, w20
	mvn	w8, w20
	lsr	w0, w8, #31
	bl	_assert
	add	w23, w23, #1
	b	LBB0_19
LBB0_23:
	mov	w23, #0
	mov	w20, #0
LBB0_24:
	mov	w0, #0
	bl	_writeint
	mov	x0, x20
	bl	_writeint
	bl	_init_user_iterator
	bl	_advance_user_iterator
Lloh30:
	adrp	x24, _ans_buff@GOTPAGE
Lloh31:
	ldr	x24, [x24, _ans_buff@GOTPAGEOFF]
	mov	w25, #0
	tbz	x0, #63, LBB0_28
LBB0_25:
	bl	_init_user_iterator
	bl	_advance_user_iterator
	tbnz	x0, #63, LBB0_37
; %bb.26:
Lloh32:
	adrp	x20, _ANS_BUFF_SIZE_SMALLER@GOTPAGE
Lloh33:
	ldr	x20, [x20, _ANS_BUFF_SIZE_SMALLER@GOTPAGEOFF]
	b	LBB0_33
LBB0_27:                                ;   in Loop: Header=BB0_28 Depth=1
	bl	_advance_user_iterator
	tbnz	x0, #63, LBB0_25
LBB0_28:                                ; =>This Inner Loop Header: Depth=1
	ldr	w21, [x27]
	mov	x0, x21
	mov	w1, #-1
	bl	_get_bookmarks_num
	mov	x20, x0
	mvn	w8, w0
	lsr	w0, w8, #31
	bl	_assert
	cbz	w20, LBB0_27
; %bb.29:                               ;   in Loop: Header=BB0_28 Depth=1
	cmp	w20, #0
	cset	w0, gt
	bl	_assert
	ldr	w8, [x28]
	cmp	w20, w8
	b.gt	LBB0_27
; %bb.30:                               ;   in Loop: Header=BB0_28 Depth=1
	ldr	w1, [x24]
	ldr	w2, [x19]
	mov	x0, x21
	bl	_get_bookmarks_packed
	cmp	w20, w0
	cset	w0, eq
	bl	_assert
	ldr	w8, [x19]
	cmp	w20, w8
	cset	w0, le
	bl	_assert
	add	w25, w20, w25
	ldr	w0, [x24]
	lsl	w1, w20, #3
	bl	_writeout
	b	LBB0_27
LBB0_31:                                ;   in Loop: Header=BB0_33 Depth=1
	ldr	w1, [x24]
	mov	x0, x22
	mov	x2, x21
	bl	_get_bookmarks_packed
	cmp	w21, w0
	cset	w0, eq
	bl	_assert
	ldr	w8, [x19]
	cmp	w21, w8
	cset	w0, le
	bl	_assert
	ldr	w0, [x24]
	lsl	w1, w21, #3
	bl	_writeout
LBB0_32:                                ;   in Loop: Header=BB0_33 Depth=1
	bl	_advance_user_iterator
	tbnz	x0, #63, LBB0_37
LBB0_33:                                ; =>This Inner Loop Header: Depth=1
	ldr	w22, [x27]
	mov	x0, x22
	mov	w1, #-1
	bl	_get_bookmarks_num
	mov	x21, x0
	mvn	w8, w0
	lsr	w0, w8, #31
	bl	_assert
	cbz	w21, LBB0_32
; %bb.34:                               ;   in Loop: Header=BB0_33 Depth=1
	cmp	w21, #0
	cset	w0, gt
	bl	_assert
	ldr	w8, [x28]
	cmp	w21, w8
	b.le	LBB0_32
; %bb.35:                               ;   in Loop: Header=BB0_33 Depth=1
	ldr	w8, [x19]
	cmp	w21, w8
	b.le	LBB0_31
; %bb.36:                               ;   in Loop: Header=BB0_33 Depth=1
Lloh34:
	adrp	x8, _stderr@GOTPAGE
Lloh35:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh36:
	ldr	w0, [x8]
	ldr	w8, [x20]
	stp	x21, x8, [sp, #8]
	str	x22, [sp]
Lloh37:
	adrp	x1, l_.str.4@PAGE
Lloh38:
	add	x1, x1, l_.str.4@PAGEOFF
	bl	_fprintf
	ldr	w21, [x20]
	b	LBB0_31
LBB0_37:
	bl	_flushout
	add	w8, w23, w26
	lsl	w8, w8, #2
	add	w8, w8, #8
	add	w9, w8, w25, lsl #3
	ldr	x10, [sp, #40]                  ; 8-byte Folded Reload
	stp	w8, w9, [x10]
	stp	w26, w23, [x10, #8]
Lloh39:
	adrp	x8, _verbosity@GOTPAGE
Lloh40:
	ldr	x8, [x8, _verbosity@GOTPAGEOFF]
Lloh41:
	ldr	w8, [x8]
	cbz	w8, LBB0_39
; %bb.38:
Lloh42:
	adrp	x8, _stderr@GOTPAGE
Lloh43:
	ldr	x8, [x8, _stderr@GOTPAGEOFF]
Lloh44:
	ldr	w0, [x8]
                                        ; kill: def $w26 killed $w26 killed $x26 def $x26
	stp	x26, x23, [sp]
Lloh45:
	adrp	x1, l_.str.5@PAGE
Lloh46:
	add	x1, x1, l_.str.5@PAGEOFF
	bl	_fprintf
LBB0_39:
	ldp	x29, x30, [sp, #128]            ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #112]            ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #96]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #80]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp, #64]             ; 16-byte Folded Reload
	ldp	x28, x27, [sp, #48]             ; 16-byte Folded Reload
	add	sp, sp, #144
	ret
	.loh AdrpLdrGot	Lloh10, Lloh11
	.loh AdrpLdrGot	Lloh8, Lloh9
	.loh AdrpLdrGot	Lloh6, Lloh7
	.loh AdrpLdrGotLdr	Lloh3, Lloh4, Lloh5
	.loh AdrpLdrGotLdr	Lloh0, Lloh1, Lloh2
	.loh AdrpLdrGot	Lloh12, Lloh13
	.loh AdrpAdd	Lloh14, Lloh15
	.loh AdrpAdd	Lloh16, Lloh17
	.loh AdrpAdd	Lloh18, Lloh19
	.loh AdrpLdrGot	Lloh22, Lloh23
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpAdd	Lloh24, Lloh25
	.loh AdrpLdrGot	Lloh28, Lloh29
	.loh AdrpLdrGot	Lloh26, Lloh27
	.loh AdrpLdrGot	Lloh30, Lloh31
	.loh AdrpLdrGot	Lloh32, Lloh33
	.loh AdrpAdd	Lloh37, Lloh38
	.loh AdrpLdrGotLdr	Lloh34, Lloh35, Lloh36
	.loh AdrpLdrGotLdr	Lloh39, Lloh40, Lloh41
	.loh AdrpAdd	Lloh45, Lloh46
	.loh AdrpLdrGotLdr	Lloh42, Lloh43, Lloh44
	.cfi_endproc
                                        ; -- End function
	.comm	_index_mode,8,3                 ; @index_mode
	.comm	_ALLOW_OLD_INDEX_MODE,8,3       ; @ALLOW_OLD_INDEX_MODE
	.comm	_bookmarks_ptr,4,2              ; @bookmarks_ptr
	.comm	_bookmarks,8,3                  ; @bookmarks
	.comm	_verbosity,4,2                  ; @verbosity
	.comm	_stderr,4,2                     ; @stderr
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"sorting %d bookmarks...\n"

l_.str.1:                               ; @.str.1
	.asciz	"building bookmark lists...\n"

l_.str.2:                               ; @.str.2
	.asciz	"writing bookmark lists...\n"

	.comm	_user_iterator,4,2              ; @user_iterator
l_.str.3:                               ; @.str.3
	.asciz	"user #%d: %d, n = %d, max_small = %d, small_cnt = %d\n"

	.comm	_MAX_SMALL_BOOKMARK,4,2         ; @MAX_SMALL_BOOKMARK
	.comm	_ANS_BUFF_SIZE,4,2              ; @ANS_BUFF_SIZE
	.comm	_ANS_BUFF_SIZE_SMALLER,4,2      ; @ANS_BUFF_SIZE_SMALLER
	.comm	_ans_buff,4,2                   ; @ans_buff
l_.str.4:                               ; @.str.4
	.asciz	"user %d: has %d bookmarks, leaving only %d in index\n"

l_.str.5:                               ; @.str.5
	.asciz	"small_users = %d, large_users = %d\n"

.subsections_via_symbols
