LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/recdata_simple.c
// Function: recdata_simple_create
recdata_t* recdata_simple_create(FILE* user_data, FILE* item_data, int N_users, int N_items, int N_prefs, int binary) {
    recdata_t* recdata;
    recdata_simple_args_t* args;
    
    recdata = malloc(sizeof(recdata_t));
    recdata->N_users = N_users;
    recdata->N_items = N_items;
    recdata->N_prefs = N_prefs;
    
    recdata->userdata_size = recdata_simple_userdata_size;
    recdata->itemdata_size = recdata_simple_itemdata_size;
    recdata->userdata = recdata_simple_userdata;
    recdata->itemdata = recdata_simple_itemdata;
    recdata->close = recdata_simple_close;
    
    args = malloc(sizeof(recdata_simple_args_t));
    recdata->args = args;
    
    args->binary = binary;
    read_data(&(args->n_userdata), &(args->i_userdata), &(args->r_userdata), user_data, N_users, N_prefs, binary);
    
    read_data(&(args->n_itemdata), &(args->i_itemdata), &(args->r_itemdata), item_data, N_items, N_prefs, binary);
    
    return recdata;    
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %r9d, %r15d
movl %r8d, %ebx
movl %ecx, %ebp
movl %edx, %r13d
movq %rsi, 0x10(%rsp)
movq %rdi, 0x8(%rsp)
pushq $0x40
popq %rdi
callq 0x10b0
movq %rax, %r12
movl %r13d, (%rax)
movl %ebp, 0x4(%rax)
movl %ebx, 0x8(%rax)
leaq -0x334(%rip), %rax      # 0x12c4
movq %rax, 0x10(%r12)
leaq -0x336(%rip), %rax      # 0x12ce
movq %rax, 0x18(%r12)
leaq -0x337(%rip), %rax      # 0x12d9
movq %rax, 0x20(%r12)
leaq -0x315(%rip), %rax      # 0x1307
movq %rax, 0x28(%r12)
leaq -0x2f2(%rip), %rax      # 0x1336
movq %rax, 0x30(%r12)
pushq $0x38
popq %rdi
callq 0x10b0
movq %rax, %r14
movq %rax, 0x38(%r12)
movl %r15d, 0x30(%rax)
leaq 0x8(%rax), %rsi
leaq 0x10(%rax), %rdx
movl %r15d, (%rsp)
movq %rax, %rdi
movq 0x8(%rsp), %rcx
movl %r13d, %r8d
movl %ebx, %r9d
callq 0x13b4
leaq 0x18(%r14), %rdi
leaq 0x20(%r14), %rsi
addq $0x28, %r14
movl %r15d, (%rsp)
movq %r14, %rdx
movq 0x10(%rsp), %rcx
movl %ebp, %r8d
movl %ebx, %r9d
callq 0x13b4
movq %r12, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/recdata_transposed.c
// Function: recdata_transposed_create
recdata_t* recdata_transposed_create(recdata_t* recdata0) {
    recdata_t* recdata;
    
    recdata = malloc(sizeof(recdata_t));
    recdata->N_users = recdata0->N_items;
    recdata->N_items = recdata0->N_users;
    recdata->N_prefs = recdata0->N_prefs;
    
    recdata->userdata_size = recdata0->itemdata_size;
    recdata->itemdata_size = recdata0->userdata_size;
    recdata->userdata = recdata0->itemdata;
    recdata->itemdata = recdata0->userdata;
    recdata->close = recdata_transposed_close;
    
    recdata->args = recdata0->args;
    
    return recdata;    
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
pushq $0x40
popq %rdi
callq 0x10b0
movq (%rbx), %xmm0
pshufd $0xe1, %xmm0, %xmm0     # xmm0 = xmm0[1,0,2,3]
movq %xmm0, (%rax)
movl 0x8(%rbx), %ecx
movl %ecx, 0x8(%rax)
movdqu 0x10(%rbx), %xmm0
pshufd $0x4e, %xmm0, %xmm0     # xmm0 = xmm0[2,3,0,1]
movdqu %xmm0, 0x10(%rax)
movdqu 0x20(%rbx), %xmm0
pshufd $0x4e, %xmm0, %xmm0     # xmm0 = xmm0[2,3,0,1]
movdqu %xmm0, 0x20(%rax)
leaq -0x45(%rip), %rcx       # 0x1698
movq %rcx, 0x30(%rax)
movq 0x38(%rbx), %rcx
movq %rcx, 0x38(%rax)
popq %rbx
retq
nop
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/similarity_setcosine.c
// Function: similarity_setcosine_calculate
idpairs_t* similarity_setcosine_calculate(int uid, int k, void* args) {
    recdata_t* recdata;
    int* coo;
    idpairs_t* ud;
    idpairs_t* id;
    int i;
    int j;
    int vid;
    int iid;
    topn_t* topn;
    idpairs_t* pairs;
    
    recdata = args;
    
    coo = calloc(recdata->N_users, sizeof(int));
    
    ud = recdata_userdata(recdata, uid);
    for (i = 0; i < idpairs_size(ud); i++) {
        iid = idpairs_keys(ud)[i];
        id = recdata_itemdata(recdata, iid);
        for (j = 0; j < idpairs_size(id); j++) {
            vid = idpairs_keys(id)[j];
            coo[vid]++;
        }
        idpairs_close_shallow(id);
    }
    idpairs_close_shallow(ud);
    
    coo[uid] = 0;
    
    topn = topn_create(k);
    for (vid = 0; vid < recdata->N_users; vid++) {
        if (coo[vid] > 0) {
            topn_add(topn, vid, coo[vid] / sqrt(recdata_userdata_size(recdata, uid) * recdata_userdata_size(recdata, vid)));
        }
    }
    
    free(coo);

    pairs = topn_get_pairs(topn);
    
    topn_close(topn);

    return pairs;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %rbx
movl %esi, 0x4(%rsp)
movl %edi, %ebp
movslq (%rdx), %rdi
pushq $0x4
popq %rsi
callq 0x1090
movq %rax, %r14
movq %rbx, %rdi
movl %ebp, (%rsp)
movl %ebp, %esi
callq 0x1294
movq %rax, %r12
xorl %r15d, %r15d
movq %r12, %rdi
callq 0x2333
cltq
cmpq %rax, %r15
jge 0x179e
movq %r12, %rdi
callq 0x2336
movl (%rax,%r15,4), %esi
movq %rbx, %rdi
callq 0x12a2
movq %rax, %r13
xorl %ebp, %ebp
movq %r13, %rdi
callq 0x2333
cltq
cmpq %rax, %rbp
jge 0x1791
movq %r13, %rdi
callq 0x2336
movslq (%rax,%rbp,4), %rax
incl (%r14,%rax,4)
incq %rbp
jmp 0x176d
movq %r13, %rdi
callq 0x232e
incq %r15
jmp 0x1745
movq %r12, %rdi
callq 0x232e
movslq (%rsp), %rax
andl $0x0, (%r14,%rax,4)
movl 0x4(%rsp), %edi
callq 0x1b30
movq %rax, %r15
xorl %r12d, %r12d
movslq (%rbx), %rax
cmpq %rax, %r12
jge 0x1820
movl (%r14,%r12,4), %ebp
testl %ebp, %ebp
jle 0x181b
movq %rbx, %rdi
movl (%rsp), %esi
callq 0x1278
movl %eax, %r13d
movq %rbx, %rdi
movl %r12d, %esi
callq 0x1278
imull %r13d, %eax
cvtsi2sd %eax, %xmm0
ucomisd 0x1811(%rip), %xmm0     # 0x3008
jb 0x17ff
sqrtsd %xmm0, %xmm0
jmp 0x1804
callq 0x10f0
cvtsi2sd %ebp, %xmm1
divsd %xmm0, %xmm1
movq %r15, %rdi
movl %r12d, %esi
movapd %xmm1, %xmm0
callq 0x1d0e
incq %r12
jmp 0x17be
movq %r14, %rdi
callq 0x1030
movq %r15, %rdi
callq 0x1e29
movq %rax, %rbx
movq %r15, %rdi
callq 0x1b74
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/similarity_setcosine.c
// Function: similarity_setcosine_create
similarity_t* similarity_setcosine_create(recdata_t* recdata) {
    similarity_t* similarity;
    
    similarity = malloc(sizeof(similarity_t));
    similarity->calculate = similarity_setcosine_calculate;
    similarity->close = similarity_setcosine_close;
    similarity->args = recdata;
    
    return similarity;
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
pushq $0x18
popq %rdi
callq 0x10b0
leaq -0x151(%rip), %rcx      # 0x1710
movq %rcx, (%rax)
leaq -0x1e(%rip), %rcx       # 0x184d
movq %rcx, 0x8(%rax)
movq %rbx, 0x10(%rax)
popq %rbx
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/similarity_veccosine.c
// Function: similarity_veccosine_calculate
idpairs_t* similarity_veccosine_calculate(int uid, int k, void* args) {
    recdata_t* recdata;
    double* norm;
    double* coo;
    idpairs_t* ud;
    idpairs_t* id;
    int i;
    int j;
    int vid;
    int iid;
    double r;
    topn_t* topn;
    idpairs_t* pairs;
    
    recdata = ((similarity_veccosine_args_t*) args)->recdata;
    norm = ((similarity_veccosine_args_t*) args)->norm;
    
    coo = calloc(recdata->N_users, sizeof(double));
    
    ud = recdata_userdata(recdata, uid);
    for (i = 0; i < idpairs_size(ud); i++) {
        iid = idpairs_keys(ud)[i];
        r = idpairs_values(ud)[i];
        id = recdata_itemdata(recdata, iid);
        for (j = 0; j < idpairs_size(id); j++) {
            vid = idpairs_keys(id)[j];
            coo[vid] += r * idpairs_values(id)[j];
        }
        idpairs_close_shallow(id);
    }
    idpairs_close_shallow(ud);
    
    coo[uid] = 0.0;
    
    topn = topn_create(k);
    for (vid = 0; vid < recdata->N_users; vid++) {
        if (coo[vid] > 0) {
            topn_add(topn, vid, coo[vid] * norm[uid] * norm[vid]);
        }
    }
    
    free(coo);

    pairs = topn_get_pairs(topn);
    
    topn_close(topn);

    return pairs;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x28, %rsp
movl %esi, 0xc(%rsp)
movl %edi, %ebp
movq (%rdx), %rbx
movq 0x8(%rdx), %rax
movq %rax, 0x10(%rsp)
movslq (%rbx), %rdi
pushq $0x8
popq %rsi
callq 0x1090
movq %rax, %r14
movq %rbx, %rdi
movl %ebp, 0x8(%rsp)
movl %ebp, %esi
callq 0x1294
movq %rax, %r12
xorl %r15d, %r15d
movq %rbx, 0x18(%rsp)
movq %r12, %rdi
callq 0x2333
cltq
cmpq %rax, %r15
jge 0x1956
movq %r12, %rdi
callq 0x2336
movl (%rax,%r15,4), %r13d
movq %r12, %rdi
callq 0x233b
movsd (%rax,%r15,8), %xmm0
movsd %xmm0, 0x20(%rsp)
movq %rbx, %rdi
movl %r13d, %esi
callq 0x12a2
movq %rax, %r13
xorl %ebp, %ebp
movq %r13, %rdi
callq 0x2333
cltq
cmpq %rax, %rbp
jge 0x1941
movq %r13, %rdi
callq 0x2336
movslq (%rax,%rbp,4), %rbx
movq %r13, %rdi
callq 0x233b
movsd (%rax,%rbp,8), %xmm0
mulsd 0x20(%rsp), %xmm0
addsd (%r14,%rbx,8), %xmm0
movsd %xmm0, (%r14,%rbx,8)
incq %rbp
jmp 0x1902
movq %r13, %rdi
callq 0x232e
incq %r15
movq 0x18(%rsp), %rbx
jmp 0x18bf
movq %r12, %rdi
callq 0x232e
movslq 0x8(%rsp), %r13
andq $0x0, (%r14,%r13,8)
movl 0xc(%rsp), %edi
callq 0x1b30
movq %rax, %r15
xorl %r12d, %r12d
xorpd %xmm1, %xmm1
movslq (%rbx), %rax
cmpq %rax, %r12
jge 0x19b4
movsd (%r14,%r12,8), %xmm0
ucomisd %xmm1, %xmm0
jbe 0x19af
movq 0x10(%rsp), %rax
mulsd (%rax,%r13,8), %xmm0
mulsd (%rax,%r12,8), %xmm0
movq %r15, %rdi
movl %r12d, %esi
callq 0x1d0e
xorpd %xmm1, %xmm1
incq %r12
jmp 0x197b
movq %r14, %rdi
callq 0x1030
movq %r15, %rdi
callq 0x1e29
movq %rax, %rbx
movq %r15, %rdi
callq 0x1b74
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/similarity_veccosine.c
// Function: calculate_norm
double* calculate_norm(recdata_t* recdata) {
    int i;
    int uid;
    idpairs_t* ud;
    double* norm;
    
    norm = malloc(recdata->N_users * sizeof(double));
     
    for (uid = 0; uid < recdata->N_users; uid++) {
        ud = recdata_userdata(recdata, uid);
        norm[uid] = 0.0;
        for (i = 0; i < idpairs_size(ud); i++) {
            norm[uid] += idpairs_values(ud)[i] * idpairs_values(ud)[i];
        }
        norm[uid] = 1 / sqrt(norm[uid]);
        idpairs_close_shallow(ud);
    }
     
    return norm;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x10, %rsp
movq %rdi, %rbx
movslq (%rdi), %r12
movq %r12, %rdi
shlq $0x3, %rdi
callq 0x10b0
movq %rax, %r14
xorl %r15d, %r15d
movslq %r12d, %rax
cmpq %rax, %r15
jge 0x1ad0
movq %rbx, %rdi
movl %r15d, %esi
callq 0x1294
movq %rax, %r12
xorps %xmm0, %xmm0
movsd %xmm0, (%rsp)
xorl %r13d, %r13d
movq %r12, %rdi
callq 0x2333
cltq
cmpq %rax, %r13
jge 0x1a91
movq %r12, %rdi
callq 0x233b
movsd (%rax,%r13,8), %xmm0
movsd %xmm0, 0x8(%rsp)
movq %r12, %rdi
callq 0x233b
movsd 0x8(%rsp), %xmm1
mulsd (%rax,%r13,8), %xmm1
movsd (%rsp), %xmm0
addsd %xmm1, %xmm0
movsd %xmm0, (%rsp)
movsd %xmm0, (%r14,%r15,8)
incq %r13
jmp 0x1a41
movsd (%rsp), %xmm0
ucomisd 0x156a(%rip), %xmm0     # 0x3008
jb 0x1aa6
sqrtsd %xmm0, %xmm0
jmp 0x1aab
callq 0x10f0
movsd 0x155d(%rip), %xmm1     # 0x3010
divsd %xmm0, %xmm1
movsd %xmm1, (%r14,%r15,8)
movq %r12, %rdi
callq 0x232e
incq %r15
movl (%rbx), %r12d
jmp 0x1a1c
movq %r14, %rax
addq $0x10, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/similarity_veccosine.c
// Function: similarity_veccosine_create
similarity_t* similarity_veccosine_create(recdata_t* recdata) {
    similarity_t* similarity;
    similarity_veccosine_args_t* args;
    
    similarity = malloc(sizeof(similarity_t));
    similarity->calculate = similarity_veccosine_calculate;
    similarity->close = similarity_veccosine_close;
    
    args = malloc(sizeof(similarity_veccosine_args_t));
    args->recdata = recdata;
    args->norm = calculate_norm(recdata);
    similarity->args = args;
    
    return similarity;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
pushq $0x18
popq %rdi
callq 0x10b0
movq %rax, %r14
leaq -0x283(%rip), %rax      # 0x1878
movq %rax, (%r14)
leaq -0x124(%rip), %rax      # 0x19e1
movq %rax, 0x8(%r14)
pushq $0x10
popq %rdi
callq 0x10b0
movq %rax, %r15
movq %rbx, (%rax)
movq %rbx, %rdi
callq 0x19f7
movq %rax, 0x8(%r15)
movq %r15, 0x10(%r14)
movq %r14, %rax
popq %rbx
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/topn.c
// Function: topn_create
topn_t* topn_create(int capacity) {
    topn_t* topn = malloc(sizeof(topn_t));

    topn->capacity = capacity;
    topn->keys = calloc(capacity, sizeof(int));
    topn->values = calloc(capacity, sizeof(double));
    topn->size = 0;
    
    return topn;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movl %edi, %ebx
pushq $0x18
popq %rdi
callq 0x10b0
movq %rax, %r14
movl %ebx, 0x10(%rax)
movslq %ebx, %rbx
pushq $0x4
popq %rsi
movq %rbx, %rdi
callq 0x1090
movq %rax, (%r14)
pushq $0x8
popq %rsi
movq %rbx, %rdi
callq 0x1090
movq %rax, 0x8(%r14)
andl $0x0, 0x14(%r14)
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/topn.c
// Function: reverse
void reverse(topn_t* topn) {
    int i = 0;
    int j = topn->size - 1;
    while (j > i) {
        swap(topn, i, j);
        j--;
        i++;
    }
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movq %rdi, %rbx
movl 0x14(%rdi), %ebp
decl %ebp
xorl %r14d, %r14d
cmpl %r14d, %ebp
jle 0x1bef
movq %rbx, %rdi
movl %r14d, %esi
movl %ebp, %edx
callq 0x1b97
incl %r14d
decl %ebp
jmp 0x1bd6
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/topn.c
// Function: minChild
int minChild(topn_t* topn, int i) {
    int l = left(i);
    int r = right(i);

    if (l >= topn->capacity) {
        return -1;
    }

    if (r >= topn->size) {
        return l;
    }

    return (topn->values[l] < topn->values[r] || (topn->values[l] == topn->values[r] && topn->keys[l] < topn->keys[r])) ? l : r;
}

// Assembly:
leal 0x1(,%rsi,2), %eax
cmpl 0x10(%rdi), %eax
jge 0x1c58
leal 0x2(,%rsi,2), %ecx
cmpl 0x14(%rdi), %ecx
jge 0x1c5b
movq 0x8(%rdi), %r8
movslq %eax, %rdx
movsd (%r8,%rdx,8), %xmm0
movslq %ecx, %rsi
movsd (%r8,%rsi,8), %xmm1
ucomisd %xmm0, %xmm1
ja 0x1c5b
ucomisd %xmm1, %xmm0
jne 0x1c55
jp 0x1c55
movq (%rdi), %rdi
movl (%rdi,%rdx,4), %edx
cmpl (%rdi,%rsi,4), %edx
jl 0x1c5b
movl %ecx, %eax
retq
pushq $-0x1
popq %rax
retq
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/topn.c
// Function: topn_sort
void topn_sort(topn_t* topn) {
    int i;
    int j;

    int origSize = topn->size;
    int origCapacity = topn->capacity;
    topn->capacity = topn->size;
    while (topn->size > 0) {
        swap(topn, 0, topn->size - 1);
        topn->size--;
        topn->capacity--;
        i = 0;
        j = minChild(topn, i);
        while (j != -1 && (topn->values[i] > topn->values[j] || (topn->values[i] == topn->values[j] && topn->keys[i] > topn->keys[j]))) {
            swap(topn, i, j);
            i = j;
            j = minChild(topn, i);
        }
    }
    topn->size = origSize;
    topn->capacity = origCapacity;
    reverse(topn);
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdi, %rbx
movl 0x10(%rdi), %r15d
movl 0x14(%rdi), %r12d
movl %r12d, 0x10(%rdi)
movl %r12d, %edx
testl %edx, %edx
jle 0x1ce8
decl %edx
xorl %ebp, %ebp
movq %rbx, %rdi
xorl %esi, %esi
callq 0x1b97
movq 0x10(%rbx), %xmm0
paddd 0x138b(%rip), %xmm0     # 0x3020
movq %xmm0, 0x10(%rbx)
movq %rbx, %rdi
movl %ebp, %esi
callq 0x1c0e
cmpl $-0x1, %eax
je 0x1ce3
movl %eax, %r14d
movq 0x8(%rbx), %rdx
movslq %ebp, %rax
movsd (%rdx,%rax,8), %xmm0
movslq %r14d, %rcx
ucomisd (%rdx,%rcx,8), %xmm0
ja 0x1cd1
jne 0x1ce3
jp 0x1ce3
movq (%rbx), %rdx
movl (%rdx,%rax,4), %eax
cmpl (%rdx,%rcx,4), %eax
jle 0x1ce3
movq %rbx, %rdi
movl %ebp, %esi
movl %r14d, %edx
callq 0x1b97
movl %r14d, %ebp
jmp 0x1c9a
movl 0x14(%rbx), %edx
jmp 0x1c76
movl %r12d, 0x14(%rbx)
movl %r15d, 0x10(%rbx)
movq %rbx, %rdi
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
jmp 0x1bc7
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/topn.c
// Function: topn_add
int topn_add(topn_t* topn, int key, double value) {
    int i;
    int j;

    if (topn->size < topn->capacity) {
        i = topn->size;
        j = parent(i);
        topn->keys[i] = key;
        topn->values[i] = value;
        while (i > 0 && (topn->values[j] > topn->values[i] || (topn->values[j] == topn->values[i] && topn->keys[j] > topn->keys[i]))) {
            swap(topn, i, j);
            i = j;
            j = parent(i);
        }
        topn->size++;

        return 1;
    } else {
        if (topn->values[0] > value || (topn->values[0] == value && topn->keys[0] > key)) {
            return 0;
        }
        i = 0;
        j = minChild(topn, i);
        topn->keys[i] = key;
        topn->values[i] = value;
        while (j != -1 && (topn->values[i] > topn->values[j] || (topn->values[i] == topn->values[j] && topn->keys[i] > topn->keys[j]))) {
            swap(topn, i, j);
            i = j;
            j = minChild(topn, i);
        }

        return 1;
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %esi, %r12d
movq %rdi, %rbx
movl 0x14(%rdi), %esi
cmpl 0x10(%rdi), %esi
jge 0x1d84
movslq %esi, %rax
movq (%rbx), %rcx
movl %r12d, (%rcx,%rax,4)
movq 0x8(%rbx), %rcx
movsd %xmm0, (%rcx,%rax,8)
pushq $0x2
popq %r14
leal -0x1(%rsi), %eax
cltd
idivl %r14d
testl %esi, %esi
jle 0x1d7c
movl %eax, %ebp
movq 0x8(%rbx), %rdx
cltq
movsd (%rdx,%rax,8), %xmm0
movl %esi, %ecx
ucomisd (%rdx,%rcx,8), %xmm0
ja 0x1d6e
jne 0x1d7c
jp 0x1d7c
movq (%rbx), %rdx
movl (%rdx,%rax,4), %eax
cmpl (%rdx,%rcx,4), %eax
jle 0x1d7c
movq %rbx, %rdi
movl %ebp, %edx
callq 0x1b97
movl %ebp, %esi
jmp 0x1d3e
incl 0x14(%rbx)
pushq $0x1
popq %rbp
jmp 0x1da2
movq 0x8(%rbx), %r13
movsd (%r13), %xmm1
xorl %ebp, %ebp
ucomisd %xmm0, %xmm1
ja 0x1da2
movq (%rbx), %rax
jne 0x1db3
jp 0x1db3
cmpl %r12d, (%rax)
jle 0x1db3
movl %ebp, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
xorl %r15d, %r15d
movq %rbx, %rdi
xorl %esi, %esi
movsd %xmm0, (%rsp)
movq %rax, %rbp
callq 0x1c0e
movl %eax, %r14d
movl %r12d, (%rbp)
movsd (%rsp), %xmm0
movsd %xmm0, (%r13)
pushq $0x1
popq %rbp
cmpl $-0x1, %r14d
je 0x1da2
movq 0x8(%rbx), %rdx
movslq %r15d, %rax
movsd (%rdx,%rax,8), %xmm0
movslq %r14d, %rcx
ucomisd (%rdx,%rcx,8), %xmm0
ja 0x1e08
jne 0x1da2
jp 0x1da2
movq (%rbx), %rdx
movl (%rdx,%rax,4), %eax
cmpl (%rdx,%rcx,4), %eax
jle 0x1da2
movq %rbx, %rdi
movl %r15d, %esi
movl %r14d, %edx
callq 0x1b97
movq %rbx, %rdi
movl %r14d, %esi
callq 0x1c0e
movl %r14d, %r15d
movl %eax, %r14d
jmp 0x1ddd
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/topn.c
// Function: topn_get_pairs
idpairs_t* topn_get_pairs(topn_t* topn) {
    idpairs_t* pairs = idpairs_create(topn_size(topn), malloc(topn_size(topn) * sizeof(int)), malloc(topn_size(topn) * sizeof(double)));
    memcpy(idpairs_keys(pairs), topn->keys, topn_size(topn) * sizeof(int));
    memcpy(idpairs_values(pairs), topn->values, topn_size(topn) * sizeof(double));
    
    return pairs;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdi, %rbx
movslq 0x14(%rdi), %r14
leaq (,%r14,4), %rdi
callq 0x10b0
movq %rax, %r15
movq %r14, %rdi
shlq $0x3, %rdi
callq 0x10b0
movl %r14d, %edi
movq %r15, %rsi
movq %rax, %rdx
callq 0x22ec
movq %rax, %r14
movq %rax, %rdi
callq 0x2336
movq (%rbx), %rsi
movslq 0x14(%rbx), %rdx
shlq $0x2, %rdx
movq %rax, %rdi
callq 0x10a0
movq %r14, %rdi
callq 0x233b
movq 0x8(%rbx), %rsi
movslq 0x14(%rbx), %rdx
shlq $0x3, %rdx
movq %rax, %rdi
callq 0x10a0
movq %r14, %rax
popq %rbx
popq %r14
popq %r15
retq
nop
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/recommender.c
// Function: recommender_recommend
idpairs_t* recommender_recommend(recommender_t* recommender, int uid, int n) {
    recdata_t* recdata;
    idpairs_t* pairs;
    idpairs_t* ud;
    int i;
    int iid;
    int jid;
    topn_t* topn;
    double* scores;
    
    recdata = recommender->recdata;
    
    scores = recommender->recommend(uid, recommender->recdata, recommender->args);

    ud = recdata_userdata(recdata, uid);
    for (i = 0; i < idpairs_size(ud); i++) {
        jid = idpairs_keys(ud)[i];
        scores[jid] = 0.0;
    }
    idpairs_close_shallow(ud);

    topn = topn_create(n);
    for (iid = 0; iid < recdata->N_items; iid++) {
        if (scores[iid] > 0) {
            topn_add(topn, iid, scores[iid]);
        }
    }
    
    free(scores);

    topn_sort(topn);
    pairs = topn_get_pairs(topn);
    idpairs_revert(pairs);
    
    topn_close(topn);

    return pairs;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %edx, %ebp
movl %esi, %r15d
movq %rdi, %rax
movq 0x10(%rdi), %rbx
movq 0x18(%rdi), %rdx
movl %esi, %edi
movq %rbx, %rsi
callq *(%rax)
movq %rax, %r14
movq %rbx, %rdi
movl %r15d, %esi
callq 0x1294
movq %rax, %r15
xorl %r12d, %r12d
movq %r15, %rdi
callq 0x2333
cltq
cmpq %rax, %r12
jge 0x1efc
movq %r15, %rdi
callq 0x2336
movslq (%rax,%r12,4), %rax
andq $0x0, (%r14,%rax,8)
incq %r12
jmp 0x1ed7
movq %r15, %rdi
callq 0x232e
movl %ebp, %edi
callq 0x1b30
movq %rax, %r15
xorl %r12d, %r12d
xorpd %xmm1, %xmm1
movslq 0x4(%rbx), %rax
cmpq %rax, %r12
jge 0x1f3e
movsd (%r14,%r12,8), %xmm0
ucomisd %xmm1, %xmm0
jbe 0x1f39
movq %r15, %rdi
movl %r12d, %esi
callq 0x1d0e
xorpd %xmm1, %xmm1
incq %r12
jmp 0x1f15
movq %r14, %rdi
callq 0x1030
movq %r15, %rdi
callq 0x1c5c
movq %r15, %rdi
callq 0x1e29
movq %rax, %rbx
movq %rax, %rdi
callq 0x239e
movq %r15, %rdi
callq 0x1b74
movq %rbx, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/recommender_ub.c
// Function: recommender_ub_recommend
double* recommender_ub_recommend(int uid, recdata_t* recdata, void* args) {
    idpairs_t* neighbors;
    idpairs_t* vd;
    int i;
    int j;
    int vid;
    double s;
    int iid;
    similarity_t* similarity = ((recommender_ub_args_t*) args)->similarity;
    int k = ((recommender_ub_args_t*) args)->k;
    int binary = ((recommender_ub_args_t*) args)->binary;
    
    double* scores = calloc(recdata->N_items, sizeof(double));
    
    neighbors = similarity_calculate(similarity, uid, k);
    for (i = 0; i < idpairs_size(neighbors); i++) {
        vid = idpairs_keys(neighbors)[i];
        vd = recdata_userdata(recdata, vid);
        s = idpairs_values(neighbors)[i];
        for (j = 0; j < idpairs_size(vd); j++) {
            iid = idpairs_keys(vd)[j];
            scores[iid] += binary ? (s) : (s * idpairs_values(vd)[j]);
        }
        idpairs_close_shallow(vd);
    }
    idpairs_close_deep(neighbors);

    return scores;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movl %edi, %ebp
movq (%rdx), %r15
movl 0x8(%rdx), %r12d
movl 0xc(%rdx), %r13d
movq %rsi, 0x10(%rsp)
movslq 0x4(%rsi), %rdi
pushq $0x8
popq %rsi
callq 0x1090
movq %rax, %r14
movq %r15, %rdi
movl %ebp, %esi
movl %r12d, %edx
callq 0x16ec
movq %rax, %rbx
xorl %ebp, %ebp
movq %rax, 0x8(%rsp)
movq %rbx, %rdi
callq 0x2333
cltq
cmpq %rax, %rbp
jge 0x2072
movq %rbx, %rdi
callq 0x2336
movl (%rax,%rbp,4), %esi
movq 0x10(%rsp), %rdi
callq 0x1294
movq %rax, %r12
movq %rbx, %rdi
callq 0x233b
movsd (%rax,%rbp,8), %xmm0
movsd %xmm0, (%rsp)
xorl %ebx, %ebx
movq %r12, %rdi
callq 0x2333
cltq
cmpq %rax, %rbx
jge 0x205d
movq %r12, %rdi
callq 0x2336
movslq (%rax,%rbx,4), %r15
movsd (%rsp), %xmm0
testl %r13d, %r13d
jne 0x204c
movq %r12, %rdi
callq 0x233b
movsd (%rax,%rbx,8), %xmm0
mulsd (%rsp), %xmm0
addsd (%r14,%r15,8), %xmm0
movsd %xmm0, (%r14,%r15,8)
incq %rbx
jmp 0x2015
movq %r12, %rdi
callq 0x232e
incq %rbp
movq 0x8(%rsp), %rbx
jmp 0x1fd6
movq %rbx, %rdi
callq 0x230f
movq %r14, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/recommender_ub.c
// Function: recommender_ub_create
recommender_t* recommender_ub_create(recdata_t* recdata, similarity_t* similarity, int k, int binary) {
    recommender_t* recommender;
    recommender_ub_args_t* args;
    
    recommender = malloc(sizeof(recommender_t));
    recommender->recommend = recommender_ub_recommend;
    recommender->close = recommender_ub_close;
    recommender->recdata = recdata;
    
    args = malloc(sizeof(recommender_ub_args_t));
    args->similarity = similarity;
    args->k = k;
    args->binary = binary;
    recommender->args = args;
    
    return recommender;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %ecx, %ebx
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %r15
pushq $0x20
popq %rdi
callq 0x10b0
movq %rax, %r12
leaq -0x128(%rip), %rax      # 0x1f90
movq %rax, (%r12)
leaq -0x37(%rip), %rax       # 0x208c
movq %rax, 0x8(%r12)
movq %r15, 0x10(%r12)
pushq $0x10
popq %rdi
callq 0x10b0
movq %r14, (%rax)
movl %ebp, 0x8(%rax)
movl %ebx, 0xc(%rax)
movq %rax, 0x18(%r12)
movq %r12, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/recommender_ib.c
// Function: recommender_ib_recommend
double* recommender_ib_recommend(int uid, recdata_t* recdata, void* args) {
    idpairs_t* neighbors;
    idpairs_t* ud;
    int i;
    int j;
    double s;
    int iid;
    int jid;
    idpairs_t** cached_neighbors = ((recommender_ib_args_t*) args)->cached_neighbors;
    int binary = ((recommender_ib_args_t*) args)->binary;
    
    double* scores = calloc(recdata->N_items, sizeof(double));
    
    ud = recdata_userdata(recdata, uid);
    for (i = 0; i < idpairs_size(ud); i++) {
        jid = idpairs_keys(ud)[i];
        neighbors = cached_neighbors[jid];
        s = binary ? 1.0 : idpairs_values(ud)[i];
        for (j = 0; j < idpairs_size(neighbors); j++) {
            iid = idpairs_keys(neighbors)[j];
            scores[iid] += s * idpairs_values(neighbors)[j];
        }
    }
    idpairs_close_shallow(ud);

    return scores;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %r14
movl %edi, %ebp
movq (%rdx), %rax
movq %rax, 0x10(%rsp)
movl 0x8(%rdx), %eax
movl %eax, 0x4(%rsp)
movslq 0x4(%rsi), %rdi
pushq $0x8
popq %rsi
callq 0x1090
movq %rax, %rbx
movq %r14, %rdi
movl %ebp, %esi
callq 0x1294
movq %rax, %r14
xorl %ebp, %ebp
movq %r14, %rdi
callq 0x2333
cltq
cmpq %rax, %rbp
jge 0x21cb
movq %r14, %rdi
callq 0x2336
movslq (%rax,%rbp,4), %rax
movq 0x10(%rsp), %rcx
movq (%rcx,%rax,8), %r15
movsd 0xeb0(%rip), %xmm0      # 0x3010
movsd %xmm0, 0x8(%rsp)
cmpl $0x0, 0x4(%rsp)
jne 0x2180
movq %r14, %rdi
callq 0x233b
movsd (%rax,%rbp,8), %xmm0
movsd %xmm0, 0x8(%rsp)
xorl %r12d, %r12d
movq %r15, %rdi
callq 0x2333
cltq
cmpq %rax, %r12
jge 0x21c3
movq %r15, %rdi
callq 0x2336
movslq (%rax,%r12,4), %r13
movq %r15, %rdi
callq 0x233b
movsd (%rax,%r12,8), %xmm0
mulsd 0x8(%rsp), %xmm0
addsd (%rbx,%r13,8), %xmm0
movsd %xmm0, (%rbx,%r13,8)
incq %r12
jmp 0x2183
incq %rbp
jmp 0x2130
movq %r14, %rdi
callq 0x232e
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/saulvargas[P]re-C-sys/recommender_ib.c
// Function: recommender_ib_close
void recommender_ib_close(recdata_t* recdata, void* args) {
    int iid;
    int N_items;
    recommender_ib_args_t* a = args;
    
    N_items = recdata->N_items;
    for (iid = 0; iid < N_items; iid++) {
        idpairs_close_deep(a->cached_neighbors[iid]);
    }
    free(a->cached_neighbors);

    free(args);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rsi, %rbx
movl 0x4(%rdi), %r14d
xorl %r15d, %r15d
testl %r14d, %r14d
cmovlel %r15d, %r14d
movq (%rbx), %rdi
cmpq %r15, %r14
je 0x2211
movq (%rdi,%r15,8), %rdi
callq 0x230f
incq %r15
jmp 0x21fb
callq 0x1030
movq %rbx, %rdi
popq %rbx
popq %r14
popq %r15
jmp 0x1030
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/recommender_ib.c
// Function: calculate_neighbors
idpairs_t** calculate_neighbors(int N_items, similarity_t* similarity, int k) {
    int iid;
    idpairs_t** idpairs;
    
    idpairs = malloc(N_items * sizeof(idpairs_t*));
    for (iid = 0; iid < N_items; iid++) {
        idpairs[iid] = similarity_calculate(similarity, iid, k);
    }
    
    return idpairs;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
movl %edx, %ebx
movq %rsi, %r14
movslq %edi, %r13
leaq (,%r13,8), %rdi
callq 0x10b0
movq %rax, %r15
xorl %r12d, %r12d
testl %r13d, %r13d
cmovlel %r12d, %r13d
cmpq %r12, %r13
je 0x2269
movq %r14, %rdi
movl %r12d, %esi
movl %ebx, %edx
callq 0x16ec
movq %rax, (%r15,%r12,8)
incq %r12
jmp 0x224e
movq %r15, %rax
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
retq
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/recommender_ib.c
// Function: recommender_ib_create
recommender_t* recommender_ib_create(recdata_t* recdata, similarity_t* similarity, int k, int binary) {
    recommender_t* recommender;
    recommender_ib_args_t* args;
    
    recommender = malloc(sizeof(recommender_t));
    recommender->recommend = recommender_ib_recommend;
    recommender->close = recommender_ib_close;
    recommender->recdata = recdata;
    
    args = malloc(sizeof(recommender_ib_args_t));
    args->cached_neighbors = calculate_neighbors(recdata->N_items, similarity, k);
    args->binary = binary;
    recommender->args = args;
    
    return recommender;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %ecx, %ebx
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %r15
pushq $0x20
popq %rdi
callq 0x10b0
movq %rax, %r12
leaq -0x1ad(%rip), %rax      # 0x20f0
movq %rax, (%r12)
leaq -0xc3(%rip), %rax       # 0x21e5
movq %rax, 0x8(%r12)
movq %r15, 0x10(%r12)
pushq $0x10
popq %rdi
callq 0x10b0
movq %rax, %r13
movl 0x4(%r15), %edi
movq %r14, %rsi
movl %ebp, %edx
callq 0x2223
movq %rax, (%r13)
movl %ebx, 0x8(%r13)
movq %r13, 0x18(%r12)
movq %r12, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/idpairs.c
// Function: idpairs_create
idpairs_t* idpairs_create(int n, int* keys, double* values) {
    idpairs_t* pairs = malloc(sizeof(idpairs_t));
    
    pairs->n = n;
    pairs->keys = keys;
    pairs->values = values;
    
    return pairs;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movq %rdx, %rbx
movq %rsi, %r14
movl %edi, %ebp
pushq $0x18
popq %rdi
callq 0x10b0
movl %ebp, (%rax)
movq %r14, 0x8(%rax)
movq %rbx, 0x10(%rax)
popq %rbx
popq %r14
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/idpairs.c
// Function: revert_int
void revert_int(int n, int* v) {
    int i;
    int x;
    for (i = 0; i < n / 2; i++) {
        x = v[i];
        v[i] = v[n - i - 1];
        v[n - i - 1] = x;
    }
}

// Assembly:
pushq $0x2
popq %rcx
movl %edi, %eax
cltd
idivl %ecx
cltq
decl %edi
xorl %ecx, %ecx
cmpq %rax, %rcx
jge 0x236b
movl (%rsi,%rcx,4), %edx
movslq %edi, %rdi
movl (%rsi,%rdi,4), %r8d
movl %r8d, (%rsi,%rcx,4)
movl %edx, (%rsi,%rdi,4)
incq %rcx
decl %edi
jmp 0x234e
retq
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/idpairs.c
// Function: revert_double
void revert_double(int n, double* v) {
    int i;
    double x;
    for (i = 0; i < n / 2; i++) {
        x = v[i];
        v[i] = v[n - i - 1];
        v[n - i - 1] = x;
    }

}

// Assembly:
pushq $0x2
popq %rcx
movl %edi, %eax
cltd
idivl %ecx
cltq
decl %edi
xorl %ecx, %ecx
cmpq %rax, %rcx
jge 0x239d
movsd (%rsi,%rcx,8), %xmm0
movslq %edi, %rdi
movsd (%rsi,%rdi,8), %xmm1
movsd %xmm1, (%rsi,%rcx,8)
movsd %xmm0, (%rsi,%rdi,8)
incq %rcx
decl %edi
jmp 0x237a
retq
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/aux.c
// Function: read_args
int read_args(int argc, char** argv, FILE** user_data, FILE** item_data, int* N_users, int* N_items, int* N_prefs, int* binary) {
    char* file;

    if (argc != 6) {
        return 0;
    }
    
    file = malloc((strlen(argv[1]) + 7) * sizeof(char));

    strcpy(file, argv[1]);
    strcat(file, ".u");
    *user_data = fopen(file, "r");

    strcpy(file, argv[1]);
    strcat(file, ".i");
    *item_data = fopen(file, "r");
    
    free(file);

    *N_users = atoi(argv[2]);
    *N_items = atoi(argv[3]);
    *N_prefs = atoi(argv[4]);
    *binary = atoi(argv[5]);
    
    return 1;
}

// Assembly:
xorl %eax, %eax
cmpl $0x6, %edi
jne 0x24c0
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rcx, %r12
movq %rdx, %r13
movq %rsi, %rbx
movq 0x8(%rsi), %r14
movq %r14, %rdi
movq %r9, 0x10(%rsp)
movq %r8, 0x8(%rsp)
callq 0x1070
leaq 0x7(%rax), %rdi
callq 0x10b0
movq %rax, %rbp
movq %rax, %rdi
movq %r14, %rsi
callq 0x1040
movq %rbp, %rdi
callq 0x1070
xorl %r15d, %r15d
movb %r15b, 0x2(%rbp,%rax)
movw $0x752e, (%rbp,%rax)    # imm = 0x752E
leaq 0xc0a(%rip), %r14       # 0x3033
movq %rbp, %rdi
movq %r14, %rsi
callq 0x10c0
movq %rax, (%r13)
movq 0x8(%rbx), %rsi
movq %rbp, %rdi
callq 0x1040
movq %rbp, %rdi
callq 0x1070
movb %r15b, 0x2(%rbp,%rax)
movw $0x692e, (%rbp,%rax)    # imm = 0x692E
movq %rbp, %rdi
movq %r14, %rsi
callq 0x10c0
movq %rax, (%r12)
movq %rbp, %rdi
callq 0x1030
movq 0x10(%rbx), %rdi
callq 0x10e0
movq 0x8(%rsp), %rcx
movl %eax, (%rcx)
movq 0x18(%rbx), %rdi
callq 0x10e0
movq 0x10(%rsp), %rcx
movl %eax, (%rcx)
movq 0x20(%rbx), %rdi
callq 0x10e0
movq 0x50(%rsp), %rcx
movl %eax, (%rcx)
movq 0x28(%rbx), %rdi
callq 0x10e0
movq 0x58(%rsp), %rcx
movl %eax, (%rcx)
pushq $0x1
popq %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/recommender_pop.c
// Function: recommender_pop_recommend
double* recommender_pop_recommend(int uid, recdata_t* recdata, void* args) {
    int iid;
    double* scores;

    (void) uid;
    (void) args;

    scores = calloc(recdata->N_items, sizeof(double));
    for (iid = 0; iid < recdata->N_items; iid++) {
        scores[iid] = recdata_itemdata_size(recdata, iid);
    }

    return scores;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %rbx
movl 0x4(%rsi), %ebp
movslq %ebp, %rdi
pushq $0x8
popq %rsi
callq 0x1090
movq %rax, %r14
xorl %r15d, %r15d
movslq %ebp, %rax
cmpq %rax, %r15
jge 0x2507
movq %rbx, %rdi
movl %r15d, %esi
callq 0x1286
cvtsi2sd %eax, %xmm0
movsd %xmm0, (%r14,%r15,8)
incq %r15
movl 0x4(%rbx), %ebp
jmp 0x24e2
movq %r14, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/saulvargas[P]re-C-sys/recommender_pop.c
// Function: recommender_pop_create
recommender_t* recommender_pop_create(recdata_t* recdata) {
    recommender_t* recommender;
    
    recommender = malloc(sizeof(recommender_t));
    recommender->recommend = recommender_pop_recommend;
    recommender->close = recommender_pop_close;
    recommender->recdata = recdata;
    recommender->args = NULL;
    
    return recommender;
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
pushq $0x20
popq %rdi
callq 0x10b0
leaq -0x65(%rip), %rcx       # 0x24c4
movq %rcx, (%rax)
leaq -0x1e(%rip), %rcx       # 0x2515
movq %rcx, 0x8(%rax)
movq %rbx, 0x10(%rax)
andq $0x0, 0x18(%rax)
popq %rbx
retq
// File: /workspace/github_c_makefile_star2_O2/eric-lo[P]3150/4-ProcessKernel/printf_example_slow.c
// Function: main
int main(void) {
	int i = 0;
	for(i = 0; i < MAX; i++) {
		printf("x\n");
	}

	return 0;
}

// Assembly:
pushq %rbp
pushq %rbx
pushq %rax
movl $0xf4240, %ebp          # imm = 0xF4240
leaq 0xeb9(%rip), %rbx       # 0x2004
subl $0x1, %ebp
jb 0x115a
movq %rbx, %rdi
callq 0x1030
jmp 0x114b
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %rbp
retq
// File: /workspace/github_c_makefile_star2_O2/antonblanchard[P]will-it-scale/tests/unlink2.c
// Function: testcase_prepare
void testcase_prepare(unsigned long nr_tasks)
{
	int i;
	tmpdirs = (char(*)[sizeof(template)])malloc(sizeof(template) * nr_tasks);
	assert(tmpdirs);

	char tmpfile[PATH_MAX];
	int fd;

	for (i = 0; i < nr_tasks; i++) {
		strcpy(tmpdirs[i], template);
		char *tmpdir = tmpdirs[i];
		assert(mkdtemp(tmpdir) != NULL);
		sprintf(tmpfile, "%s/willitscale", tmpdir);
		fd = open(tmpfile, O_RDWR|O_CREAT, 0600);
		assert(fd >= 0);
		close(fd);
	}

	local_nr_tasks = nr_tasks;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1018, %rsp           # imm = 0x1018
movq %rdi, %r13
imulq $0x18, %rdi, %rdi
callq 0x21e0
movq %rax, 0xa5a4(%rip)      # 0xd1c8
testq %rax, %rax
je 0x2d01
leaq 0x6ca(%rip), %r14       # 0x32fe
leaq 0x10(%rsp), %r15
pushq $0x42
popq %rbp
xorl %ebx, %ebx
movq %r13, 0x8(%rsp)
subq $0x1, %r13
jb 0x2cad
movq 0xa578(%rip), %rax      # 0xd1c8
leaq (%rax,%rbx), %r12
movups 0x673(%rip), %xmm0      # 0x32ce
movups %xmm0, (%rax,%rbx)
movabsq $0x5858585858582e, %rcx # imm = 0x5858585858582E
movq %rcx, 0x10(%rax,%rbx)
movq %r12, %rdi
callq 0x2210
testq %rax, %rax
je 0x2ccb
movq %r15, %rdi
movq %r14, %rsi
movq %r12, %rdx
xorl %eax, %eax
callq 0x22a0
movq %r15, %rdi
movl %ebp, %esi
movl $0x180, %edx            # imm = 0x180
xorl %eax, %eax
callq 0x2240
testl %eax, %eax
js 0x2ce4
movl %eax, %edi
callq 0x2170
addq $0x18, %rbx
jmp 0x2c43
movq 0x8(%rsp), %rax
movq %rax, 0xa517(%rip)      # 0xd1d0
addq $0x1018, %rsp           # imm = 0x1018
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
leaq 0x614(%rip), %rdi       # 0x32e6
leaq 0x5c0(%rip), %rsi       # 0x3299
leaq 0x5c9(%rip), %rcx       # 0x32a9
pushq $0x1d
jmp 0x2cfb
leaq 0x622(%rip), %rdi       # 0x330d
leaq 0x5a7(%rip), %rsi       # 0x3299
leaq 0x5b0(%rip), %rcx       # 0x32a9
pushq $0x20
popq %rdx
callq 0x2140
leaq 0x589(%rip), %rdi       # 0x3291
leaq 0x58a(%rip), %rsi       # 0x3299
leaq 0x593(%rip), %rcx       # 0x32a9
pushq $0x15
jmp 0x2cfb
// File: /workspace/github_c_makefile_star2_O2/antonblanchard[P]will-it-scale/tests/unlink2.c
// Function: testcase
void testcase(unsigned long long *iterations, unsigned long nr)
{
	char tmpfile[PATH_MAX];

	sprintf(tmpfile, "%s/willitscale", tmpdirs[nr]);

	while (1) {
		int fd = open(tmpfile, O_RDWR|O_CREAT, 0600);
		assert(fd >= 0);
		close(fd);
		unlink(tmpfile);

		(*iterations)++;
	}
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
subq $0x1000, %rsp           # imm = 0x1000
movq %rdi, %rbx
imulq $0x18, %rsi, %rdx
addq 0xa495(%rip), %rdx      # 0xd1c8
leaq 0x5c4(%rip), %rsi       # 0x32fe
movq %rsp, %r14
movq %r14, %rdi
xorl %eax, %eax
callq 0x22a0
pushq $0x42
popq %rbp
movq %r14, %rdi
movl %ebp, %esi
movl $0x180, %edx            # imm = 0x180
xorl %eax, %eax
callq 0x2240
testl %eax, %eax
js 0x2d73
movl %eax, %edi
callq 0x2170
movq %r14, %rdi
callq 0x2080
incq (%rbx)
jmp 0x2d4a
leaq 0x593(%rip), %rdi       # 0x330d
leaq 0x518(%rip), %rsi       # 0x3299
leaq 0x58d(%rip), %rcx       # 0x3315
pushq $0x30
popq %rdx
callq 0x2140
// File: /workspace/github_c_makefile_star2_O2/antonblanchard[P]will-it-scale/tests/unlink2.c
// Function: testcase_cleanup
void testcase_cleanup(void)
{
	int i;
	char tmpfile[PATH_MAX];

	for (i = 0; i < local_nr_tasks; i++) {
		sprintf(tmpfile, "%s/willitscale", tmpdirs[i]);
		unlink(tmpfile);
		rmdir(tmpdirs[i]);
	}
	free(tmpdirs);
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x1008, %rsp           # imm = 0x1008
leaq 0x559(%rip), %rbx       # 0x32fe
movq %rsp, %r14
xorl %r15d, %r15d
xorl %r12d, %r12d
movq 0xa413(%rip), %rdx      # 0xd1c8
cmpq %r12, 0xa414(%rip)      # 0xd1d0
jbe 0x2dee
addq %r15, %rdx
movq %r14, %rdi
movq %rbx, %rsi
xorl %eax, %eax
callq 0x22a0
movq %r14, %rdi
callq 0x2080
movq 0xa3eb(%rip), %rdi      # 0xd1c8
addq %r15, %rdi
callq 0x20f0
incq %r12
addq $0x18, %r15
jmp 0x2dae
movq %rdx, %rdi
addq $0x1008, %rsp           # imm = 0x1008
popq %rbx
popq %r12
popq %r14
popq %r15
jmp 0x2050
// File: /workspace/github_c_makefile_star2_O2/pipde[P]deos-songlib/utils/rra/rrainfo.c
// Function: main
int
main(int argc,char **argv)
    {
    int argIndex = 1;

    int i;

    argIndex = processOptions(argc,argv);

    if (argIndex == argc)
        info("stdin",stdin);
    else
        {
        for (i = argIndex; i < argc; ++i)
            {
            FILE *fp = OpenFile(argv[i],"r");
            info(argv[i],OpenFile(argv[i],"r"));
            fclose(fp);
            }
        }

    return 0;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rsi, %rbx
movl %edi, %r14d
movslq %edi, %r13
cmpl $0x2, %r13d
pushq $0x1
popq %r12
cmovgel %edi, %r12d
pushq $0x1
popq %r15
cmpq %r13, %r15
jge 0x13e8
movq (%rbx,%r15,8), %rsi
cmpb $0x2d, (%rsi)
jne 0x13e5
movzbl 0x1(%rsi), %eax
cmpl $0x62, %eax
je 0x13be
cmpl $0x63, %eax
je 0x13b2
cmpl $0x72, %eax
je 0x13ca
cmpl $0x73, %eax
je 0x13d6
cmpl $0x76, %eax
je 0x145e
leaq 0x1cd3(%rip), %rdi      # 0x307c
xorl %eax, %eax
callq 0x153c
jmp 0x13e0
movl $0x1, 0x4dac(%rip)      # 0x6168
jmp 0x13e0
movl $0x1, 0x4d9c(%rip)      # 0x6164
jmp 0x13e0
movl $0x1, 0x4d8c(%rip)      # 0x6160
jmp 0x13e0
movl $0x1, 0x4d7c(%rip)      # 0x615c
incq %r15
jmp 0x1373
movl %r15d, %r12d
cmpl %r14d, %r12d
jne 0x1414
movq 0x4be4(%rip), %rax      # 0x5fd8
movq (%rax), %rsi
leaq 0x1c13(%rip), %rdi      # 0x3011
callq 0x1481
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %r13, -0x30(%rbp)
movl %r12d, %r13d
cmpq -0x30(%rbp), %r13
jge 0x1403
movq (%rbx,%r13,8), %rdi
leaq 0x20c0(%rip), %r14      # 0x34ec
movq %r14, %rsi
callq 0x166c
movq %rax, %r15
movq (%rbx,%r13,8), %r12
movq %r12, %rdi
movq %r14, %rsi
callq 0x166c
movq %r12, %rdi
movq %rax, %rsi
callq 0x1481
movq %r15, %rdi
callq 0x1090
incq %r13
jmp 0x141b
movq 0x4cd3(%rip), %rsi      # 0x6138
movq 0x4cd4(%rip), %rdx      # 0x6140
leaq 0x1bfa(%rip), %rdi      # 0x306d
xorl %eax, %eax
callq 0x10b0
xorl %edi, %edi
callq 0x1200
// File: /workspace/github_c_makefile_star2_O2/pipde[P]deos-songlib/utils/rra/rrainfo.c
// Function: info
static void
info(char *name,FILE *in)
    {
    RRA *h;

    h = newRRAHeader();
    readRRAHeader(in,h,0);

    printf("%s\n",name);
    if (channels)
        printf("    %d\n",h->channels);
    else if (sampleRate)
        printf("    %d\n",h->sampleRate);
    else if (samples)
        printf("    %d\n",h->samples);
    else if (bitsPerSample)
        printf("    %d\n",h->bitsPerSample);
    else
        {
        printf("    sampleRate: %d\n",h->sampleRate);
        printf("    bitsPerSample: %d\n",h->bitsPerSample);
        printf("    channels: %d\n",h->channels);
        printf("    samples: %d\n",h->samples);
        }
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %r15
callq 0x18c8
movq %rax, %rbx
movq %r14, %rdi
movq %rax, %rsi
xorl %edx, %edx
callq 0x1c2d
movq %r15, %rdi
callq 0x1070
cmpl $0x0, 0x4cb3(%rip)      # 0x6168
je 0x14bb
movl (%rbx), %esi
jmp 0x14e3
cmpl $0x0, 0x4c9e(%rip)      # 0x6160
je 0x14c9
movl 0x4(%rbx), %esi
jmp 0x14e3
cmpl $0x0, 0x4c8c(%rip)      # 0x615c
je 0x14d7
movl 0xc(%rbx), %esi
jmp 0x14e3
cmpl $0x0, 0x4c86(%rip)      # 0x6164
je 0x14fb
movl 0x8(%rbx), %esi
leaq 0x1b2d(%rip), %rdi      # 0x3017
xorl %eax, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
jmp 0x10b0
movl 0x4(%rbx), %esi
leaq 0x1b1a(%rip), %rdi      # 0x301f
xorl %eax, %eax
callq 0x10b0
movl 0x8(%rbx), %esi
leaq 0x1b1d(%rip), %rdi      # 0x3033
xorl %eax, %eax
callq 0x10b0
movl (%rbx), %esi
leaq 0x1b24(%rip), %rdi      # 0x304a
xorl %eax, %eax
callq 0x10b0
movl 0xc(%rbx), %esi
leaq 0x1b25(%rip), %rdi      # 0x305c
jmp 0x14ea
nopl (%rax)
// File: /workspace/github_c_makefile_star2_O2/micahstairs[P]ScrambleChecker/movedelta.cpp
// Function: mindelta(cubepos const&, cubepos const&)
int mindelta(const cubepos &cp, const cubepos &cp2 = identity_cube) {
   int s = 0 ;
   for (int i=0; i<12; i++)
      if (cp.e[i] != cp2.e[i])
         s++ ;
   int r = md_lookup[s] ;
   s = 0 ;
   for (int i=0; i<8; i++)
      if (cp.c[i] != cp2.c[i])
         s++ ;
   s = md_lookup[s] ;
   if (s > r)
      return s ;
   else
      return r ;
}

// Assembly:
xorl %eax, %eax
xorl %ecx, %ecx
cmpq $0xc, %rax
je 0x249d
movb 0x8(%rdi,%rax), %dl
xorl %r8d, %r8d
cmpb 0x8(%rsi,%rax), %dl
setne %r8b
addl %r8d, %ecx
incq %rax
jmp 0x2480
movl %ecx, %eax
leaq 0x5c9a(%rip), %rcx      # 0x8140
movl (%rcx,%rax,4), %eax
xorl %edx, %edx
xorl %r8d, %r8d
cmpq $0x8, %rdx
je 0x24cb
movb (%rdi,%rdx), %r9b
xorl %r10d, %r10d
cmpb (%rsi,%rdx), %r9b
setne %r10b
addl %r10d, %r8d
incq %rdx
jmp 0x24ae
movl %r8d, %edx
movl (%rcx,%rdx,4), %ecx
cmpl %eax, %ecx
cmovgl %ecx, %eax
retq
// File: /workspace/github_c_makefile_star2_O2/micahstairs[P]ScrambleChecker/movedelta.cpp
// Function: parsemoveseq(char const*)
moveseq parsemoveseq(const char *s) {
  moveseq r ;
  const char *faces = "UuFfRrDdBbLlIiJjKk" ;
  while (*s) {
    while (*s && *s <= ' ')
       s++ ;
    if (*s == 0 || *s == '/')
       break ;
    const char *fp = strchr(faces, *s) ;
    if (fp == 0) {
       cerr << "Illegal face in " << *s << endl ;
       exit(10) ;
    }
    int f = (fp - faces) / 2 ;
    if (f * TWISTS > NMOVES)
       error("! bad face for this metric") ;
    s++ ;
    switch (*s) {
case '-':
case '3':
case '\'':
       r.push_back(f*TWISTS+2) ;
       s++ ;
       break ;
case '2':
       r.push_back(f*TWISTS+1) ;
       s++ ;
       break ;
case '+':
case '1':
       s++ ;
default:
       r.push_back(f*TWISTS) ;
       break ;
    }
  }
  return r ;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rsi, %r14
movq %rdi, %rbx
xorps %xmm0, %xmm0
movups %xmm0, (%rdi)
andq $0x0, 0x10(%rdi)
leaq 0x2b53(%rip), %r15      # 0x5050
pushq $0x13
popq %r12
pushq $0x2
popq %r13
movb (%r14), %al
testb %al, %al
je 0x25e2
incq %r14
testb %al, %al
je 0x2520
cmpb $0x20, %al
jg 0x2520
movb (%r14), %al
jmp 0x2510
testb %al, %al
je 0x25e2
movzbl %al, %esi
cmpl $0x2f, %esi
je 0x25e2
movq %r15, %rdi
movq %r12, %rdx
callq 0x2170
testq %rax, %rax
je 0x25f4
subq %r15, %rax
cqto
idivq %r13
movq %rax, %rbp
cmpl $0x7, %ebp
jl 0x2564
leaq 0x2b15(%rip), %rdi      # 0x5074
callq 0x48e6
leal (%rbp,%rbp,2), %eax
movzbl (%r14), %ecx
cmpq $0x33, %rcx
ja 0x2595
movabsq $0x8208000000000, %rdx  # imm = 0x8208000000000
btq %rcx, %rdx
jb 0x25ab
movabsq $0x2080000000000, %rdx  # imm = 0x2080000000000
btq %rcx, %rdx
jae 0x25c1
incq %r14
movl %eax, 0xc(%rsp)
movq %rbx, %rdi
leaq 0xc(%rsp), %rsi
callq 0x2fb0
jmp 0x2505
addl $0x2, %eax
movl %eax, 0x14(%rsp)
movq %rbx, %rdi
leaq 0x14(%rsp), %rsi
callq 0x2fb0
jmp 0x25da
cmpq $0x32, %rcx
jne 0x2595
incl %eax
movl %eax, 0x10(%rsp)
movq %rbx, %rdi
leaq 0x10(%rsp), %rsi
callq 0x2fb0
incq %r14
jmp 0x2505
movq %rbx, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq 0x59ed(%rip), %rdi      # 0x7fe8
leaq 0x2a61(%rip), %rsi      # 0x5063
callq 0x2120
movsbl -0x1(%r14), %esi
movq %rax, %rdi
callq 0x2180
movq %rax, %rdi
callq 0x2080
pushq $0xa
popq %rdi
callq 0x21a0
jmp 0x262c
jmp 0x262c
jmp 0x262c
jmp 0x262c
movq %rax, %r14
movq %rbx, %rdi
callq 0x2f7c
movq %r14, %rdi
callq 0x2250
// File: /workspace/github_c_makefile_star2_O2/micahstairs[P]ScrambleChecker/movedelta.cpp
// Function: parseposition(cubepos&, char const*)
void parseposition(cubepos &cp, const char *s) {
  cp = identity_cube ;
  if (cp.parse_Singmaster(s) == 0) {
    cubepos cp2 ;
    cp.invert_into(cp2) ;
    cp = cp2 ;
    return ;
  }
  cp = identity_cube ;
  moveseq r = parsemoveseq(s) ;
  for (int i=0; i<r.size(); i++)
    cp.movepc(r[i]) ;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x5fe0(%rip), %r15      # 0x8635
movl 0x10(%r15), %eax
movl %eax, 0x10(%rdi)
movups (%r15), %xmm0
movups %xmm0, (%rdi)
callq 0x3782
testq %rax, %rax
je 0x26b9
movl 0x10(%r15), %eax
movl %eax, 0x10(%rbx)
movups (%r15), %xmm0
movups %xmm0, (%rbx)
movq %rsp, %rdi
movq %r14, %rsi
callq 0x24d7
xorl %r14d, %r14d
movq (%rsp), %rax
movq 0x8(%rsp), %rcx
subq %rax, %rcx
sarq $0x2, %rcx
cmpq %r14, %rcx
jbe 0x26af
movl (%rax,%r14,4), %esi
movq %rbx, %rdi
callq 0x426a
incq %r14
jmp 0x2689
movq %rsp, %rdi
callq 0x2f7c
jmp 0x26e5
movl 0x10(%r15), %eax
movq %rsp, %r14
movl %eax, 0x10(%r14)
movups (%r15), %xmm0
movaps %xmm0, (%r14)
movq %rbx, %rdi
movq %r14, %rsi
callq 0x3734
movl 0x10(%r14), %eax
movl %eax, 0x10(%rbx)
movaps (%r14), %xmm0
movups %xmm0, (%rbx)
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %rbx
movq %rsp, %rdi
callq 0x2f7c
movq %rbx, %rdi
callq 0x2250