// File: splatlab[P]debgr/threadsafe-gqf/gqf.c
// Function: qf_dump_block(quotient_filter const*, unsigned long)
static inline void qf_dump_block(const QF *qf, uint64_t i)
{
	uint64_t j;

	printf("%-192d", get_block(qf, i)->offset);
	printf("\n");

	for (j = 0; j < SLOTS_PER_BLOCK; j++)
		printf("%02lx ", j);
	printf("\n");

	for (j = 0; j < SLOTS_PER_BLOCK; j++)
		printf(" %d ", (get_block(qf, i)->occupieds[j/64] & (1ULL << (j%64))) ? 1 : 0);
	printf("\n");

	for (j = 0; j < SLOTS_PER_BLOCK; j++)
		printf(" %d ", (get_block(qf, i)->runends[j/64] & (1ULL << (j%64))) ? 1 : 0);
	printf("\n");

#if BITS_PER_SLOT == 8 || BITS_PER_SLOT == 16 || BITS_PER_SLOT == 32
	for (j = 0; j < SLOTS_PER_BLOCK; j++)
		printf("%02x ", get_block(qf, i)->slots[j]);
#elif BITS_PER_SLOT == 64
	for (j = 0; j < SLOTS_PER_BLOCK; j++)
		printf("%02lx ", get_block(qf, i)->slots[j]);
#else
	for (j = 0; j < SLOTS_PER_BLOCK * qf->metadata->bits_per_slot / 8; j++)
		printf("%02x ", get_block(qf, i)->slots[j]);
#endif

	printf("\n");

	printf("\n");
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0x27590
movzbl (%rax), %esi
leaq 0x63ee(%rip), %rdi      # 0x2ab15
movb $0x0, %al
callq 0x3030
leaq 0x6375(%rip), %rdi      # 0x2aaaa
movb $0x0, %al
callq 0x3030
movq $0x0, -0x18(%rbp)
cmpq $0x40, -0x18(%rbp)
jae 0x2476b
movq -0x18(%rbp), %rsi
leaq 0x63c6(%rip), %rdi      # 0x2ab1c
movb $0x0, %al
callq 0x3030
movq -0x18(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x18(%rbp)
jmp 0x24744
leaq 0x6338(%rip), %rdi      # 0x2aaaa
movb $0x0, %al
callq 0x3030
movq $0x0, -0x18(%rbp)
cmpq $0x40, -0x18(%rbp)
jae 0x247e7
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0x27590
movq -0x18(%rbp), %rcx
shrq $0x6, %rcx
movq 0x1(%rax,%rcx,8), %rax
movq %rax, -0x20(%rbp)
movq -0x18(%rbp), %rcx
andq $0x3f, %rcx
movl $0x1, %eax
shlq %cl, %rax
movq -0x20(%rbp), %rcx
andq %rax, %rcx
xorl %esi, %esi
movl $0x1, %eax
cmpq $0x0, %rcx
cmovnel %eax, %esi
leaq 0x6351(%rip), %rdi      # 0x2ab23
movb $0x0, %al
callq 0x3030
movq -0x18(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x18(%rbp)
jmp 0x24781
leaq 0x62bc(%rip), %rdi      # 0x2aaaa
movb $0x0, %al
callq 0x3030
movq $0x0, -0x18(%rbp)
cmpq $0x40, -0x18(%rbp)
jae 0x24863
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0x27590
movq -0x18(%rbp), %rcx
shrq $0x6, %rcx
movq 0x9(%rax,%rcx,8), %rax
movq %rax, -0x28(%rbp)
movq -0x18(%rbp), %rcx
andq $0x3f, %rcx
movl $0x1, %eax
shlq %cl, %rax
movq -0x28(%rbp), %rcx
andq %rax, %rcx
xorl %esi, %esi
movl $0x1, %eax
cmpq $0x0, %rcx
cmovnel %eax, %esi
leaq 0x62d5(%rip), %rdi      # 0x2ab23
movb $0x0, %al
callq 0x3030
movq -0x18(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x18(%rbp)
jmp 0x247fd
leaq 0x6240(%rip), %rdi      # 0x2aaaa
movb $0x0, %al
callq 0x3030
movq $0x0, -0x18(%rbp)
movq -0x18(%rbp), %rax
movq -0x8(%rbp), %rcx
movq 0x8(%rcx), %rcx
movq 0x38(%rcx), %rcx
shlq $0x6, %rcx
shrq $0x3, %rcx
cmpq %rcx, %rax
jae 0x248c8
movq -0x8(%rbp), %rdi
movq -0x10(%rbp), %rsi
callq 0x27590
movq -0x18(%rbp), %rcx
movzbl 0x11(%rax,%rcx), %esi
leaq 0x6275(%rip), %rdi      # 0x2ab28
movb $0x0, %al
callq 0x3030
movq -0x18(%rbp), %rax
addq $0x1, %rax
movq %rax, -0x18(%rbp)
jmp 0x24879
leaq 0x61db(%rip), %rdi      # 0x2aaaa
movb $0x0, %al
callq 0x3030
leaq 0x61cd(%rip), %rdi      # 0x2aaaa
movb $0x0, %al
callq 0x3030
addq $0x30, %rsp
popq %rbp
retq
nopw (%rax,%rax)