	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_sum_vector_on_end              ## -- Begin function sum_vector_on_end
	.p2align	4, 0x90
_sum_vector_on_end:                     ## @sum_vector_on_end
	.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	%rdi, %r15
	movq	16(%rdi), %rbx
	callq	_merge_init_response
	testq	%rax, %rax
	js	LBB0_1
## %bb.3:
	movq	%rbx, -48(%rbp)                 ## 8-byte Spill
	movl	(%rbx), %edi
	andl	$7, %edi
	callq	_clear_gather_heap
	cmpl	$0, (%r15)
	jle	LBB0_11
## %bb.4:
	movl	$8, %ebx
	xorl	%r13d, %r13d
	movq	_received_bad_answers@GOTPCREL(%rip), %r14
	movq	_verbosity@GOTPCREL(%rip), %r12
	jmp	LBB0_5
	.p2align	4, 0x90
LBB0_10:                                ##   in Loop: Header=BB0_5 Depth=1
	incq	%r13
	movslq	(%r15), %rax
	addq	$16, %rbx
	cmpq	%rax, %r13
	jge	LBB0_11
LBB0_5:                                 ## =>This Inner Loop Header: Depth=1
	movq	8(%r15), %rax
	movq	-8(%rax,%rbx), %rcx
	testq	%rcx, %rcx
	js	LBB0_8
## %bb.6:                               ##   in Loop: Header=BB0_5 Depth=1
	movl	(%rax,%rbx), %edi
	movq	%rcx, %rsi
	callq	_gather_heap_insert
	testl	%eax, %eax
	jns	LBB0_10
## %bb.7:                               ##   in Loop: Header=BB0_5 Depth=1
	incl	(%r14)
	jmp	LBB0_10
	.p2align	4, 0x90
LBB0_8:                                 ##   in Loop: Header=BB0_5 Depth=1
	cmpl	$4, (%r12)
	jl	LBB0_10
## %bb.9:                               ##   in Loop: Header=BB0_5 Depth=1
	movq	_stderr@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	leaq	L_.str(%rip), %rsi
	movl	%r13d, %edx
	callq	_fprintf
	jmp	LBB0_10
LBB0_11:
	movq	_TL_VECTOR_TOTAL@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_tl_store_int
	movq	_GH_total@GOTPCREL(%rip), %rax
	movl	(%rax), %edi
	callq	_tl_store_int
	xorl	%eax, %eax
	callq	_get_gather_heap_head
	testq	%rax, %rax
	movq	-48(%rbp), %r14                 ## 8-byte Reload
	je	LBB0_19
## %bb.12:
	movl	$-2, %ebx
	movq	_R@GOTPCREL(%rip), %r13
	movq	_MAX_RES@GOTPCREL(%rip), %r12
	jmp	LBB0_13
	.p2align	4, 0x90
LBB0_16:                                ##   in Loop: Header=BB0_13 Depth=1
	movslq	%ebx, %rsi
	addl	$2, %ebx
	movq	%rdx, 16(%rcx,%rsi,8)
	movq	8(%rax), %rax
	movq	%rax, 24(%rcx,%rsi,8)
	cmpl	(%r12), %ebx
	jge	LBB0_18
LBB0_17:                                ##   in Loop: Header=BB0_13 Depth=1
	xorl	%eax, %eax
	callq	_gather_heap_advance
	xorl	%eax, %eax
	callq	_get_gather_heap_head
	testq	%rax, %rax
	je	LBB0_18
LBB0_13:                                ## =>This Inner Loop Header: Depth=1
	movq	(%rax), %rdx
	movq	(%r13), %rcx
	testl	%ebx, %ebx
	js	LBB0_16
## %bb.14:                              ##   in Loop: Header=BB0_13 Depth=1
	movl	%ebx, %esi
	cmpq	(%rcx,%rsi,8), %rdx
	jne	LBB0_16
