// File: JenTus[P]TCEM/src_TCEM/allocator.cc
// Function: Cide::allocator::readCompareNodes()
void allocator::readCompareNodes() {

        //string probGraphFile = opt->getValue("probGraphFile");
        ifstream myfile (compareFile, ios::in);

        //double *itemProbs; //item-specific influence probabilities

        if (myfile.is_open()) {
            string line1;
            string line2;
            getline(myfile, line1);
            getline(myfile, line2);

            vector<string> nodeids1;
            vector<string> nodeids2;

            split1(line1, nodeids1);
            split1(line2, nodeids2);

            if(nodeids1.size() > nodeids2.size()){
                for (int i = 2; i < nodeids1.size(); ++i) {
                    unsigned int tt = strToInt(nodeids1[i]);
                    compareblue.push_back(tt);
                }
                for (int i = 2; i < nodeids2.size(); ++i) {
                    unsigned int tt = strToInt(nodeids2[i]);
                    comparered.push_back(tt);
                }
            }
            else{
                for (int i = 2; i < nodeids1.size(); ++i) {
                    unsigned int tt = strToInt(nodeids1[i]);
                    comparered.push_back(tt);
                }
                for (int i = 2; i < nodeids2.size(); ++i) {
                    unsigned int tt = strToInt(nodeids2[i]);
                    compareblue.push_back(tt);
                }
            }

            myfile.close();
        }

        k_r = comparered.size();
        k_b = compareblue.size();
        cout << "total number of red nodes " << k_r << endl;
        cout << "total number of blue nodes " << k_b << endl;
    }

