// File: /workspace/github_c_makefile_star2_O3/deplinenoise[P]tundra/unittest/Test_HashTable.cpp
// Function: HashSetTest_MultiDistinct_Test::TestBody()
TEST_F(HashSetTest, MultiDistinct)
{
  HashSet<kFlagCaseSensitive> tbl;
  HashSetInit(&tbl, &heap);

  for (int i = 0; i < 2048; ++i)
  {
    char str[128];
    sprintf(str, "foo%d", i);
    HashSetInsert(&tbl, Djb2Hash(str), StrDup(&alloc, str));
  }
  EXPECT_EQ(2048, tbl.m_RecordCount);

  for (int i = 0; i < 2048; ++i)
  {
    char str[128];
    sprintf(str, "foo%d", i);
    EXPECT_TRUE(HashSetLookup(&tbl, Djb2Hash(str), str));
  }
  HashSetDestroy(&tbl);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0xf8, %rsp
movq %rdi, %rbx
leaq 0x10(%rdi), %rax
xorps %xmm0, %xmm0
leaq 0x40(%rsp), %rcx
movups %xmm0, 0xc(%rcx)
movaps %xmm0, (%rcx)
movq %rax, 0x20(%rcx)
addq $0x18, %rbx
leaq 0x70(%rsp), %r12
xorl %ebp, %ebp
movq %r12, %rdi
leaq 0x16db3(%rip), %rsi     # 0x563b5
movl %ebp, %edx
xorl %eax, %eax
callq 0xc0f0
movq %r12, %rdi
callq 0x40c20
movl %eax, %r13d
movq %r12, %rdi
callq 0xc260
movq %rax, %r15
leaq 0x1(%rax), %rsi
movl $0x1, %edx
movq %rbx, %rdi
callq 0x41fb0
movq %rax, %r14
movq %rax, %rdi
movq %r12, %rsi
movq %r15, %rdx
callq 0xc4b0
movb $0x0, (%r14,%r15)
leaq 0x40(%rsp), %rdi
movl %r13d, %esi
movq %r14, %rdx
callq 0x406fe
incl %ebp
cmpl $0x800, %ebp            # imm = 0x800
jne 0x3f5f8
leaq 0x18(%rsp), %rcx
movl $0x800, (%rcx)          # imm = 0x800
leaq 0x58(%rsp), %r8
leaq 0x16d42(%rip), %rsi     # 0x563bb
leaq 0x16d0d(%rip), %rdx     # 0x5638d
leaq 0x70(%rsp), %rbx
movq %rbx, %rdi
callq 0x3ba7c
cmpb $0x0, (%rbx)
jne 0x3f70c
leaq 0x18(%rsp), %rdi
callq 0x12e46
movq 0x78(%rsp), %rax
testq %rax, %rax
je 0x3f6ab
movq (%rax), %r8
jmp 0x3f6b2
leaq 0x18815(%rip), %r8      # 0x57ec7
leaq 0x16cb8(%rip), %rdx     # 0x56371
leaq 0x8(%rsp), %rdi
movl $0x1, %esi
movl $0x91, %ecx
callq 0x10b64
leaq 0x8(%rsp), %rdi
leaq 0x18(%rsp), %rsi
callq 0x10c00
leaq 0x8(%rsp), %rdi
callq 0x10bd0
cmpq $0x0, 0x18(%rsp)
je 0x3f70c
movl $0x1, %edi
callq 0x10b61
testb %al, %al
je 0x3f70c
movq 0x18(%rsp), %rdi
testq %rdi, %rdi
je 0x3f70c
movq (%rdi), %rax
callq *0x8(%rax)
leaq 0x78(%rsp), %rdi
xorl %esi, %esi
callq 0x2c37a
leaq 0x10(%rsp), %rbx
leaq 0x16c91(%rip), %r14     # 0x563b5
leaq 0x70(%rsp), %r15
leaq 0x40(%rsp), %r12
leaq 0x38(%rsp), %rbp
xorl %r13d, %r13d
movq %r15, %rdi
movq %r14, %rsi
movl %r13d, %edx
xorl %eax, %eax
callq 0xc0f0
movq %r15, %rdi
callq 0x40c20
movq %r12, %rdi
movl %eax, %esi
movq %r15, %rdx
callq 0x40288
cmpl $-0x1, %eax
setne 0x8(%rsp)
movq $0x0, 0x10(%rsp)
je 0x3f789
movq %rbx, %rdi
xorl %esi, %esi
callq 0x2c37a
incl %r13d
cmpl $0x800, %r13d           # imm = 0x800
jne 0x3f736
jmp 0x3f837
movq %rsp, %rdi
callq 0x12e46
leaq 0x18(%rsp), %rdi
leaq 0x8(%rsp), %rsi
leaq 0x16c66(%rip), %rdx     # 0x56408
leaq 0x13af7(%rip), %rcx     # 0x532a0
leaq 0x12faa(%rip), %r8      # 0x5275a
callq 0x143f5
movq 0x18(%rsp), %r8
movq %rbp, %rdi
movl $0x1, %esi
leaq 0x16ba8(%rip), %rdx     # 0x56371
movl $0x97, %ecx
callq 0x10b64
movq %rbp, %rdi
movq %rsp, %rsi
callq 0x10c00
movq %rbp, %rdi
callq 0x10bd0
movq 0x18(%rsp), %rdi
leaq 0x28(%rsp), %rax
cmpq %rax, %rdi
je 0x3f802
movq 0x28(%rsp), %rsi
incq %rsi
callq 0xc600
cmpq $0x0, (%rsp)
je 0x3f76e
movl $0x1, %edi
callq 0x10b61
testb %al, %al
je 0x3f76e
movq (%rsp), %rdi
testq %rdi, %rdi
je 0x3f76e
movq (%rdi), %rax
callq *0x8(%rax)
jmp 0x3f76e
movq 0x40(%rsp), %rsi
movq 0x60(%rsp), %rdi
callq 0x41eea
movq 0x48(%rsp), %rsi
movq 0x60(%rsp), %rdi
callq 0x41eea
addq $0xf8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x3f8e7
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x10bd0
jmp 0x3f87b
movq %rax, %rbx
leaq 0x18(%rsp), %rdi
callq 0x31a70
jmp 0x3f88a
movq %rax, %rbx
leaq 0x70(%rsp), %rdi
jmp 0x3f8da
jmp 0x3f8e7
jmp 0x3f8e7
movq %rax, %rbx
jmp 0x3f8cd
movq %rax, %rbx
jmp 0x3f8d5
movq %rax, %rbx
leaq 0x38(%rsp), %rdi
callq 0x10bd0
jmp 0x3f8b1
movq %rax, %rbx
movq 0x18(%rsp), %rdi
leaq 0x28(%rsp), %rax
cmpq %rax, %rdi
je 0x3f8cd
movq 0x28(%rsp), %rsi
incq %rsi
callq 0xc600
movq %rsp, %rdi
callq 0x31a70
leaq 0x8(%rsp), %rdi
callq 0x31a82
movq %rbx, %rdi
callq 0xcbb0
movq %rax, %rdi
callq 0x287ef
nop