LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: chhylp123[P]hifiasm/Purge_Dups.cpp
// Function: get_available_cnt(asg_t*, unsigned int, unsigned char*, asg_arc_t*)
inline int get_available_cnt(asg_t *g, uint32_t v, uint8_t* del, asg_arc_t* v_s)
{
    //v has direction
    if(del && del[v>>1]) return 0;
    uint32_t i, kv = 0;
    asg_arc_t *av = asg_arc_a(g, v);
    uint32_t nv = asg_arc_n(g, v);

    for (i = 0, kv = 0; i < nv; i++)
    {
        if(!av[i].del)
        {
            if(del && del[av[i].v>>1]) continue;
            if(v_s) v_s[kv] = av[i];
            kv++;
        }
    }

    return kv;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movq %rdx, -0x20(%rbp)
movq %rcx, -0x28(%rbp)
cmpq $0x0, -0x20(%rbp)
je 0x186207
movq -0x20(%rbp), %rax
movl -0x14(%rbp), %ecx
shrl %ecx
movl %ecx, %ecx
cmpb $0x0, (%rax,%rcx)
je 0x186207
movl $0x0, -0x4(%rbp)
jmp 0x1862f9
movl $0x0, -0x30(%rbp)
movq -0x10(%rbp), %rax
movq 0x8(%rax), %rax
movq -0x10(%rbp), %rcx
movq 0x28(%rcx), %rcx
movl -0x14(%rbp), %edx
movq (%rcx,%rdx,8), %rcx
shrq $0x20, %rcx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movq %rax, -0x38(%rbp)
movq -0x10(%rbp), %rax
movq 0x28(%rax), %rax
movl -0x14(%rbp), %ecx
movq (%rax,%rcx,8), %rax
movl %eax, -0x3c(%rbp)
movl $0x0, -0x2c(%rbp)
movl $0x0, -0x30(%rbp)
movl -0x2c(%rbp), %eax
cmpl -0x3c(%rbp), %eax
jae 0x1862f3
movq -0x38(%rbp), %rax
movl -0x2c(%rbp), %ecx
imulq $0x18, %rcx, %rcx
addq %rcx, %rax
movl 0xc(%rax), %eax
shrl $0x1f, %eax
cmpl $0x0, %eax
jne 0x1862e3
cmpq $0x0, -0x20(%rbp)
je 0x1862a1
movq -0x20(%rbp), %rax
movq -0x38(%rbp), %rcx
movl -0x2c(%rbp), %edx
imulq $0x18, %rdx, %rdx
addq %rdx, %rcx
movl 0x8(%rcx), %ecx
shrl %ecx
movl %ecx, %ecx
cmpb $0x0, (%rax,%rcx)
je 0x1862a1
jmp 0x1862e5
cmpq $0x0, -0x28(%rbp)
je 0x1862da
movq -0x38(%rbp), %rcx
movl -0x2c(%rbp), %eax
imulq $0x18, %rax, %rax
addq %rax, %rcx
movq -0x28(%rbp), %rax
movl -0x30(%rbp), %edx
imulq $0x18, %rdx, %rdx
addq %rdx, %rax
movq (%rcx), %rdx
movq %rdx, (%rax)
movq 0x8(%rcx), %rdx
movq %rdx, 0x8(%rax)
movq 0x10(%rcx), %rcx
movq %rcx, 0x10(%rax)
movl -0x30(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x30(%rbp)
jmp 0x1862e5
movl -0x2c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2c(%rbp)
jmp 0x186254
movl -0x30(%rbp), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
popq %rbp
retq
nop
// File: chhylp123[P]hifiasm/htab.cpp
// Function: yak_copt_init(yak_copt_t*)
void yak_copt_init(yak_copt_t *o)
{
	memset(o, 0, sizeof(yak_copt_t));
	o->bf_shift = 0;
	o->bf_n_hash = 4;
	o->k = 31;
	o->w = 1;
	o->pre = YAK_COUNTER_BITS;
	o->n_thread = 4;
	o->chunk_size = 20000000;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rdi
xorl %esi, %esi
movl $0x30, %edx
callq 0x2100
movq -0x8(%rbp), %rax
movl $0x0, (%rax)
movq -0x8(%rbp), %rax
movl $0x4, 0x4(%rax)
movq -0x8(%rbp), %rax
movl $0x1f, 0x8(%rax)
movq -0x8(%rbp), %rax
movl $0x1, 0xc(%rax)
movq -0x8(%rbp), %rax
movl $0xc, 0x18(%rax)
movq -0x8(%rbp), %rax
movl $0x4, 0x1c(%rax)
movq -0x8(%rbp), %rax
movq $0x1312d00, 0x20(%rax)  # imm = 0x1312D00
addq $0x10, %rsp
popq %rbp
retq
nop
// File: chhylp123[P]hifiasm/htab.cpp
// Function: yak_bf_init(int, int)
yak_bf_t *yak_bf_init(int n_shift, int n_hashes)
{
	yak_bf_t *b;
	void *ptr = 0;
	if (n_shift + YAK_BLK_SHIFT > 64 || n_shift < YAK_BLK_SHIFT) return 0;
	CALLOC(b, 1);
	b->n_shift = n_shift;
	b->n_hashes = n_hashes;
	posix_memalign(&ptr, 1<<(YAK_BLK_SHIFT-3), 1ULL<<(n_shift-3));
	b->b = (uint8_t*)ptr;
	bzero(b->b, 1ULL<<(n_shift-3));
	return b;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movl %edi, -0xc(%rbp)
movl %esi, -0x10(%rbp)
movq $0x0, -0x20(%rbp)
movl -0xc(%rbp), %eax
addl $0x9, %eax
cmpl $0x40, %eax
jg 0x186497
cmpl $0x9, -0xc(%rbp)
jge 0x1864a1
movq $0x0, -0x8(%rbp)
jmp 0x18651c
movl $0x1, %edi
movl $0x10, %esi
callq 0x2140
movq %rax, -0x18(%rbp)
movl -0xc(%rbp), %ecx
movq -0x18(%rbp), %rax
movl %ecx, (%rax)
movl -0x10(%rbp), %ecx
movq -0x18(%rbp), %rax
movl %ecx, 0x4(%rax)
movl -0xc(%rbp), %eax
subl $0x3, %eax
movl %eax, %eax
movl %eax, %ecx
movl $0x1, %edx
shlq %cl, %rdx
leaq -0x20(%rbp), %rdi
movl $0x40, %esi
callq 0x20e0
movq -0x20(%rbp), %rcx
movq -0x18(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x18(%rbp), %rax
movq 0x8(%rax), %rdi
movl -0xc(%rbp), %eax
subl $0x3, %eax
movl %eax, %eax
movl %eax, %ecx
movl $0x1, %edx
shlq %cl, %rdx
xorl %esi, %esi
callq 0x2100
movq -0x18(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/htab.cpp
// Function: yak_bf_insert(yak_bf_t*, unsigned long)
int yak_bf_insert(yak_bf_t *b, uint64_t hash)
{
	int x = b->n_shift - YAK_BLK_SHIFT;
	uint64_t y = hash & ((1ULL<<x) - 1);
	int h1 = hash >> x & YAK_BLK_MASK;
	int h2 = hash >> b->n_shift & YAK_BLK_MASK;
	uint8_t *p = &b->b[y<<(YAK_BLK_SHIFT-3)];
	int i, z = h1, cnt = 0;
	if ((h2&31) == 0) h2 = (h2 + 1) & YAK_BLK_MASK; // otherwise we may repeatedly use a few bits
	for (i = 0; i < b->n_hashes; z = (z + h2) & YAK_BLK_MASK) {
		uint8_t *q = &p[z>>3], u;
		u = 1<<(z&7);
		cnt += !!(*q & u);
		*q |= u;
		++i;
	}
	return cnt;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rax
movl (%rax), %eax
subl $0x9, %eax
movl %eax, -0x14(%rbp)
movq -0x10(%rbp), %rax
movl -0x14(%rbp), %ecx
movl $0x1, %edx
shlq %cl, %rdx
movq %rdx, %rcx
subq $0x1, %rcx
andq %rcx, %rax
movq %rax, -0x20(%rbp)
movq -0x10(%rbp), %rax
movl -0x14(%rbp), %ecx
shrq %cl, %rax
andq $0x1ff, %rax            # imm = 0x1FF
movl %eax, -0x24(%rbp)
movq -0x10(%rbp), %rax
movq -0x8(%rbp), %rcx
movl (%rcx), %ecx
shrq %cl, %rax
andq $0x1ff, %rax            # imm = 0x1FF
movl %eax, -0x28(%rbp)
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movq -0x20(%rbp), %rcx
shlq $0x6, %rcx
addq %rcx, %rax
movq %rax, -0x30(%rbp)
movl -0x24(%rbp), %eax
movl %eax, -0x38(%rbp)
movl $0x0, -0x3c(%rbp)
movl -0x28(%rbp), %eax
andl $0x1f, %eax
cmpl $0x0, %eax
jne 0x18660b
movl -0x28(%rbp), %eax
addl $0x1, %eax
andl $0x1ff, %eax            # imm = 0x1FF
movl %eax, -0x28(%rbp)
movl $0x0, -0x34(%rbp)
movl -0x34(%rbp), %eax
movq -0x8(%rbp), %rcx
cmpl 0x4(%rcx), %eax
jge 0x18668c
movq -0x30(%rbp), %rax
movl -0x38(%rbp), %ecx
sarl $0x3, %ecx
movslq %ecx, %rcx
addq %rcx, %rax
movq %rax, -0x48(%rbp)
movl -0x38(%rbp), %ecx
andl $0x7, %ecx
movl $0x1, %eax
shll %cl, %eax
movb %al, -0x49(%rbp)
movq -0x48(%rbp), %rax
movzbl (%rax), %eax
movzbl -0x49(%rbp), %ecx
andl %ecx, %eax
cmpl $0x0, %eax
setne %al
xorb $-0x1, %al
xorb $-0x1, %al
andb $0x1, %al
movzbl %al, %eax
addl -0x3c(%rbp), %eax
movl %eax, -0x3c(%rbp)
movzbl -0x49(%rbp), %edx
movq -0x48(%rbp), %rax
movzbl (%rax), %ecx
orl %edx, %ecx
movb %cl, (%rax)
movl -0x34(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x34(%rbp)
movl -0x38(%rbp), %eax
addl -0x28(%rbp), %eax
andl $0x1ff, %eax            # imm = 0x1FF
movl %eax, -0x38(%rbp)
jmp 0x186612
movl -0x3c(%rbp), %eax
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/htab.cpp
// Function: ha_pt_gen(ha_ct_t*, int, int)
ha_pt_t *ha_pt_gen(ha_ct_t *ct, int n_thread, int is_l)
{
	pt_gen_aux_t a;
	int i;
	ha_pt_t *pt;
	ha_ct_destroy_bf(ct);
	CALLOC(pt, 1);
	pt->k = ct->k, pt->pre = ct->pre, pt->tot = ct->tot;
	CALLOC(pt->h, 1<<pt->pre);
	for (i = 0; i < 1<<pt->pre; ++i) {
		pt->h[i].h = yak_pt_init();
		yak_pt_resize(pt->h[i].h, kh_size(ct->h[i].h));
	}
	a.ct = ct, a.pt = pt, a.is_l = is_l;
	kt_for(n_thread, worker_pt_gen, &a, 1<<pt->pre);
	free(ct->h); free(ct);
	return pt;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl %edx, -0x10(%rbp)
movq -0x8(%rbp), %rdi
callq 0x186c60
movl $0x1, %edi
movl $0x20, %esi
callq 0x2140
movq %rax, -0x38(%rbp)
movq -0x8(%rbp), %rax
movl (%rax), %ecx
movq -0x38(%rbp), %rax
movl %ecx, (%rax)
movq -0x8(%rbp), %rax
movl 0x4(%rax), %ecx
movq -0x38(%rbp), %rax
movl %ecx, 0x4(%rax)
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rcx
movq -0x38(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x38(%rbp), %rax
movl 0x4(%rax), %ecx
movl $0x1, %eax
shll %cl, %eax
movslq %eax, %rdi
movl $0x20, %esi
callq 0x2140
movq %rax, %rcx
movq -0x38(%rbp), %rax
movq %rcx, 0x18(%rax)
movl $0x0, -0x2c(%rbp)
movl -0x2c(%rbp), %eax
movq -0x38(%rbp), %rcx
movl 0x4(%rcx), %ecx
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
cmpl %ecx, %eax
jge 0x186bf9
callq 0x186cf0
movq %rax, %rcx
movq -0x38(%rbp), %rax
movq 0x18(%rax), %rax
movslq -0x2c(%rbp), %rdx
shlq $0x5, %rdx
addq %rdx, %rax
movq %rcx, (%rax)
movq -0x38(%rbp), %rax
movq 0x18(%rax), %rax
movslq -0x2c(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movq (%rax), %rdi
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rax
movslq -0x2c(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq (%rax), %rax
movl 0x4(%rax), %esi
callq 0x186d00
movl -0x2c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2c(%rbp)
jmp 0x186b85
movq -0x8(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x38(%rbp), %rax
movq %rax, -0x20(%rbp)
movl -0x10(%rbp), %eax
movl %eax, -0x18(%rbp)
movl -0xc(%rbp), %edi
movq -0x38(%rbp), %rax
movl 0x4(%rax), %ecx
movl $0x1, %eax
shll %cl, %eax
movslq %eax, %rcx
leaq 0x106(%rip), %rsi       # 0x186d30
leaq -0x28(%rbp), %rdx
callq 0x16d710
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rdi
callq 0x2210
movq -0x8(%rbp), %rdi
callq 0x2210
movq -0x38(%rbp), %rax
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/htab.cpp
// Function: ha_ct_destroy_bf(ha_ct_t*)
static void ha_ct_destroy_bf(ha_ct_t *h)
{
	int i;
	for (i = 0; i < 1<<h->pre; ++i) {
		if (h->h[i].b)
			yak_bf_destroy(h->h[i].b);
		h->h[i].b = 0;
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
movl $0x0, -0xc(%rbp)
movl -0xc(%rbp), %eax
movq -0x8(%rbp), %rcx
movl 0x4(%rcx), %ecx
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
cmpl %ecx, %eax
jge 0x186ce6
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rax
movslq -0xc(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
cmpq $0x0, 0x8(%rax)
je 0x186cc0
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rax
movslq -0xc(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq 0x8(%rax), %rdi
callq 0x186530
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rax
movslq -0xc(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq $0x0, 0x8(%rax)
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x186c73
addq $0x10, %rsp
popq %rbp
retq
nopl (%rax)
// File: chhylp123[P]hifiasm/htab.cpp
// Function: worker_pt_gen(void*, long, int)
static void worker_pt_gen(void *data, long i, int tid) // callback for kt_for()
{
	pt_gen_aux_t *a = (pt_gen_aux_t*)data;
	ha_pt1_t *b = &a->pt->h[i];
	yak_ct_t *g = a->ct->h[i].h;
	khint_t k;
	for (k = 0, b->n = 0; k != kh_end(g); ++k) {
		if (kh_exist(g, k)) {
			int absent;
			khint_t l;
			l = yak_pt_put(b->h, kh_key(g, k) >> a->ct->pre << YAK_COUNTER_BITS, &absent);
			///this should be the start index of kh_key's corresponding pos at ha_idxpos_t* a
			kh_val(b->h, l) = b->n;
			b->n += kh_key(g, k) & YAK_MAX_COUNT;
		}
	}
	yak_ct_destroy(g);
	a->ct->h[i].h = 0;
	if(a->is_l) CALLOC(b->al, b->n);
	else CALLOC(b->a, b->n);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq 0x8(%rax), %rax
movq 0x18(%rax), %rax
movq -0x10(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movq %rax, -0x28(%rbp)
movq -0x20(%rbp), %rax
movq (%rax), %rax
movq 0x20(%rax), %rax
movq -0x10(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq (%rax), %rax
movq %rax, -0x30(%rbp)
movl $0x0, -0x34(%rbp)
movq -0x28(%rbp), %rax
movq $0x0, 0x8(%rax)
movl -0x34(%rbp), %eax
movl %eax, -0x40(%rbp)
movq -0x30(%rbp), %rax
cmpq $0x0, 0x10(%rax)
je 0x186db9
movq -0x30(%rbp), %rax
movl (%rax), %ecx
movl $0x1, %eax
shll %cl, %eax
movl %eax, -0x44(%rbp)
jmp 0x186dc0
xorl %eax, %eax
movl %eax, -0x44(%rbp)
jmp 0x186dc0
movl -0x40(%rbp), %eax
movl -0x44(%rbp), %ecx
cmpl %ecx, %eax
je 0x186e79
movq -0x30(%rbp), %rax
movq 0x8(%rax), %rax
movl -0x34(%rbp), %ecx
shrl $0x5, %ecx
movl %ecx, %ecx
movl (%rax,%rcx,4), %eax
movl -0x34(%rbp), %ecx
andl $0x1f, %ecx
shrl %cl, %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0x186e69
movq -0x28(%rbp), %rax
movq (%rax), %rdi
movq -0x30(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x34(%rbp), %ecx
movq (%rax,%rcx,8), %rsi
movq -0x20(%rbp), %rax
movq (%rax), %rax
movl 0x4(%rax), %eax
movl %eax, %ecx
shrq %cl, %rsi
shlq $0xc, %rsi
leaq -0x38(%rbp), %rdx
callq 0x18c080
movl %eax, -0x3c(%rbp)
movq -0x28(%rbp), %rax
movq 0x8(%rax), %rcx
movq -0x28(%rbp), %rax
movq (%rax), %rax
movq 0x10(%rax), %rax
movl -0x3c(%rbp), %edx
shlq $0x4, %rdx
addq %rdx, %rax
movq %rcx, 0x8(%rax)
movq -0x30(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x34(%rbp), %ecx
movq (%rax,%rcx,8), %rcx
andq $0xfff, %rcx            # imm = 0xFFF
movq -0x28(%rbp), %rax
addq 0x8(%rax), %rcx
movq %rcx, 0x8(%rax)
jmp 0x186e6b
movl -0x34(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x34(%rbp)
jmp 0x186d96
movq -0x30(%rbp), %rdi
callq 0x18c0c0
movq -0x20(%rbp), %rax
movq (%rax), %rax
movq 0x20(%rax), %rax
movq -0x10(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq $0x0, (%rax)
movq -0x20(%rbp), %rax
cmpl $0x0, 0x10(%rax)
je 0x186ec8
movq -0x28(%rbp), %rax
movq 0x8(%rax), %rdi
movl $0x10, %esi
callq 0x2140
movq %rax, %rcx
movq -0x28(%rbp), %rax
movq %rcx, 0x18(%rax)
jmp 0x186ee5
movq -0x28(%rbp), %rax
movq 0x8(%rax), %rdi
movl $0x8, %esi
callq 0x2140
movq %rax, %rcx
movq -0x28(%rbp), %rax
movq %rcx, 0x10(%rax)
addq $0x50, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: chhylp123[P]hifiasm/htab.cpp
// Function: ha_pt_gen_count(ha_ct_t*, int)
ha_pt_t *ha_pt_gen_count(ha_ct_t *ct, int n_thread)
{
	pt_gen_aux_t a;
	int i;
	ha_pt_t *pt;
	ha_ct_destroy_bf(ct);
	CALLOC(pt, 1);
	pt->k = ct->k, pt->pre = ct->pre, pt->tot = ct->tot;
	CALLOC(pt->h, 1<<pt->pre);
	for (i = 0; i < 1<<pt->pre; ++i) {
		pt->h[i].h = yak_pt_init();
		yak_pt_resize(pt->h[i].h, kh_size(ct->h[i].h));
	}
	a.ct = ct, a.pt = pt;
	kt_for(n_thread, worker_pt_gen_count, &a, 1<<pt->pre);
	free(ct->h); free(ct);
	return pt;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movq -0x8(%rbp), %rdi
callq 0x186c60
movl $0x1, %edi
movl $0x20, %esi
callq 0x2140
movq %rax, -0x38(%rbp)
movq -0x8(%rbp), %rax
movl (%rax), %ecx
movq -0x38(%rbp), %rax
movl %ecx, (%rax)
movq -0x8(%rbp), %rax
movl 0x4(%rax), %ecx
movq -0x38(%rbp), %rax
movl %ecx, 0x4(%rax)
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rcx
movq -0x38(%rbp), %rax
movq %rcx, 0x8(%rax)
movq -0x38(%rbp), %rax
movl 0x4(%rax), %ecx
movl $0x1, %eax
shll %cl, %eax
movslq %eax, %rdi
movl $0x20, %esi
callq 0x2140
movq %rax, %rcx
movq -0x38(%rbp), %rax
movq %rcx, 0x18(%rax)
movl $0x0, -0x2c(%rbp)
movl -0x2c(%rbp), %eax
movq -0x38(%rbp), %rcx
movl 0x4(%rcx), %ecx
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
cmpl %ecx, %eax
jge 0x186fe6
callq 0x186cf0
movq %rax, %rcx
movq -0x38(%rbp), %rax
movq 0x18(%rax), %rax
movslq -0x2c(%rbp), %rdx
shlq $0x5, %rdx
addq %rdx, %rax
movq %rcx, (%rax)
movq -0x38(%rbp), %rax
movq 0x18(%rax), %rax
movslq -0x2c(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movq (%rax), %rdi
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rax
movslq -0x2c(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq (%rax), %rax
movl 0x4(%rax), %esi
callq 0x186d00
movl -0x2c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2c(%rbp)
jmp 0x186f72
movq -0x8(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x38(%rbp), %rax
movq %rax, -0x20(%rbp)
movl -0xc(%rbp), %edi
movq -0x38(%rbp), %rax
movl 0x4(%rax), %ecx
movl $0x1, %eax
shll %cl, %eax
movslq %eax, %rcx
leaq 0x2f(%rip), %rsi        # 0x187040
leaq -0x28(%rbp), %rdx
callq 0x16d710
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rdi
callq 0x2210
movq -0x8(%rbp), %rdi
callq 0x2210
movq -0x38(%rbp), %rax
addq $0x40, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: chhylp123[P]hifiasm/htab.cpp
// Function: worker_pt_gen_count(void*, long, int)
static void worker_pt_gen_count(void *data, long i, int tid) // callback for kt_for()
{
	pt_gen_aux_t *a = (pt_gen_aux_t*)data;
	ha_pt1_t *b = &a->pt->h[i];
	yak_ct_t *g = a->ct->h[i].h;
	khint_t k;
	for (k = 0, b->n = 0; k != kh_end(g); ++k) {
		if (kh_exist(g, k)) {
			int absent;
			khint_t l;
			l = yak_pt_put(b->h, kh_key(g, k) >> a->ct->pre << YAK_COUNTER_BITS, &absent);
			kh_val(b->h, l) = 0; kh_key(b->h, l) |= kh_key(g, k) & YAK_MAX_COUNT;
		}
	}
	yak_ct_destroy(g);
	a->ct->h[i].h = 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq 0x8(%rax), %rax
movq 0x18(%rax), %rax
movq -0x10(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movq %rax, -0x28(%rbp)
movq -0x20(%rbp), %rax
movq (%rax), %rax
movq 0x20(%rax), %rax
movq -0x10(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq (%rax), %rax
movq %rax, -0x30(%rbp)
movl $0x0, -0x34(%rbp)
movq -0x28(%rbp), %rax
movq $0x0, 0x8(%rax)
movl -0x34(%rbp), %eax
movl %eax, -0x40(%rbp)
movq -0x30(%rbp), %rax
cmpq $0x0, 0x10(%rax)
je 0x1870c9
movq -0x30(%rbp), %rax
movl (%rax), %ecx
movl $0x1, %eax
shll %cl, %eax
movl %eax, -0x44(%rbp)
jmp 0x1870d0
xorl %eax, %eax
movl %eax, -0x44(%rbp)
jmp 0x1870d0
movl -0x40(%rbp), %eax
movl -0x44(%rbp), %ecx
cmpl %ecx, %eax
je 0x187198
movq -0x30(%rbp), %rax
movq 0x8(%rax), %rax
movl -0x34(%rbp), %ecx
shrl $0x5, %ecx
movl %ecx, %ecx
movl (%rax,%rcx,4), %eax
movl -0x34(%rbp), %ecx
andl $0x1f, %ecx
shrl %cl, %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0x187188
movq -0x28(%rbp), %rax
movq (%rax), %rdi
movq -0x30(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x34(%rbp), %ecx
movq (%rax,%rcx,8), %rsi
movq -0x20(%rbp), %rax
movq (%rax), %rax
movl 0x4(%rax), %eax
movl %eax, %ecx
shrq %cl, %rsi
shlq $0xc, %rsi
leaq -0x38(%rbp), %rdx
callq 0x18c080
movl %eax, -0x3c(%rbp)
movq -0x28(%rbp), %rax
movq (%rax), %rax
movq 0x10(%rax), %rax
movl -0x3c(%rbp), %ecx
shlq $0x4, %rcx
addq %rcx, %rax
movq $0x0, 0x8(%rax)
movq -0x30(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x34(%rbp), %ecx
movq (%rax,%rcx,8), %rcx
andq $0xfff, %rcx            # imm = 0xFFF
movq -0x28(%rbp), %rax
movq (%rax), %rax
movq 0x10(%rax), %rax
movl -0x3c(%rbp), %edx
shlq $0x4, %rdx
addq %rdx, %rax
orq (%rax), %rcx
movq %rcx, (%rax)
jmp 0x18718a
movl -0x34(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x34(%rbp)
jmp 0x1870a6
movq -0x30(%rbp), %rdi
callq 0x18c0c0
movq -0x20(%rbp), %rax
movq (%rax), %rax
movq 0x20(%rax), %rax
movq -0x10(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq $0x0, (%rax)
addq $0x50, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/htab.cpp
// Function: ha_pt_cnt_insert_list(ha_pt_s*, int, unsigned long const*)
int ha_pt_cnt_insert_list(ha_pt_t *h, int n, const uint64_t *a)
{
	int j, mask = (1<<h->pre) - 1, n_ins = 0;
	ha_pt1_t *g;
	if (n == 0) return 0;
	g = &h->h[a[0]&mask];
	for (j = 0; j < n; ++j) {
		uint64_t x = a[j] >> h->pre;
		khint_t k;
		assert((a[j]&mask) == (a[0]&mask));
		k = yak_pt_get(g->h, x<<YAK_COUNTER_BITS);
		if (k == kh_end(g->h)) continue; // TODO: understand why we sometimes come here
		++kh_val(g->h, k);
		++n_ins;
	}
	// fprintf(stderr, "n: %d, n_ins: %d\n", n, n_ins);
	return n_ins;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movq %rdx, -0x20(%rbp)
movq -0x10(%rbp), %rax
movl 0x4(%rax), %ecx
movl $0x1, %eax
shll %cl, %eax
subl $0x1, %eax
movl %eax, -0x28(%rbp)
movl $0x0, -0x2c(%rbp)
cmpl $0x0, -0x14(%rbp)
jne 0x187530
movl $0x0, -0x4(%rbp)
jmp 0x187656
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
movq -0x20(%rbp), %rcx
movq (%rcx), %rcx
movslq -0x28(%rbp), %rdx
andq %rdx, %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movq %rax, -0x38(%rbp)
movl $0x0, -0x24(%rbp)
movl -0x24(%rbp), %eax
cmpl -0x14(%rbp), %eax
jge 0x187650
movq -0x20(%rbp), %rax
movslq -0x24(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movq -0x10(%rbp), %rcx
movl 0x4(%rcx), %ecx
shrq %cl, %rax
movq %rax, -0x40(%rbp)
movq -0x20(%rbp), %rax
movslq -0x24(%rbp), %rcx
movq (%rax,%rcx,8), %rax
movslq -0x28(%rbp), %rcx
andq %rcx, %rax
movq -0x20(%rbp), %rcx
movq (%rcx), %rcx
movslq -0x28(%rbp), %rdx
andq %rdx, %rcx
cmpq %rcx, %rax
jne 0x1875a6
jmp 0x1875c5
leaq 0x2033a5(%rip), %rdi    # 0x38a952
leaq 0x20334b(%rip), %rsi    # 0x38a8ff
movl $0x1d8, %edx            # imm = 0x1D8
leaq 0x2033ad(%rip), %rcx    # 0x38a96d
callq 0x2130
movq -0x38(%rbp), %rax
movq (%rax), %rdi
movq -0x40(%rbp), %rsi
shlq $0xc, %rsi
callq 0x1874c0
movl %eax, -0x44(%rbp)
movl -0x44(%rbp), %eax
movl %eax, -0x48(%rbp)
movq -0x38(%rbp), %rax
movq (%rax), %rax
cmpq $0x0, 0x10(%rax)
je 0x187605
movq -0x38(%rbp), %rax
movq (%rax), %rax
movl (%rax), %ecx
movl $0x1, %eax
shll %cl, %eax
movl %eax, -0x4c(%rbp)
jmp 0x18760c
xorl %eax, %eax
movl %eax, -0x4c(%rbp)
jmp 0x18760c
movl -0x48(%rbp), %eax
movl -0x4c(%rbp), %ecx
cmpl %ecx, %eax
jne 0x187618
jmp 0x187642
movq -0x38(%rbp), %rax
movq (%rax), %rax
movq 0x10(%rax), %rax
movl -0x44(%rbp), %ecx
shlq $0x4, %rcx
addq %rcx, %rax
movq 0x8(%rax), %rcx
addq $0x1, %rcx
movq %rcx, 0x8(%rax)
movl -0x2c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2c(%rbp)
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
jmp 0x187558
movl -0x2c(%rbp), %eax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x50, %rsp
popq %rbp
retq
nop
// File: chhylp123[P]hifiasm/htab.cpp
// Function: ha_pt_destroy(ha_pt_s*)
void ha_pt_destroy(ha_pt_t *h)
{
	int i;
	if (h == 0) return;
	for (i = 0; i < 1<<h->pre; ++i) {
		yak_pt_destroy(h->h[i].h);
		if(h->h[i].a){
			free(h->h[i].a); h->h[i].a = NULL;
		}
		if(h->h[i].al){
			free(h->h[i].al); h->h[i].al = NULL;
		}	
	}
	free(h->h); free(h);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
cmpq $0x0, -0x8(%rbp)
jne 0x187678
jmp 0x18777d
movl $0x0, -0xc(%rbp)
movl -0xc(%rbp), %eax
movq -0x8(%rbp), %rcx
movl 0x4(%rcx), %ecx
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
cmpl %ecx, %eax
jge 0x187767
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rax
movslq -0xc(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movq (%rax), %rdi
callq 0x187790
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rax
movslq -0xc(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
cmpq $0x0, 0x10(%rax)
je 0x187706
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rax
movslq -0xc(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movq 0x10(%rax), %rdi
callq 0x2210
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rax
movslq -0xc(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movq $0x0, 0x10(%rax)
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rax
movslq -0xc(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
cmpq $0x0, 0x18(%rax)
je 0x187757
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rax
movslq -0xc(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movq 0x18(%rax), %rdi
callq 0x2210
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rax
movslq -0xc(%rbp), %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movq $0x0, 0x18(%rax)
jmp 0x187759
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x18767f
movq -0x8(%rbp), %rax
movq 0x18(%rax), %rdi
callq 0x2210
movq -0x8(%rbp), %rdi
callq 0x2210
addq $0x10, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/htab.cpp
// Function: ha_pt_get(ha_pt_s const*, unsigned long, int*)
const ha_idxpos_t *ha_pt_get(const ha_pt_t *h, uint64_t hash, int *n)
{
	khint_t k;
	const ha_pt1_t *g = &h->h[hash & ((1ULL<<h->pre) - 1)];
	*n = 0;
	k = yak_pt_get(g->h, hash >> h->pre << YAK_COUNTER_BITS);
	if (k == kh_end(g->h)) return 0;
	*n = kh_key(g->h, k) & YAK_MAX_COUNT;
	return &g->a[kh_val(g->h, k)];
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
movq -0x18(%rbp), %rcx
movq %rcx, -0x40(%rbp)
movq -0x10(%rbp), %rcx
movl 0x4(%rcx), %ecx
movl $0x1, %edx
shlq %cl, %rdx
movq -0x40(%rbp), %rcx
subq $0x1, %rdx
andq %rdx, %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movq %rax, -0x30(%rbp)
movq -0x20(%rbp), %rax
movl $0x0, (%rax)
movq -0x30(%rbp), %rax
movq (%rax), %rdi
movq -0x18(%rbp), %rsi
movq -0x10(%rbp), %rax
movl 0x4(%rax), %eax
movl %eax, %ecx
shrq %cl, %rsi
shlq $0xc, %rsi
callq 0x1874c0
movl %eax, -0x24(%rbp)
movl -0x24(%rbp), %eax
movl %eax, -0x34(%rbp)
movq -0x30(%rbp), %rax
movq (%rax), %rax
cmpq $0x0, 0x10(%rax)
je 0x18784f
movq -0x30(%rbp), %rax
movq (%rax), %rax
movl (%rax), %ecx
movl $0x1, %eax
shll %cl, %eax
movl %eax, -0x44(%rbp)
jmp 0x187856
xorl %eax, %eax
movl %eax, -0x44(%rbp)
jmp 0x187856
movl -0x34(%rbp), %eax
movl -0x44(%rbp), %ecx
cmpl %ecx, %eax
jne 0x18786a
movq $0x0, -0x8(%rbp)
jmp 0x1878bc
movq -0x30(%rbp), %rax
movq (%rax), %rax
movq 0x10(%rax), %rax
movl -0x24(%rbp), %ecx
shlq $0x4, %rcx
addq %rcx, %rax
movq (%rax), %rax
andq $0xfff, %rax            # imm = 0xFFF
movl %eax, %ecx
movq -0x20(%rbp), %rax
movl %ecx, (%rax)
movq -0x30(%rbp), %rax
movq 0x10(%rax), %rax
movq -0x30(%rbp), %rcx
movq (%rcx), %rcx
movq 0x10(%rcx), %rcx
movl -0x24(%rbp), %edx
shlq $0x4, %rdx
addq %rdx, %rcx
movq 0x8(%rcx), %rcx
shlq $0x3, %rcx
addq %rcx, %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x50, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/htab.cpp
// Function: ha_ptl_get(ha_pt_s const*, unsigned long, int*)
const ha_idxposl_t *ha_ptl_get(const ha_pt_t *h, uint64_t hash, int *n)
{
	khint_t k;
	const ha_pt1_t *g = &h->h[hash & ((1ULL<<h->pre) - 1)];
	*n = 0;
	k = yak_pt_get(g->h, hash >> h->pre << YAK_COUNTER_BITS);
	if (k == kh_end(g->h)) return 0;
	*n = kh_key(g->h, k) & YAK_MAX_COUNT;
	return &g->al[kh_val(g->h, k)];
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq %rdx, -0x20(%rbp)
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
movq -0x18(%rbp), %rcx
movq %rcx, -0x40(%rbp)
movq -0x10(%rbp), %rcx
movl 0x4(%rcx), %ecx
movl $0x1, %edx
shlq %cl, %rdx
movq -0x40(%rbp), %rcx
subq $0x1, %rdx
andq %rdx, %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movq %rax, -0x30(%rbp)
movq -0x20(%rbp), %rax
movl $0x0, (%rax)
movq -0x30(%rbp), %rax
movq (%rax), %rdi
movq -0x18(%rbp), %rsi
movq -0x10(%rbp), %rax
movl 0x4(%rax), %eax
movl %eax, %ecx
shrq %cl, %rsi
shlq $0xc, %rsi
callq 0x1874c0
movl %eax, -0x24(%rbp)
movl -0x24(%rbp), %eax
movl %eax, -0x34(%rbp)
movq -0x30(%rbp), %rax
movq (%rax), %rax
cmpq $0x0, 0x10(%rax)
je 0x18796f
movq -0x30(%rbp), %rax
movq (%rax), %rax
movl (%rax), %ecx
movl $0x1, %eax
shll %cl, %eax
movl %eax, -0x44(%rbp)
jmp 0x187976
xorl %eax, %eax
movl %eax, -0x44(%rbp)
jmp 0x187976
movl -0x34(%rbp), %eax
movl -0x44(%rbp), %ecx
cmpl %ecx, %eax
jne 0x18798a
movq $0x0, -0x8(%rbp)
jmp 0x1879dc
movq -0x30(%rbp), %rax
movq (%rax), %rax
movq 0x10(%rax), %rax
movl -0x24(%rbp), %ecx
shlq $0x4, %rcx
addq %rcx, %rax
movq (%rax), %rax
andq $0xfff, %rax            # imm = 0xFFF
movl %eax, %ecx
movq -0x20(%rbp), %rax
movl %ecx, (%rax)
movq -0x30(%rbp), %rax
movq 0x18(%rax), %rax
movq -0x30(%rbp), %rcx
movq (%rcx), %rcx
movq 0x10(%rcx), %rcx
movl -0x24(%rbp), %edx
shlq $0x4, %rdx
addq %rdx, %rcx
movq 0x8(%rcx), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x50, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/htab.cpp
// Function: ha_pt_cnt(ha_pt_s const*, unsigned long)
const int ha_pt_cnt(const ha_pt_t *h, uint64_t hash)
{
	khint_t k;
	const ha_pt1_t *g = &h->h[hash & ((1ULL<<h->pre) - 1)];
	k = yak_pt_get(g->h, hash >> h->pre << YAK_COUNTER_BITS);
	if (k == kh_end(g->h)) return 0;
	return kh_key(g->h, k) & YAK_MAX_COUNT;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq 0x18(%rax), %rax
movq -0x18(%rbp), %rcx
movq %rcx, -0x38(%rbp)
movq -0x10(%rbp), %rcx
movl 0x4(%rcx), %ecx
movl $0x1, %edx
shlq %cl, %rdx
movq -0x38(%rbp), %rcx
subq $0x1, %rdx
andq %rdx, %rcx
shlq $0x5, %rcx
addq %rcx, %rax
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
movq (%rax), %rdi
movq -0x18(%rbp), %rsi
movq -0x10(%rbp), %rax
movl 0x4(%rax), %eax
movl %eax, %ecx
shrq %cl, %rsi
shlq $0xc, %rsi
callq 0x1874c0
movl %eax, -0x1c(%rbp)
movl -0x1c(%rbp), %eax
movl %eax, -0x2c(%rbp)
movq -0x28(%rbp), %rax
movq (%rax), %rax
cmpq $0x0, 0x10(%rax)
je 0x187a81
movq -0x28(%rbp), %rax
movq (%rax), %rax
movl (%rax), %ecx
movl $0x1, %eax
shll %cl, %eax
movl %eax, -0x3c(%rbp)
jmp 0x187a88
xorl %eax, %eax
movl %eax, -0x3c(%rbp)
jmp 0x187a88
movl -0x2c(%rbp), %eax
movl -0x3c(%rbp), %ecx
cmpl %ecx, %eax
jne 0x187a9b
movl $0x0, -0x4(%rbp)
jmp 0x187abc
movq -0x28(%rbp), %rax
movq (%rax), %rax
movq 0x10(%rax), %rax
movl -0x1c(%rbp), %ecx
shlq $0x4, %rcx
addq %rcx, %rax
movq (%rax), %rax
andq $0xfff, %rax            # imm = 0xFFF
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/htab.cpp
// Function: ha_ft_cnt(void const*, unsigned long)
int32_t ha_ft_cnt(const void *hh, uint64_t y)
{
	yak_ft_t *h = (yak_ft_t*)hh;
	khint_t k;
	k = yak_ft_get(h, y);
	return k == kh_end(h)? 0 : kh_val(h, k) == INT16_MAX? INT32_MAX : kh_val(h, k);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x18(%rbp)
movq -0x18(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0x188dc0
movl %eax, -0x1c(%rbp)
movl -0x1c(%rbp), %eax
movl %eax, -0x20(%rbp)
movq -0x18(%rbp), %rax
cmpq $0x0, 0x10(%rax)
je 0x188d4b
movq -0x18(%rbp), %rax
movl (%rax), %ecx
movl $0x1, %eax
shll %cl, %eax
movl %eax, -0x24(%rbp)
jmp 0x188d52
xorl %eax, %eax
movl %eax, -0x24(%rbp)
jmp 0x188d52
movl -0x20(%rbp), %eax
movl -0x24(%rbp), %ecx
cmpl %ecx, %eax
jne 0x188d63
xorl %eax, %eax
movl %eax, -0x28(%rbp)
jmp 0x188da9
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x1c(%rbp), %ecx
imulq $0xa, %rcx, %rcx
addq %rcx, %rax
movswl 0x8(%rax), %eax
cmpl $0x7fff, %eax           # imm = 0x7FFF
jne 0x188d8a
movl $0x7fffffff, %eax       # imm = 0x7FFFFFFF
movl %eax, -0x2c(%rbp)
jmp 0x188da3
movq -0x18(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x1c(%rbp), %ecx
imulq $0xa, %rcx, %rcx
addq %rcx, %rax
movswl 0x8(%rax), %eax
movl %eax, -0x2c(%rbp)
movl -0x2c(%rbp), %eax
movl %eax, -0x28(%rbp)
movl -0x28(%rbp), %eax
addq $0x30, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/htab.cpp
// Function: debug_ct_index(void*, void*)
void debug_ct_index(void* q_ct_idx, void* r_ct_idx)
{
	ha_ct_t* ct_idx = (ha_ct_t*)q_ct_idx;
	yak_ct_t *g = NULL;
	uint64_t i;
	khint_t k;
	for (i = 0; (int)i < 1<<ct_idx->pre; i++)
	{
		g = ct_idx->h[i].h;
		for (k = 0; k < kh_end(g); ++k) 
		{
			if (kh_exist(g, k)) 
			{
				int c = kh_key(g, k) & YAK_MAX_COUNT;
				uint64_t hash = ((kh_key(g, k) >> ct_idx->pre)<<ct_idx->pre) | i;
				int q = query_ct_index(r_ct_idx, hash);
				if(q!=c)
				{
					fprintf(stderr, "ERROR:c: %d, q: %d\n", c, q);
				}
			}
		}
	}
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x18(%rbp)
movq $0x0, -0x20(%rbp)
movq $0x0, -0x28(%rbp)
movq -0x28(%rbp), %rax
movq -0x18(%rbp), %rcx
movl 0x4(%rcx), %ecx
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
cmpl %ecx, %eax
jge 0x188f9e
movq -0x18(%rbp), %rax
movq 0x20(%rax), %rax
movq -0x28(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq (%rax), %rax
movq %rax, -0x20(%rbp)
movl $0x0, -0x2c(%rbp)
movl -0x2c(%rbp), %eax
movl %eax, -0x40(%rbp)
movq -0x20(%rbp), %rax
cmpq $0x0, 0x10(%rax)
je 0x188ec8
movq -0x20(%rbp), %rax
movl (%rax), %ecx
movl $0x1, %eax
shll %cl, %eax
movl %eax, -0x44(%rbp)
jmp 0x188ecf
xorl %eax, %eax
movl %eax, -0x44(%rbp)
jmp 0x188ecf
movl -0x40(%rbp), %eax
movl -0x44(%rbp), %ecx
cmpl %ecx, %eax
jae 0x188f8b
movq -0x20(%rbp), %rax
movq 0x8(%rax), %rax
movl -0x2c(%rbp), %ecx
shrl $0x5, %ecx
movl %ecx, %ecx
movl (%rax,%rcx,4), %eax
movl -0x2c(%rbp), %ecx
andl $0x1f, %ecx
shrl %cl, %eax
andl $0x1, %eax
cmpl $0x0, %eax
je 0x188f7b
movq -0x20(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x2c(%rbp), %ecx
movq (%rax,%rcx,8), %rax
andq $0xfff, %rax            # imm = 0xFFF
movl %eax, -0x30(%rbp)
movq -0x20(%rbp), %rax
movq 0x10(%rax), %rax
movl -0x2c(%rbp), %ecx
movq (%rax,%rcx,8), %rax
movq -0x18(%rbp), %rcx
movl 0x4(%rcx), %ecx
shrq %cl, %rax
movq -0x18(%rbp), %rcx
movl 0x4(%rcx), %ecx
shlq %cl, %rax
orq -0x28(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x10(%rbp), %rdi
movq -0x38(%rbp), %rsi
callq 0x188fb0
movl %eax, -0x3c(%rbp)
movl -0x3c(%rbp), %eax
cmpl -0x30(%rbp), %eax
je 0x188f79
movq 0x23b07e(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
movl -0x30(%rbp), %edx
movl -0x3c(%rbp), %ecx
leaq 0x201bd8(%rip), %rsi    # 0x38ab4a
movb $0x0, %al
callq 0x22a0
jmp 0x188f7b
jmp 0x188f7d
movl -0x2c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2c(%rbp)
jmp 0x188ea5
jmp 0x188f8d
movq -0x28(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x28(%rbp)
jmp 0x188e68
addq $0x50, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/htab.cpp
// Function: query_ct_index(void*, unsigned long)
int query_ct_index(void* ct_idx, uint64_t hash)
{
	ha_ct1_t *g = &(((ha_ct_t*)ct_idx)->h[hash & ((1ULL<<((ha_ct_t*)ct_idx)->pre) - 1)]);
	khint_t k;
	k = yak_ct_get(g->h, hash);
	if (k == kh_end(g->h)) return 0;
	return ((kh_key(g->h, k)&YAK_MAX_COUNT)==YAK_MAX_COUNT)?-1:(kh_key(g->h, k)&YAK_MAX_COUNT);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq 0x20(%rax), %rax
movq -0x18(%rbp), %rcx
movq %rcx, -0x30(%rbp)
movq -0x10(%rbp), %rcx
movl 0x4(%rcx), %ecx
movl $0x1, %edx
shlq %cl, %rdx
movq -0x30(%rbp), %rcx
subq $0x1, %rdx
andq %rdx, %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rax
movq (%rax), %rdi
movq -0x18(%rbp), %rsi
callq 0x18a740
movl %eax, -0x24(%rbp)
movl -0x24(%rbp), %eax
movl %eax, -0x28(%rbp)
movq -0x20(%rbp), %rax
movq (%rax), %rax
cmpq $0x0, 0x10(%rax)
je 0x189031
movq -0x20(%rbp), %rax
movq (%rax), %rax
movl (%rax), %ecx
movl $0x1, %eax
shll %cl, %eax
movl %eax, -0x34(%rbp)
jmp 0x189038
xorl %eax, %eax
movl %eax, -0x34(%rbp)
jmp 0x189038
movl -0x28(%rbp), %eax
movl -0x34(%rbp), %ecx
cmpl %ecx, %eax
jne 0x18904b
movl $0x0, -0x4(%rbp)
jmp 0x18909b
movq -0x20(%rbp), %rax
movq (%rax), %rax
movq 0x10(%rax), %rax
movl -0x24(%rbp), %ecx
movq (%rax,%rcx,8), %rax
andq $0xfff, %rax            # imm = 0xFFF
cmpq $0xfff, %rax            # imm = 0xFFF
jne 0x189078
movq $-0x1, %rax
movq %rax, -0x40(%rbp)
jmp 0x189094
movq -0x20(%rbp), %rax
movq (%rax), %rax
movq 0x10(%rax), %rax
movl -0x24(%rbp), %ecx
movq (%rax,%rcx,8), %rax
andq $0xfff, %rax            # imm = 0xFFF
movq %rax, -0x40(%rbp)
movq -0x40(%rbp), %rax
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/htab.cpp
// Function: ha_ft_ul_gen(hifiasm_opt_t const*, ma_utg_v*, int, int, int)
void *ha_ft_ul_gen(const hifiasm_opt_t *asm_opt, ma_utg_v *us, int k, int w, int cutoff)
{
	yak_ft_t *flt_tab;
    ha_ct_t *h;
	///HAF_COUNT_EXACT ---> no bf; HAF_COUNT_ALL ---> no minimizer
	h = ha_count(asm_opt, HAF_COUNT_ALL|HAF_UG_READ, !(asm_opt->flag&HA_F_NO_HPC), k, w, NULL, NULL, NULL, us, 0, NULL, 0);
	
	// cutoff = (int)(asm_opt->hom_cov * asm_opt->high_factor);
    if (cutoff > YAK_MAX_COUNT - 1) cutoff = YAK_MAX_COUNT - 1;
	// fprintf(stderr, "[M::%s::] cutoff->%d\n\n", __func__, cutoff);
	ha_ct_shrink(h, cutoff, YAK_MAX_COUNT, asm_opt->thread_num);
	flt_tab = gen_hh(h, asm_opt->max_kmer_cnt);
	ha_ct_destroy(h);
	fprintf(stderr, "[M::%s::%.3f*%.2f@%.3fGB] ==> filtered out %ld k-mers occurring %d or more times\n", __func__,
            yak_realtime(), yak_cpu_usage(), yak_peakrss_in_gb(), (long)kh_size(flt_tab), cutoff);
	return (void*)flt_tab;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movl %ecx, -0x18(%rbp)
movl %r8d, -0x1c(%rbp)
movq -0x8(%rbp), %rdi
movq -0x8(%rbp), %rax
movl (%rax), %eax
andl $0x1, %eax
cmpl $0x0, %eax
setne %al
xorb $-0x1, %al
andb $0x1, %al
movzbl %al, %edx
movl -0x14(%rbp), %ecx
movl -0x18(%rbp), %r8d
movq -0x10(%rbp), %rax
movl $0x82, %esi
xorl %r9d, %r9d
xorl %r10d, %r10d
movq $0x0, (%rsp)
movq $0x0, 0x8(%rsp)
movq %rax, 0x10(%rsp)
movl $0x0, 0x18(%rsp)
movq $0x0, 0x20(%rsp)
movl $0x0, 0x28(%rsp)
callq 0x1886f0
movq %rax, -0x30(%rbp)
cmpl $0xffe, -0x1c(%rbp)     # imm = 0xFFE
jle 0x189145
movl $0xffe, -0x1c(%rbp)     # imm = 0xFFE
movq -0x30(%rbp), %rdi
movl -0x1c(%rbp), %esi
movq -0x8(%rbp), %rax
movl 0x7c(%rax), %ecx
movl $0xfff, %edx            # imm = 0xFFF
callq 0x1891f0
movq -0x30(%rbp), %rdi
movq -0x8(%rbp), %rax
movl 0xb0(%rax), %esi
callq 0x1892f0
movq %rax, -0x28(%rbp)
movq -0x30(%rbp), %rdi
callq 0x1894a0
movq 0x23ae5c(%rip), %rax    # 0x3c3fe0
movq (%rax), %rax
movq %rax, -0x48(%rbp)
callq 0x1b7ca0
movsd %xmm0, -0x38(%rbp)
callq 0x1b7d20
movsd %xmm0, -0x40(%rbp)
callq 0x1b7d00
movq -0x48(%rbp), %rdi
movsd -0x40(%rbp), %xmm1
movaps %xmm0, %xmm2
movsd -0x38(%rbp), %xmm0
movq -0x28(%rbp), %rax
movl 0x4(%rax), %eax
movl %eax, %ecx
movl -0x1c(%rbp), %r8d
leaq 0x201995(%rip), %rsi    # 0x38ab5e
leaq 0x2019e0(%rip), %rdx    # 0x38abb0
movb $0x3, %al
callq 0x22a0
movq -0x28(%rbp), %rax
addq $0x80, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/htab.cpp
// Function: ha_ct_shrink(ha_ct_t*, int, int, int)
static void ha_ct_shrink(ha_ct_t *h, int min, int max, int n_thread)
{
	int i;
	shrink_aux_t a;
	a.h = h, a.min = min, a.max = max;
	///still start 4096 threads
	kt_for(n_thread, worker_ct_shrink, &a, 1<<h->pre);
	for (i = 0, h->tot = 0; i < 1<<h->pre; ++i)
		h->tot += kh_size(h->h[i].h);
	fprintf(stderr, "[M::%s::%.3f*%.2f] ==> counted %ld distinct minimizer k-mers\n", __func__,
			yak_realtime(), yak_cpu_usage(), (long)h->tot);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl %edx, -0x10(%rbp)
movl %ecx, -0x14(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x20(%rbp)
movl -0xc(%rbp), %eax
movl %eax, -0x28(%rbp)
movl -0x10(%rbp), %eax
movl %eax, -0x24(%rbp)
movl -0x14(%rbp), %edi
movq -0x8(%rbp), %rax
movl 0x4(%rax), %ecx
movl $0x1, %eax
shll %cl, %eax
movslq %eax, %rcx
leaq 0x780c(%rip), %rsi      # 0x190a40
leaq -0x28(%rbp), %rdx
callq 0x16d710
movl $0x0, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq $0x0, 0x10(%rax)
movl -0x18(%rbp), %eax
movq -0x8(%rbp), %rcx
movl 0x4(%rcx), %ecx
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
cmpl %ecx, %eax
jge 0x189299
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rax
movslq -0x18(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq (%rax), %rax
movl 0x4(%rax), %eax
movl %eax, %ecx
movq -0x8(%rbp), %rax
addq 0x10(%rax), %rcx
movq %rcx, 0x10(%rax)
movl -0x18(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x18(%rbp)
jmp 0x189250
movq 0x23ad40(%rip), %rax    # 0x3c3fe0
movq (%rax), %rax
movq %rax, -0x38(%rbp)
callq 0x1b7ca0
movsd %xmm0, -0x30(%rbp)
callq 0x1b7d20
movq -0x38(%rbp), %rdi
movaps %xmm0, %xmm1
movsd -0x30(%rbp), %xmm0
movq -0x8(%rbp), %rax
movq 0x10(%rax), %rcx
leaq 0x20191a(%rip), %rsi    # 0x38abeb
leaq 0x201ef7(%rip), %rdx    # 0x38b1cf
movb $0x2, %al
callq 0x22a0
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: chhylp123[P]hifiasm/htab.cpp
// Function: ha_ct_destroy(ha_ct_t*)
static void ha_ct_destroy(ha_ct_t *h)
{
	int i;
	if (h == 0) return;
	ha_ct_destroy_bf(h);
	for (i = 0; i < 1<<h->pre; ++i)
		yak_ct_destroy(h->h[i].h);
	free(h->h); free(h);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x10, %rsp
movq %rdi, -0x8(%rbp)
cmpq $0x0, -0x8(%rbp)
jne 0x1894b5
jmp 0x189518
movq -0x8(%rbp), %rdi
callq 0x186c60
movl $0x0, -0xc(%rbp)
movl -0xc(%rbp), %eax
movq -0x8(%rbp), %rcx
movl 0x4(%rcx), %ecx
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
cmpl %ecx, %eax
jge 0x189502
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rax
movslq -0xc(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq (%rax), %rdi
callq 0x18c0c0
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x1894c5
movq -0x8(%rbp), %rax
movq 0x20(%rax), %rdi
callq 0x2210
movq -0x8(%rbp), %rdi
callq 0x2210
addq $0x10, %rsp
popq %rbp
retq
nop
// File: chhylp123[P]hifiasm/htab.cpp
// Function: ha_ft_ug_gen(hifiasm_opt_t const*, ma_utg_v*, int, int, int, int, int)
void *ha_ft_ug_gen(const hifiasm_opt_t *asm_opt, ma_utg_v *us, int is_HPC, int k, int w, int min_freq, int max_freq)
{
	yak_ft_t *flt_tab;
	ha_ct_t *h;
	///HAF_COUNT_EXACT ---> no bf; HAF_COUNT_ALL ---> no minimizer
	h = ha_count(asm_opt, HAF_COUNT_ALL|HAF_UG_READ|HAF_COUNT_EXACT, is_HPC, k, w, NULL, NULL, NULL, us, 0, NULL, 0);
	ha_ct_shrink(h, min_freq, max_freq>YAK_MAX_COUNT-1?YAK_MAX_COUNT-1:max_freq, asm_opt->thread_num);
	flt_tab = gen_hh(h, YAK_MAX_COUNT);
	ha_ct_destroy(h);
	return (void*)flt_tab;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movl 0x10(%rbp), %eax
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movl %ecx, -0x18(%rbp)
movl %r8d, -0x1c(%rbp)
movl %r9d, -0x20(%rbp)
movq -0x8(%rbp), %rdi
movl -0x14(%rbp), %edx
movl -0x18(%rbp), %ecx
movl -0x1c(%rbp), %r8d
movq -0x10(%rbp), %rax
movl $0x83, %esi
xorl %r9d, %r9d
xorl %r10d, %r10d
movq $0x0, (%rsp)
movq $0x0, 0x8(%rsp)
movq %rax, 0x10(%rsp)
movl $0x0, 0x18(%rsp)
movq $0x0, 0x20(%rsp)
movl $0x0, 0x28(%rsp)
callq 0x1886f0
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rax
movq %rax, -0x40(%rbp)
movl -0x20(%rbp), %eax
movl %eax, -0x34(%rbp)
cmpl $0xffe, 0x10(%rbp)      # imm = 0xFFE
jle 0x1895ba
movl $0xffe, %eax            # imm = 0xFFE
movl %eax, -0x44(%rbp)
jmp 0x1895c0
movl 0x10(%rbp), %eax
movl %eax, -0x44(%rbp)
movl -0x34(%rbp), %esi
movq -0x40(%rbp), %rdi
movl -0x44(%rbp), %edx
movq -0x8(%rbp), %rax
movl 0x7c(%rax), %ecx
callq 0x1891f0
movq -0x30(%rbp), %rdi
movl $0xfff, %esi            # imm = 0xFFF
callq 0x1892f0
movq %rax, -0x28(%rbp)
movq -0x30(%rbp), %rdi
callq 0x1894a0
movq -0x28(%rbp), %rax
addq $0x80, %rsp
popq %rbp
retq
nop
// File: chhylp123[P]hifiasm/htab.cpp
// Function: write_ct_index(void*, char*)
int write_ct_index(void *i_ct_idx, char* file_name)
{
	char* gfa_name = (char*)malloc(strlen(file_name)+25);
    sprintf(gfa_name, "%s.ct_flt", file_name);
    FILE* fp = fopen(gfa_name, "w");
	if (!fp) {
		free(gfa_name);
        return 0;
    }
	ha_ct_t* ct_idx = (ha_ct_t*)i_ct_idx;
	int i;
	ha_ct1_t *g;
	fwrite(&ct_idx->k, sizeof(ct_idx->k), 1, fp);
	fwrite(&ct_idx->pre, sizeof(ct_idx->pre), 1, fp);
	fwrite(&ct_idx->n_hash, sizeof(ct_idx->n_hash), 1, fp);
	fwrite(&ct_idx->n_shift, sizeof(ct_idx->n_shift), 1, fp);
	fwrite(&ct_idx->tot, sizeof(ct_idx->tot), 1, fp);
	for (i = 0; i < 1<<ct_idx->pre; i++)
	{
		g = &(ct_idx->h[i]);
		yak_ct_save(g->h, fp);
	}


	fprintf(stderr, "[M::%s] Index has been written.\n", __func__);
    free(gfa_name);
	fclose(fp);
	return 1;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x10(%rbp)
movq %rsi, -0x18(%rbp)
movq -0x18(%rbp), %rdi
callq 0x20a0
movq %rax, %rdi
addq $0x19, %rdi
callq 0x2270
movq %rax, -0x20(%rbp)
movq -0x20(%rbp), %rdi
movq -0x18(%rbp), %rdx
leaq 0x201520(%rip), %rsi    # 0x38ae38
movb $0x0, %al
callq 0x2050
movq -0x20(%rbp), %rdi
leaq 0x20faa8(%rip), %rsi    # 0x3993d2
callq 0x2200
movq %rax, -0x28(%rbp)
cmpq $0x0, -0x28(%rbp)
jne 0x18994f
movq -0x20(%rbp), %rdi
callq 0x2210
movl $0x0, -0x4(%rbp)
jmp 0x189a62
movq -0x10(%rbp), %rax
movq %rax, -0x30(%rbp)
movq -0x30(%rbp), %rdi
movq -0x28(%rbp), %rcx
movl $0x4, %esi
movl $0x1, %edx
callq 0x2400
movq -0x30(%rbp), %rdi
addq $0x4, %rdi
movq -0x28(%rbp), %rcx
movl $0x4, %esi
movl $0x1, %edx
callq 0x2400
movq -0x30(%rbp), %rdi
addq $0x8, %rdi
movq -0x28(%rbp), %rcx
movl $0x4, %esi
movl $0x1, %edx
callq 0x2400
movq -0x30(%rbp), %rdi
addq $0xc, %rdi
movq -0x28(%rbp), %rcx
movl $0x4, %esi
movl $0x1, %edx
callq 0x2400
movq -0x30(%rbp), %rdi
addq $0x10, %rdi
movq -0x28(%rbp), %rcx
movl $0x8, %esi
movl $0x1, %edx
callq 0x2400
movl $0x0, -0x34(%rbp)
movl -0x34(%rbp), %eax
movq -0x30(%rbp), %rcx
movl 0x4(%rcx), %ecx
movl $0x1, %edx
shll %cl, %edx
movl %edx, %ecx
cmpl %ecx, %eax
jge 0x189a2a
movq -0x30(%rbp), %rax
movq 0x20(%rax), %rax
movslq -0x34(%rbp), %rcx
shlq $0x4, %rcx
addq %rcx, %rax
movq %rax, -0x40(%rbp)
movq -0x40(%rbp), %rax
movq (%rax), %rdi
movq -0x28(%rbp), %rsi
callq 0x18a770
movl -0x34(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x34(%rbp)
jmp 0x1899e1
movq 0x23a5af(%rip), %rax    # 0x3c3fe0
movq (%rax), %rdi
leaq 0x201407(%rip), %rsi    # 0x38ae42
leaq 0x201421(%rip), %rdx    # 0x38ae63
movb $0x0, %al
callq 0x22a0
movq -0x20(%rbp), %rdi
callq 0x2210
movq -0x28(%rbp), %rdi
callq 0x21a0
movl $0x1, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x40, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: chhylp123[P]hifiasm/htab.cpp
// Function: ha_ct_hist(ha_ct_t const*, long*, int)
static void ha_ct_hist(const ha_ct_t *h, int64_t cnt[YAK_N_COUNTS], int n_thread)
{
	hist_aux_t a;
	int i, j;
	a.h = h;
	memset(cnt, 0, YAK_N_COUNTS * sizeof(uint64_t));
	CALLOC(a.cnt, n_thread);
	///start 4096 threads
	kt_for(n_thread, worker_ct_hist, &a, 1<<h->pre);
	for (i = 0; i < YAK_N_COUNTS; ++i) cnt[i] = 0;
	for (j = 0; j < n_thread; ++j)
		for (i = 0; i < YAK_N_COUNTS; ++i)
			cnt[i] += a.cnt[j].c[i];
	free(a.cnt);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movl %edx, -0x14(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x10(%rbp), %rdi
xorl %esi, %esi
movl $0x8000, %edx           # imm = 0x8000
callq 0x2100
movslq -0x14(%rbp), %rdi
movl $0x8000, %esi           # imm = 0x8000
callq 0x2140
movq %rax, -0x20(%rbp)
movl -0x14(%rbp), %edi
movq -0x8(%rbp), %rax
movl 0x4(%rax), %ecx
movl $0x1, %eax
shll %cl, %eax
movslq %eax, %rcx
leaq 0x77f8(%rip), %rsi      # 0x1912c0
leaq -0x28(%rbp), %rdx
callq 0x16d710
movl $0x0, -0x2c(%rbp)
cmpl $0x1000, -0x2c(%rbp)    # imm = 0x1000
jge 0x189afc
movq -0x10(%rbp), %rax
movslq -0x2c(%rbp), %rcx
movq $0x0, (%rax,%rcx,8)
movl -0x2c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2c(%rbp)
jmp 0x189ad8
movl $0x0, -0x30(%rbp)
movl -0x30(%rbp), %eax
cmpl -0x14(%rbp), %eax
jge 0x189b5a
movl $0x0, -0x2c(%rbp)
cmpl $0x1000, -0x2c(%rbp)    # imm = 0x1000
jge 0x189b4d
movq -0x20(%rbp), %rax
movslq -0x30(%rbp), %rcx
shlq $0xf, %rcx
addq %rcx, %rax
movslq -0x2c(%rbp), %rcx
movq (%rax,%rcx,8), %rdx
movq -0x10(%rbp), %rax
movslq -0x2c(%rbp), %rcx
addq (%rax,%rcx,8), %rdx
movq %rdx, (%rax,%rcx,8)
movl -0x2c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x2c(%rbp)
jmp 0x189b12
jmp 0x189b4f
movl -0x30(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x30(%rbp)
jmp 0x189b03
movq -0x20(%rbp), %rdi
callq 0x2210
addq $0x30, %rsp
popq %rbp
retq
nopl (%rax)