// File: /workspace/github_cpp_makefile_star2_O1/Merulo[P]CompilerJFTT/src/Calculators/NumberGenerator.cpp
// Function: NumberGenerator::generateWithIncAndAdd(unsigned long long, std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char>>)
void NumberGenerator::generateWithIncAndAdd(unsigned long long target, std::string name)
{
    while (target > 10)
    {
        if (target % 2 == 0)
        {
            _result.push_back({"ADD", name, name});
            target = target / 2;
        }
        else
        {
            _result.push_back({"INC", name});
            target--;
        }
    }
    for(size_t i = 0; i < target; i++)
    {
        _result.push_back({"INC", name});
    }
    _result.push_back({"SUB", name, name});
    std::reverse(_result.begin(), _result.end());
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x1e8, %rsp            # imm = 0x1E8
movq %rsi, %rbx
movq %rdi, %r14
cmpq $0xb, %rdi
jb 0x19a66
leaq 0x168(%rsp), %r13
movq %rsp, %r12
leaq 0x148(%rsp), %rbp
testb $0x1, %r14b
jne 0x198f9
leaq 0xf8(%rsp), %rax
movq %rax, 0xe8(%rsp)
leaq 0xe8(%rsp), %rdi
leaq 0x1e8f5(%rip), %rsi     # 0x380a2
leaq 0x1e8f1(%rip), %rdx     # 0x380a5
callq 0x54fc
leaq 0xd8(%rsp), %rax
movq %rax, 0xc8(%rsp)
movq (%rbx), %rsi
movq 0x8(%rbx), %rdx
addq %rsi, %rdx
leaq 0xc8(%rsp), %rdi
callq 0xca12
leaq 0x178(%rsp), %rax
movq %rax, 0x168(%rsp)
movq (%rbx), %rsi
movq 0x8(%rbx), %rdx
addq %rsi, %rdx
movq %r13, %r15
movq %r13, %rdi
callq 0xca12
movq %r12, %rdi
leaq 0xe8(%rsp), %rsi
leaq 0xc8(%rsp), %rdx
movq %r15, %rcx
callq 0xbe58
leaq 0x2cae1(%rip), %rdi     # 0x46308
movq %r12, %rsi
callq 0xcf0e
movq 0x40(%rsp), %rdi
leaq 0x50(%rsp), %rax
cmpq %rax, %rdi
je 0x1984b
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x42a0
movq 0x20(%rsp), %rdi
leaq 0x30(%rsp), %rax
cmpq %rax, %rdi
je 0x19867
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x42a0
movq (%rsp), %rdi
leaq 0x10(%rsp), %rax
cmpq %rax, %rdi
je 0x19882
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x42a0
movq 0x168(%rsp), %rdi
leaq 0x178(%rsp), %rax
cmpq %rax, %rdi
je 0x198a7
movq 0x178(%rsp), %rsi
incq %rsi
callq 0x42a0
movq 0xc8(%rsp), %rdi
leaq 0xd8(%rsp), %rax
cmpq %rax, %rdi
je 0x198cc
movq 0xd8(%rsp), %rsi
incq %rsi
callq 0x42a0
movq 0xe8(%rsp), %rdi
leaq 0xf8(%rsp), %rax
cmpq %rax, %rdi
je 0x198f1
movq 0xf8(%rsp), %rsi
incq %rsi
callq 0x42a0
shrq %r14
jmp 0x19a5c
leaq 0xb8(%rsp), %rax
movq %rax, 0xa8(%rsp)
leaq 0xa8(%rsp), %rdi
leaq 0x1e786(%rip), %rsi     # 0x3809e
leaq 0x1e782(%rip), %rdx     # 0x380a1
callq 0x54fc
leaq 0x98(%rsp), %rax
movq %rax, 0x88(%rsp)
movq (%rbx), %rsi
movq 0x8(%rbx), %rdx
addq %rsi, %rdx
leaq 0x88(%rsp), %rdi
callq 0xca12
leaq 0x158(%rsp), %rax
movq %rax, 0x148(%rsp)
movq %rbp, %rdi
leaq 0x1e77e(%rip), %rdx     # 0x380e3
movq %rdx, %rsi
callq 0x54fc
movq %r12, %rdi
leaq 0xa8(%rsp), %rsi
leaq 0x88(%rsp), %rdx
movq %rbp, %rcx
callq 0xbe58
leaq 0x2c979(%rip), %rdi     # 0x46308
movq %r12, %rsi
callq 0xcf0e
movq 0x40(%rsp), %rdi
leaq 0x50(%rsp), %rax
cmpq %rax, %rdi
je 0x199b3
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x42a0
movq 0x20(%rsp), %rdi
leaq 0x30(%rsp), %rax
cmpq %rax, %rdi
je 0x199cf
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x42a0
movq (%rsp), %rdi
leaq 0x10(%rsp), %rax
cmpq %rax, %rdi
je 0x199ea
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x42a0
movq 0x148(%rsp), %rdi
leaq 0x158(%rsp), %rax
cmpq %rax, %rdi
je 0x19a0f
movq 0x158(%rsp), %rsi
incq %rsi
callq 0x42a0
movq 0x88(%rsp), %rdi
leaq 0x98(%rsp), %rax
cmpq %rax, %rdi
je 0x19a34
movq 0x98(%rsp), %rsi
incq %rsi
callq 0x42a0
movq 0xa8(%rsp), %rdi
leaq 0xb8(%rsp), %rax
cmpq %rax, %rdi
je 0x19a59
movq 0xb8(%rsp), %rsi
incq %rsi
callq 0x42a0
decq %r14
cmpq $0xa, %r14
ja 0x19784
testq %r14, %r14
je 0x19bcf
leaq 0x128(%rsp), %rbp
leaq 0x1e665(%rip), %r15     # 0x380e3
leaq 0x108(%rsp), %r12
movq %rsp, %r13
leaq 0x78(%rsp), %rax
movq %rax, 0x68(%rsp)
leaq 0x68(%rsp), %rdi
leaq 0x1e5ff(%rip), %rsi     # 0x3809e
leaq 0x1e5fb(%rip), %rdx     # 0x380a1
callq 0x54fc
leaq 0x138(%rsp), %rax
movq %rax, 0x128(%rsp)
movq (%rbx), %rsi
movq 0x8(%rbx), %rdx
addq %rsi, %rdx
movq %rbp, %rdi
callq 0xca12
leaq 0x118(%rsp), %rax
movq %rax, 0x108(%rsp)
movq %r12, %rdi
movq %r15, %rsi
movq %r15, %rdx
callq 0x54fc
movq %r13, %rdi
leaq 0x68(%rsp), %rsi
movq %rbp, %rdx
movq %r12, %rcx
callq 0xbe58
leaq 0x2c803(%rip), %rdi     # 0x46308
movq %r13, %rsi
callq 0xcf0e
movq 0x40(%rsp), %rdi
leaq 0x50(%rsp), %rax
cmpq %rax, %rdi
je 0x19b29
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x42a0
movq 0x20(%rsp), %rdi
leaq 0x30(%rsp), %rax
cmpq %rax, %rdi
je 0x19b45
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x42a0
movq (%rsp), %rdi
leaq 0x10(%rsp), %rax
cmpq %rax, %rdi
je 0x19b60
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x42a0
movq 0x108(%rsp), %rdi
leaq 0x118(%rsp), %rax
cmpq %rax, %rdi
je 0x19b85
movq 0x118(%rsp), %rsi
incq %rsi
callq 0x42a0
movq 0x128(%rsp), %rdi
leaq 0x138(%rsp), %rax
cmpq %rax, %rdi
je 0x19baa
movq 0x138(%rsp), %rsi
incq %rsi
callq 0x42a0
movq 0x68(%rsp), %rdi
leaq 0x78(%rsp), %rax
cmpq %rax, %rdi
je 0x19bc6
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x42a0
decq %r14
jne 0x19a89
leaq 0x1d8(%rsp), %r14
movq %r14, -0x10(%r14)
leaq 0x1e4b4(%rip), %rsi     # 0x38096
leaq 0x1e4b0(%rip), %rdx     # 0x38099
leaq 0x1c8(%rsp), %rdi
callq 0x54fc
leaq 0x1b8(%rsp), %r15
movq %r15, -0x10(%r15)
movq (%rbx), %rsi
movq 0x8(%rbx), %rdx
addq %rsi, %rdx
leaq 0x1a8(%rsp), %rdi
callq 0xca12
leaq 0x198(%rsp), %r12
movq %r12, -0x10(%r12)
movq (%rbx), %rsi
movq 0x8(%rbx), %rdx
addq %rsi, %rdx
leaq 0x188(%rsp), %rdi
callq 0xca12
movq %rsp, %rdi
leaq 0x1c8(%rsp), %rsi
leaq 0x1a8(%rsp), %rdx
leaq 0x188(%rsp), %rcx
callq 0xbe58
leaq 0x2c6a4(%rip), %rdi     # 0x46308
movq %rsp, %rsi
callq 0xcf0e
movq 0x40(%rsp), %rdi
leaq 0x50(%rsp), %rax
cmpq %rax, %rdi
je 0x19c88
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x42a0
leaq 0x30(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x19ca3
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x42a0
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x19cbe
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x42a0
movq 0x188(%rsp), %rdi
cmpq %r12, %rdi
je 0x19cdb
movq 0x198(%rsp), %rsi
incq %rsi
callq 0x42a0
movq 0x1a8(%rsp), %rdi
cmpq %r15, %rdi
je 0x19cf8
movq 0x1b8(%rsp), %rsi
incq %rsi
callq 0x42a0
movq 0x1c8(%rsp), %rdi
cmpq %r14, %rdi
je 0x19d15
movq 0x1d8(%rsp), %rsi
incq %rsi
callq 0x42a0
movq 0x2c5ec(%rip), %rbx     # 0x46308
movq 0x2c5ed(%rip), %r14     # 0x46310
cmpq %r14, %rbx
setne %al
addq $-0x68, %r14
cmpq %rbx, %r14
seta %cl
andb %al, %cl
cmpb $0x1, %cl
jne 0x19d52
movq %rbx, %rdi
movq %r14, %rsi
callq 0x1a1ff
addq $0x68, %rbx
addq $-0x68, %r14
cmpq %r14, %rbx
jb 0x19d3a
addq $0x1e8, %rsp            # imm = 0x1E8
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %rbx
movq %rsp, %rdi
callq 0xbf10
jmp 0x19d74
movq %rax, %rbx
movq 0x188(%rsp), %rdi
cmpq %r12, %rdi
je 0x19d96
movq 0x198(%rsp), %rsi
incq %rsi
callq 0x42a0
jmp 0x19d96
movq %rax, %rbx
movq 0x1a8(%rsp), %rdi
cmpq %r15, %rdi
je 0x19db8
movq 0x1b8(%rsp), %rsi
incq %rsi
callq 0x42a0
jmp 0x19db8
movq %rax, %rbx
movq 0x1c8(%rsp), %rdi
cmpq %r14, %rdi
je 0x19f87
movq 0x1d8(%rsp), %rsi
jmp 0x19f7f
jmp 0x19eff
jmp 0x19eff
movq %rax, %rbx
jmp 0x19e2f
movq %rax, %rbx
movq %rsp, %rdi
callq 0xbf10
jmp 0x19e0a
movq %rax, %rbx
jmp 0x19ed9
movq %rax, %rbx
jmp 0x19e8f
movq %rax, %rbx
jmp 0x19e54
movq %rax, %rbx
movq 0x148(%rsp), %rdi
leaq 0x158(%rsp), %rax
cmpq %rax, %rdi
je 0x19e2f
movq 0x158(%rsp), %rsi
incq %rsi
callq 0x42a0
movq 0x88(%rsp), %rdi
leaq 0x98(%rsp), %rax
cmpq %rax, %rdi
je 0x19e54
movq 0x98(%rsp), %rsi
incq %rsi
callq 0x42a0
movq 0xa8(%rsp), %rdi
leaq 0xb8(%rsp), %rax
cmpq %rax, %rdi
je 0x19f87
movq 0xb8(%rsp), %rsi
jmp 0x19f7f
jmp 0x19eff
movq %rax, %rbx
jmp 0x19eb4
movq %rax, %rbx
movq %rsp, %rdi
callq 0xbf10
movq 0x168(%rsp), %rdi
leaq 0x178(%rsp), %rax
cmpq %rax, %rdi
je 0x19eb4
movq 0x178(%rsp), %rsi
incq %rsi
callq 0x42a0
movq 0xc8(%rsp), %rdi
leaq 0xd8(%rsp), %rax
cmpq %rax, %rdi
je 0x19ed9
movq 0xd8(%rsp), %rsi
incq %rsi
callq 0x42a0
movq 0xe8(%rsp), %rdi
leaq 0xf8(%rsp), %rax
cmpq %rax, %rdi
je 0x19f87
movq 0xf8(%rsp), %rsi
jmp 0x19f7f
movq %rax, %rbx
jmp 0x19f87
movq %rax, %rbx
jmp 0x19f6b
movq %rax, %rbx
jmp 0x19f46
movq %rax, %rbx
jmp 0x19f21
movq %rax, %rbx
movq %rsp, %rdi
callq 0xbf10
movq 0x108(%rsp), %rdi
leaq 0x118(%rsp), %rax
cmpq %rax, %rdi
je 0x19f46
movq 0x118(%rsp), %rsi
incq %rsi
callq 0x42a0
movq 0x128(%rsp), %rdi
leaq 0x138(%rsp), %rax
cmpq %rax, %rdi
je 0x19f6b
movq 0x138(%rsp), %rsi
incq %rsi
callq 0x42a0
movq 0x68(%rsp), %rdi
leaq 0x78(%rsp), %rax
cmpq %rax, %rdi
je 0x19f87
movq 0x78(%rsp), %rsi
incq %rsi
callq 0x42a0
movq %rbx, %rdi
callq 0x44c0
nop