// File: /workspace/github_c_makefile_star2_O0/samtools[P]htslib/test/test-regidx.c
// Function: main
int main(int argc, char **argv)
{
    static struct option loptions[] =
    {
        {"help",0,0,'h'},
        {"verbose",0,0,'v'},
        {"seed",1,0,'s'},
        {0,0,0,0}
    };
    int c;
    int seed = (int)time(NULL);
    while ((c = getopt_long(argc, argv, "hvs:",loptions,NULL)) >= 0)
    {
        switch (c)
        {
            case 's': seed = atoi(optarg); break;
            case 'v': verbose++; break;
            default: usage(); break;
        }
    }

    info("Testing sequential access\n");
    test_sequential_access();

    info("Testing TAB\n");
    test(create_line_tab,regidx_parse_tab);

    info("Testing REG\n");
    test(create_line_reg,regidx_parse_reg);

    info("Testing BED\n");
    test(create_line_bed,regidx_parse_bed);

    info("Testing custom payload\n");
    test_custom_payload();

    info("Testing cases encountered in past\n");
    test_explicit("12:2064519-2064763","12:2064488-2067434","1");

    int i, ntest = 1000, nreg = 50;
    srand(seed);
    info("%d randomized tests, %d regions per test. Random seed is %d\n", ntest,nreg,seed);
    for (i=0; i<ntest; i++) test_random(nreg,1,1000);

    return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x30, %rsp
movl $0x0, -0x4(%rbp)
movl %edi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
xorl %eax, %eax
movl %eax, %edi
callq 0x4440
movl %eax, -0x18(%rbp)
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rsi
leaq 0xe3e71(%rip), %rdx     # 0xeb591
leaq 0x102de9(%rip), %rcx    # 0x10a510
xorl %eax, %eax
movl %eax, %r8d
callq 0x4850
movl %eax, -0x14(%rbp)
cmpl $0x0, %eax
jl 0x777c
movl -0x14(%rbp), %eax
movl %eax, -0x28(%rbp)
subl $0x73, %eax
je 0x7750
jmp 0x7746
movl -0x28(%rbp), %eax
subl $0x76, %eax
je 0x7764
jmp 0x7775
movq 0x102871(%rip), %rax    # 0x109fc8
movq (%rax), %rdi
callq 0x47d0
movl %eax, -0x18(%rbp)
jmp 0x777a
movl 0x1075da(%rip), %eax    # 0x10ed44
addl $0x1, %eax
movl %eax, 0x1075d1(%rip)    # 0x10ed44
jmp 0x777a
callq 0x7890
jmp 0x7712
leaq 0xe3e13(%rip), %rdi     # 0xeb596
movb $0x0, %al
callq 0x7920
callq 0x5d40
leaq 0xe3e1b(%rip), %rdi     # 0xeb5b1
movb $0x0, %al
callq 0x7920
leaq -0xab4(%rip), %rdi      # 0x6cf0
leaq 0x2755(%rip), %rsi      # 0x9f00
callq 0x6d90
leaq 0xe3e07(%rip), %rdi     # 0xeb5be
movb $0x0, %al
callq 0x7920
leaq -0xa85(%rip), %rdi      # 0x6d40
leaq 0x3894(%rip), %rsi      # 0xb060
callq 0x6d90
leaq 0xe3df3(%rip), %rdi     # 0xeb5cb
movb $0x0, %al
callq 0x7920
leaq -0xb46(%rip), %rdi      # 0x6ca0
leaq 0x2e33(%rip), %rsi      # 0xa620
callq 0x6d90
leaq 0xe3ddf(%rip), %rdi     # 0xeb5d8
movb $0x0, %al
callq 0x7920
callq 0x60a0
leaq 0xe3de4(%rip), %rdi     # 0xeb5f0
movb $0x0, %al
callq 0x7920
leaq 0xe3df9(%rip), %rdi     # 0xeb613
leaq 0xe3e05(%rip), %rsi     # 0xeb626
leaq 0xe6b8d(%rip), %rdx     # 0xee3b5
callq 0x68c0
movl $0x3e8, -0x20(%rbp)     # imm = 0x3E8
movl $0x32, -0x24(%rbp)
movl -0x18(%rbp), %edi
callq 0x4480
movl -0x20(%rbp), %esi
movl -0x24(%rbp), %edx
movl -0x18(%rbp), %ecx
leaq 0xe3de6(%rip), %rdi     # 0xeb639
movb $0x0, %al
callq 0x7920
movl $0x0, -0x1c(%rbp)
movl -0x1c(%rbp), %eax
cmpl -0x20(%rbp), %eax
jge 0x7886
movl -0x24(%rbp), %edi
movl $0x1, %esi
movl $0x3e8, %edx            # imm = 0x3E8
callq 0x65a0
movl -0x1c(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x1c(%rbp)
jmp 0x7861
xorl %eax, %eax
addq $0x30, %rsp
popq %rbp
retq
nop