// File: /workspace/github_c_makefile_star2_O0/lh3[P]minimap2/index.c
// Function: mm_idx_gen
mm_idx_t *mm_idx_gen(mm_bseq_file_t *fp, int w, int k, int b, int flag, int mini_batch_size, int n_threads, uint64_t batch_size)
{
	pipeline_t pl;
	if (fp == 0 || mm_bseq_eof(fp)) return 0;
	memset(&pl, 0, sizeof(pipeline_t));
	pl.mini_batch_size = (uint64_t)mini_batch_size < batch_size? mini_batch_size : batch_size;
	pl.batch_size = batch_size;
	pl.fp = fp;
	pl.mi = mm_idx_init(w, k, b, flag);

	kt_pipeline(n_threads < 3? n_threads : 3, worker_pipeline, &pl, 3);
	if (mm_verbose >= 3)
		fprintf(stderr, "[M::%s::%.3f*%.2f] collected minimizers\n", __func__, realtime() - mm_realtime0, cputime() / (realtime() - mm_realtime0));

	mm_idx_post(pl.mi, n_threads);
	if (mm_verbose >= 3)
		fprintf(stderr, "[M::%s::%.3f*%.2f] sorted minimizers\n", __func__, realtime() - mm_realtime0, cputime() / (realtime() - mm_realtime0));

	return pl.mi;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
movq 0x18(%rbp), %rax
movl 0x10(%rbp), %eax
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movl %edx, -0x18(%rbp)
movl %ecx, -0x1c(%rbp)
movl %r8d, -0x20(%rbp)
movl %r9d, -0x24(%rbp)
cmpq $0x0, -0x10(%rbp)
je 0x8fec
movq -0x10(%rbp), %rdi
callq 0x1c580
cmpl $0x0, %eax
je 0x8ff9
movq $0x0, -0x8(%rbp)
jmp 0x9187
leaq -0x50(%rbp), %rdi
xorl %esi, %esi
movl $0x28, %edx
callq 0x21b0
movslq -0x24(%rbp), %rax
cmpq 0x18(%rbp), %rax
jae 0x901d
movslq -0x24(%rbp), %rax
movq %rax, -0x58(%rbp)
jmp 0x9025
movq 0x18(%rbp), %rax
movq %rax, -0x58(%rbp)
movq -0x58(%rbp), %rax
movl %eax, -0x50(%rbp)
movq 0x18(%rbp), %rax
movq %rax, -0x48(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x38(%rbp)
movl -0x14(%rbp), %edi
movl -0x18(%rbp), %esi
movl -0x1c(%rbp), %edx
movl -0x20(%rbp), %ecx
callq 0x7b90
movq %rax, -0x30(%rbp)
cmpl $0x3, 0x10(%rbp)
jge 0x905f
movl 0x10(%rbp), %eax
movl %eax, -0x5c(%rbp)
jmp 0x9069
movl $0x3, %eax
movl %eax, -0x5c(%rbp)
jmp 0x9069
movl -0x5c(%rbp), %edi
leaq 0x12d(%rip), %rsi       # 0x91a0
leaq -0x50(%rbp), %rdx
movl $0x3, %ecx
callq 0x1a200
leaq 0x55688(%rip), %rax     # 0x5e710
cmpl $0x3, (%rax)
jl 0x90f4
movq 0x54f64(%rip), %rax     # 0x5dff8
movq (%rax), %rax
movq %rax, -0x70(%rbp)
callq 0x54e0
leaq 0x55899(%rip), %rax     # 0x5e940
subsd (%rax), %xmm0
movsd %xmm0, -0x68(%rbp)
callq 0x5450
movsd %xmm0, -0x78(%rbp)
callq 0x54e0
movsd -0x78(%rbp), %xmm1
movq -0x70(%rbp), %rdi
movaps %xmm0, %xmm2
movsd -0x68(%rbp), %xmm0
leaq 0x55869(%rip), %rax     # 0x5e940
subsd (%rax), %xmm2
divsd %xmm2, %xmm1
leaq 0x4dd5a(%rip), %rsi     # 0x56e40
leaq 0x4dd7c(%rip), %rdx     # 0x56e69
movb $0x2, %al
callq 0x2250
movq -0x30(%rbp), %rdi
movl 0x10(%rbp), %esi
callq 0x98f0
leaq 0x55609(%rip), %rax     # 0x5e710
cmpl $0x3, (%rax)
jl 0x917f
movq 0x54ee5(%rip), %rax     # 0x5dff8
movq (%rax), %rax
movq %rax, -0x88(%rbp)
callq 0x54e0
leaq 0x55817(%rip), %rax     # 0x5e940
subsd (%rax), %xmm0
movsd %xmm0, -0x80(%rbp)
callq 0x5450
movsd %xmm0, -0x90(%rbp)
callq 0x54e0
movsd -0x90(%rbp), %xmm1
movq -0x88(%rbp), %rdi
movaps %xmm0, %xmm2
movsd -0x80(%rbp), %xmm0
leaq 0x557de(%rip), %rax     # 0x5e940
subsd (%rax), %xmm2
divsd %xmm2, %xmm1
leaq 0x4dd03(%rip), %rsi     # 0x56e74
leaq 0x4dcf1(%rip), %rdx     # 0x56e69
movb $0x2, %al
callq 0x2250
movq -0x30(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x90, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)