## %bb.15:                              ##   in Loop: Header=BB0_13 Depth=1
	movq	8(%rax), %rax
	addq	%rax, 8(%rcx,%rsi,8)
	jmp	LBB0_17
LBB0_18:
	testl	%ebx, %ebx
	js	LBB0_19
## %bb.20:
	addl	$2, %ebx
	movl	(%r14), %eax
	testb	$1, %al
	jne	LBB0_22
## %bb.21:
	shrl	%ebx
	jmp	LBB0_26
LBB0_1:
	movq	%rbx, %rdi
	jmp	LBB0_2
LBB0_19:
	xorl	%edi, %edi
	callq	_tl_store_int
	jmp	LBB0_27
LBB0_22:
	movq	(%r13), %rdi
	shrl	%ebx
	testb	$4, %al
	jne	LBB0_23
## %bb.24:
	movq	_cmpd@GOTPCREL(%rip), %rax
	jmp	LBB0_25
LBB0_23:
	movq	_cmp@GOTPCREL(%rip), %rax
LBB0_25:
	movl	(%rax), %ecx
	movl	%ebx, %esi
	movl	$8, %edx
	callq	_qsort
LBB0_26:
	movl	4(%r14), %r12d
	cmpl	%r12d, %ebx
	cmovll	%ebx, %r12d
	movl	%r12d, %edi
	callq	_tl_store_int
	movq	(%r13), %rdi
	shll	$3, %r12d
	movl	%r12d, %esi
	callq	_tl_store_raw_data
LBB0_27:
	xorl	%eax, %eax
	callq	_tl_store_end
	movq	%r14, %rdi
LBB0_2:
	movl	$8, %esi
	callq	_zfree
	movq	%r15, %rdi
	addq	$8, %rsp
	popq	%rbx
	popq	%r12
	popq	%r13
	popq	%r14
	popq	%r15
	popq	%rbp
	jmp	_merge_delete                   ## TAILCALL
	.cfi_endproc
                                        ## -- End function
	.comm	_received_bad_answers,4,2       ## @received_bad_answers
	.comm	_verbosity,4,2                  ## @verbosity
	.comm	_stderr,4,2                     ## @stderr
	.section	__TEXT,__cstring,cstring_literals
L_.str:                                 ## @.str
	.asciz	"Dropping result %d (num = %d)\n"

	.comm	_TL_VECTOR_TOTAL,4,2            ## @TL_VECTOR_TOTAL
	.comm	_GH_total,4,2                   ## @GH_total
	.comm	_R,8,3                          ## @R
	.comm	_MAX_RES,4,2                    ## @MAX_RES
	.comm	_cmp,4,2                        ## @cmp
	.comm	_cmpd,4,2                       ## @cmpd
.subsections_via_symbols

	.section	__TEXT,__text,regular,pure_instructions
	.build_version macos, 13, 0	sdk_version 13, 3
	.globl	_sum_vector_on_end              ; -- Begin function sum_vector_on_end
	.p2align	2
_sum_vector_on_end:                     ; @sum_vector_on_end
	.cfi_startproc
