// File: /workspace/github_cpp_makefile_star2_O1/hanhwi[P]SimPoint/analysiscode/Simpoint.cpp
// Function: Simpoint::savePreClusteringData()
void Simpoint::savePreClusteringData() {
    if (options.saveVectorsTxtFmtName != "") {
        Logger::log() << "  Saving Simpoint-format vector data to text file '" 
            << options.saveVectorsTxtFmtName << "'\n";
        ofstream output(options.saveVectorsTxtFmtName.c_str());
        Utilities::check(output.is_open(), "Simpoint::savePreClusteringData(): could not open file " +
                                options.saveVectorsTxtFmtName);
        wholeDataset->write(output);
        output.close();
    }

    if (options.saveVectorsBinFmtName != "") {
        Logger::log() << "  Saving Simpoint-format vector data to binary file '" 
            << options.saveVectorsBinFmtName << "'\n";
        ofstream output(options.saveVectorsBinFmtName.c_str());
        Utilities::check(output.is_open(), "Simpoint::savePreClusteringData(): could not open file " +
                                options.saveVectorsBinFmtName);
        wholeDataset->writeBinary(output);
        output.close();
    }

    if (options.saveVectorWeightsName != "") {
        Logger::log() << "  Saving weights of each input vector to file '" 
            << options.saveVectorWeightsName << "'\n";

        ofstream output(options.saveVectorWeightsName.c_str());
        Utilities::check(output.is_open(), "Simpoint::saveVectorWeights(): could not open file " +
                                options.saveVectorWeightsName);
        output.precision(20);
        for (unsigned int i = 0; i < wholeDataset->numRows(); i++) {
            output << wholeDataset->getWeight(i) << endl;
        }
        output.close();
    }
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x220, %rsp            # imm = 0x220
movq %rdi, %rbx
leaq 0x1e0(%rdi), %r14
leaq 0x10288(%rip), %rsi     # 0x1c23a
movq %r14, %rdi
callq 0x40e0
testl %eax, %eax
je 0xc0b7
leaq 0x1b367(%rip), %r12     # 0x27330
movl (%r12), %eax
shrl $0x1f, %eax
movq 0x8(%r12,%rax,8), %r15
leaq 0x10a8c(%rip), %rsi     # 0x1ca68
movl $0x33, %edx
movq %r15, %rdi
callq 0x4330
movq 0x1e0(%rbx), %rsi
movq 0x1e8(%rbx), %rdx
movq %r15, %rdi
callq 0x4330
leaq 0x10681(%rip), %rsi     # 0x1c687
movl $0x2, %edx
movq %rax, %rdi
callq 0x4330
movq 0x1e0(%rbx), %rsi
leaq 0x20(%rsp), %rdi
movl $0x10, %edx
callq 0x4310
leaq 0x90(%rsp), %rdi
callq 0x40b0
movl %eax, %ebp
leaq 0x10a5d(%rip), %rsi     # 0x1ca9c
movq %rsp, %rdi
movq %r14, %rdx
callq 0x5ed9
testb %bpl, %bpl
je 0xc36a
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xc06e
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x42d0
movq (%rbx), %rdi
leaq 0x20(%rsp), %rsi
callq 0x703e
leaq 0x20(%rsp), %rdi
callq 0x4440
movq 0x1af3c(%rip), %rax     # 0x26fc8
movq (%rax), %rcx
movq 0x18(%rax), %rax
leaq 0x28(%rsp), %rdi
movq %rcx, -0x8(%rdi)
movq -0x18(%rcx), %rcx
movq %rax, 0x20(%rsp,%rcx)
callq 0x4240
leaq 0x118(%rsp), %rdi
callq 0x4120
leaq 0x200(%rbx), %r14
leaq 0x10175(%rip), %rsi     # 0x1c23a
movq %r14, %rdi
callq 0x40e0
testl %eax, %eax
je 0xc1ca
leaq 0x1b254(%rip), %r12     # 0x27330
movl (%r12), %eax
shrl $0x1f, %eax
movq 0x8(%r12,%rax,8), %r15
leaq 0x109e5(%rip), %rsi     # 0x1cad4
movl $0x35, %edx
movq %r15, %rdi
callq 0x4330
movq 0x200(%rbx), %rsi
movq 0x208(%rbx), %rdx
movq %r15, %rdi
callq 0x4330
leaq 0x1056e(%rip), %rsi     # 0x1c687
movl $0x2, %edx
movq %rax, %rdi
callq 0x4330
movq 0x200(%rbx), %rsi
leaq 0x20(%rsp), %rdi
movl $0x10, %edx
callq 0x4310
leaq 0x90(%rsp), %rdi
callq 0x40b0
movl %eax, %ebp
leaq 0x1094a(%rip), %rsi     # 0x1ca9c
movq %rsp, %rdi
movq %r14, %rdx
callq 0x5ed9
testb %bpl, %bpl
je 0xc3a5
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xc181
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x42d0
movq (%rbx), %rdi
leaq 0x20(%rsp), %rsi
callq 0x75f8
leaq 0x20(%rsp), %rdi
callq 0x4440
movq 0x1ae29(%rip), %rax     # 0x26fc8
movq (%rax), %rcx
movq 0x18(%rax), %rax
leaq 0x28(%rsp), %rdi
movq %rcx, -0x8(%rdi)
movq -0x18(%rcx), %rcx
movq %rax, 0x20(%rsp,%rcx)
callq 0x4240
leaq 0x118(%rsp), %rdi
callq 0x4120
leaq 0x160(%rbx), %r14
leaq 0x10062(%rip), %rsi     # 0x1c23a
movq %r14, %rdi
callq 0x40e0
testl %eax, %eax
je 0xc35a
leaq 0x1b141(%rip), %r12     # 0x27330
movl (%r12), %eax
shrl $0x1f, %eax
movq 0x8(%r12,%rax,8), %r15
leaq 0x10908(%rip), %rsi     # 0x1cb0a
movl $0x2f, %edx
movq %r15, %rdi
callq 0x4330
movq 0x160(%rbx), %rsi
movq 0x168(%rbx), %rdx
movq %r15, %rdi
callq 0x4330
leaq 0x1045b(%rip), %rsi     # 0x1c687
movl $0x2, %edx
movq %rax, %rdi
callq 0x4330
movq 0x160(%rbx), %rsi
leaq 0x20(%rsp), %rdi
movl $0x10, %edx
callq 0x4310
leaq 0x90(%rsp), %rdi
callq 0x40b0
movl %eax, %ebp
leaq 0x108d5(%rip), %rsi     # 0x1cb3a
movq %rsp, %rdi
movq %r14, %rdx
callq 0x5ed9
testb %bpl, %bpl
je 0xc3e0
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xc294
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x42d0
movq 0x20(%rsp), %rax
movq -0x18(%rax), %rax
movq $0x14, 0x28(%rsp,%rax)
movq (%rbx), %rax
movq 0x8(%rax), %rcx
subq (%rax), %rcx
shrq $0x3, %rcx
imull $0xaaaaaaab, %ecx, %ecx # imm = 0xAAAAAAAB
testl %ecx, %ecx
je 0xc31e
xorl %r12d, %r12d
leaq 0x20(%rsp), %r14
movq 0x18(%rax), %rax
movsd (%rax,%r12,8), %xmm0
movq %r14, %rdi
callq 0x4510
movq %rax, %r15
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %r15, %rdi
movl $0xa, %esi
callq 0x4290
movsbl %al, %esi
movq %r15, %rdi
callq 0x4030
movq %rax, %rdi
callq 0x41d0
movq (%rbx), %rax
movq 0x8(%rax), %rcx
subq (%rax), %rcx
incq %r12
shrq $0x3, %rcx
imull $0xaaaaaaab, %ecx, %ecx # imm = 0xAAAAAAAB
cmpq %rcx, %r12
jb 0xc2c6
leaq 0x20(%rsp), %rdi
callq 0x4440
movq 0x1ac99(%rip), %rax     # 0x26fc8
movq (%rax), %rcx
movq 0x18(%rax), %rax
leaq 0x28(%rsp), %rdi
movq %rcx, -0x8(%rdi)
movq -0x18(%rcx), %rcx
movq %rax, 0x20(%rsp,%rcx)
callq 0x4240
leaq 0x118(%rsp), %rdi
callq 0x4120
addq $0x220, %rsp            # imm = 0x220
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
movl (%r12), %eax
shrl $0x1f, %eax
movq 0x8(%r12,%rax,8), %rbx
leaq 0xfdfb(%rip), %rsi      # 0x1c178
movl $0x8, %edx
movq %rbx, %rdi
callq 0x4330
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
movq %rbx, %rdi
callq 0x4330
movq %rax, %rdi
callq 0x4160
jmp 0xc419
movl (%r12), %eax
shrl $0x1f, %eax
movq 0x8(%r12,%rax,8), %rbx
leaq 0xfdc0(%rip), %rsi      # 0x1c178
movl $0x8, %edx
movq %rbx, %rdi
callq 0x4330
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
movq %rbx, %rdi
callq 0x4330
movq %rax, %rdi
callq 0x4160
jmp 0xc419
movl (%r12), %eax
shrl $0x1f, %eax
movq 0x8(%r12,%rax,8), %rbx
leaq 0xfd85(%rip), %rsi      # 0x1c178
movl $0x8, %edx
movq %rbx, %rdi
callq 0x4330
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
movq %rbx, %rdi
callq 0x4330
movq %rax, %rdi
callq 0x4160
movl $0x1, %edi
callq 0x4370
jmp 0xc427
jmp 0xc427
movq %rax, %rbx
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xc456
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x42d0
jmp 0xc456
jmp 0xc453
jmp 0xc453
jmp 0xc453
jmp 0xc453
jmp 0xc453
jmp 0xc453
movq %rax, %rbx
leaq 0x20(%rsp), %rdi
callq 0x4480
movq %rbx, %rdi
callq 0x4580