// Assembly:
subq $0x3d8, %rsp            # imm = 0x3D8
movq %rdi, 0x3d0(%rsp)
movq 0x3d0(%rsp), %rax
movq %rax, 0x78(%rsp)
movq 0x40(%rax), %rsi
leaq 0x1c8(%rsp), %rdi
movq %rdi, 0x80(%rsp)
movl $0x8, %edx
callq 0x46b0
movq 0x80(%rsp), %rdi
callq 0x45c0
movb %al, 0x8b(%rsp)
jmp 0x5f90
movb 0x8b(%rsp), %al
testb $0x1, %al
jne 0x5fa0
jmp 0x64ed
leaq 0x198(%rsp), %rdi
movq %rdi, 0x70(%rsp)
callq 0x4500
leaq 0x178(%rsp), %rdi
callq 0x4500
movq 0x70(%rsp), %rsi
leaq 0x1c8(%rsp), %rdi
callq 0x40a0
jmp 0x5fd3
leaq 0x1c8(%rsp), %rdi
leaq 0x178(%rsp), %rsi
callq 0x40a0
jmp 0x5fea
leaq 0x160(%rsp), %rdi
movq %rdi, 0x68(%rsp)
callq 0xf0c0
leaq 0x148(%rsp), %rdi
callq 0xf0c0
movq 0x68(%rsp), %rsi
leaq 0x198(%rsp), %rdi
callq 0xf0d0
jmp 0x601d
leaq 0x178(%rsp), %rdi
leaq 0x148(%rsp), %rsi
callq 0xf0d0
jmp 0x6034
leaq 0x160(%rsp), %rdi
callq 0xf3b0
movq %rax, 0x60(%rsp)
leaq 0x148(%rsp), %rdi
callq 0xf3b0
movq %rax, %rcx
movq 0x60(%rsp), %rax
cmpq %rcx, %rax
jbe 0x6292
movl $0x2, 0x144(%rsp)
movslq 0x144(%rsp), %rax
movq %rax, 0x58(%rsp)
leaq 0x160(%rsp), %rdi
callq 0xf3b0
movq %rax, %rcx
movq 0x58(%rsp), %rax
cmpq %rcx, %rax
jae 0x619e
movslq 0x144(%rsp), %rsi
leaq 0x160(%rsp), %rdi
callq 0xf330
movq %rax, %rsi
leaq 0x120(%rsp), %rdi
callq 0x4140
jmp 0x60c1
leaq 0x120(%rsp), %rdi
callq 0xf1f0
movl %eax, 0x54(%rsp)
jmp 0x60d4
leaq 0x120(%rsp), %rdi
callq 0x41f0
movl 0x54(%rsp), %eax
movq 0x78(%rsp), %rdi
movl %eax, 0x140(%rsp)
addq $0x108, %rdi            # imm = 0x108
movl 0x140(%rsp), %eax
movl %eax, 0x11c(%rsp)
leaq 0x11c(%rsp), %rsi
callq 0xef60
jmp 0x6115
jmp 0x6117
movl 0x144(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x144(%rsp)
jmp 0x606f
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x1c0(%rsp)
movl %eax, 0x1bc(%rsp)
jmp 0x65bc
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x1c0(%rsp)
movl %eax, 0x1bc(%rsp)
jmp 0x64ce
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x1c0(%rsp)
movl %eax, 0x1bc(%rsp)
jmp 0x64b4
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x1c0(%rsp)
movl %eax, 0x1bc(%rsp)
leaq 0x120(%rsp), %rdi
callq 0x41f0
jmp 0x64b4
movl $0x2, 0x118(%rsp)
movslq 0x118(%rsp), %rax
movq %rax, 0x48(%rsp)
leaq 0x148(%rsp), %rdi
callq 0xf3b0
movq %rax, %rcx
movq 0x48(%rsp), %rax
cmpq %rcx, %rax
jae 0x628d
movslq 0x118(%rsp), %rsi
leaq 0x148(%rsp), %rdi
callq 0xf330
movq %rax, %rsi
leaq 0xf0(%rsp), %rdi
callq 0x4140
jmp 0x61fb
leaq 0xf0(%rsp), %rdi
callq 0xf1f0
movl %eax, 0x44(%rsp)
jmp 0x620e
leaq 0xf0(%rsp), %rdi
callq 0x41f0
movl 0x44(%rsp), %eax
movq 0x78(%rsp), %rdi
movl %eax, 0x114(%rsp)
addq $0xf0, %rdi
movl 0x114(%rsp), %eax
movl %eax, 0xec(%rsp)
leaq 0xec(%rsp), %rsi
callq 0xef60
jmp 0x624f
jmp 0x6251
movl 0x118(%rsp), %eax
addl $0x1, %eax
movl %eax, 0x118(%rsp)
jmp 0x61a9
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x1c0(%rsp)
movl %eax, 0x1bc(%rsp)
leaq 0xf0(%rsp), %rdi
callq 0x41f0
jmp 0x64b4
jmp 0x646f
movl $0x2, 0xe8(%rsp)
movslq 0xe8(%rsp), %rax
movq %rax, 0x38(%rsp)
leaq 0x160(%rsp), %rdi
callq 0xf3b0
movq %rax, %rcx
movq 0x38(%rsp), %rax
cmpq %rcx, %rax
jae 0x6381
movslq 0xe8(%rsp), %rsi
leaq 0x160(%rsp), %rdi
callq 0xf330
movq %rax, %rsi
leaq 0xc0(%rsp), %rdi
callq 0x4140
jmp 0x62ef
leaq 0xc0(%rsp), %rdi
callq 0xf1f0
movl %eax, 0x34(%rsp)
jmp 0x6302
leaq 0xc0(%rsp), %rdi
callq 0x41f0
movl 0x34(%rsp), %eax
movq 0x78(%rsp), %rdi
movl %eax, 0xe4(%rsp)
addq $0xf0, %rdi
movl 0xe4(%rsp), %eax
movl %eax, 0xbc(%rsp)
leaq 0xbc(%rsp), %rsi
callq 0xef60
jmp 0x6343
jmp 0x6345
movl 0xe8(%rsp), %eax
addl $0x1, %eax
movl %eax, 0xe8(%rsp)
jmp 0x629d
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x1c0(%rsp)
movl %eax, 0x1bc(%rsp)
leaq 0xc0(%rsp), %rdi
callq 0x41f0
jmp 0x64b4
movl $0x2, 0xb8(%rsp)
movslq 0xb8(%rsp), %rax
movq %rax, 0x28(%rsp)
leaq 0x148(%rsp), %rdi
callq 0xf3b0
movq %rax, %rcx
movq 0x28(%rsp), %rax
cmpq %rcx, %rax
jae 0x646d
movslq 0xb8(%rsp), %rsi
leaq 0x148(%rsp), %rdi
callq 0xf330
movq %rax, %rsi
leaq 0x90(%rsp), %rdi
callq 0x4140
jmp 0x63de
leaq 0x90(%rsp), %rdi
callq 0xf1f0
movl %eax, 0x24(%rsp)
jmp 0x63f1
leaq 0x90(%rsp), %rdi
callq 0x41f0
movl 0x24(%rsp), %eax
movq 0x78(%rsp), %rdi
movl %eax, 0xb4(%rsp)
addq $0x108, %rdi            # imm = 0x108
movl 0xb4(%rsp), %eax
movl %eax, 0x8c(%rsp)
leaq 0x8c(%rsp), %rsi
callq 0xef60
jmp 0x6432
jmp 0x6434
movl 0xb8(%rsp), %eax
addl $0x1, %eax
movl %eax, 0xb8(%rsp)
jmp 0x638c
movq %rax, %rcx
movl %edx, %eax
movq %rcx, 0x1c0(%rsp)
movl %eax, 0x1bc(%rsp)
leaq 0x90(%rsp), %rdi
callq 0x41f0
jmp 0x64b4
jmp 0x646f
leaq 0x1c8(%rsp), %rdi
callq 0x40b0
jmp 0x647e
leaq 0x148(%rsp), %rdi
callq 0xf350
leaq 0x160(%rsp), %rdi
callq 0xf350
leaq 0x178(%rsp), %rdi
callq 0x41f0
leaq 0x198(%rsp), %rdi
callq 0x41f0
jmp 0x64ed
leaq 0x148(%rsp), %rdi
callq 0xf350
leaq 0x160(%rsp), %rdi
callq 0xf350
leaq 0x178(%rsp), %rdi
callq 0x41f0
leaq 0x198(%rsp), %rdi
callq 0x41f0
jmp 0x65bc
movq 0x78(%rsp), %rdi
addq $0xf0, %rdi
callq 0xe130
movq 0x78(%rsp), %rdi
movl %eax, 0x78(%rdi)
addq $0x108, %rdi            # imm = 0x108
callq 0xe130
movq %rax, %rcx
movq 0x78(%rsp), %rax
movl %ecx, 0x7c(%rax)
movq 0x28ab4(%rip), %rdi     # 0x2efd8
leaq 0x1de60(%rip), %rsi     # 0x2438b
callq 0x4370
movq %rax, 0x18(%rsp)
jmp 0x6537
movq 0x18(%rsp), %rdi
movq 0x78(%rsp), %rax
movl 0x78(%rax), %esi
callq 0x4650
movq %rax, 0x10(%rsp)
jmp 0x6550
movq 0x10(%rsp), %rdi
movq 0x28a6c(%rip), %rsi     # 0x2efc8
callq 0x43c0
jmp 0x6563
movq 0x28a6e(%rip), %rdi     # 0x2efd8
leaq 0x1de35(%rip), %rsi     # 0x243a6
callq 0x4370
movq %rax, 0x8(%rsp)
jmp 0x657d
movq 0x8(%rsp), %rdi
movq 0x78(%rsp), %rax
movl 0x7c(%rax), %esi
callq 0x4650
movq %rax, (%rsp)
jmp 0x6595
movq (%rsp), %rdi
movq 0x28a28(%rip), %rsi     # 0x2efc8
callq 0x43c0
jmp 0x65a7
leaq 0x1c8(%rsp), %rdi
callq 0x40d0
addq $0x3d8, %rsp            # imm = 0x3D8
retq
leaq 0x1c8(%rsp), %rdi
callq 0x40d0
movq 0x1c0(%rsp), %rdi
callq 0x4680
nopw %cs:(%rax,%rax)