; %bb.0:
	stp	x26, x25, [sp, #-80]!           ; 16-byte Folded Spill
	.cfi_def_cfa_offset 80
	stp	x24, x23, [sp, #16]             ; 16-byte Folded Spill
	stp	x22, x21, [sp, #32]             ; 16-byte Folded Spill
	stp	x20, x19, [sp, #48]             ; 16-byte Folded Spill
	stp	x29, x30, [sp, #64]             ; 16-byte Folded Spill
	add	x29, sp, #64
	.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	x19, x0
	ldr	x20, [x0, #16]
	bl	_merge_init_response
	tbnz	x0, #63, LBB0_23
; %bb.1:
	ldr	w8, [x20]
	and	w0, w8, #0x7
	bl	_clear_gather_heap
	ldr	w8, [x19]
	cmp	w8, #1
	b.lt	LBB0_9
; %bb.2:
	mov	x23, #0
	mov	x21, #0
Lloh0:
	adrp	x24, _received_bad_answers@GOTPAGE
Lloh1:
	ldr	x24, [x24, _received_bad_answers@GOTPAGEOFF]
Lloh2:
	adrp	x25, _verbosity@GOTPAGE
Lloh3:
	ldr	x25, [x25, _verbosity@GOTPAGEOFF]
Lloh4:
	adrp	x26, _stderr@GOTPAGE
Lloh5:
	ldr	x26, [x26, _stderr@GOTPAGEOFF]
Lloh6:
	adrp	x22, l_.str@PAGE
Lloh7:
	add	x22, x22, l_.str@PAGEOFF
	b	LBB0_4
LBB0_3:                                 ;   in Loop: Header=BB0_4 Depth=1
	add	x21, x21, #1
	ldrsw	x8, [x19]
	add	x23, x23, #16
	cmp	x21, x8
	b.ge	LBB0_9
LBB0_4:                                 ; =>This Inner Loop Header: Depth=1
	ldr	x8, [x19, #8]
	ldr	x3, [x8, x23]
	tbnz	x3, #63, LBB0_7
; %bb.5:                                ;   in Loop: Header=BB0_4 Depth=1
	add	x8, x8, x23
	ldr	w0, [x8, #8]
	mov	x1, x3
	bl	_gather_heap_insert
	tbz	w0, #31, LBB0_3
; %bb.6:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	w8, [x24]
	add	w8, w8, #1
	str	w8, [x24]
	b	LBB0_3
LBB0_7:                                 ;   in Loop: Header=BB0_4 Depth=1
	ldr	w8, [x25]
	cmp	w8, #4
	b.lt	LBB0_3
; %bb.8:                                ;   in Loop: Header=BB0_4 Depth=1
	ldr	w0, [x26]
	mov	x1, x22
	mov	x2, x21
	bl	_fprintf
	b	LBB0_3
LBB0_9:
Lloh8:
	adrp	x8, _TL_VECTOR_TOTAL@GOTPAGE
Lloh9:
	ldr	x8, [x8, _TL_VECTOR_TOTAL@GOTPAGEOFF]
Lloh10:
	ldr	w0, [x8]
	bl	_tl_store_int
Lloh11:
	adrp	x8, _GH_total@GOTPAGE
Lloh12:
	ldr	x8, [x8, _GH_total@GOTPAGEOFF]
Lloh13:
	ldr	w0, [x8]
	bl	_tl_store_int
	bl	_get_gather_heap_head
	cbz	x0, LBB0_19
; %bb.10:
	mov	w23, #-2
Lloh14:
	adrp	x22, _R@GOTPAGE
Lloh15:
	ldr	x22, [x22, _R@GOTPAGEOFF]
Lloh16:
	adrp	x21, _MAX_RES@GOTPAGE
Lloh17:
	ldr	x21, [x21, _MAX_RES@GOTPAGEOFF]
	b	LBB0_13
LBB0_11:                                ;   in Loop: Header=BB0_13 Depth=1
	sxtw	x9, w23
	add	x9, x9, #2
	str	x10, [x8, x9, lsl #3]
	ldr	x10, [x0, #8]
	add	x8, x8, w23, sxtw #3
	str	x10, [x8, #24]
	ldr	w8, [x21]
	mov	x23, x9
	cmp	w9, w8
	b.ge	LBB0_16
LBB0_12:                                ;   in Loop: Header=BB0_13 Depth=1
	bl	_gather_heap_advance
	bl	_get_gather_heap_head
	mov	x9, x23
	cbz	x0, LBB0_16
LBB0_13:                                ; =>This Inner Loop Header: Depth=1
	ldr	x10, [x0]
	ldr	x8, [x22]
	tbnz	w23, #31, LBB0_11
; %bb.14:                               ;   in Loop: Header=BB0_13 Depth=1
	ldr	x9, [x8, w23, uxtw #3]
	cmp	x10, x9
	b.ne	LBB0_11
; %bb.15:                               ;   in Loop: Header=BB0_13 Depth=1
	ldr	x9, [x0, #8]
	add	w10, w23, #1
	lsl	x10, x10, #3
	ldr	x11, [x8, x10]
	add	x9, x11, x9
	str	x9, [x8, x10]
	b	LBB0_12
LBB0_16:
	tbnz	w9, #31, LBB0_19
; %bb.17:
	add	w8, w9, #2
	ldr	w9, [x20]
	tbnz	w9, #0, LBB0_20
; %bb.18:
	lsr	w21, w8, #1
	b	LBB0_21
LBB0_19:
	mov	w0, #0
	bl	_tl_store_int
	b	LBB0_22
LBB0_20:
	ldr	x0, [x22]
Lloh18:
	adrp	x10, _cmp@GOTPAGE
Lloh19:
	ldr	x10, [x10, _cmp@GOTPAGEOFF]
	lsr	w21, w8, #1
Lloh20:
	adrp	x8, _cmpd@GOTPAGE
Lloh21:
	ldr	x8, [x8, _cmpd@GOTPAGEOFF]
	tst	w9, #0x4
	csel	x8, x8, x10, eq
	ldr	w3, [x8]
	mov	x1, x21
	mov	w2, #8
	bl	_qsort
LBB0_21:
	ldr	w8, [x20, #4]
	cmp	w21, w8
	csel	w21, w21, w8, lt
	mov	x0, x21
	bl	_tl_store_int
	ldr	x0, [x22]
	lsl	w1, w21, #3
	bl	_tl_store_raw_data
LBB0_22:
	bl	_tl_store_end
LBB0_23:
	mov	x0, x20
	mov	w1, #8
	bl	_zfree
	mov	x0, x19
	ldp	x29, x30, [sp, #64]             ; 16-byte Folded Reload
	ldp	x20, x19, [sp, #48]             ; 16-byte Folded Reload
	ldp	x22, x21, [sp, #32]             ; 16-byte Folded Reload
	ldp	x24, x23, [sp, #16]             ; 16-byte Folded Reload
	ldp	x26, x25, [sp], #80             ; 16-byte Folded Reload
	b	_merge_delete
	.loh AdrpAdd	Lloh6, Lloh7
	.loh AdrpLdrGot	Lloh4, Lloh5
	.loh AdrpLdrGot	Lloh2, Lloh3
	.loh AdrpLdrGot	Lloh0, Lloh1
	.loh AdrpLdrGotLdr	Lloh11, Lloh12, Lloh13
	.loh AdrpLdrGotLdr	Lloh8, Lloh9, Lloh10
	.loh AdrpLdrGot	Lloh16, Lloh17
	.loh AdrpLdrGot	Lloh14, Lloh15
	.loh AdrpLdrGot	Lloh20, Lloh21
	.loh AdrpLdrGot	Lloh18, Lloh19
	.cfi_endproc
                                        ; -- End function
	.comm	_received_bad_answers,4,2       ; @received_bad_answers
	.comm	_verbosity,4,2                  ; @verbosity
	.comm	_stderr,4,2                     ; @stderr
	.section	__TEXT,__cstring,cstring_literals
l_.str:                                 ; @.str
	.asciz	"Dropping result %d (num = %d)\n"

	.comm	_TL_VECTOR_TOTAL,4,2            ; @TL_VECTOR_TOTAL
	.comm	_GH_total,4,2                   ; @GH_total
	.comm	_R,8,3                          ; @R
	.comm	_MAX_RES,4,2                    ; @MAX_RES
	.comm	_cmp,4,2                        ; @cmp
	.comm	_cmpd,4,2                       ; @cmpd
.subsections_via_symbols
