LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: romkatv[P]action-chain/src/action_chain.cc
// Function: romkatv::ActionChain::Work::RunAllSlow(romkatv::ActionChain::Work*, romkatv::ActionChain::Work*)
void ActionChain::Work::RunAllSlow(Work* w, Work* next) {
  do {
    do {
      assert(w != nullptr && w != Sealed());
      assert(next != nullptr && next != Sealed());
      w->Destroy();
      ::operator delete(w, kAllocSize);
      w = next;
      w->invoke_(w);
      next = w->next_.load(std::memory_order_acquire);
    } while (next);
    next = w->next_.exchange(Sealed(), std::memory_order_acq_rel);
  } while (next);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
jmp 0xc272
xorl %eax, %eax
cmpq $0x0, -0x8(%rbp)
movb %al, -0x11(%rbp)
je 0xc29b
movq -0x8(%rbp), %rax
movq %rax, -0x20(%rbp)
callq 0xa9d0
movq %rax, %rcx
movq -0x20(%rbp), %rax
cmpq %rcx, %rax
setne %al
movb %al, -0x11(%rbp)
movb -0x11(%rbp), %al
testb $0x1, %al
jne 0xc2a4
jmp 0xc2a6
jmp 0xc2c5
leaq 0x1129(%rip), %rdi      # 0xd3d6
leaq 0x15bc(%rip), %rsi      # 0xd870
movl $0xa, %edx
leaq 0x15c4(%rip), %rcx      # 0xd884
callq 0x3170
xorl %eax, %eax
cmpq $0x0, -0x10(%rbp)
movb %al, -0x21(%rbp)
je 0xc2ee
movq -0x10(%rbp), %rax
movq %rax, -0x30(%rbp)
callq 0xa9d0
movq %rax, %rcx
movq -0x30(%rbp), %rax
cmpq %rcx, %rax
setne %al
movb %al, -0x21(%rbp)
movb -0x21(%rbp), %al
testb $0x1, %al
jne 0xc2f7
jmp 0xc2f9
jmp 0xc318
leaq 0x1282(%rip), %rdi      # 0xd582
leaq 0x1569(%rip), %rsi      # 0xd870
movl $0xb, %edx
leaq 0x1571(%rip), %rcx      # 0xd884
callq 0x3170
movq -0x8(%rbp), %rdi
callq 0xae20
movq -0x8(%rbp), %rdi
movl $0x20, %esi
callq 0x3260
movq -0x10(%rbp), %rax
movq %rax, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq 0x8(%rax), %rax
movq -0x8(%rbp), %rdi
callq *%rax
movq -0x8(%rbp), %rdi
movl $0x2, %esi
callq 0xa8a0
movq %rax, -0x10(%rbp)
cmpq $0x0, -0x10(%rbp)
jne 0xc272
movq -0x8(%rbp), %rax
movq %rax, -0x38(%rbp)
callq 0xa9d0
movq -0x38(%rbp), %rdi
movq %rax, %rsi
movl $0x4, %edx
callq 0xaa10
movq %rax, -0x10(%rbp)
cmpq $0x0, -0x10(%rbp)
jne 0xc270
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: iZhangHui[P]CppPrimer/CH06_Functions/examples/mainret.cc
// Function: main
int main()
{
    bool some_failure = false;
    if (some_failure)
        return EXIT_FAILURE;  // defined in cstdlib
    else
        return EXIT_SUCCESS;  // defined in cstdlib
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movl $0x0, -0x4(%rbp)
movb $0x0, -0x5(%rbp)
testb $0x1, -0x5(%rbp)
je 0x114e
movl $0x1, -0x4(%rbp)
jmp 0x1155
movl $0x0, -0x4(%rbp)
movl -0x4(%rbp), %eax
popq %rbp
retq
// File: dianejdan[P]Eclat/./DbReader.hpp
// Function: DbReader::template_type(char*)
int template_type(char* filename){

        ifstream in_(filename); // open input file
        char buffer[4096]; // store each line/transaction
        string line;

        int typ = 3;
        // parse the input file, add item and tid into the tid list
        in_.getline(buffer, 4096);
        line = buffer;
        size_t pos1 = line.find_first_not_of(" ");
        if (buffer[pos1+1] == ' '){
            if (buffer[pos1] == '0' || buffer[pos1] == '1' || buffer[pos1] == '2' ||
                buffer[pos1] == '3' || buffer[pos1] == '4' || buffer[pos1] == '5' ||
                buffer[pos1] == '6' || buffer[pos1] == '7' || buffer[pos1] == '8' ||
                buffer[pos1] == '9')
                typ = 1;
            else
                typ = 2;
        }

        in_.close();
        return typ;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x1270, %rsp           # imm = 0x1270
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x10(%rbp), %rsi
leaq -0x218(%rbp), %rdi
movq %rdi, -0x1268(%rbp)
movl $0x8, %edx
callq 0x23c0
leaq -0x1240(%rbp), %rdi
callq 0x2320
movq -0x1268(%rbp), %rdi
movl $0x3, -0x1244(%rbp)
leaq -0x1220(%rbp), %rsi
movl $0x1000, %edx           # imm = 0x1000
callq 0x20b0
jmp 0x286f
leaq -0x1240(%rbp), %rdi
leaq -0x1220(%rbp), %rsi
callq 0x2310
jmp 0x2884
leaq -0x1240(%rbp), %rdi
leaq 0xe89b(%rip), %rsi      # 0x1112d
xorl %eax, %eax
movl %eax, %edx
callq 0x2130
movq %rax, -0x1260(%rbp)
movq -0x1260(%rbp), %rax
movsbl -0x121f(%rbp,%rax), %eax
cmpl $0x20, %eax
jne 0x29d2
movq -0x1260(%rbp), %rax
movsbl -0x1220(%rbp,%rax), %eax
cmpl $0x30, %eax
je 0x298e
movq -0x1260(%rbp), %rax
movsbl -0x1220(%rbp,%rax), %eax
cmpl $0x31, %eax
je 0x298e
movq -0x1260(%rbp), %rax
movsbl -0x1220(%rbp,%rax), %eax
cmpl $0x32, %eax
je 0x298e
movq -0x1260(%rbp), %rax
movsbl -0x1220(%rbp,%rax), %eax
cmpl $0x33, %eax
je 0x298e
movq -0x1260(%rbp), %rax
movsbl -0x1220(%rbp,%rax), %eax
cmpl $0x34, %eax
je 0x298e
movq -0x1260(%rbp), %rax
movsbl -0x1220(%rbp,%rax), %eax
cmpl $0x35, %eax
je 0x298e
movq -0x1260(%rbp), %rax
movsbl -0x1220(%rbp,%rax), %eax
cmpl $0x36, %eax
je 0x298e
movq -0x1260(%rbp), %rax
movsbl -0x1220(%rbp,%rax), %eax
cmpl $0x37, %eax
je 0x298e
movq -0x1260(%rbp), %rax
movsbl -0x1220(%rbp,%rax), %eax
cmpl $0x38, %eax
je 0x298e
movq -0x1260(%rbp), %rax
movsbl -0x1220(%rbp,%rax), %eax
cmpl $0x39, %eax
jne 0x29c6
movl $0x1, -0x1244(%rbp)
jmp 0x29d0
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x1250(%rbp)
movl %eax, -0x1254(%rbp)
leaq -0x1240(%rbp), %rdi
callq 0x2160
leaq -0x218(%rbp), %rdi
callq 0x2090
jmp 0x2a13
movl $0x2, -0x1244(%rbp)
jmp 0x29d2
leaq -0x218(%rbp), %rdi
callq 0x2070
jmp 0x29e0
movl -0x1244(%rbp), %eax
movl %eax, -0x126c(%rbp)
leaq -0x1240(%rbp), %rdi
callq 0x2160
leaq -0x218(%rbp), %rdi
callq 0x2090
movl -0x126c(%rbp), %eax
addq $0x1270, %rsp           # imm = 0x1270
popq %rbp
retq
movq -0x1250(%rbp), %rdi
callq 0x2390
nop
// File: dianejdan[P]Eclat/./PatternStore.hpp
// Function: PatternStore<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>::add_pattern(Pattern<std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>>*, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::vector<int, std::allocator<int>>)
void add_pattern(Pattern<Typ> *parent, Typ item, vector<int> newTidList){
        Pattern<Typ> *new_pat = new Pattern<Typ>(); // create a Pattern node
        new_pat->set_item(item);
        new_pat->set_tid_list(newTidList);
        parent->add_child(new_pat); // add to the children list of its parent
                                    // i.e. I link its parent and its child
        ++numPatterns; // once add a frequent pattern, increase number of frequent
                       // pattern by 1
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xb0, %rsp
movq %rdx, -0x90(%rbp)
movq %rcx, -0x88(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq %rcx, -0x20(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x80(%rbp)
movl $0x50, %edi
callq 0x2230
movq %rax, %rdi
movq %rdi, %rax
movq %rax, -0x78(%rbp)
callq 0xd390
jmp 0xd7ec
movq -0x90(%rbp), %rsi
movq -0x78(%rbp), %rax
movq %rax, -0x28(%rbp)
movq -0x28(%rbp), %rax
movq %rax, -0xa0(%rbp)
leaq -0x58(%rbp), %rdi
movq %rdi, -0x98(%rbp)
callq 0x20e0
movq -0xa0(%rbp), %rdi
movq -0x98(%rbp), %rsi
callq 0xeed0
jmp 0xd82b
leaq -0x58(%rbp), %rdi
callq 0x2160
movq -0x88(%rbp), %rsi
movq -0x28(%rbp), %rax
movq %rax, -0xb0(%rbp)
leaq -0x70(%rbp), %rdi
movq %rdi, -0xa8(%rbp)
callq 0x4b50
movq -0xb0(%rbp), %rdi
movq -0xa8(%rbp), %rsi
callq 0xeef0
jmp 0xd86b
leaq -0x70(%rbp), %rdi
callq 0x4860
movq -0x10(%rbp), %rdi
movq -0x28(%rbp), %rsi
callq 0xef50
movq -0x80(%rbp), %rax
movl 0x8(%rax), %ecx
addl $0x1, %ecx
movl %ecx, 0x8(%rax)
addq $0xb0, %rsp
popq %rbp
retq
movq -0x78(%rbp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
movl $0x50, %esi
callq 0x2240
jmp 0xd8df
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
leaq -0x58(%rbp), %rdi
callq 0x2160
jmp 0xd8df
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
leaq -0x70(%rbp), %rdi
callq 0x4860
movq -0x30(%rbp), %rdi
callq 0x2390
nopl (%rax,%rax)
// File: miklhh[P]mandelbrot/src/main.cpp
// Function: shutdown(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, unsigned char)
void shutdown(std::string str, uint8_t exit_code)
{
    render_destroy();
    std::cout << "Shutdown message: " << str.c_str() << std::endl;
    std::cout << "Returning to system with exit code: " << int(exit_code) << std::endl;
    exit(exit_code);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x20(%rbp)
movb %sil, %al
movq %rdi, -0x8(%rbp)
movb %al, -0x9(%rbp)
callq 0x4690
movq 0x118fe(%rip), %rdi     # 0x14fd0
leaq 0xa94f(%rip), %rsi      # 0xe028
callq 0x3260
movq -0x20(%rbp), %rdi
movq %rax, -0x18(%rbp)
callq 0x30f0
movq -0x18(%rbp), %rdi
movq %rax, %rsi
callq 0x3260
movq %rax, %rdi
movq 0x118b7(%rip), %rsi     # 0x14fb8
callq 0x3290
movq 0x118c3(%rip), %rdi     # 0x14fd0
leaq 0xa927(%rip), %rsi      # 0xe03b
callq 0x3260
movq %rax, %rdi
movzbl -0x9(%rbp), %esi
callq 0x33c0
movq %rax, %rdi
movq 0x11889(%rip), %rsi     # 0x14fb8
callq 0x3290
movzbl -0x9(%rbp), %edi
callq 0x32f0
nopl (%rax)
// File: miklhh[P]mandelbrot/src/render.cpp
// Function: render_init(int)
void render_init(int n_threads)
{
    /* Initialize render buffer. */
    for (int y = 0; y < scr_height; y++)
    {
        render_buffer.push_back(std::vector<rgb_t>());
        for (int x = 0; x < scr_width; x++)
        {
            render_buffer.at(y).push_back(rgb_t{ 0, 0, 0, 0 });
        }
    }
    /* Initialize the thread pool. */
    thread_pool = mandelbrot_thread_pool_create(n_threads, render_segment);
    if (thread_pool == NULL)
    {
        std::cerr << "Error initializeing threadpool, exiting." << std::endl;
        #ifdef _WIN32
        system("pause");
        #endif  
        exit(1);
    }
    /* Initialze render data. */
    rendering_complete = false;
    render_initialized = true;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movl %edi, -0x4(%rbp)
movl $0x0, -0x8(%rbp)
movl -0x8(%rbp), %eax
leaq 0xa305(%rip), %rcx      # 0xe024
cmpl (%rcx), %eax
jge 0x3dfc
xorps %xmm0, %xmm0
movaps %xmm0, -0x20(%rbp)
movq $0x0, -0x10(%rbp)
leaq -0x20(%rbp), %rdi
movq %rdi, -0x60(%rbp)
callq 0x4790
movq -0x60(%rbp), %rsi
leaq 0x1151a(%rip), %rdi     # 0x15268
callq 0x4760
jmp 0x3d55
leaq -0x20(%rbp), %rdi
callq 0x47b0
movl $0x0, -0x30(%rbp)
movl -0x30(%rbp), %eax
leaq 0xa2b1(%rip), %rcx      # 0xe020
cmpl (%rcx), %eax
jge 0x3dec
movslq -0x8(%rbp), %rsi
leaq 0x114ea(%rip), %rdi     # 0x15268
callq 0x4810
movq %rax, %rdi
movl -0x34(%rbp), %eax
andl $0xffffff00, %eax       # imm = 0xFFFFFF00
orl $0x0, %eax
movl %eax, -0x34(%rbp)
movl -0x34(%rbp), %eax
andl $0xffff00ff, %eax       # imm = 0xFFFF00FF
orl $0x0, %eax
movl %eax, -0x34(%rbp)
movl -0x34(%rbp), %eax
andl $0xff00ffff, %eax       # imm = 0xFF00FFFF
orl $0x0, %eax
movl %eax, -0x34(%rbp)
movl -0x34(%rbp), %eax
andl $0xffffff, %eax         # imm = 0xFFFFFF
orl $0x0, %eax
movl %eax, -0x34(%rbp)
leaq -0x34(%rbp), %rsi
callq 0x4850
movl -0x30(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x30(%rbp)
jmp 0x3d65
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
leaq -0x20(%rbp), %rdi
callq 0x47b0
jmp 0x3ea0
jmp 0x3dee
movl -0x8(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x8(%rbp)
jmp 0x3d15
movl -0x4(%rbp), %eax
movl %eax, -0x74(%rbp)
leaq 0xa7(%rip), %rsi        # 0x3eb0
leaq -0x58(%rbp), %rdi
movq %rdi, -0x70(%rbp)
callq 0x4880
movl -0x74(%rbp), %edi
movq -0x70(%rbp), %rsi
callq 0x7720
movq %rax, -0x68(%rbp)
jmp 0x3e28
movq -0x68(%rbp), %rax
movq %rax, 0x11455(%rip)     # 0x15288
leaq -0x58(%rbp), %rdi
callq 0x4910
cmpq $0x0, 0x11444(%rip)     # 0x15288
jne 0x3e89
movq 0x111a3(%rip), %rdi     # 0x14ff0
leaq 0xa2a4(%rip), %rsi      # 0xe0f8
callq 0x3260
movq %rax, %rdi
movq 0x11155(%rip), %rsi     # 0x14fb8
callq 0x3290
movl $0x1, %edi
callq 0x32f0
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
leaq -0x58(%rbp), %rdi
callq 0x4910
jmp 0x3ea0
movb $0x0, 0x11400(%rip)     # 0x15290
movb $0x1, 0x113e9(%rip)     # 0x15280
addq $0x80, %rsp
popq %rbp
retq
movq -0x28(%rbp), %rdi
callq 0x33e0
nopl (%rax)
// File: miklhh[P]mandelbrot/src/render.cpp
// Function: render_mandelbrot(std::complex<double> const&, scale_t const&)
void render_mandelbrot(
    const std::complex<double> & point, 
    const scale_t & scale)
{
    std::complex<double> upper_left { 
        point.real() - scale.x, 
        point.imag() + scale.y };
    std::complex<double> lower_right { 
        point.real() + scale.x, 
        point.imag() - scale.y };
    std::cout << "Upper left: " << upper_left << std::endl;
    std::cout << "Lower right: " << lower_right << std::endl;
    render_mandelbrot(upper_left, lower_right);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq -0x8(%rbp), %rdi
callq 0x4930
movq -0x10(%rbp), %rax
subsd (%rax), %xmm0
movsd %xmm0, -0x40(%rbp)
movq -0x8(%rbp), %rdi
callq 0x4950
movaps %xmm0, %xmm1
movsd -0x40(%rbp), %xmm0
movq -0x10(%rbp), %rax
addsd 0x8(%rax), %xmm1
leaq -0x20(%rbp), %rdi
callq 0x3980
movq -0x8(%rbp), %rdi
callq 0x4930
movq -0x10(%rbp), %rax
addsd (%rax), %xmm0
movsd %xmm0, -0x38(%rbp)
movq -0x8(%rbp), %rdi
callq 0x4950
movaps %xmm0, %xmm1
movsd -0x38(%rbp), %xmm0
movq -0x10(%rbp), %rax
subsd 0x8(%rax), %xmm1
leaq -0x30(%rbp), %rdi
callq 0x3980
movq 0x11007(%rip), %rdi     # 0x14fd0
leaq 0xa151(%rip), %rsi      # 0xe121
callq 0x3260
movq %rax, %rdi
leaq -0x20(%rbp), %rsi
callq 0x32e0
movq %rax, %rdi
movq 0x10fcd(%rip), %rsi     # 0x14fb8
callq 0x3290
movq 0x10fd9(%rip), %rdi     # 0x14fd0
leaq 0xa130(%rip), %rsi      # 0xe12e
callq 0x3260
movq %rax, %rdi
leaq -0x30(%rbp), %rsi
callq 0x32e0
movq %rax, %rdi
movq 0x10f9f(%rip), %rsi     # 0x14fb8
callq 0x3290
leaq -0x20(%rbp), %rdi
leaq -0x30(%rbp), %rsi
callq 0x4040
addq $0x40, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: miklhh[P]mandelbrot/src/render.cpp
// Function: get_scale(std::complex<double>, std::complex<double>)
static scale_t get_scale(
    std::complex<double> upper_left, 
    std::complex<double> lower_right)
{
    scale_t scale {
        (lower_right.real() - upper_left.real()) / scr_width,
        (lower_right.imag() - upper_left.imag()) / scr_height
    };
    return scale;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movsd %xmm0, -0x20(%rbp)
movsd %xmm1, -0x18(%rbp)
movsd %xmm2, -0x30(%rbp)
movsd %xmm3, -0x28(%rbp)
leaq -0x30(%rbp), %rdi
movq %rdi, -0x50(%rbp)
callq 0x4930
movsd %xmm0, -0x48(%rbp)
leaq -0x20(%rbp), %rdi
movq %rdi, -0x40(%rbp)
callq 0x4930
movq -0x50(%rbp), %rdi
movaps %xmm0, %xmm1
movsd -0x48(%rbp), %xmm0
subsd %xmm1, %xmm0
leaq 0x9dae(%rip), %rax      # 0xe020
cvtsi2sdl (%rax), %xmm1
divsd %xmm1, %xmm0
movsd %xmm0, -0x10(%rbp)
callq 0x4950
movq -0x40(%rbp), %rdi
movsd %xmm0, -0x38(%rbp)
callq 0x4950
movaps %xmm0, %xmm1
movsd -0x38(%rbp), %xmm0
subsd %xmm1, %xmm0
leaq 0x9d7f(%rip), %rax      # 0xe024
cvtsi2sdl (%rax), %xmm1
divsd %xmm1, %xmm0
movsd %xmm0, -0x8(%rbp)
movsd -0x10(%rbp), %xmm0
movsd -0x8(%rbp), %xmm1
addq $0x50, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: miklhh[P]mandelbrot/src/render.cpp
// Function: get_offset(std::complex<double> const&, std::complex<double> const&)
static offset_t get_offset(
    const std::complex<double> & upper_left,
    const std::complex<double> & lower_right)
{
    offset_t offset{
        upper_left.real() + (lower_right.real() - upper_left.real()) / 2,
        lower_right.imag() + (upper_left.imag() - lower_right.imag()) / 2
    };
    return offset;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x18(%rbp)
movq %rsi, -0x20(%rbp)
movq -0x18(%rbp), %rdi
callq 0x4930
movsd %xmm0, -0x40(%rbp)
movq -0x20(%rbp), %rdi
callq 0x4930
movsd %xmm0, -0x48(%rbp)
movq -0x18(%rbp), %rdi
callq 0x4930
movsd -0x48(%rbp), %xmm1
movaps %xmm0, %xmm2
movsd -0x40(%rbp), %xmm0
subsd %xmm2, %xmm1
movsd 0x9dc2(%rip), %xmm2     # 0xe0e0
movsd %xmm2, -0x30(%rbp)
mulsd %xmm2, %xmm1
addsd %xmm1, %xmm0
movsd %xmm0, -0x10(%rbp)
movq -0x20(%rbp), %rdi
callq 0x4950
movsd %xmm0, -0x28(%rbp)
movq -0x18(%rbp), %rdi
callq 0x4950
movsd %xmm0, -0x38(%rbp)
movq -0x20(%rbp), %rdi
callq 0x4950
movsd -0x38(%rbp), %xmm1
movsd -0x30(%rbp), %xmm2
movaps %xmm0, %xmm3
movsd -0x28(%rbp), %xmm0
subsd %xmm3, %xmm1
mulsd %xmm2, %xmm1
addsd %xmm1, %xmm0
movsd %xmm0, -0x8(%rbp)
movsd -0x10(%rbp), %xmm0
movsd -0x8(%rbp), %xmm1
addq $0x50, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: miklhh[P]mandelbrot/src/render.cpp
// Function: render_draw_to_SDL_Renderer(SDL_Renderer*)
void render_draw_to_SDL_Renderer(SDL_Renderer* renderer)
{
    for (int y = 0; y < scr_height; y++)
    {
        for (int x = 0; x < scr_width; x++)
        {
            SDL_SetRenderDrawColor(
                renderer,
                render_buffer[y][x].red,
                render_buffer[y][x].green,
                render_buffer[y][x].blue,
                render_buffer[y][x].alpha);
            SDL_RenderDrawPoint(renderer, x, y);
        }
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movl $0x0, -0xc(%rbp)
movl -0xc(%rbp), %eax
leaq 0x9c77(%rip), %rcx      # 0xe024
cmpl (%rcx), %eax
jge 0x44bd
movl $0x0, -0x10(%rbp)
movl -0x10(%rbp), %eax
leaq 0x9c5a(%rip), %rcx      # 0xe020
cmpl (%rcx), %eax
jge 0x44ad
movq -0x8(%rbp), %rax
movq %rax, -0x20(%rbp)
movslq -0xc(%rbp), %rsi
leaq 0x10e87(%rip), %rdi     # 0x15268
callq 0x4970
movq %rax, %rdi
movslq -0x10(%rbp), %rsi
callq 0x4990
movl (%rax), %eax
andl $0xff, %eax
movb %al, -0x13(%rbp)
movslq -0xc(%rbp), %rsi
leaq 0x10e61(%rip), %rdi     # 0x15268
callq 0x4970
movq %rax, %rdi
movslq -0x10(%rbp), %rsi
callq 0x4990
movl (%rax), %eax
shrl $0x8, %eax
andl $0xff, %eax
movb %al, -0x12(%rbp)
movslq -0xc(%rbp), %rsi
leaq 0x10e38(%rip), %rdi     # 0x15268
callq 0x4970
movq %rax, %rdi
movslq -0x10(%rbp), %rsi
callq 0x4990
movl (%rax), %eax
shrl $0x10, %eax
andl $0xff, %eax
movb %al, -0x11(%rbp)
movslq -0xc(%rbp), %rsi
leaq 0x10e0f(%rip), %rdi     # 0x15268
callq 0x4970
movq %rax, %rdi
movslq -0x10(%rbp), %rsi
callq 0x4990
movq -0x20(%rbp), %rdi
movb -0x13(%rbp), %sil
movb -0x12(%rbp), %dl
movb -0x11(%rbp), %cl
movl (%rax), %eax
shrl $0x18, %eax
movzbl %sil, %esi
movzbl %dl, %edx
movzbl %cl, %ecx
movzbl %al, %r8d
callq 0x3350
movq -0x8(%rbp), %rdi
movl -0x10(%rbp), %esi
movl -0xc(%rbp), %edx
callq 0x3250
movl -0x10(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x10(%rbp)
jmp 0x43bc
jmp 0x44af
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x43a3
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: miklhh[P]mandelbrot/src/render.cpp
// Function: render_create_bmp(char const*)
int render_create_bmp(const char* file_name)
{
    /* Create a surface and unlock the pixels*/
    std::cout << "Creating BMP." << std::endl;
    SDL_Surface* surface = SDL_CreateRGBSurface(0, scr_width, scr_height, 32, 0, 0, 0, 0);
    SDL_LockSurface(surface);
    for (int y = 0; y < scr_height; y++)
    {
        for (int x = 0; x < scr_width; x++)
        {
            set_pixel_on_surface(surface, x, y, render_buffer[y][x]);
        }
    }
    SDL_UnlockSurface(surface);
    SDL_SaveBMP(surface, file_name);
    std::cout << "BMP created." << std::endl;
    return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movq 0x10acd(%rip), %rdi     # 0x14fd0
leaq 0x9c5e(%rip), %rsi      # 0xe168
callq 0x3260
movq %rax, %rdi
movq 0x10a9f(%rip), %rsi     # 0x14fb8
callq 0x3290
leaq 0x9afb(%rip), %rax      # 0xe020
movl (%rax), %esi
leaq 0x9af6(%rip), %rax      # 0xe024
movl (%rax), %edx
xorl %r9d, %r9d
movl $0x20, %ecx
movl %r9d, %edi
movl %r9d, %r8d
movl $0x0, (%rsp)
movl $0x0, 0x8(%rsp)
callq 0x3330
movq %rax, -0x10(%rbp)
movq -0x10(%rbp), %rdi
callq 0x3320
movl $0x0, -0x14(%rbp)
movl -0x14(%rbp), %eax
leaq 0x9ab4(%rip), %rcx      # 0xe024
cmpl (%rcx), %eax
jge 0x45eb
movl $0x0, -0x18(%rbp)
movl -0x18(%rbp), %eax
leaq 0x9a9b(%rip), %rcx      # 0xe020
cmpl (%rcx), %eax
jge 0x45db
movq -0x10(%rbp), %rax
movq %rax, -0x30(%rbp)
movl -0x18(%rbp), %eax
movl %eax, -0x24(%rbp)
movl -0x14(%rbp), %eax
movl %eax, -0x20(%rbp)
movslq -0x14(%rbp), %rsi
leaq 0x10cc0(%rip), %rdi     # 0x15268
callq 0x4970
movq %rax, %rdi
movslq -0x18(%rbp), %rsi
callq 0x4990
movq -0x30(%rbp), %rdi
movl -0x24(%rbp), %esi
movl -0x20(%rbp), %edx
movl (%rax), %eax
movl %eax, -0x1c(%rbp)
movl -0x1c(%rbp), %ecx
callq 0x4650
movl -0x18(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x18(%rbp)
jmp 0x457b
jmp 0x45dd
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0x4566
movq -0x10(%rbp), %rdi
callq 0x3340
movq -0x10(%rbp), %rax
movq %rax, -0x38(%rbp)
movq -0x8(%rbp), %rdi
leaq 0x9b6f(%rip), %rsi      # 0xe176
callq 0x3100
movq -0x38(%rbp), %rdi
movq %rax, %rsi
movl $0x1, %edx
callq 0x3150
movq 0x109ac(%rip), %rdi     # 0x14fd0
leaq 0x9b4e(%rip), %rsi      # 0xe179
callq 0x3260
movq %rax, %rdi
movq 0x1097e(%rip), %rsi     # 0x14fb8
callq 0x3290
xorl %eax, %eax
addq $0x50, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: miklhh[P]mandelbrot/src/color.cpp
// Function: get_color(unsigned int, std::complex<double> const&, std::complex<double> const&)
rgb_t get_color(
    unsigned int iterations, 
    const std::complex<double> & zn, 
    const std::complex<double> & c)
{
    rgb_t color{ 0, 0, 0, 0 };

    /* If it converges. */
    extern unsigned int max_iterations;
    if (iterations == max_iterations)
    {
        return color;
    }
    else
    {
        double convergence_value = get_convergence_value(iterations, zn, c);
        rgb_t color = hsl_to_rgb(
            {
                log(10 * convergence_value),
                1,
                0.7
            });
        return color;
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x80, %rsp
movl %edi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
leaq -0x1c(%rbp), %rdi
xorl %esi, %esi
movl $0x4, %edx
callq 0x3140
movl -0x8(%rbp), %eax
leaq 0xecc0(%rip), %rcx      # 0x15230
cmpl (%rcx), %eax
jne 0x657f
movl -0x1c(%rbp), %eax
movl %eax, -0x4(%rbp)
jmp 0x661c
movl -0x8(%rbp), %edi
movq -0x10(%rbp), %rax
movq (%rax), %rcx
movq %rcx, -0x38(%rbp)
movq 0x8(%rax), %rax
movq %rax, -0x30(%rbp)
movq -0x18(%rbp), %rax
movq (%rax), %rcx
movq %rcx, -0x48(%rbp)
movq 0x8(%rax), %rax
movq %rax, -0x40(%rbp)
movsd -0x38(%rbp), %xmm0
movsd -0x30(%rbp), %xmm1
movsd -0x48(%rbp), %xmm2
movsd -0x40(%rbp), %xmm3
callq 0x6630
movsd %xmm0, -0x28(%rbp)
movsd 0x7c4a(%rip), %xmm0     # 0xe218
mulsd -0x28(%rbp), %xmm0
callq 0x31f0
movsd %xmm0, -0x60(%rbp)
movsd 0x7a23(%rip), %xmm0     # 0xe008
movsd %xmm0, -0x58(%rbp)
movsd 0x7c1e(%rip), %xmm0     # 0xe210
movsd %xmm0, -0x50(%rbp)
leaq -0x60(%rbp), %rax
movq (%rax), %rcx
movq %rcx, (%rsp)
movq 0x8(%rax), %rcx
movq %rcx, 0x8(%rsp)
movq 0x10(%rax), %rax
movq %rax, 0x10(%rsp)
callq 0x6710
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x80, %rsp
popq %rbp
retq
nopl (%rax,%rax)
// File: miklhh[P]mandelbrot/src/color.cpp
// Function: get_convergence_value(int, std::complex<double>, std::complex<double>)
static double get_convergence_value(
    int iterations, 
    std::complex<double> zn, 
    std::complex<double> c)
{
    /* Enchance the divirging point to get a 'smoother' value. */
    const double escape_radius = 2.0;
    for (int i = 0; i < 5; i++)
    {
        zn = zn * zn + c;
        iterations++;
    }
    return double(iterations) - log2( log( abs(zn) ) / log(escape_radius) );
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x70, %rsp
movsd %xmm0, -0x10(%rbp)
movsd %xmm1, -0x8(%rbp)
movsd %xmm2, -0x20(%rbp)
movsd %xmm3, -0x18(%rbp)
movl %edi, -0x24(%rbp)
movsd 0x7bc9(%rip), %xmm0     # 0xe220
movsd %xmm0, -0x30(%rbp)
movl $0x0, -0x34(%rbp)
cmpl $0x5, -0x34(%rbp)
jge 0x66ba
leaq -0x10(%rbp), %rsi
movq %rsi, %rdi
callq 0x6b40
movsd %xmm0, -0x58(%rbp)
movsd %xmm1, -0x50(%rbp)
leaq -0x58(%rbp), %rdi
leaq -0x20(%rbp), %rsi
callq 0x6b00
movsd %xmm0, -0x48(%rbp)
movsd %xmm1, -0x40(%rbp)
movq -0x48(%rbp), %rax
movq %rax, -0x10(%rbp)
movq -0x40(%rbp), %rax
movq %rax, -0x8(%rbp)
movl -0x24(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x24(%rbp)
movl -0x34(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x34(%rbp)
jmp 0x6663
cvtsi2sdl -0x24(%rbp), %xmm0
movsd %xmm0, -0x60(%rbp)
leaq -0x10(%rbp), %rdi
callq 0x6b80
callq 0x31f0
movsd %xmm0, -0x68(%rbp)
movsd 0x7b41(%rip), %xmm0     # 0xe220
callq 0x31f0
movaps %xmm0, %xmm1
movsd -0x68(%rbp), %xmm0
divsd %xmm1, %xmm0
callq 0x3400
movaps %xmm0, %xmm1
movsd -0x60(%rbp), %xmm0
subsd %xmm1, %xmm0
addq $0x70, %rsp
popq %rbp
retq
nopw (%rax,%rax)
// File: miklhh[P]mandelbrot/src/color.cpp
// Function: shift_range(double, double, double)
static double shift_range(double value, double range_lower, double range_higher)
{
    const int max_shifts = 1000;
    const double shift_value = range_higher - range_lower;
    for (int i = 0; i < max_shifts; i++)
    {
        if (value < range_lower) { value += shift_value; }
        else if (value > range_higher) { value -= shift_value; }
        else return value;
    }
    return value;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
movsd %xmm0, -0x10(%rbp)
movsd %xmm1, -0x18(%rbp)
movsd %xmm2, -0x20(%rbp)
movl $0x3e8, -0x24(%rbp)     # imm = 0x3E8
movsd -0x20(%rbp), %xmm0
subsd -0x18(%rbp), %xmm0
movsd %xmm0, -0x30(%rbp)
movl $0x0, -0x34(%rbp)
cmpl $0x3e8, -0x34(%rbp)     # imm = 0x3E8
jge 0x6ae6
movsd -0x10(%rbp), %xmm1
movsd -0x18(%rbp), %xmm0
ucomisd %xmm1, %xmm0
jbe 0x6aaa
movsd -0x30(%rbp), %xmm0
addsd -0x10(%rbp), %xmm0
movsd %xmm0, -0x10(%rbp)
jmp 0x6ad9
movsd -0x10(%rbp), %xmm0
ucomisd -0x20(%rbp), %xmm0
jbe 0x6acb
movsd -0x30(%rbp), %xmm1
movsd -0x10(%rbp), %xmm0
subsd %xmm1, %xmm0
movsd %xmm0, -0x10(%rbp)
jmp 0x6ad7
movsd -0x10(%rbp), %xmm0
movsd %xmm0, -0x8(%rbp)
jmp 0x6af0
jmp 0x6ad9
jmp 0x6adb
movl -0x34(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x34(%rbp)
jmp 0x6a80
movsd -0x10(%rbp), %xmm0
movsd %xmm0, -0x8(%rbp)
movsd -0x8(%rbp), %xmm0
popq %rbp
retq
nopw (%rax,%rax)
// File: miklhh[P]mandelbrot/src/supersampling.cpp
// Function: get_px_1x_ss(int, int)
rgb_t get_px_1x_ss(int px_x, int px_y)
{
    using std::complex;
    double x = double((px_x - scr_width / 2) * scale.x + offset.x);
    double y = double((px_y - scr_height / 2) * scale.y + offset.y);
    complex<double> c(x, y);
    complex<double> z(0, 0);
    unsigned int iterations;
    for (iterations = 0; iterations < max_iterations; iterations++)
    {
        z = z * z + c;
        if (test_escape(z, 2.0)) { break; }
    }
    return get_color(iterations, z, c);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x70, %rsp
movl %edi, -0x8(%rbp)
movl %esi, -0xc(%rbp)
movl -0x8(%rbp), %eax
movl %eax, -0x70(%rbp)
leaq 0x7205(%rip), %rax      # 0xe020
movl (%rax), %eax
movl $0x2, %ecx
cltd
idivl %ecx
movl %eax, %ecx
movl -0x70(%rbp), %eax
subl %ecx, %eax
cvtsi2sd %eax, %xmm0
movsd 0xe490(%rip), %xmm2     # 0x152c8
movsd 0xe498(%rip), %xmm1     # 0x152d8
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
movsd %xmm0, -0x18(%rbp)
movl -0xc(%rbp), %eax
movl %eax, -0x6c(%rbp)
leaq 0x71ca(%rip), %rax      # 0xe024
movl (%rax), %eax
movl $0x2, %ecx
cltd
idivl %ecx
movl %eax, %ecx
movl -0x6c(%rbp), %eax
subl %ecx, %eax
cvtsi2sd %eax, %xmm0
movsd 0xe459(%rip), %xmm2     # 0x152d0
movsd 0xe461(%rip), %xmm1     # 0x152e0
mulsd %xmm2, %xmm0
addsd %xmm1, %xmm0
movsd %xmm0, -0x20(%rbp)
movsd -0x18(%rbp), %xmm0
movsd -0x20(%rbp), %xmm1
leaq -0x30(%rbp), %rdi
callq 0x3980
leaq -0x40(%rbp), %rdi
xorps %xmm1, %xmm1
movaps %xmm1, %xmm0
callq 0x3980
movl $0x0, -0x44(%rbp)
movl -0x44(%rbp), %eax
leaq 0xe371(%rip), %rcx      # 0x15230
cmpl (%rcx), %eax
jae 0x6f26
leaq -0x40(%rbp), %rsi
movq %rsi, %rdi
callq 0x6b40
movsd %xmm0, -0x68(%rbp)
movsd %xmm1, -0x60(%rbp)
leaq -0x68(%rbp), %rdi
leaq -0x30(%rbp), %rsi
callq 0x6b00
movsd %xmm0, -0x58(%rbp)
movsd %xmm1, -0x50(%rbp)
movq -0x58(%rbp), %rax
movq %rax, -0x40(%rbp)
movq -0x50(%rbp), %rax
movq %rax, -0x38(%rbp)
leaq -0x40(%rbp), %rdi
movsd 0x7314(%rip), %xmm0     # 0xe220
callq 0x6f50
testb $0x1, %al
jne 0x6f17
jmp 0x6f19
jmp 0x6f26
jmp 0x6f1b
movl -0x44(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x44(%rbp)
jmp 0x6eb5
movl -0x44(%rbp), %edi
leaq -0x40(%rbp), %rsi
leaq -0x30(%rbp), %rdx
callq 0x6540
movl %eax, -0x4(%rbp)
movl -0x4(%rbp), %eax
addq $0x70, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: miklhh[P]mandelbrot/src/thread_pool.cpp
// Function: mandelbrot_thread_pool_create(int, std::function<void (segment_t)>)
mandelbrot_threadpool* mandelbrot_thread_pool_create(
    int threads,
    std::function<void(segment_t)> render_segment_callback)
{
    /* Allocate the threadpool and set it up. */
    mandelbrot_threadpool* threadpool = new mandelbrot_threadpool;
    if (threadpool != NULL) 
    {
        /* Create the proper amount of thread objects. */
        for (int i = 0; i < threads; i++)
        {
            /* No need to lock mutex since no other threads are using resources. */
            threadpool->workers.push_back(std::thread());
            threadpool->worker_busy.push_back(false);
        }
        /* Set threadpool data. */
        threadpool->render_segment = render_segment_callback;
        threadpool->n_threads = threads;
        return threadpool;
    }
    else 
    { 
        return NULL; 
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x60, %rsp
movq %rsi, -0x48(%rbp)
movl %edi, -0xc(%rbp)
movq %rsi, -0x18(%rbp)
movl $0x108, %edi            # imm = 0x108
callq 0x3270
movq %rax, %rdi
movq %rdi, %rax
movq %rax, -0x40(%rbp)
callq 0x7f00
jmp 0x774e
movq -0x40(%rbp), %rax
movq %rax, -0x20(%rbp)
cmpq $0x0, -0x20(%rbp)
je 0x7821
movl $0x0, -0x30(%rbp)
movl -0x30(%rbp), %eax
cmpl -0xc(%rbp), %eax
jge 0x77fa
movq -0x20(%rbp), %rax
addq $0x8, %rax
movq %rax, -0x58(%rbp)
movq $0x0, -0x38(%rbp)
leaq -0x38(%rbp), %rdi
movq %rdi, -0x50(%rbp)
callq 0x7fd0
movq -0x58(%rbp), %rdi
movq -0x50(%rbp), %rsi
callq 0x7fa0
jmp 0x77a4
leaq -0x38(%rbp), %rdi
callq 0x7ff0
movq -0x20(%rbp), %rdi
addq $0x48, %rdi
xorl %esi, %esi
callq 0x8020
movl -0x30(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x30(%rbp)
jmp 0x7768
movq -0x40(%rbp), %rdi
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
movl $0x108, %esi            # imm = 0x108
callq 0x3280
jmp 0x7833
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x28(%rbp)
movl %eax, -0x2c(%rbp)
leaq -0x38(%rbp), %rdi
callq 0x7ff0
jmp 0x7833
movq -0x48(%rbp), %rsi
movq -0x20(%rbp), %rdi
addq $0xe8, %rdi
callq 0x80f0
movl -0xc(%rbp), %ecx
movq -0x20(%rbp), %rax
movl %ecx, (%rax)
movq -0x20(%rbp), %rax
movq %rax, -0x8(%rbp)
jmp 0x7829
movq $0x0, -0x8(%rbp)
movq -0x8(%rbp), %rax
addq $0x60, %rsp
popq %rbp
retq
movq -0x28(%rbp), %rdi
callq 0x33e0
nopl (%rax)
// File: miklhh[P]mandelbrot/src/thread_pool.cpp
// Function: mandelbrot_thread_pool_add_job(mandelbrot_threadpool*, segment_t)
void mandelbrot_thread_pool_add_job(
    mandelbrot_threadpool* threadpool, 
    segment_t segment)
{
    /* Add the job to the job queue and launch the thread pool. */
    std::unique_lock<std::mutex> jobs_lock(threadpool->jobs_mutex);
    threadpool->jobs.push(segment);
    jobs_lock.unlock();
    mandelbrot_thread_pool_launch(threadpool);
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x40, %rsp
movq %rsi, -0x10(%rbp)
movq %rdx, -0x8(%rbp)
movq %rdi, -0x18(%rbp)
movq -0x18(%rbp), %rsi
addq $0x70, %rsi
leaq -0x28(%rbp), %rdi
callq 0x8140
movq -0x18(%rbp), %rdi
addq $0x98, %rdi
leaq -0x10(%rbp), %rsi
callq 0x8180
jmp 0x787b
leaq -0x28(%rbp), %rdi
callq 0x81b0
jmp 0x7886
movq -0x18(%rbp), %rdi
callq 0x78c0
jmp 0x7891
leaq -0x28(%rbp), %rdi
callq 0x8200
addq $0x40, %rsp
popq %rbp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
leaq -0x28(%rbp), %rdi
callq 0x8200
movq -0x30(%rbp), %rdi
callq 0x33e0
nop
// File: miklhh[P]mandelbrot/src/thread_pool.cpp
// Function: mandelbrot_thread_pool_launch(mandelbrot_threadpool*)
static void mandelbrot_thread_pool_launch(mandelbrot_threadpool* threadpool)
{
    /* Try to find a free thread. */
    std::unique_lock<std::mutex> worker_busy_lock(threadpool->jobs_mutex);
    int index_next_free_thread = -1;
    for (int i = 0; i < threadpool->n_threads; i++)
    {
        if (!threadpool->worker_busy.at(i)) 
        { 
            index_next_free_thread = i;
            break;
        }
    }
    /* Act acordingly if thread has been found. */
    if (index_next_free_thread != -1)
    {
        /* A free thread has been found. Launch it. */
        threadpool->worker_busy.at(index_next_free_thread) = true;
        threadpool->workers.at(index_next_free_thread) = std::thread(
            mandelbrot_thread_pool_thread_callback,
            threadpool,
            index_next_free_thread);
        threadpool->workers.at(index_next_free_thread).detach();
    }
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rsi
addq $0x70, %rsi
leaq -0x18(%rbp), %rdi
callq 0x8140
movl $0xffffffff, -0x1c(%rbp) # imm = 0xFFFFFFFF
movl $0x0, -0x20(%rbp)
movl -0x20(%rbp), %eax
movq -0x8(%rbp), %rcx
cmpl (%rcx), %eax
jge 0x795b
movq -0x8(%rbp), %rdi
addq $0x48, %rdi
movslq -0x20(%rbp), %rsi
callq 0x83d0
movq %rdx, -0x68(%rbp)
movq %rax, -0x60(%rbp)
jmp 0x7914
movq -0x68(%rbp), %rax
movq -0x60(%rbp), %rcx
movq %rcx, -0x30(%rbp)
movq %rax, -0x28(%rbp)
leaq -0x30(%rbp), %rdi
callq 0x8420
xorb $-0x1, %al
testb $0x1, %al
jne 0x7935
jmp 0x794e
movl -0x20(%rbp), %eax
movl %eax, -0x1c(%rbp)
jmp 0x795b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
jmp 0x7a42
jmp 0x7950
movl -0x20(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x20(%rbp)
jmp 0x78ee
cmpl $-0x1, -0x1c(%rbp)
je 0x7a30
movq -0x8(%rbp), %rdi
addq $0x48, %rdi
movslq -0x1c(%rbp), %rsi
callq 0x83d0
movq %rdx, -0x78(%rbp)
movq %rax, -0x70(%rbp)
jmp 0x7980
movq -0x78(%rbp), %rax
movq -0x70(%rbp), %rcx
movq %rcx, -0x50(%rbp)
movq %rax, -0x48(%rbp)
leaq -0x50(%rbp), %rdi
movl $0x1, %esi
callq 0x9540
leaq 0x22b(%rip), %rsi       # 0x7bd0
leaq -0x58(%rbp), %rdi
leaq -0x8(%rbp), %rdx
leaq -0x1c(%rbp), %rcx
callq 0x9590
jmp 0x79b8
movq -0x8(%rbp), %rdi
addq $0x8, %rdi
movslq -0x1c(%rbp), %rsi
callq 0x8310
movq %rax, -0x80(%rbp)
jmp 0x79cf
movq -0x80(%rbp), %rdi
leaq -0x58(%rbp), %rsi
movq %rsi, -0x90(%rbp)
callq 0x9660
movq -0x90(%rbp), %rdi
callq 0x7ff0
movq -0x8(%rbp), %rdi
addq $0x8, %rdi
movslq -0x1c(%rbp), %rsi
callq 0x8310
movq %rax, -0x88(%rbp)
jmp 0x7a09
movq -0x88(%rbp), %rdi
callq 0x33d0
jmp 0x7a17
jmp 0x7a30
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x38(%rbp)
movl %eax, -0x3c(%rbp)
leaq -0x58(%rbp), %rdi
callq 0x7ff0
jmp 0x7a42
leaq -0x18(%rbp), %rdi
callq 0x8200
addq $0x90, %rsp
popq %rbp
retq
leaq -0x18(%rbp), %rdi
callq 0x8200
movq -0x38(%rbp), %rdi
callq 0x33e0
nopw %cs:(%rax,%rax)
// File: miklhh[P]mandelbrot/src/thread_pool.cpp
// Function: mandelbrot_thread_pool_destroy(mandelbrot_threadpool*)
int mandelbrot_thread_pool_destroy(mandelbrot_threadpool * threadpool)
{
    std::cout << "Killing threads." << std::endl;
    std::this_thread::sleep_for(std::chrono::milliseconds(200));
    for (int i = 0; i < threadpool->n_threads; i++)
    {
        threadpool->workers.at(i).~thread();
    }
    delete threadpool;
    return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq 0xd55d(%rip), %rdi      # 0x14fd0
leaq 0x6806(%rip), %rsi      # 0xe280
callq 0x3260
movq %rax, %rdi
movq 0xd52f(%rip), %rsi      # 0x14fb8
callq 0x3290
movl $0xc8, -0x14(%rbp)
leaq -0x10(%rbp), %rdi
leaq -0x14(%rbp), %rsi
callq 0x82f0
leaq -0x10(%rbp), %rdi
callq 0x8240
movl $0x0, -0x18(%rbp)
movl -0x18(%rbp), %eax
movq -0x8(%rbp), %rcx
cmpl (%rcx), %eax
jge 0x7ae1
movq -0x8(%rbp), %rdi
addq $0x8, %rdi
movslq -0x18(%rbp), %rsi
callq 0x8310
movq %rax, %rdi
callq 0x7ff0
movl -0x18(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x18(%rbp)
jmp 0x7ab2
movq -0x8(%rbp), %rax
movq %rax, -0x20(%rbp)
cmpq $0x0, %rax
je 0x7b06
movq -0x20(%rbp), %rdi
callq 0x8350
movq -0x20(%rbp), %rdi
movl $0x108, %esi            # imm = 0x108
callq 0x3280
xorl %eax, %eax
addq $0x20, %rsp
popq %rbp
retq
nop
// File: miklhh[P]mandelbrot/src/thread_pool.cpp
// Function: mandelbrot_thread_pool_get_active_workers(mandelbrot_threadpool*)
int mandelbrot_thread_pool_get_active_workers(mandelbrot_threadpool * threadpool)
{
    std::lock_guard<std::mutex> lock_worker_busy(threadpool->worker_busy_mutex);
    int active_workers = 0;
    for (int i = 0; i < threadpool->n_threads; i++)
    {
        if (threadpool->worker_busy.at(i)) { active_workers++; }
    }
    return active_workers;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x50, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rsi
addq $0x20, %rsi
leaq -0x10(%rbp), %rdi
callq 0x83a0
movl $0x0, -0x14(%rbp)
movl $0x0, -0x18(%rbp)
movl -0x18(%rbp), %eax
movq -0x8(%rbp), %rcx
cmpl (%rcx), %eax
jge 0x7baf
movq -0x8(%rbp), %rdi
addq $0x48, %rdi
movslq -0x18(%rbp), %rsi
callq 0x83d0
movq %rdx, -0x48(%rbp)
movq %rax, -0x40(%rbp)
jmp 0x7b61
movq -0x48(%rbp), %rax
movq -0x40(%rbp), %rcx
movq %rcx, -0x28(%rbp)
movq %rax, -0x20(%rbp)
leaq -0x28(%rbp), %rdi
callq 0x8420
testb $0x1, %al
jne 0x7b80
jmp 0x7ba2
movl -0x14(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x14(%rbp)
jmp 0x7ba2
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x30(%rbp)
movl %eax, -0x34(%rbp)
leaq -0x10(%rbp), %rdi
callq 0x8450
jmp 0x7bc7
jmp 0x7ba4
movl -0x18(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x18(%rbp)
jmp 0x7b3b
movl -0x14(%rbp), %eax
movl %eax, -0x4c(%rbp)
leaq -0x10(%rbp), %rdi
callq 0x8450
movl -0x4c(%rbp), %eax
addq $0x50, %rsp
popq %rbp
retq
movq -0x30(%rbp), %rdi
callq 0x33e0
// File: iZhangHui[P]CppPrimer/CH05_Statements/examples/othercnt.cc
// Function: main
int main()
{
    char ch;
    // initialize counters for each vowel
    unsigned vowelCnt = 0;
    unsigned otherCnt = 0;  // count anything that isn't a vowel

    while (cin >> ch) {
        // if ch is a vowel, increment the appropriate counter
        switch (ch) {
			case 'a': case 'e': case 'i': case 'o': case 'u':
				++vowelCnt;
				break;
            default:
                ++otherCnt;
                break;
        }
    }
    // print results
    cout << "Number of vowels: \t" << vowelCnt << '\n'
         << "Total non-vowels : \t" << otherCnt << '\n';

    return 0;
}

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movl $0x0, -0x4(%rbp)
movl $0x0, -0xc(%rbp)
movl $0x0, -0x10(%rbp)
movq 0x2ddc(%rip), %rdi      # 0x3fe0
leaq -0x5(%rbp), %rsi
callq 0x1070
movq %rax, %rdi
movq (%rdi), %rax
addq -0x18(%rax), %rdi
callq 0x1060
testb $0x1, %al
jne 0x1222
jmp 0x126e
movsbl -0x5(%rbp), %eax
movl %eax, -0x14(%rbp)
subl $0x61, %eax
je 0x1258
jmp 0x1230
movl -0x14(%rbp), %eax
subl $0x65, %eax
je 0x1258
jmp 0x123a
movl -0x14(%rbp), %eax
subl $0x69, %eax
je 0x1258
jmp 0x1244
movl -0x14(%rbp), %eax
subl $0x6f, %eax
je 0x1258
jmp 0x124e
movl -0x14(%rbp), %eax
subl $0x75, %eax
jne 0x1263
jmp 0x1258
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x126c
movl -0x10(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x10(%rbp)
jmp 0x11fd
movq 0x2d5b(%rip), %rdi      # 0x3fd0
leaq 0xd88(%rip), %rsi       # 0x2004
callq 0x1040
movq %rax, %rdi
movl -0xc(%rbp), %esi
callq 0x1080
movq %rax, %rdi
movl $0xa, %esi
callq 0x1050
movq %rax, %rdi
leaq 0xd75(%rip), %rsi       # 0x2018
callq 0x1040
movq %rax, %rdi
movl -0x10(%rbp), %esi
callq 0x1080
movq %rax, %rdi
movl $0xa, %esi
callq 0x1050
xorl %eax, %eax
addq $0x20, %rsp
popq %rbp
retq
// File: icemiliang[P]vot/src/votx/otx.cc
// Function: votx::OTX::setup(int, int, double, double, bool, double, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, bool)
void OTX::setup(const int pMaxIterD, const int pMaxIterH, const double pThres,
        const double pLearnRate, const bool pFlagVerb, const double vPlotScale,
        const std::string pPrefix, const bool pFlagDebug) {
        vFlagVerb = pFlagVerb;
        vFlagDebug = pFlagDebug;
        vPrefix = pPrefix;
        vMaxIterD = pMaxIterD;
        vMaxIterH = pMaxIterH;
        vThres = pThres;
        vLearnRate = pLearnRate;

        vNumDiracXs = vDiracXs.size();
        vNumEmpiricalXs = vEmpiricalXs.size();

        // Set h to 1 and gradient to 0
        vHs = std::vector<double>(vNumDiracXs, 1.0);
        vGradient = std::vector<double>(vNumDiracXs, 0.0);
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0xe0, %rsp
movq %r8, -0xc8(%rbp)
movl %esi, %eax
movq -0xc8(%rbp), %rsi
movl %eax, -0xbc(%rbp)
movq %rdi, %r8
movl -0xbc(%rbp), %edi
movb %r9b, %al
movq %r8, -0x8(%rbp)
movl %edi, -0xc(%rbp)
movl %edx, -0x10(%rbp)
movsd %xmm0, -0x18(%rbp)
movsd %xmm1, -0x20(%rbp)
andb $0x1, %cl
movb %cl, -0x21(%rbp)
movsd %xmm2, -0x30(%rbp)
movq %rsi, -0x38(%rbp)
andb $0x1, %al
movb %al, -0x39(%rbp)
movq -0x8(%rbp), %rdi
movq %rdi, -0xb8(%rbp)
movb -0x21(%rbp), %al
andb $0x1, %al
movb %al, 0x70(%rdi)
movb -0x39(%rbp), %al
andb $0x1, %al
movb %al, 0x71(%rdi)
addq $0x88, %rdi
callq 0x9060
movq -0xb8(%rbp), %rdi
movl -0xc(%rbp), %eax
movl %eax, 0x74(%rdi)
movl -0x10(%rbp), %eax
movl %eax, 0x78(%rdi)
movsd -0x18(%rbp), %xmm0
movsd %xmm0, 0x68(%rdi)
movsd -0x20(%rbp), %xmm0
movsd %xmm0, 0x60(%rdi)
callq 0x20200
movq -0xb8(%rbp), %rdi
movl %eax, 0x7c(%rdi)
addq $0x18, %rdi
callq 0x20220
movq %rax, %rcx
movq -0xb8(%rbp), %rax
movl %ecx, 0x80(%rax)
movslq 0x7c(%rax), %rax
movq %rax, -0xb0(%rbp)
movabsq $0x3ff0000000000000, %rax # imm = 0x3FF0000000000000
movq %rax, -0x60(%rbp)
leaq -0x61(%rbp), %rdi
movq %rdi, -0xa8(%rbp)
callq 0xee40
movq -0xb0(%rbp), %rsi
movq -0xa8(%rbp), %rcx
leaq -0x58(%rbp), %rdi
leaq -0x60(%rbp), %rdx
callq 0x20240
jmp 0x1db71
movq -0xb8(%rbp), %rdi
addq $0x30, %rdi
leaq -0x58(%rbp), %rsi
movq %rsi, -0xe0(%rbp)
callq 0x202c0
movq -0xe0(%rbp), %rdi
callq 0x202f0
leaq -0x61(%rbp), %rdi
callq 0x20350
movq -0xb8(%rbp), %rax
movslq 0x7c(%rax), %rax
movq %rax, -0xd8(%rbp)
movq $0x0, -0x98(%rbp)
leaq -0x99(%rbp), %rdi
movq %rdi, -0xd0(%rbp)
callq 0xee40
movq -0xd8(%rbp), %rsi
movq -0xd0(%rbp), %rcx
leaq -0x90(%rbp), %rdi
leaq -0x98(%rbp), %rdx
callq 0x20240
jmp 0x1dbf4
movq -0xb8(%rbp), %rdi
addq $0x48, %rdi
leaq -0x90(%rbp), %rsi
callq 0x202c0
leaq -0x90(%rbp), %rdi
callq 0x202f0
leaq -0x99(%rbp), %rdi
callq 0x20350
addq $0xe0, %rsp
popq %rbp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
leaq -0x61(%rbp), %rdi
callq 0x20350
jmp 0x1dc5b
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x70(%rbp)
movl %eax, -0x74(%rbp)
leaq -0x99(%rbp), %rdi
callq 0x20350
movq -0x70(%rbp), %rdi
callq 0x98c0
nopw %cs:(%rax,%rax)
// File: icemiliang[P]vot/src/votx/otx.cc
// Function: votx::OTX::import_data(std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
void OTX::import_data(const std::string pDiracFile, const std::string pEmpiricalFile) {
        std::cout << "--> Importing data... " << std::endl;
        read_diracX_from_file(pDiracFile);
        read_empiricalX_from_file(pEmpiricalFile);
        std::cout << std::endl;
        check_total_mass();
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x90, %rsp
movq %rsi, -0x80(%rbp)
movq %rdx, -0x88(%rbp)
movq %rdi, -0x8(%rbp)
movq %rsi, -0x10(%rbp)
movq %rdx, -0x18(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x78(%rbp)
movq 0x19307(%rip), %rdi     # 0x36fa8
leaq 0x811c(%rip), %rsi      # 0x25dc4
callq 0x9480
movq %rax, %rdi
movq 0x19291(%rip), %rsi     # 0x36f48
callq 0x94d0
movq -0x80(%rbp), %rsi
leaq -0x38(%rbp), %rdi
movq %rdi, -0x70(%rbp)
callq 0x91f0
movq -0x78(%rbp), %rdi
movq -0x70(%rbp), %rsi
callq 0x1dd80
jmp 0x1dcdc
leaq -0x38(%rbp), %rdi
callq 0x9a08
movq -0x88(%rbp), %rsi
leaq -0x68(%rbp), %rdi
movq %rdi, -0x90(%rbp)
callq 0x91f0
movq -0x78(%rbp), %rdi
movq -0x90(%rbp), %rsi
callq 0x1e350
jmp 0x1dd0e
leaq -0x68(%rbp), %rdi
callq 0x9a08
movq 0x1928a(%rip), %rdi     # 0x36fa8
movq 0x19223(%rip), %rsi     # 0x36f48
callq 0x94d0
movq -0x78(%rbp), %rdi
callq 0x1e910
addq $0x90, %rsp
popq %rbp
retq
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x38(%rbp), %rdi
callq 0x9a08
jmp 0x1dd68
movq %rax, %rcx
movl %edx, %eax
movq %rcx, -0x40(%rbp)
movl %eax, -0x44(%rbp)
leaq -0x68(%rbp), %rdi
callq 0x9a08
movq -0x40(%rbp), %rdi
callq 0x98c0
nopw %cs:(%rax,%rax)
// File: icemiliang[P]vot/src/votx/otx.cc
// Function: votx::OTX::cluster()
void OTX::cluster() {
        int iterD = 0;
        while (iterD < vMaxIterD) {
            int iterH = 0;
            while (iterH < vMaxIterH) {
                // break if map converges 
                if (update_map(iterD, iterH)) {
                    if (vFlagVerb) write_results(iterD,iterH);
                    break;
                } 
                if (vFlagVerb) write_results(iterD,iterH);
                iterH++;
            }

            // break if dirac converges
            if (update_dirac()) { write_results(iterD,iterH); break; }
            write_results(iterD,iterH);

            if (vFlagDebug) getchar();
            
            iterD++;
        }
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x8(%rbp)
movq -0x8(%rbp), %rax
movq %rax, -0x18(%rbp)
movl $0x0, -0xc(%rbp)
movq -0x18(%rbp), %rcx
movl -0xc(%rbp), %eax
cmpl 0x74(%rcx), %eax
jge 0x1ec9e
movl $0x0, -0x10(%rbp)
movq -0x18(%rbp), %rcx
movl -0x10(%rbp), %eax
cmpl 0x78(%rcx), %eax
jge 0x1ec52
movq -0x18(%rbp), %rdi
movl -0xc(%rbp), %esi
movl -0x10(%rbp), %edx
callq 0x1ecb0
testb $0x1, %al
jne 0x1ec13
jmp 0x1ec2e
movq -0x18(%rbp), %rax
testb $0x1, 0x70(%rax)
je 0x1ec2c
movq -0x18(%rbp), %rdi
movl -0xc(%rbp), %esi
movl -0x10(%rbp), %edx
callq 0x1ed60
jmp 0x1ec52
movq -0x18(%rbp), %rax
testb $0x1, 0x70(%rax)
je 0x1ec47
movq -0x18(%rbp), %rdi
movl -0xc(%rbp), %esi
movl -0x10(%rbp), %edx
callq 0x1ed60
movl -0x10(%rbp), %eax
addl $0x1, %eax
movl %eax, -0x10(%rbp)
jmp 0x1ebf2
movq -0x18(%rbp), %rdi
callq 0x1f230
testb $0x1, %al
jne 0x1ec61
jmp 0x1ec72
movq -0x18(%rbp), %rdi
movl -0xc(%rbp), %esi
movl -0x10(%rbp), %edx
callq 0x1ed60
jmp 0x1ec9e
movq -0x18(%rbp), %rdi
movl -0xc(%rbp), %esi
movl -0x10(%rbp), %edx
callq 0x1ed60
movq -0x18(%rbp), %rax
testb $0x1, 0x71(%rax)
je 0x1ec90
callq 0x96a0
movl -0xc(%rbp), %eax
addl $0x1, %eax
movl %eax, -0xc(%rbp)
jmp 0x1ebdb
addq $0x20, %rsp
popq %rbp
retq
nopw %cs:(%rax,%rax)
// File: icemiliang[P]vot/src/votx/otx.cc
// Function: votx::OTX::update_map(int, int)
bool OTX::update_map(int iterD, int iterH) {
        if (vFlagVerb || vFlagDebug) {
            std::cout << "updating map... iterD: " << iterD 
                                    << ", iterH: " << iterH << std::endl;    
        }
        // If gradient norm less than threshold
        if (compute_gradient() < vThres) { return true; }
        update_h();
        return false;
    }

// Assembly:
pushq %rbp
movq %rsp, %rbp
subq $0x20, %rsp
movq %rdi, -0x10(%rbp)
movl %esi, -0x14(%rbp)
movl %edx, -0x18(%rbp)
movq -0x10(%rbp), %rax
movq %rax, -0x20(%rbp)
testb $0x1, 0x70(%rax)
jne 0x1ecda
movq -0x20(%rbp), %rax
testb $0x1, 0x71(%rax)
je 0x1ed21
movq 0x182c7(%rip), %rdi     # 0x36fa8
leaq 0x723f(%rip), %rsi      # 0x25f27
callq 0x9480
movq %rax, %rdi
movl -0x14(%rbp), %esi
callq 0x9890
movq %rax, %rdi
leaq 0x723d(%rip), %rsi      # 0x25f3f
callq 0x9480
movq %rax, %rdi
movl -0x18(%rbp), %esi
callq 0x9890
movq %rax, %rdi
movq 0x1822c(%rip), %rsi     # 0x36f48
callq 0x94d0
movq -0x20(%rbp), %rdi
callq 0x1f4a0
movq -0x20(%rbp), %rax
movaps %xmm0, %xmm1
movsd 0x68(%rax), %xmm0
ucomisd %xmm1, %xmm0
jbe 0x1ed42
movb $0x1, -0x1(%rbp)
jmp 0x1ed4f
movq -0x20(%rbp), %rdi
callq 0x1fad0
movb $0x0, -0x1(%rbp)
movb -0x1(%rbp), %al
andb $0x1, %al
addq $0x20, %rsp
popq %rbp
retq
nopw (%rax,%rax)