// File: /workspace/github_cpp_makefile_star2_O1/CastellanZhang[P]lambdaFM/lambdafm_predict.cpp
// Function: main
int main(int argc, char* argv[])
{
    cin.sync_with_stdio(false);
    cout.sync_with_stdio(false);
    Option opt;
    try
    {
        opt = parse_option(argv_to_args(argc, argv));
    }
    catch(const invalid_argument& e)
    {
        cout << e.what() << endl;
        cout << predict_help() << endl;
        return EXIT_FAILURE;
    }


    ifstream f_model(opt.model_path.c_str());
    ofstream f_predict(opt.predict_path.c_str(), ofstream::out);

    ftrl_predictor predictor(opt.dim, f_model, f_predict);

    pc_frame frame;
    frame.init(predictor, opt.threads_num);
    frame.run();

    f_model.close();
    f_predict.close();
    return 0;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x578, %rsp            # imm = 0x578
movq %rsi, %rbx
movl %edi, %ebp
xorl %r14d, %r14d
xorl %edi, %edi
callq 0x3100
xorl %edi, %edi
callq 0x3100
leaq 0x10(%rsp), %r12
movq %r12, -0x10(%r12)
movq %r14, -0x8(%r12)
movb %r14b, (%r12)
leaq 0x30(%rsp), %r13
movq %r13, -0x10(%r13)
movq %r14, -0x8(%r13)
movb %r14b, (%r13)
movabsq $0x800000001, %rax      # imm = 0x800000001
movq %rax, 0x10(%r13)
leaq 0x290(%rsp), %rdi
movl %ebp, %esi
movq %rbx, %rdx
callq 0x4498
leaq 0x88(%rsp), %rdi
leaq 0x290(%rsp), %rsi
callq 0x4545
leaq 0x20(%rsp), %rbx
movq %rsp, %r14
leaq 0x88(%rsp), %rsi
movq %r14, %rdi
callq 0x3310
leaq 0xa8(%rsp), %r15
movq %rbx, %rdi
movq %r15, %rsi
callq 0x3310
movq (%r15), %rdi
movq 0x20(%r15), %rax
movq %rax, 0x40(%r14)
leaq 0xb8(%rsp), %rax
cmpq %rax, %rdi
je 0x4977
callq 0x3260
leaq 0x98(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x498d
callq 0x3260
leaq 0x290(%rsp), %rdi
callq 0x5224
movq (%rsp), %rsi
leaq 0x88(%rsp), %rdi
movl $0x8, %edx
callq 0x3460
movq 0x20(%rsp), %rsi
leaq 0x290(%rsp), %rdi
movl $0x10, %edx
callq 0x32c0
cvtsi2sdl 0x44(%rsp), %xmm0
leaq 0x48(%rsp), %rdi
leaq 0x88(%rsp), %rsi
leaq 0x290(%rsp), %rdx
callq 0x3e20
xorpd %xmm0, %xmm0
leaq 0x508(%rsp), %r14
movupd %xmm0, -0x58(%r14)
movupd %xmm0, -0x68(%r14)
movq $0x0, -0x48(%r14)
movupd %xmm0, (%r14)
movupd %xmm0, 0x10(%r14)
movupd %xmm0, 0x20(%r14)
movupd %xmm0, 0x30(%r14)
movupd %xmm0, 0x40(%r14)
movq %r14, %rdi
xorl %esi, %esi
callq 0x55e0
leaq 0x558(%rsp), %r15
xorpd %xmm0, %xmm0
movupd %xmm0, (%r15)
movq $0x0, 0x10(%r15)
movl 0x40(%rsp), %edx
leaq 0x490(%rsp), %rdi
leaq 0x48(%rsp), %rsi
movl $0x1388, %ecx           # imm = 0x1388
movl $0x30d40, %r8d          # imm = 0x30D40
callq 0x6258
leaq 0x490(%rsp), %rdi
callq 0x6810
leaq 0x88(%rsp), %rdi
callq 0x3060
leaq 0x290(%rsp), %rdi
callq 0x3340
movq %r15, %rdi
callq 0x5780
movq %r14, %rdi
callq 0x57b4
movq 0x8512(%rip), %rax      # 0xcfb8
movq (%rax), %rcx
movq 0x18(%rax), %rax
leaq 0x298(%rsp), %rdi
movq %rcx, -0x8(%rdi)
movq -0x18(%rcx), %rcx
movq %rax, 0x290(%rsp,%rcx)
callq 0x3220
leaq 0x388(%rsp), %rdi
callq 0x30c0
leaq 0x88(%rsp), %rdi
callq 0x3070
xorl %ebx, %ebx
movq 0x20(%rsp), %rdi
cmpq %r13, %rdi
je 0x4af5
callq 0x3260
movq (%rsp), %rdi
cmpq %r12, %rdi
je 0x4b03
callq 0x3260
movl %ebx, %eax
addq $0x578, %rsp            # imm = 0x578
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x4b19
movq %rax, %rbx
jmp 0x4c2d
movq %rax, %rbx
jmp 0x4c3a
movq %rax, %rbx
jmp 0x4c47
movq %rdx, %r14
movq %rax, %rbx
leaq 0x290(%rsp), %rdi
callq 0x5224
jmp 0x4b4c
movq %rdx, %r14
movq %rax, %rbx
cmpl $0x1, %r14d
jne 0x4c47
movq %rbx, %rdi
callq 0x30f0
movq (%rax), %rcx
movq %rax, %rdi
callq *0x10(%rcx)
movq 0x8452(%rip), %rdi      # 0xcfc0
movq %rax, %rsi
callq 0x3280
movq %rax, %rdi
callq 0x3120
leaq 0x98(%rsp), %r14
movq %r14, -0x10(%r14)
leaq 0x44a3(%rip), %rsi      # 0x9034
leaq 0x4598(%rip), %rdx      # 0x9130
leaq 0x88(%rsp), %rdi
callq 0x59dc
movq 0x88(%rsp), %rsi
movq 0x90(%rsp), %rdx
movq 0x8404(%rip), %rdi      # 0xcfc0
callq 0x32e0
movq %rax, %rdi
callq 0x3120
movq 0x88(%rsp), %rdi
cmpq %r14, %rdi
je 0x4bdb
callq 0x3260
movl $0x1, %ebx
callq 0x33e0
jmp 0x4ae6
jmp 0x4b29
jmp 0x4c08
movq %rax, %rbx
movq 0x88(%rsp), %rdi
cmpq %r14, %rdi
je 0x4c0b
callq 0x3260
jmp 0x4c0b
movq %rax, %rbx
callq 0x33e0
jmp 0x4c47
movq %rax, %rdi
callq 0x5292
movq %rax, %rbx
movq %r15, %rdi
callq 0x5780
movq %r14, %rdi
callq 0x57b4
leaq 0x290(%rsp), %rdi
callq 0x3380
leaq 0x88(%rsp), %rdi
callq 0x3070
movq %rsp, %rdi
callq 0x5268
movq %rbx, %rdi
callq 0x3440
nop