// File: /workspace/github_cpp_makefile_star2_O3/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 0x1024e(%rip), %rsi     # 0x1c23a
movq %r14, %rdi
callq 0x40e0
testl %eax, %eax
je 0xc0f1
leaq 0x1b32d(%rip), %r12     # 0x27330
movl (%r12), %eax
shrl $0x1f, %eax
movq 0x8(%r12,%rax,8), %r15
leaq 0x10a52(%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 0x10647(%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 0x10a23(%rip), %rsi     # 0x1ca9c
movq %rsp, %rdi
movq %r14, %rdx
callq 0x5ea5
testb %bpl, %bpl
je 0xc3a4
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xc0a8
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x42d0
movq (%rbx), %rdi
leaq 0x20(%rsp), %rsi
callq 0x7022
leaq 0x20(%rsp), %rdi
callq 0x4440
movq 0x1af02(%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 0x1013b(%rip), %rsi     # 0x1c23a
movq %r14, %rdi
callq 0x40e0
testl %eax, %eax
je 0xc204
leaq 0x1b21a(%rip), %r12     # 0x27330
movl (%r12), %eax
shrl $0x1f, %eax
movq 0x8(%r12,%rax,8), %r15
leaq 0x109ab(%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 0x10534(%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 0x10910(%rip), %rsi     # 0x1ca9c
movq %rsp, %rdi
movq %r14, %rdx
callq 0x5ea5
testb %bpl, %bpl
je 0xc3df
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xc1bb
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x42d0
movq (%rbx), %rdi
leaq 0x20(%rsp), %rsi
callq 0x75dc
leaq 0x20(%rsp), %rdi
callq 0x4440
movq 0x1adef(%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 0x10028(%rip), %rsi     # 0x1c23a
movq %r14, %rdi
callq 0x40e0
testl %eax, %eax
je 0xc394
leaq 0x1b107(%rip), %r12     # 0x27330
movl (%r12), %eax
shrl $0x1f, %eax
movq 0x8(%r12,%rax,8), %r15
leaq 0x108ce(%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 0x10421(%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 0x1089b(%rip), %rsi     # 0x1cb3a
movq %rsp, %rdi
movq %r14, %rdx
callq 0x5ea5
testb %bpl, %bpl
je 0xc41a
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xc2ce
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 0xc358
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 0xc300
leaq 0x20(%rsp), %rdi
callq 0x4440
movq 0x1ac5f(%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 0xfdc1(%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 0xc453
movl (%r12), %eax
shrl $0x1f, %eax
movq 0x8(%r12,%rax,8), %rbx
leaq 0xfd86(%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 0xc453
movl (%r12), %eax
shrl $0x1f, %eax
movq 0x8(%r12,%rax,8), %rbx
leaq 0xfd4b(%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 0xc461
jmp 0xc461
movq %rax, %rbx
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0xc490
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x42d0
jmp 0xc490
jmp 0xc48d
jmp 0xc48d
jmp 0xc48d
jmp 0xc48d
jmp 0xc48d
jmp 0xc48d
movq %rax, %rbx
leaq 0x20(%rsp), %rdi
callq 0x4480
movq %rbx, %rdi
callq 0x4580