LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/go.c
// Function: run_mcts
mcts_tree *run_mcts(mcts_tree *tree, network *net, float *board, float *ko, int player, int n, float cpuct, float secs)
{
    int i;
    double t = what_time_is_it_now();
    if(player < 0) flip_board(board);
    if(!tree) tree = expand(copy_board(board), ko, net);
    assert(compare_board(tree->board, board));
    for(i = 0; i < n; ++i){
        if (secs > 0 && (what_time_is_it_now() - t) > secs) break;
        int max_i = max_int_index(tree->visit_count, 19*19+1);
        if (tree->visit_count[max_i] >= n) break;
        select_mcts(tree, net, ko, cpuct);
    }
    if(player < 0) flip_board(board);
    //fprintf(stderr, "%f Seconds\n", what_time_is_it_now() - t);
    return tree;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movss %xmm1, 0xc(%rsp)
movss %xmm0, 0x14(%rsp)
movl %r9d, %r14d
movl %r8d, %ebp
movq %rcx, %r15
movq %rdx, %rbx
movq %rsi, %r12
movq %rdi, %r13
xorl %eax, %eax
callq 0x3bc0
movsd %xmm0, 0x20(%rsp)
movl %ebp, 0x10(%rsp)
testl %ebp, %ebp
jns 0x3af6e
movq %rbx, %rdi
callq 0x3a26f
testq %r13, %r13
jne 0x3af89
movq %rbx, %rdi
callq 0x3ac1c
movq %rax, %rdi
movq %r12, %rdx
callq 0x3aac9
movq %rax, %r13
movq (%r13), %rdi
movq %rbx, %rsi
callq 0x3a818
testl %eax, %eax
je 0x3b02f
cvtss2sd 0xc(%rsp), %xmm0
movsd %xmm0, 0x18(%rsp)
testl %r14d, %r14d
movl $0x0, %ebp
cmovgl %r14d, %ebp
subl $0x1, %ebp
jb 0x3b00e
movss 0xc(%rsp), %xmm0
ucomiss 0x110b1(%rip), %xmm0    # 0x4c078
jbe 0x3afde
xorl %eax, %eax
callq 0x3bc0
subsd 0x20(%rsp), %xmm0
ucomisd 0x18(%rsp), %xmm0
ja 0x3b00e
movq 0x18(%r13), %rdi
movl $0x16a, %esi            # imm = 0x16A
callq 0x4c4a
movq 0x18(%r13), %rcx
cltq
cmpl %r14d, (%rcx,%rax,4)
jge 0x3b00e
movq %r13, %rdi
movq %r12, %rsi
movq %r15, %rdx
movss 0x14(%rsp), %xmm0
callq 0x3ac54
jmp 0x3afb5
cmpl $0x0, 0x10(%rsp)
jns 0x3b01d
movq %rbx, %rdi
callq 0x3a26f
movq %r13, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x1634b(%rip), %rdi     # 0x51381
leaq 0x16366(%rip), %rsi     # 0x513a3
leaq 0x16364(%rip), %rcx     # 0x513a8
movl $0x1f9, %edx            # imm = 0x1F9
callq 0x31b0
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/go.c
// Function: move_mcts
mcts_tree *move_mcts(mcts_tree *tree, int index)
{
    if(index < 0 || index > 19*19 || !tree || !tree->children[index]) {
        free_mcts(tree);
        tree = 0;
    } else {
        mcts_tree *swap = tree;
        tree = tree->children[index];
        swap->children[index] = 0;
        free_mcts(swap);
    }
    return tree;
}

// Assembly:
pushq %rbx
cmpl $0x16a, %esi            # imm = 0x16A
setae %al
testq %rdi, %rdi
sete %cl
orb %al, %cl
jne 0x3b07d
movq 0x8(%rdi), %rax
movl %esi, %ecx
movq (%rax,%rcx,8), %rbx
testq %rbx, %rbx
je 0x3b07d
andq $0x0, (%rax,%rcx,8)
callq 0x3a82e
jmp 0x3b084
callq 0x3a82e
xorl %ebx, %ebx
movq %rbx, %rax
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/go.c
// Function: suicide_go
int suicide_go(float *b, int p, int r, int c)
{
    int *l = calculate_liberties(b);
    int safe = 0;
    safe = safe || makes_safe_go(b, l, p, r+1, c);
    safe = safe || makes_safe_go(b, l, p, r-1, c);
    safe = safe || makes_safe_go(b, l, p, r, c+1);
    safe = safe || makes_safe_go(b, l, p, r, c-1);
    free(l);
    return !safe;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %ecx, %r14d
movl %edx, %r15d
movl %esi, %ebp
movq %rdi, %r12
callq 0x3a552
movq %rax, %rbx
leal 0x1(%r15), %ecx
movq %r12, %rdi
movq %rax, %rsi
movl %ebp, %edx
movl %r14d, %r8d
callq 0x3b3f0
xorl %r13d, %r13d
testl %eax, %eax
jne 0x3b3d6
leal -0x1(%r15), %ecx
movq %r12, %rdi
movq %rbx, %rsi
movl %ebp, %edx
movl %r14d, %r8d
callq 0x3b3f0
testl %eax, %eax
jne 0x3b3d6
leal 0x1(%r14), %r8d
movq %r12, %rdi
movq %rbx, %rsi
movl %ebp, %edx
movl %r15d, %ecx
callq 0x3b3f0
testl %eax, %eax
jne 0x3b3d6
decl %r14d
movq %r12, %rdi
movq %rbx, %rsi
movl %ebp, %edx
movl %r15d, %ecx
movl %r14d, %r8d
callq 0x3b3f0
movl %eax, %r13d
xorl $0x1, %r13d
movq %rbx, %rdi
callq 0x3040
movl %r13d, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/go.c
// Function: makes_safe_go
static int makes_safe_go(float *b, int *lib, int p, int r, int c){
    if (r < 0 || r >= 19 || c < 0 || c >= 19) return 0;
    if (occupied(b,r*19 + c) == -p){
        if (lib[r*19 + c] > 1) return 0;
        else return 1;
    }
    if (!occupied(b,r*19 + c)) return 1;
    if (lib[r*19 + c] > 1) return 1;
    return 0;
}

// Assembly:
cmpl $0x13, %ecx
setae %al
cmpl $0x13, %r8d
setae %r9b
orb %al, %r9b
je 0x3b407
xorl %ecx, %ecx
jmp 0x3b455
imull $0x13, %ecx, %eax
addl %r8d, %eax
movss (%rdi,%rax,4), %xmm0
xorps %xmm1, %xmm1
ucomiss %xmm1, %xmm0
jne 0x3b41c
jnp 0x3b42a
cmpl $-0x1, %edx
je 0x3b440
cmpl $0x2, (%rsi,%rax,4)
setge %cl
jmp 0x3b455
movss 0x5a4(%rdi,%rax,4), %xmm0
cmpneqss %xmm0, %xmm1
movd %xmm1, %ecx
addl %edx, %ecx
jne 0x3b449
cmpl $0x2, (%rsi,%rax,4)
setl %cl
jmp 0x3b455
movb $0x1, %cl
xorps %xmm1, %xmm1
ucomiss %xmm1, %xmm0
jne 0x3b421
jp 0x3b421
movzbl %cl, %eax
retq
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/go.c
// Function: check_ko
int check_ko(float *x, float *ko)
{
    if(!ko) return 0;
    float curr[19*19*3];
    copy_cpu(19*19*3, x, 1, curr, 1);
    if(curr[19*19*2] != ko[19*19*2]) flip_board(curr);
    if(compare_board(curr, ko)) return 1;
    return 0;
}

// Assembly:
pushq %r14
pushq %rbx
subq $0x10f8, %rsp           # imm = 0x10F8
movq %rsi, %rbx
testq %rsi, %rsi
je 0x3b4ad
movq %rdi, %rsi
movq %rsp, %r14
pushq $0x1
popq %rdx
movl $0x43b, %edi            # imm = 0x43B
movq %r14, %rcx
movl %edx, %r8d
callq 0x1b5a3
movss 0xb48(%r14), %xmm0
ucomiss 0xb48(%rbx), %xmm0
jne 0x3b498
jnp 0x3b4a0
movq %rsp, %rdi
callq 0x3a26f
movq %rsp, %rdi
movq %rbx, %rsi
callq 0x3a818
jmp 0x3b4af
xorl %eax, %eax
addq $0x10f8, %rsp           # imm = 0x10F8
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/go.c
// Function: valid_go
void valid_go(char *cfgfile, char *weightfile, int multi, char *filename)
{
    srand(time(0));
    char *base = basecfg(cfgfile);
    printf("%s\n", base);
    network *net = load_network(cfgfile, weightfile, 0);
    set_batch_network(net, 1);
    printf("Learning Rate: %g, Momentum: %g, Decay: %g\n", net->learning_rate, net->momentum, net->decay);

    float *board = calloc(19*19*3, sizeof(float));
    float *move = calloc(19*19+2, sizeof(float));
    // moves m = load_go_moves("/home/pjreddie/backup/go.test");
    moves m = load_go_moves(filename);

    int N = m.n;
    int i,j;
    int correct = 0;
    for (i = 0; i <N; ++i) {
        char *b = m.data[i];
        int player = b[0] - '0';
        //int result = b[1] - '0';
        int row = b[2];
        int col = b[3];
        int truth = col + 19*row;
        string_to_board(b+4, board);
        if(player > 0) for(j = 0; j < 19*19; ++j) board[19*19*2 + j] = 1;
        predict_move2(net, board, move, multi);
        int index = max_index(move, 19*19+1);
        if(index == truth) ++correct;
        printf("%d Accuracy %f\n", i, (float) correct/(i+1));
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rcx, %rbx
movl %edx, 0x4(%rsp)
movq %rsi, %r15
movq %rdi, %r12
xorl %r14d, %r14d
xorl %edi, %edi
callq 0x32c0
movl %eax, %edi
callq 0x3220
movq %r12, %rdi
callq 0x41c8
movq %rax, %rdi
callq 0x30b0
movq %r12, %rdi
movq %r15, %rsi
xorl %edx, %edx
callq 0x22658
movq %rax, %r15
pushq $0x1
popq %rsi
movq %rax, %rdi
callq 0x22f00
cvtss2sd 0x34(%r15), %xmm0
cvtss2sd 0x38(%r15), %xmm1
movq %r15, 0x18(%rsp)
cvtss2sd 0x3c(%r15), %xmm2
leaq 0x159a1(%rip), %rdi     # 0x50ed0
movb $0x3, %al
callq 0x3160
pushq $0x4
popq %r13
movl $0x43b, %edi            # imm = 0x43B
movq %r13, %rsi
callq 0x3250
movq %rax, %r12
movl $0x16b, %edi            # imm = 0x16B
movq %r13, %rsi
callq 0x3250
movq %rax, 0x10(%rsp)
movq %rbx, %rdi
callq 0x3984e
movq %rax, 0x8(%rsp)
testl %edx, %edx
cmovlel %r14d, %edx
movq %rdx, 0x20(%rsp)
xorl %r15d, %r15d
cmpq 0x20(%rsp), %r14
je 0x3b626
movq 0x8(%rsp), %rax
movq (%rax,%r14,8), %rdi
movb (%rdi), %r13b
movsbl 0x2(%rdi), %ebx
movsbl 0x3(%rdi), %ebp
addq $0x4, %rdi
movq %r12, %rsi
callq 0x398fd
cmpb $0x31, %r13b
jl 0x3b5c3
xorl %eax, %eax
cmpq $0x169, %rax            # imm = 0x169
je 0x3b5c3
movl $0x3f800000, 0xb48(%r12,%rax,4) # imm = 0x3F800000
incq %rax
jmp 0x3b5aa
imull $0x13, %ebx, %ebx
addl %ebp, %ebx
movq 0x18(%rsp), %rdi
movq %r12, %rsi
movq 0x10(%rsp), %r13
movq %r13, %rdx
movl 0x4(%rsp), %ecx
callq 0x3a2c3
movq %r13, %rdi
movl $0x16a, %esi            # imm = 0x16A
callq 0x4c73
xorl %ecx, %ecx
cmpl %ebx, %eax
sete %cl
addl %ecx, %r15d
cvtsi2ss %r15d, %xmm0
leaq 0x1(%r14), %rbx
cvtsi2ss %ebx, %xmm1
divss %xmm1, %xmm0
cvtss2sd %xmm0, %xmm0
leaq 0x15e41(%rip), %rdi     # 0x51455
movl %r14d, %esi
movb $0x1, %al
callq 0x3160
movq %rbx, %r14
jmp 0x3b577
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/go.c
// Function: print_game
int print_game(float *board, FILE *fp)
{
    int i, j;
    int count = 3;
    fprintf(fp, "komi 6.5\n");
    fprintf(fp, "boardsize 19\n");
    fprintf(fp, "clear_board\n");
    for(j = 0; j < 19; ++j){
        for(i = 0; i < 19; ++i){
            if(occupied(board,j*19 + i) == 1) fprintf(fp, "play black %c%d\n", 'A'+i+(i>=8), 19-j);
            if(occupied(board,j*19 + i) == -1) fprintf(fp, "play white %c%d\n", 'A'+i+(i>=8), 19-j);
            if(occupied(board,j*19 + i)) ++count;
        }
    }
    return count;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movq %rdi, %r14
leaq 0x15e18(%rip), %rdi     # 0x51465
pushq $0x9
popq %rsi
pushq $0x1
popq %r15
movq %r15, %rdx
movq %rbx, %rcx
callq 0x3440
leaq 0x15e09(%rip), %rdi     # 0x5146f
pushq $0xd
popq %rsi
movq %r15, %rdx
movq %rbx, %rcx
callq 0x3440
leaq 0x15e02(%rip), %rdi     # 0x5147d
pushq $0xc
popq %rsi
movq %r15, %rdx
movq %rbx, %rcx
callq 0x3440
pushq $0x3
popq %rbp
xorps %xmm2, %xmm2
pushq $0x1
popq %r12
xorl %eax, %eax
cmpq $0x13, %rax
je 0x3b76a
pushq $0x13
popq %r13
movq %rax, (%rsp)
subl %eax, %r13d
xorl %r15d, %r15d
cmpq $0x13, %r15
je 0x3b75a
movss (%r14,%r15,4), %xmm0
ucomiss %xmm2, %xmm0
jne 0x3b6c4
jnp 0x3b6ee
cmpq $0x8, %r15
movl %r15d, %edx
sbbl $-0x1, %edx
addl $0x41, %edx
movq %rbx, %rdi
leaq 0x15daf(%rip), %rsi     # 0x5148a
movl %r13d, %ecx
xorl %eax, %eax
callq 0x3270
xorps %xmm2, %xmm2
movss (%r14,%r15,4), %xmm0
ucomiss %xmm2, %xmm0
jne 0x3b730
jp 0x3b730
movss 0x5a4(%r14,%r15,4), %xmm1
ucomiss %xmm2, %xmm1
jne 0x3b706
jnp 0x3b730
cmpq $0x8, %r15
movl %r15d, %edx
sbbl $-0x1, %edx
addl $0x41, %edx
movq %rbx, %rdi
leaq 0x15d7e(%rip), %rsi     # 0x5149b
movl %r13d, %ecx
xorl %eax, %eax
callq 0x3270
xorps %xmm2, %xmm2
movss (%r14,%r15,4), %xmm0
ucomiss %xmm2, %xmm0
movl %r12d, %eax
jne 0x3b750
jp 0x3b750
movss 0x5a4(%r14,%r15,4), %xmm0
cmpneqss %xmm2, %xmm0
movd %xmm0, %eax
andl $0x1, %eax
addl %eax, %ebp
incq %r15
jmp 0x3b6ad
movq (%rsp), %rax
incq %rax
addq $0x4c, %r14
jmp 0x3b695
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/go.c
// Function: stdin_ready
int stdin_ready()
{
    fd_set readfds;
    FD_ZERO(&readfds);

    struct timeval timeout;
    timeout.tv_sec = 0;
    timeout.tv_usec = 0;
    FD_SET(STDIN_FILENO, &readfds);

    if (select(1, &readfds, NULL, NULL, &timeout)){
        return 1;
    }
    return 0;
}

// Assembly:
subq $0x98, %rsp
xorl %eax, %eax
cmpq $0x10, %rax
je 0x3b795
andq $0x0, 0x18(%rsp,%rax,8)
incq %rax
jmp 0x3b784
xorps %xmm0, %xmm0
movq %rsp, %r8
movaps %xmm0, (%r8)
leaq 0x18(%rsp), %rsi
orb $0x1, (%rsi)
pushq $0x1
popq %rdi
xorl %edx, %edx
xorl %ecx, %ecx
callq 0x32d0
xorl %ecx, %ecx
testl %eax, %eax
setne %cl
movl %ecx, %eax
addq $0x98, %rsp
retq
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/go.c
// Function: ponder
mcts_tree *ponder(mcts_tree *tree, network *net, float *b, float *ko, int player, float cpuct)
{
    double t = what_time_is_it_now();
    int count = 0;
    if (tree) count = tree->total_count;
    while(!stdin_ready()){
        if (what_time_is_it_now() - t > 120) break;
        tree = run_mcts(tree, net, b, ko, player, 100000, cpuct, .1);
    }
    fprintf(stderr, "Pondered %d moves...\n", tree->total_count - count);
    return tree;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movss %xmm0, 0xc(%rsp)
movl %r8d, %ebp
movq %rcx, %r14
movq %rdx, %r15
movq %rsi, %r12
movq %rdi, %rbx
xorl %r13d, %r13d
xorl %eax, %eax
callq 0x3bc0
movsd %xmm0, 0x10(%rsp)
testq %rbx, %rbx
je 0x3b844
movl 0x38(%rbx), %r13d
jmp 0x3b844
xorl %eax, %eax
callq 0x3bc0
subsd 0x10(%rsp), %xmm0
ucomisd 0x15b19(%rip), %xmm0    # 0x51330
ja 0x3b84d
movq %rbx, %rdi
movq %r12, %rsi
movq %r15, %rdx
movq %r14, %rcx
movl %ebp, %r8d
movl $0x186a0, %r9d          # imm = 0x186A0
movss 0xc(%rsp), %xmm0
movss 0x10a2c(%rip), %xmm1    # 0x4c268
callq 0x3af25
movq %rax, %rbx
callq 0x3b77b
testl %eax, %eax
je 0x3b802
movq 0x287a4(%rip), %rax     # 0x63ff8
movq (%rax), %rdi
movl 0x38(%rbx), %edx
subl %r13d, %edx
leaq 0x15c48(%rip), %rsi     # 0x514ac
xorl %eax, %eax
callq 0x3270
movq %rbx, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/go.c
// Function: score_game
float score_game(float *board)
{
    int i;
    FILE *f = fopen("game.txt", "w");
    int count = print_game(board, f);
    fprintf(f, "final_score\n");
    fclose(f);
    FILE *p = popen("./gnugo --mode gtp < game.txt", "r");
    for(i = 0; i < count; ++i){
        free(fgetl(p));
        free(fgetl(p));
    }
    char *l = 0;
    float score = 0;
    char player = 0;
    while((l = fgetl(p))){
        fprintf(stderr, "%s  \t", l);
        int n = sscanf(l, "= %c+%f", &player, &score);
        free(l);
        if (n == 2) break;
    }
    if(player == 'W') score = -score;
    pclose(p);
    return score;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
leaq 0x14be5(%rip), %rdi     # 0x517c5
leaq 0x15600(%rip), %rsi     # 0x521e7
callq 0x3390
movq %rax, %r14
movq %rbx, %rdi
movq %rax, %rsi
callq 0x3b635
movl %eax, %ebp
leaq 0x14c87(%rip), %rdi     # 0x5188a
pushq $0xc
popq %rsi
pushq $0x1
popq %rdx
movq %r14, %rcx
callq 0x3440
movq %r14, %rdi
callq 0x3130
leaq 0x14b90(%rip), %rdi     # 0x517b0
leaq 0x150c2(%rip), %rsi     # 0x51ce9
callq 0x3380
movq %rax, %rbx
xorl %r14d, %r14d
testl %ebp, %ebp
cmovgl %ebp, %r14d
subl $0x1, %r14d
jb 0x3cc60
movq %rbx, %rdi
callq 0x3d32
movq %rax, %rdi
callq 0x3040
movq %rbx, %rdi
callq 0x3d32
movq %rax, %rdi
callq 0x3040
jmp 0x3cc38
leaq 0x4(%rsp), %r14
andl $0x0, (%r14)
leaq 0x3(%rsp), %r15
movb $0x0, (%r15)
leaq 0x14c24(%rip), %r13     # 0x5189d
movq %rbx, %rdi
callq 0x3d32
testq %rax, %rax
je 0x3ccc8
movq %rax, %rbp
movq 0x27368(%rip), %rax     # 0x63ff8
movq (%rax), %rdi
leaq 0x14bfd(%rip), %rsi     # 0x51897
movq %rbp, %rdx
xorl %eax, %eax
callq 0x3270
movq %rbp, %rdi
movq %r13, %rsi
movq %r15, %rdx
movq %r14, %rcx
xorl %eax, %eax
callq 0x3320
movl %eax, %r12d
movq %rbp, %rdi
callq 0x3040
cmpl $0x2, %r12d
jne 0x3cc79
cmpb $0x57, 0x3(%rsp)
jne 0x3cce2
movss 0x4(%rsp), %xmm0
xorps 0xf474(%rip), %xmm0     # 0x4c150
movss %xmm0, 0x4(%rsp)
movq %rbx, %rdi
callq 0x3170
movss 0x4(%rsp), %xmm0
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/go.c
// Function: propagate_liberty
static void propagate_liberty(float *board, int *lib, int *visited, int row, int col, int side)
{
    if (row < 0 || row > 18 || col < 0 || col > 18) return;
    int index = row*19 + col;
    if (occupied(board,index) != side) return;
    if (visited[index]) return;
    visited[index] = 1;
    lib[index] += 1;
    propagate_liberty(board, lib, visited, row+1, col, side);
    propagate_liberty(board, lib, visited, row-1, col, side);
    propagate_liberty(board, lib, visited, row, col+1, side);
    propagate_liberty(board, lib, visited, row, col-1, side);
}

// Assembly:
cmpl $0x12, %ecx
ja 0x3d3ea
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %r9d, %ebx
movl %r8d, %r14d
movl %ecx, %r15d
movq %rdx, %r12
movq %rsi, %r13
movq %rdi, %rbp
imull $0x13, %ecx, %eax
movq %rax, 0x10(%rsp)
leal 0x1(%r15), %eax
movl %eax, 0xc(%rsp)
leal -0x1(%r15), %eax
movl %eax, 0x8(%rsp)
cmpl $0x12, %r14d
ja 0x3d3dc
movq 0x10(%rsp), %rax
addl %r14d, %eax
movss (%rbp,%rax,4), %xmm0
ucomiss 0xed21(%rip), %xmm0     # 0x4c078
pushq $0x1
popq %rcx
jne 0x3d374
jp 0x3d374
movss 0x5a4(%rbp,%rax,4), %xmm0
cmpneqss 0xed08(%rip), %xmm0     # 0x4c078
movd %xmm0, %ecx
cmpl %ebx, %ecx
jne 0x3d3dc
cmpl $0x0, (%r12,%rax,4)
jne 0x3d3dc
movl $0x1, (%r12,%rax,4)
incl (%r13,%rax,4)
movq %rbp, %rdi
movq %r13, %rsi
movq %r12, %rdx
movl 0xc(%rsp), %ecx
movl %r14d, %r8d
movl %ebx, %r9d
callq 0x3d2f7
movq %rbp, %rdi
movq %r13, %rsi
movq %r12, %rdx
movl 0x8(%rsp), %ecx
movl %r14d, %r8d
movl %ebx, %r9d
callq 0x3d2f7
leal 0x1(%r14), %r8d
movq %rbp, %rdi
movq %r13, %rsi
movq %r12, %rdx
movl %r15d, %ecx
movl %ebx, %r9d
callq 0x3d2f7
decl %r14d
jmp 0x3d338
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/rnn.c
// Function: load_files
unsigned char **load_files(char *filename, int *n)
{
    list *paths = get_paths(filename);
    *n = paths->size;
    unsigned char **contents = calloc(*n, sizeof(char *));
    int i;
    node *x = paths->front;
    for(i = 0; i < *n; ++i){
        contents[i] = read_file((char *)x->val);
        x = x->next;
    }
    return contents;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rsi, %rbx
callq 0x1c8c8
movq %rax, %r14
movl (%rax), %ebp
movl %ebp, (%rbx)
movslq %ebp, %rdi
pushq $0x8
popq %rsi
callq 0x3250
movq %rax, %r15
xorl %r12d, %r12d
movslq %ebp, %rax
cmpq %rax, %r12
jge 0x3d433
movq 0x8(%r14), %r14
movq (%r14), %rdi
callq 0x4404
movq %rax, (%r15,%r12,8)
incq %r12
movl (%rbx), %ebp
jmp 0x3d414
movq %r15, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/rnn.c
// Function: read_tokenized_data
int *read_tokenized_data(char *filename, size_t *read)
{
    size_t size = 512;
    size_t count = 0;
    FILE *fp = fopen(filename, "r");
    int *d = calloc(size, sizeof(int));
    int n, one;
    one = fscanf(fp, "%d", &n);
    while(one == 1){
        ++count;
        if(count > size){
            size = size*2;
            d = realloc(d, size*sizeof(int));
        }
        d[count-1] = n;
        one = fscanf(fp, "%d", &n);
    }
    fclose(fp);
    d = realloc(d, count*sizeof(int));
    *read = count;
    return d;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, 0x10(%rsp)
leaq 0x14890(%rip), %rsi     # 0x51ce9
callq 0x3390
movq %rax, %r14
movl $0x200, %r12d           # imm = 0x200
pushq $0x4
popq %rsi
movl $0x200, %edi            # imm = 0x200
callq 0x3250
movq %rax, %r15
leaq 0x147c5(%rip), %rbp     # 0x51c43
xorl %r13d, %r13d
movq %r14, %rdi
movq %rbp, %rsi
leaq 0xc(%rsp), %rdx
xorl %eax, %eax
callq 0x30a0
cmpl $0x1, %eax
jne 0x3d4d3
leaq 0x1(%r13), %rbx
cmpq %r12, %rbx
jbe 0x3d4c6
movq %r15, %rdi
movq %r14, %r15
movq %rbp, %r14
leaq (%r12,%r12), %rbp
shlq $0x3, %r12
movq %r12, %rsi
callq 0x3350
movq %rbp, %r12
movq %r14, %rbp
movq %r15, %r14
movq %rax, %r15
movl 0xc(%rsp), %eax
movl %eax, (%r15,%r13,4)
movq %rbx, %r13
jmp 0x3d481
movq %r14, %rdi
callq 0x3130
leaq (,%r13,4), %rsi
movq %r15, %rdi
callq 0x3350
movq 0x10(%rsp), %rcx
movq %r13, (%rcx)
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/rnn.c
// Function: read_tokens
char **read_tokens(char *filename, size_t *read)
{
    size_t size = 512;
    size_t count = 0;
    FILE *fp = fopen(filename, "r");
    char **d = calloc(size, sizeof(char *));
    char *line;
    while((line=fgetl(fp)) != 0){
        ++count;
        if(count > size){
            size = size*2;
            d = realloc(d, size*sizeof(char *));
        }
        if(0==strcmp(line, "<NEWLINE>")) line = "\n";
        d[count-1] = line;
    }
    fclose(fp);
    d = realloc(d, count*sizeof(char *));
    *read = count;
    return d;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, (%rsp)
leaq 0x147d1(%rip), %rsi     # 0x51ce9
callq 0x3390
movq %rax, %r14
movl $0x200, %r12d           # imm = 0x200
pushq $0x8
popq %rsi
movl $0x200, %edi            # imm = 0x200
callq 0x3250
movq %rax, %r15
xorl %r13d, %r13d
movq %r14, %rdi
callq 0x3d32
testq %rax, %rax
je 0x3d596
movq %rax, %rbp
leaq 0x1(%r13), %rbx
cmpq %r12, %rbx
jbe 0x3d571
movq %r15, %rdi
movq %r14, %r15
leaq (%r12,%r12), %r14
shlq $0x4, %r12
movq %r12, %rsi
callq 0x3350
movq %r14, %r12
movq %r15, %r14
movq %rax, %r15
movq %rbp, %rdi
leaq 0x143d5(%rip), %rsi     # 0x51950
callq 0x3260
testl %eax, %eax
leaq 0x13f90(%rip), %rax     # 0x51519
cmoveq %rax, %rbp
movq %rbp, (%r15,%r13,8)
movq %rbx, %r13
jmp 0x3d539
movq %r14, %rdi
callq 0x3130
leaq (,%r13,8), %rsi
movq %r15, %rdi
callq 0x3350
movq (%rsp), %rcx
movq %r13, (%rcx)
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/rnn.c
// Function: get_rnn_token_data
float_pair get_rnn_token_data(int *tokens, size_t *offsets, int characters, size_t len, int batch, int steps)
{
    float *x = calloc(batch * steps * characters, sizeof(float));
    float *y = calloc(batch * steps * characters, sizeof(float));
    int i,j;
    for(i = 0; i < batch; ++i){
        for(j = 0; j < steps; ++j){
            int curr = tokens[(offsets[i])%len];
            int next = tokens[(offsets[i] + 1)%len];

            x[(j*batch + i)*characters + curr] = 1;
            y[(j*batch + i)*characters + next] = 1;

            offsets[i] = (offsets[i] + 1) % len;

            if(curr >= characters || curr < 0 || next >= characters || next < 0){
                error("Bad char");
            }
        }
    }
    float_pair p;
    p.x = x;
    p.y = y;
    return p;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movl %r9d, %ebx
movl %r8d, %ebp
movq %rcx, 0x30(%rsp)
movl %edx, %r15d
movq %rsi, %r12
movq %rdi, %r13
movl %r8d, %eax
imull %edx, %eax
movl %eax, 0xc(%rsp)
imull %r9d, %eax
movslq %eax, %r14
pushq $0x4
popq %rsi
movq %r14, %rdi
callq 0x3250
movq %rax, 0x18(%rsp)
movq %r14, %rdi
pushq $0x4
popq %rsi
callq 0x3250
xorl %ecx, %ecx
testl %ebx, %ebx
cmovlel %ecx, %ebx
movl %ebx, 0x8(%rsp)
xorl %ebx, %ebx
testl %ebp, %ebp
cmovlel %ebx, %ebp
movq %rbp, 0x20(%rsp)
movq %rax, 0x10(%rsp)
xorl %r14d, %r14d
cmpq 0x20(%rsp), %r14
je 0x3d6df
movq %rbx, 0x28(%rsp)
movl 0x8(%rsp), %ebp
subl $0x1, %ebp
jb 0x3d6cf
movq (%r12,%r14,8), %rcx
movq %rcx, %rax
xorl %edx, %edx
movq 0x30(%rsp), %r8
divq %r8
movl (%r13,%rdx,4), %esi
incq %rcx
movq %rcx, %rax
xorl %edx, %edx
divq %r8
movl (%r13,%rdx,4), %eax
leal (%rbx,%rsi), %ecx
movslq %ecx, %rcx
movq 0x18(%rsp), %r8
movl $0x3f800000, %r9d       # imm = 0x3F800000
movl %r9d, (%r8,%rcx,4)
leal (%rbx,%rax), %ecx
movslq %ecx, %rcx
movq 0x10(%rsp), %r8
movl %r9d, (%r8,%rcx,4)
movq %rdx, (%r12,%r14,8)
cmpl %r15d, %esi
setge %cl
testl %esi, %esi
sets %dl
orb %cl, %dl
jne 0x3d6ba
cmpl %r15d, %eax
setl %cl
testl %eax, %eax
setns %al
testb %al, %cl
jne 0x3d6c6
leaq 0x14299(%rip), %rdi     # 0x5195a
callq 0x43df
addl 0xc(%rsp), %ebx
jmp 0x3d645
incq %r14
movq 0x28(%rsp), %rbx
addl %r15d, %ebx
jmp 0x3d631
movq 0x18(%rsp), %rax
movq 0x10(%rsp), %rdx
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/rnn.c
// Function: get_seq2seq_data
float_pair get_seq2seq_data(char **source, char **dest, int n, int characters, size_t len, int batch, int steps)
{
    int i,j;
    float *x = calloc(batch * steps * characters, sizeof(float));
    float *y = calloc(batch * steps * characters, sizeof(float));
    for(i = 0; i < batch; ++i){
        int index = rand()%n;
        //int slen = strlen(source[index]);
        //int dlen = strlen(dest[index]);
        for(j = 0; j < steps; ++j){
            unsigned char curr = source[index][j];
            unsigned char next = dest[index][j];

            x[(j*batch + i)*characters + curr] = 1;
            y[(j*batch + i)*characters + next] = 1;

            if(curr > 255 || curr <= 0 || next > 255 || next <= 0){
                /*text[(index+j+2)%len] = 0;
                printf("%ld %d %d %d %d\n", index, j, len, (int)text[index+j], (int)text[index+j+1]);
                printf("%s", text+index);
                */
                error("Bad char");
            }
        }
    }
    float_pair p;
    p.x = x;
    p.y = y;
    return p;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movl %r9d, %ebp
movl %ecx, %r15d
movl %edx, 0x4(%rsp)
movq %rsi, 0x48(%rsp)
movq %rdi, 0x40(%rsp)
movl 0x90(%rsp), %ebx
movl %r9d, %eax
imull %ecx, %eax
imull %ebx, %eax
movslq %eax, %r13
pushq $0x4
popq %r12
movq %r13, %rdi
movq %r12, %rsi
callq 0x3250
movq %rax, %r14
movq %r13, %rdi
movq %r12, %rsi
callq 0x3250
movslq %ebp, %r13
xorl %ecx, %ecx
testl %ebx, %ebx
cmovlel %ecx, %ebx
movq %rbx, 0x50(%rsp)
testl %r13d, %r13d
movl $0x0, %edx
cmovgl %r13d, %edx
movq %rdx, 0x20(%rsp)
movslq %r15d, %rdx
imulq %rdx, %r13
shlq $0x2, %rdx
movq %rdx, 0x18(%rsp)
shlq $0x2, %r13
movl $0x3f800000, %ebx       # imm = 0x3F800000
movq %r14, 0x10(%rsp)
movq %rax, 0x8(%rsp)
movq %rax, %r15
cmpq 0x20(%rsp), %rcx
je 0x3d826
movq %rcx, 0x38(%rsp)
callq 0x34e0
cltd
idivl 0x4(%rsp)
movslq %edx, %rbp
movq %r14, 0x30(%rsp)
movq %r15, 0x28(%rsp)
xorl %r12d, %r12d
cmpq %r12, 0x50(%rsp)
je 0x3d804
movq 0x40(%rsp), %rax
movq (%rax,%rbp,8), %rax
movzbl (%rax,%r12), %ecx
movq 0x48(%rsp), %rax
movq (%rax,%rbp,8), %rax
movzbl (%rax,%r12), %eax
movl %ebx, (%r14,%rcx,4)
movl %ebx, (%r15,%rax,4)
testl %ecx, %ecx
je 0x3d7ed
testb %al, %al
jne 0x3d7f9
leaq 0x14166(%rip), %rdi     # 0x5195a
callq 0x43df
incq %r12
addq %r13, %r15
addq %r13, %r14
jmp 0x3d7ba
movq 0x38(%rsp), %rcx
incq %rcx
movq 0x18(%rsp), %rax
movq 0x28(%rsp), %r15
addq %rax, %r15
movq 0x30(%rsp), %r14
addq %rax, %r14
jmp 0x3d790
movq 0x10(%rsp), %rax
movq 0x8(%rsp), %rdx
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/rnn.c
// Function: get_rnn_data
float_pair get_rnn_data(unsigned char *text, size_t *offsets, int characters, size_t len, int batch, int steps)
{
    float *x = calloc(batch * steps * characters, sizeof(float));
    float *y = calloc(batch * steps * characters, sizeof(float));
    int i,j;
    for(i = 0; i < batch; ++i){
        for(j = 0; j < steps; ++j){
            unsigned char curr = text[(offsets[i])%len];
            unsigned char next = text[(offsets[i] + 1)%len];

            x[(j*batch + i)*characters + curr] = 1;
            y[(j*batch + i)*characters + next] = 1;

            offsets[i] = (offsets[i] + 1) % len;

            if(curr > 255 || curr <= 0 || next > 255 || next <= 0){
                /*text[(index+j+2)%len] = 0;
                printf("%ld %d %d %d %d\n", index, j, len, (int)text[index+j], (int)text[index+j+1]);
                printf("%s", text+index);
                */
                error("Bad char");
            }
        }
    }
    float_pair p;
    p.x = x;
    p.y = y;
    return p;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x38, %rsp
movl %r9d, %ebp
movl %r8d, %r14d
movq %rcx, %r15
movq %rsi, %r12
movq %rdi, %r13
movl %r8d, %eax
movl %edx, 0xc(%rsp)
imull %edx, %eax
movl %eax, 0x14(%rsp)
imull %r9d, %eax
movslq %eax, %rbx
pushq $0x4
popq %rsi
movq %rbx, %rdi
callq 0x3250
movq %rax, 0x18(%rsp)
movq %rbx, %rdi
pushq $0x4
popq %rsi
callq 0x3250
xorl %ecx, %ecx
testl %ebp, %ebp
cmovlel %ecx, %ebp
movl %ebp, 0x10(%rsp)
testl %r14d, %r14d
cmovlel %ecx, %r14d
movq %r14, 0x20(%rsp)
movq %rax, %r9
movl $0x3f800000, %r10d      # imm = 0x3F800000
xorl %ebp, %ebp
movq %r13, 0x30(%rsp)
cmpq 0x20(%rsp), %rbp
je 0x3d960
movq %rcx, 0x28(%rsp)
movl %ecx, %ebx
movl 0x10(%rsp), %r14d
subl $0x1, %r14d
jb 0x3d94f
movq (%r12,%rbp,8), %rcx
movq %rcx, %rax
xorl %edx, %edx
divq %r15
movzbl (%r13,%rdx), %esi
testl %esi, %esi
setne %dil
incq %rcx
movq %rcx, %rax
xorl %edx, %edx
divq %r15
movzbl (%r13,%rdx), %eax
testl %eax, %eax
setne %cl
addl %ebx, %esi
movslq %esi, %rsi
movq 0x18(%rsp), %r8
movl %r10d, (%r8,%rsi,4)
addl %ebx, %eax
cltq
movl %r10d, (%r9,%rax,4)
movq %rdx, (%r12,%rbp,8)
testb %cl, %dil
jne 0x3d946
leaq 0x14036(%rip), %rdi     # 0x5195a
movq %r12, %r13
movq %r15, %r12
movq %r9, %r15
callq 0x43df
movl $0x3f800000, %r10d      # imm = 0x3F800000
movq %r15, %r9
movq %r12, %r15
movq %r13, %r12
movq 0x30(%rsp), %r13
addl 0x14(%rsp), %ebx
jmp 0x3d8ca
incq %rbp
movq 0x28(%rsp), %rcx
addl 0xc(%rsp), %ecx
jmp 0x3d8b3
movq 0x18(%rsp), %rax
movq %r9, %rdx
addq $0x38, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/regressor.c
// Function: predict_regressor
void predict_regressor(char *cfgfile, char *weightfile, char *filename)
{
    network *net = load_network(cfgfile, weightfile, 0);
    set_batch_network(net, 1);
    srand(2222222);

    clock_t time;
    char buff[256];
    char *input = buff;
    while(1){
        if(filename){
            strncpy(input, filename, 256);
        }else{
            printf("Enter Image Path: ");
            fflush(stdout);
            input = fgets(input, 256, stdin);
            if(!input) return;
            strtok(input, "\n");
        }
        image im = load_image_color(input, 0, 0);
        image sized = letterbox_image(im, net->w, net->h);

        float *X = sized.data;
        time=clock();
        float *predictions = network_predict(net, X);
        printf("Predicted: %f\n", predictions[0]);
        printf("%s: Predicted in %f seconds.\n", input, sec(clock()-time));
        free_image(im);
        free_image(sized);
        if (filename) break;
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x158, %rsp            # imm = 0x158
movq %rdx, %rbx
xorl %edx, %edx
callq 0x22658
movq %rax, %r14
pushq $0x1
popq %rsi
movq %rax, %rdi
callq 0x22f00
movl $0x21e88e, %edi         # imm = 0x21E88E
callq 0x3220
leaq 0x50(%rsp), %r13
leaq 0x112c8(%rip), %rbp     # 0x5101c
testq %rbx, %rbx
je 0x3fd6b
movl $0x100, %edx            # imm = 0x100
movq %r13, %rdi
movq %rbx, %rsi
callq 0x3080
jmp 0x3fdba
leaq 0x112d0(%rip), %rdi     # 0x51042
xorl %eax, %eax
callq 0x3160
movq 0x24250(%rip), %rax     # 0x63fd0
movq (%rax), %rdi
callq 0x3310
movq 0x24249(%rip), %rax     # 0x63fd8
movq (%rax), %rdx
movq %r13, %rdi
movl $0x100, %esi            # imm = 0x100
callq 0x3230
testq %rax, %rax
je 0x3fe7a
movq %rax, %r13
movq %rax, %rdi
leaq 0x11764(%rip), %rsi     # 0x51519
callq 0x33b0
leaq 0x20(%rsp), %rdi
movq %r13, %rsi
xorl %edx, %edx
xorl %ecx, %ecx
callq 0xbf36
movl 0x90(%r14), %edx
movl 0x94(%r14), %esi
movq 0x30(%rsp), %rax
movq %rax, 0x10(%rsp)
movups 0x20(%rsp), %xmm0
movups %xmm0, (%rsp)
leaq 0x38(%rsp), %rdi
callq 0xe7d0
movq 0x48(%rsp), %r12
callq 0x3120
movq %rax, %r15
movq %r14, %rdi
movq %r12, %rsi
callq 0x233e2
cvtss2sd (%rax), %xmm0
leaq 0x11d32(%rip), %rdi     # 0x51b4b
movb $0x1, %al
callq 0x3160
callq 0x3120
subq %r15, %rax
movq %rax, %rdi
callq 0x437c
cvtss2sd %xmm0, %xmm0
movq %rbp, %rdi
movq %r13, %rsi
movb $0x1, %al
callq 0x3160
movq 0x30(%rsp), %rax
movq %rax, 0x10(%rsp)
movups 0x20(%rsp), %xmm0
movups %xmm0, (%rsp)
callq 0xba88
movq 0x48(%rsp), %rax
movq %rax, 0x10(%rsp)
movups 0x38(%rsp), %xmm0
movups %xmm0, (%rsp)
callq 0xba88
testq %rbx, %rbx
je 0x3fd54
addq $0x158, %rsp            # imm = 0x158
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/regressor.c
// Function: run_regressor
void run_regressor(int argc, char **argv)
{
    if(argc < 4){
        fprintf(stderr, "usage: %s %s [train/test/valid] [cfg] [weights (optional)]\n", argv[0], argv[1]);
        return;
    }

    char *gpu_list = find_char_arg(argc, argv, "-gpus", 0);
    int *gpus = 0;
    int gpu = 0;
    int ngpus = 0;
    if(gpu_list){
        printf("%s\n", gpu_list);
        int len = strlen(gpu_list);
        ngpus = 1;
        int i;
        for(i = 0; i < len; ++i){
            if (gpu_list[i] == ',') ++ngpus;
        }
        gpus = calloc(ngpus, sizeof(int));
        for(i = 0; i < ngpus; ++i){
            gpus[i] = atoi(gpu_list);
            gpu_list = strchr(gpu_list, ',')+1;
        }
    } else {
        gpu = gpu_index;
        gpus = &gpu;
        ngpus = 1;
    }

    int cam_index = find_int_arg(argc, argv, "-c", 0);
    int clear = find_arg(argc, argv, "-clear");
    char *data = argv[3];
    char *cfg = argv[4];
    char *weights = (argc > 5) ? argv[5] : 0;
    char *filename = (argc > 6) ? argv[6]: 0;
    if(0==strcmp(argv[2], "test")) predict_regressor(data, cfg, weights);
    else if(0==strcmp(argv[2], "train")) train_regressor(data, cfg, weights, gpus, ngpus, clear);
    else if(0==strcmp(argv[2], "demo")) demo_regressor(data, cfg, weights, cam_index, filename);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
cmpl $0x3, %edi
jle 0x3ffb4
movl %edi, %r14d
leaq 0x11a1e(%rip), %rdx     # 0x518cc
xorl %r12d, %r12d
movq %rbx, %rsi
xorl %ecx, %ecx
callq 0x4151
testq %rax, %rax
je 0x3fefc
movq %rax, %r15
movq %rax, %rdi
callq 0x30b0
movq %r15, %rdi
callq 0x3140
testl %eax, %eax
cmovlel %r12d, %eax
pushq $0x1
popq %rbp
cmpq %r12, %rax
je 0x3fef2
xorl %ecx, %ecx
cmpb $0x2c, (%r15,%r12)
sete %cl
addl %ecx, %ebp
incq %r12
jmp 0x3fedc
movl %ebp, %eax
subq $0x1, %rax
jae 0x3fef4
jmp 0x3feff
pushq $0x1
popq %rbp
leaq 0x11239(%rip), %rdx     # 0x5113f
xorl %r15d, %r15d
movl %r14d, %edi
movq %rbx, %rsi
xorl %ecx, %ecx
callq 0x4041
leaq 0x11138(%rip), %rdx     # 0x51055
movl %r14d, %edi
movq %rbx, %rsi
callq 0x3fdd
movl %eax, %r12d
cmpl $0x6, %r14d
jl 0x3ff35
movq 0x28(%rbx), %r15
movq 0x18(%rbx), %r13
movq 0x20(%rbx), %r14
movq 0x10(%rbx), %rbx
leaq 0x121cd(%rip), %rsi     # 0x52115
movq %rbx, %rdi
callq 0x3260
testl %eax, %eax
je 0x3ff76
leaq 0x113b9(%rip), %rsi     # 0x51314
movq %rbx, %rdi
callq 0x3260
testl %eax, %eax
je 0x3ff92
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %r13, %rdi
movq %r14, %rsi
movq %r15, %rdx
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x3fd15
movq %r13, %rdi
movq %r14, %rsi
movq %r15, %rdx
movl %ebp, %r8d
movl %r12d, %r9d
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x3f704
movq 0x2403d(%rip), %rax     # 0x63ff8
movq (%rax), %rdi
movq (%rbx), %rdx
movq 0x8(%rbx), %rcx
leaq 0x1100e(%rip), %rsi     # 0x50fda
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
jmp 0x3270
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/classifier.c
// Function: get_regression_values
float *get_regression_values(char **labels, int n)
{
    float *v = calloc(n, sizeof(float));
    int i;
    for(i = 0; i < n; ++i){
        char *p = strchr(labels[i], ' ');
        *p = 0;
        v[i] = atof(p+1);
    }
    return v;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdi, %rbx
movslq %esi, %r14
pushq $0x4
popq %rsi
movq %r14, %rdi
callq 0x3250
movq %rax, %r15
xorl %r12d, %r12d
testl %r14d, %r14d
cmovlel %r12d, %r14d
pushq $0x20
popq %rbp
cmpq %r12, %r14
je 0x40038
movq (%rbx,%r12,8), %rdi
movl %ebp, %esi
callq 0x3150
movb $0x0, (%rax)
leaq 0x1(%rax), %rdi
callq 0x30f0
cvtsd2ss %xmm0, %xmm0
movss %xmm0, (%r15,%r12,4)
incq %r12
jmp 0x4000d
movq %r15, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/yolo.c
// Function: print_yolo_detections
void print_yolo_detections(FILE **fps, char *id, int total, int classes, int w, int h, detection *dets)
{
    int i, j;
    for(i = 0; i < total; ++i){
        float xmin = dets[i].bbox.x - dets[i].bbox.w/2.;
        float xmax = dets[i].bbox.x + dets[i].bbox.w/2.;
        float ymin = dets[i].bbox.y - dets[i].bbox.h/2.;
        float ymax = dets[i].bbox.y + dets[i].bbox.h/2.;

        if (xmin < 0) xmin = 0;
        if (ymin < 0) ymin = 0;
        if (xmax > w) xmax = w;
        if (ymax > h) ymax = h;

        for(j = 0; j < classes; ++j){
            if (dets[i].prob[j]) fprintf(fps[j], "%s %f %f %f %f %f\n", id, dets[i].prob[j],
                    xmin, ymin, xmax, ymax);
        }
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x58, %rsp
movl %ecx, %ebx
movq %rsi, %r15
movq %rdi, %r12
movq 0x90(%rsp), %rcx
movd %r9d, %xmm0
movd %r8d, %xmm1
punpckldq %xmm0, %xmm1    # xmm1 = xmm1[0],xmm0[0],xmm1[1],xmm0[1]
cvtdq2ps %xmm1, %xmm0
xorl %esi, %esi
testl %ebx, %ebx
cmovlel %esi, %ebx
movaps %xmm0, 0x40(%rsp)
testl %edx, %edx
cmovlel %esi, %edx
movq %rdx, (%rsp)
shufps $0x55, %xmm0, %xmm0     # xmm0 = xmm0[1,1,1,1]
movaps %xmm0, 0x30(%rsp)
leaq 0xd835(%rip), %r13      # 0x520ce
cmpq (%rsp), %rsi
je 0x449a2
imulq $0x30, %rsi, %rbp
cvtps2pd (%rcx,%rbp), %xmm0
cvtps2pd 0x8(%rcx,%rbp), %xmm1
mulpd 0x79e8(%rip), %xmm1     # 0x4c2a0
movapd %xmm1, %xmm2
addpd %xmm0, %xmm2
cvtpd2ps %xmm2, %xmm3
movaps 0x40(%rsp), %xmm4
movaps %xmm4, %xmm2
cmpltps %xmm3, %xmm2
unpcklps %xmm2, %xmm2            # xmm2 = xmm2[0,0,1,1]
movmskpd %xmm2, %eax
movaps %xmm4, %xmm2
testb $0x1, %al
jne 0x448e1
movaps %xmm3, %xmm2
movq %rsi, 0x8(%rsp)
movaps 0x30(%rsp), %xmm4
testb $0x2, %al
jne 0x448f6
shufps $0x55, %xmm3, %xmm3     # xmm3 = xmm3[1,1,1,1]
movaps %xmm3, %xmm4
addq %rcx, %rbp
subpd %xmm1, %xmm0
cvtsd2ss %xmm0, %xmm1
movhlps %xmm0, %xmm0            # xmm0 = xmm0[1,1]
cvtsd2ss %xmm0, %xmm0
xorps %xmm3, %xmm3
maxss %xmm1, %xmm3
xorps %xmm1, %xmm1
maxss %xmm0, %xmm1
cvtss2sd %xmm3, %xmm0
movsd %xmm0, 0x28(%rsp)
cvtss2sd %xmm1, %xmm0
movsd %xmm0, 0x20(%rsp)
cvtss2sd %xmm2, %xmm0
movsd %xmm0, 0x18(%rsp)
cvtss2sd %xmm4, %xmm0
movsd %xmm0, 0x10(%rsp)
xorl %r14d, %r14d
cmpq %r14, %rbx
je 0x4498d
movq 0x18(%rbp), %rax
movss (%rax,%r14,4), %xmm0
ucomiss 0x7721(%rip), %xmm0     # 0x4c078
jne 0x4495b
jnp 0x44988
movq (%r12,%r14,8), %rdi
cvtss2sd %xmm0, %xmm0
movq %r13, %rsi
movq %r15, %rdx
movsd 0x28(%rsp), %xmm1
movsd 0x20(%rsp), %xmm2
movsd 0x18(%rsp), %xmm3
movsd 0x10(%rsp), %xmm4
movb $0x5, %al
callq 0x3270
incq %r14
jmp 0x44941
movq 0x8(%rsp), %rsi
incq %rsi
movq 0x90(%rsp), %rcx
jmp 0x44899
addq $0x58, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/detector.c
// Function: print_detector_detections
void print_detector_detections(FILE **fps, char *id, detection *dets, int total, int classes, int w, int h)
{
    int i, j;
    for(i = 0; i < total; ++i){
        float xmin = dets[i].bbox.x - dets[i].bbox.w/2. + 1;
        float xmax = dets[i].bbox.x + dets[i].bbox.w/2. + 1;
        float ymin = dets[i].bbox.y - dets[i].bbox.h/2. + 1;
        float ymax = dets[i].bbox.y + dets[i].bbox.h/2. + 1;

        if (xmin < 1) xmin = 1;
        if (ymin < 1) ymin = 1;
        if (xmax > w) xmax = w;
        if (ymax > h) ymax = h;

        for(j = 0; j < classes; ++j){
            if (dets[i].prob[j]) fprintf(fps[j], "%s %f %f %f %f %f\n", id, dets[i].prob[j],
                    xmin, ymin, xmax, ymax);
        }
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movl %r8d, %ebx
movq %rsi, %r12
movq %rdi, %r13
movd %r9d, %xmm0
movd 0xa0(%rsp), %xmm1
punpckldq %xmm1, %xmm0    # xmm0 = xmm0[0],xmm1[0],xmm0[1],xmm1[1]
cvtdq2ps %xmm0, %xmm0
movaps %xmm0, 0x50(%rsp)
shufps $0x55, %xmm0, %xmm0     # xmm0 = xmm0[1,1,1,1]
movaps %xmm0, 0x40(%rsp)
xorl %esi, %esi
testl %r8d, %r8d
cmovlel %esi, %ebx
testl %ecx, %ecx
cmovlel %esi, %ecx
movq %rcx, 0x10(%rsp)
leaq 0xc192(%rip), %rbp      # 0x520ce
movq %rdx, 0x8(%rsp)
cmpq 0x10(%rsp), %rsi
je 0x46070
imulq $0x30, %rsi, %r15
cvtps2pd (%rdx,%r15), %xmm0
cvtps2pd 0x8(%rdx,%r15), %xmm1
mulpd 0x633d(%rip), %xmm1     # 0x4c2a0
movapd %xmm1, %xmm2
addpd %xmm0, %xmm2
addpd 0xb3cd(%rip), %xmm2     # 0x51340
cvtpd2ps %xmm2, %xmm4
movaps 0x50(%rsp), %xmm3
movaps %xmm3, %xmm2
cmpltps %xmm4, %xmm2
unpcklps %xmm2, %xmm2            # xmm2 = xmm2[0,0,1,1]
movmskpd %xmm2, %eax
movaps %xmm3, %xmm2
testb $0x1, %al
jne 0x45f94
movaps %xmm4, %xmm2
movq %rsi, 0x18(%rsp)
movaps 0x40(%rsp), %xmm3
testb $0x2, %al
jne 0x45fa9
shufps $0x55, %xmm4, %xmm4     # xmm4 = xmm4[1,1,1,1]
movaps %xmm4, %xmm3
addq %rdx, %r15
subpd %xmm1, %xmm0
movapd %xmm0, %xmm1
movsd 0x616c(%rip), %xmm4     # 0x4c128
addsd %xmm4, %xmm1
cvtsd2ss %xmm1, %xmm1
unpckhpd %xmm0, %xmm0            # xmm0 = xmm0[1,1]
addsd %xmm4, %xmm0
cvtsd2ss %xmm0, %xmm0
movss 0x6030(%rip), %xmm5     # 0x4c008
movaps %xmm5, %xmm4
maxss %xmm1, %xmm4
movaps %xmm5, %xmm1
maxss %xmm0, %xmm1
cvtss2sd %xmm4, %xmm0
movsd %xmm0, 0x38(%rsp)
cvtss2sd %xmm1, %xmm0
movsd %xmm0, 0x30(%rsp)
cvtss2sd %xmm2, %xmm0
movsd %xmm0, 0x28(%rsp)
cvtss2sd %xmm3, %xmm0
movsd %xmm0, 0x20(%rsp)
xorl %r14d, %r14d
cmpq %r14, %rbx
je 0x4605e
movq 0x18(%r15), %rax
movss (%rax,%r14,4), %xmm0
ucomiss 0x6051(%rip), %xmm0     # 0x4c078
jne 0x4602b
jnp 0x46059
movq (%r13,%r14,8), %rdi
cvtss2sd %xmm0, %xmm0
movq %rbp, %rsi
movq %r12, %rdx
movsd 0x38(%rsp), %xmm1
movsd 0x30(%rsp), %xmm2
movsd 0x28(%rsp), %xmm3
movsd 0x20(%rsp), %xmm4
movb $0x5, %al
callq 0x3270
incq %r14
jmp 0x46011
movq 0x18(%rsp), %rsi
incq %rsi
movq 0x8(%rsp), %rdx
jmp 0x45f41
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/detector.c
// Function: print_imagenet_detections
void print_imagenet_detections(FILE *fp, int id, detection *dets, int total, int classes, int w, int h)
{
    int i, j;
    for(i = 0; i < total; ++i){
        float xmin = dets[i].bbox.x - dets[i].bbox.w/2.;
        float xmax = dets[i].bbox.x + dets[i].bbox.w/2.;
        float ymin = dets[i].bbox.y - dets[i].bbox.h/2.;
        float ymax = dets[i].bbox.y + dets[i].bbox.h/2.;

        if (xmin < 0) xmin = 0;
        if (ymin < 0) ymin = 0;
        if (xmax > w) xmax = w;
        if (ymax > h) ymax = h;

        for(j = 0; j < classes; ++j){
            int class = j;
            if (dets[i].prob[class]) fprintf(fp, "%d %d %f %f %f %f %f\n", id, j+1, dets[i].prob[class],
                    xmin, ymin, xmax, ymax);
        }
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x68, %rsp
movl %r8d, %ebx
movl %esi, %ebp
movq %rdi, %r12
movd %r9d, %xmm0
movd 0xa0(%rsp), %xmm1
punpckldq %xmm1, %xmm0    # xmm0 = xmm0[0],xmm1[0],xmm0[1],xmm1[1]
cvtdq2ps %xmm0, %xmm0
xorl %esi, %esi
testl %r8d, %r8d
cmovlel %esi, %ebx
movaps %xmm0, 0x50(%rsp)
testl %ecx, %ecx
cmovlel %esi, %ecx
movq %rcx, 0x10(%rsp)
shufps $0x55, %xmm0, %xmm0     # xmm0 = xmm0[1,1,1,1]
movaps %xmm0, 0x40(%rsp)
leaq 0xc085(%rip), %r13      # 0x52156
movq %rdx, 0x8(%rsp)
cmpq 0x10(%rsp), %rsi
je 0x461e1
imulq $0x30, %rsi, %r15
cvtps2pd (%rdx,%r15), %xmm0
cvtps2pd 0x8(%rdx,%r15), %xmm1
mulpd 0x61a8(%rip), %xmm1     # 0x4c2a0
movapd %xmm1, %xmm2
addpd %xmm0, %xmm2
cvtpd2ps %xmm2, %xmm3
movaps 0x50(%rsp), %xmm4
movaps %xmm4, %xmm2
cmpltps %xmm3, %xmm2
unpcklps %xmm2, %xmm2            # xmm2 = xmm2[0,0,1,1]
movmskpd %xmm2, %eax
movaps %xmm4, %xmm2
testb $0x1, %al
jne 0x46121
movaps %xmm3, %xmm2
movq %rsi, 0x18(%rsp)
movaps 0x40(%rsp), %xmm4
testb $0x2, %al
jne 0x46136
shufps $0x55, %xmm3, %xmm3     # xmm3 = xmm3[1,1,1,1]
movaps %xmm3, %xmm4
addq %rdx, %r15
subpd %xmm1, %xmm0
cvtsd2ss %xmm0, %xmm1
movhlps %xmm0, %xmm0            # xmm0 = xmm0[1,1]
cvtsd2ss %xmm0, %xmm0
xorps %xmm3, %xmm3
maxss %xmm1, %xmm3
xorps %xmm1, %xmm1
maxss %xmm0, %xmm1
cvtss2sd %xmm3, %xmm0
movsd %xmm0, 0x38(%rsp)
cvtss2sd %xmm1, %xmm0
movsd %xmm0, 0x30(%rsp)
cvtss2sd %xmm2, %xmm0
movsd %xmm0, 0x28(%rsp)
cvtss2sd %xmm4, %xmm0
movsd %xmm0, 0x20(%rsp)
xorl %r14d, %r14d
cmpq %r14, %rbx
je 0x461cf
movq 0x18(%r15), %rax
movss (%rax,%r14,4), %xmm0
ucomiss 0x5ee1(%rip), %xmm0     # 0x4c078
jne 0x4619b
jnp 0x461ca
cvtss2sd %xmm0, %xmm0
leal 0x1(%r14), %ecx
movq %r12, %rdi
movq %r13, %rsi
movl %ebp, %edx
movsd 0x38(%rsp), %xmm1
movsd 0x30(%rsp), %xmm2
movsd 0x28(%rsp), %xmm3
movsd 0x20(%rsp), %xmm4
movb $0x5, %al
callq 0x3270
incq %r14
jmp 0x46181
movq 0x18(%rsp), %rsi
incq %rsi
movq 0x8(%rsp), %rdx
jmp 0x460d6
addq $0x68, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/nightmare.c
// Function: abs_mean
float abs_mean(float *x, int n)
{
    int i;
    float sum = 0;
    for (i = 0; i < n; ++i){
        sum += fabs(x[i]);
    }
    return sum/n;
}

// Assembly:
xorl %eax, %eax
testl %esi, %esi
movl $0x0, %ecx
cmovgl %esi, %ecx
xorps %xmm0, %xmm0
movaps 0x41ea(%rip), %xmm1     # 0x4c140
cmpq %rax, %rcx
je 0x47f6c
movss (%rdi,%rax,4), %xmm2
andps %xmm1, %xmm2
addss %xmm2, %xmm0
incq %rax
jmp 0x47f56
cvtsi2ss %esi, %xmm1
divss %xmm1, %xmm0
retq
// File: /workspace/github_c_makefile_star2_O2/SimpleDoger[P]Darknet_CPU_Only/nightmare.c
// Function: calculate_loss
void calculate_loss(float *output, float *delta, int n, float thresh)
{
    int i;
    float mean = mean_array(output, n); 
    float var = variance_array(output, n);
    for(i = 0; i < n; ++i){
        if(delta[i] > mean + thresh*sqrt(var)) delta[i] = output[i];
        else delta[i] = 0;
    }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x28, %rsp
movss %xmm0, 0x8(%rsp)
movl %edx, %ebx
movq %rsi, %r14
movq %rdi, %r15
movl %edx, %esi
callq 0x48c4
movss %xmm0, (%rsp)
movq %r15, %rdi
movl %ebx, %esi
callq 0x49b0
cvtss2sd (%rsp), %xmm2
cvtss2sd 0x8(%rsp), %xmm3
cvtss2sd %xmm0, %xmm4
xorl %r12d, %r12d
testl %ebx, %ebx
cmovlel %r12d, %ebx
sqrtsd %xmm4, %xmm5
xorpd %xmm6, %xmm6
movsd %xmm2, (%rsp)
movsd %xmm3, 0x20(%rsp)
movsd %xmm4, 0x18(%rsp)
movsd %xmm5, 0x10(%rsp)
cmpq %r12, %rbx
je 0x48042
cvtss2sd (%r14,%r12,4), %xmm7
ucomisd %xmm6, %xmm4
movapd %xmm5, %xmm0
jae 0x48020
movapd %xmm4, %xmm0
movsd %xmm7, 0x8(%rsp)
callq 0x3460
movsd 0x8(%rsp), %xmm7
xorpd %xmm6, %xmm6
movsd 0x10(%rsp), %xmm5
movsd 0x18(%rsp), %xmm4
movsd 0x20(%rsp), %xmm3
movsd (%rsp), %xmm2
mulsd %xmm3, %xmm0
addsd %xmm2, %xmm0
xorps %xmm1, %xmm1
ucomisd %xmm0, %xmm7
jbe 0x48037
movss (%r15,%r12,4), %xmm1
movss %xmm1, (%r14,%r12,4)
incq %r12
jmp 0x47fdb
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq