// File: /workspace/github_cpp_makefile_star2_O2/Albuso0[P]support/main.cpp
// Function: main
int main(int argc, char *argv[])
{
    double pmin = 0;
    int L = 0;
    double M = 0;
    std::string fin = "", hist = "";
    
    std::CommandLine cmd;
    cmd.AddValue ("pmin",  "Minimum mass", pmin);
    cmd.AddValue ("L",  "Polynoimal degree. Default c0*log(1/pmin)", L);
    cmd.AddValue ("M",  "M/n is the right-end of approximation interval. Default c1*log(1/pmin)", M);
    cmd.AddValue ("fin",  "fingerprint data file", fin);
    cmd.AddValue ("hist",  "histogram data file", hist);
    cmd.Parse (argc, argv);
    if( pmin == 0 ) { std::cerr<<"Please input pmin!\n"; exit(1); }
    if( L == 0 ) L = 0.45*log(1/pmin); // Default value
    if( M == 0 ) M = 0.5*log(1/pmin);  // Default value
    if( (hist=="") && (fin=="") ) { std::cerr<<"Please input fingerprint or histogram!\n"; exit(1); }
    
    printf("\n");
    // Configure estimator
    Support support( pmin );  // set pmin
    support.setDegree( L );   // set degree    =L
    support.setInterval( M ); // set interval  =[pmin,M/n]
    print_param(support);

    // Input fingerprint from file
    if ( fin!="")
        support.setFin(fin);
    else
        support.setHist(hist);
    print_results(support);

    
    return 0;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x110, %rsp            # imm = 0x110
andq $0x0, 0x30(%rsp)
movq %rsi, %rbx
andl $0x0, 0x4(%rsp)
movl %edi, %ebp
andq $0x0, 0x28(%rsp)
leaq 0x1e99(%rip), %r14      # 0x51ed
leaq 0x90(%rsp), %rdi
leaq 0x38(%rsp), %rdx
movq %r14, %rsi
callq 0x386c
leaq 0xb0(%rsp), %rdi
leaq 0x38(%rsp), %rdx
movq %r14, %rsi
callq 0x386c
leaq 0x78(%rsp), %rax
movq %rax, 0x8(%rax)
movq %rax, (%rax)
andq $0x0, 0x10(%rax)
leaq 0x1cd7(%rip), %rsi      # 0x506d
leaq 0x38(%rsp), %rdi
leaq 0x3(%rsp), %rdx
callq 0x386c
leaq 0x1cc6(%rip), %rsi      # 0x5072
leaq 0x8(%rsp), %rdi
leaq 0x2(%rsp), %rdx
callq 0x386c
leaq 0x78(%rsp), %rdi
leaq 0x38(%rsp), %rsi
leaq 0x8(%rsp), %rdx
leaq 0x30(%rsp), %rcx
callq 0x38a8
leaq 0x8(%rsp), %rdi
callq 0x20e0
leaq 0x38(%rsp), %rdi
callq 0x20e0
leaq 0x1c90(%rip), %rsi      # 0x507f
leaq 0x38(%rsp), %rdi
leaq 0x3(%rsp), %rdx
callq 0x386c
leaq 0x1c7c(%rip), %rsi      # 0x5081
leaq 0x8(%rsp), %rdi
leaq 0x2(%rsp), %rdx
callq 0x386c
leaq 0x78(%rsp), %rdi
leaq 0x38(%rsp), %rsi
leaq 0x8(%rsp), %rdx
leaq 0x4(%rsp), %rcx
callq 0x393e
leaq 0x8(%rsp), %rdi
callq 0x20e0
leaq 0x38(%rsp), %rdi
callq 0x20e0
leaq 0x1c63(%rip), %rsi      # 0x50ab
leaq 0x38(%rsp), %rdi
leaq 0x3(%rsp), %rdx
callq 0x386c
leaq 0x1c4f(%rip), %rsi      # 0x50ad
leaq 0x8(%rsp), %rdi
leaq 0x2(%rsp), %rdx
callq 0x386c
leaq 0x78(%rsp), %rdi
leaq 0x38(%rsp), %rsi
leaq 0x8(%rsp), %rdx
leaq 0x28(%rsp), %rcx
callq 0x38a8
leaq 0x8(%rsp), %rdi
callq 0x20e0
leaq 0x38(%rsp), %rdi
callq 0x20e0
leaq 0x1c53(%rip), %rsi      # 0x50f4
leaq 0x38(%rsp), %rdi
leaq 0x3(%rsp), %rdx
callq 0x386c
leaq 0x1c41(%rip), %rsi      # 0x50f8
leaq 0x8(%rsp), %rdi
leaq 0x2(%rsp), %rdx
callq 0x386c
leaq 0x78(%rsp), %rdi
leaq 0x38(%rsp), %rsi
leaq 0x8(%rsp), %rdx
leaq 0x90(%rsp), %rcx
callq 0x39d4
leaq 0x8(%rsp), %rdi
callq 0x20e0
leaq 0x38(%rsp), %rdi
callq 0x20e0
leaq 0x1c11(%rip), %rsi      # 0x510e
leaq 0x38(%rsp), %rdi
leaq 0x3(%rsp), %rdx
callq 0x386c
leaq 0x1c00(%rip), %rsi      # 0x5113
leaq 0x8(%rsp), %rdi
leaq 0x2(%rsp), %rdx
callq 0x386c
leaq 0x78(%rsp), %rdi
leaq 0x38(%rsp), %rsi
leaq 0x8(%rsp), %rdx
leaq 0xb0(%rsp), %rcx
callq 0x39d4
leaq 0x8(%rsp), %rdi
callq 0x20e0
leaq 0x38(%rsp), %rdi
callq 0x20e0
leaq 0x78(%rsp), %rdi
movl %ebp, %esi
movq %rbx, %rdx
callq 0x3e88
movsd 0x30(%rsp), %xmm1
xorpd %xmm0, %xmm0
ucomisd %xmm0, %xmm1
jne 0x3577
jnp 0x36ec
cmpl $0x0, 0x4(%rsp)
jne 0x359f
movsd 0x1a82(%rip), %xmm0     # 0x5008
divsd %xmm1, %xmm0
callq 0x21a0
mulsd 0x1a89(%rip), %xmm0     # 0x5020
cvttsd2si %xmm0, %eax
movl %eax, 0x4(%rsp)
movsd 0x28(%rsp), %xmm0
xorpd %xmm1, %xmm1
ucomisd %xmm1, %xmm0
jne 0x35d2
jp 0x35d2
movsd 0x1a4f(%rip), %xmm0     # 0x5008
divsd 0x30(%rsp), %xmm0
callq 0x21a0
mulsd 0x1a5c(%rip), %xmm0     # 0x5028
movsd %xmm0, 0x28(%rsp)
leaq 0x1c14(%rip), %rsi      # 0x51ed
leaq 0xb0(%rsp), %rdi
callq 0x3a6a
testb %al, %al
je 0x3606
leaq 0x1bfc(%rip), %rsi      # 0x51ed
leaq 0x90(%rsp), %rdi
callq 0x3a6a
testb %al, %al
jne 0x3701
pushq $0xa
popq %rdi
callq 0x22a0
movsd 0x30(%rsp), %xmm0
leaq 0x38(%rsp), %rdi
callq 0x29dc
movl 0x4(%rsp), %eax
leaq 0x38(%rsp), %rdi
movl %eax, 0x10(%rdi)
movsd 0x28(%rsp), %xmm0
movsd %xmm0, 0x18(%rdi)
callq 0x37b8
leaq 0x1bac(%rip), %rsi      # 0x51ed
leaq 0x90(%rsp), %rdi
callq 0x3a77
testb %al, %al
je 0x3679
leaq 0xf0(%rsp), %rbx
leaq 0x90(%rsp), %rsi
movq %rbx, %rdi
callq 0x2290
leaq 0x38(%rsp), %rdi
movq %rbx, %rsi
callq 0x2a40
jmp 0x369e
leaq 0xd0(%rsp), %rbx
leaq 0xb0(%rsp), %rsi
movq %rbx, %rdi
callq 0x2290
leaq 0x38(%rsp), %rdi
movq %rbx, %rsi
callq 0x2ccc
movq %rbx, %rdi
callq 0x20e0
leaq 0x38(%rsp), %rdi
callq 0x380d
leaq 0x38(%rsp), %rdi
callq 0x2e42
leaq 0x78(%rsp), %rdi
callq 0x42c4
leaq 0xb0(%rsp), %rdi
callq 0x20e0
leaq 0x90(%rsp), %rdi
callq 0x20e0
xorl %eax, %eax
addq $0x110, %rsp            # imm = 0x110
popq %rbx
popq %r14
popq %rbp
retq
movq 0x48fd(%rip), %rdi      # 0x7ff0
leaq 0x1a2d(%rip), %rsi      # 0x5127
callq 0x2200
jmp 0x3714
movq 0x48e8(%rip), %rdi      # 0x7ff0
leaq 0x1a2c(%rip), %rsi      # 0x513b
callq 0x2200
pushq $0x1
popq %rdi
callq 0x2260
movq %rax, %rbx
leaq 0xd0(%rsp), %rdi
jmp 0x3734
movq %rax, %rbx
leaq 0xf0(%rsp), %rdi
callq 0x20e0
jmp 0x3782
jmp 0x377a
jmp 0x3755
jmp 0x3764
jmp 0x377a
jmp 0x3755
jmp 0x3764
jmp 0x377a
jmp 0x3755
jmp 0x3764
jmp 0x377a
jmp 0x3755
jmp 0x3764
jmp 0x377a
movq %rax, %rbx
leaq 0x8(%rsp), %rdi
callq 0x20e0
jmp 0x3767
movq %rax, %rbx
leaq 0x38(%rsp), %rdi
callq 0x20e0
jmp 0x378c
jmp 0x377a
movq %rax, %rbx
jmp 0x37a3
movq %rax, %rbx
jmp 0x378c
movq %rax, %rbx
leaq 0x38(%rsp), %rdi
callq 0x2e42
leaq 0x78(%rsp), %rdi
callq 0x42c4
leaq 0xb0(%rsp), %rdi
callq 0x20e0
leaq 0x90(%rsp), %rdi
callq 0x20e0
movq %rbx, %rdi
callq 0x2340