// File: /workspace/github_cpp_makefile_star2_O3/kelwinfc[P]ci4721-Fernandez-Gyomrey/src/inst.cpp
// Function: opd::to_string[abi:cxx11]()
string opd::to_string() {
    stringstream out; 
    switch (type) {
        case O_SYM:   return data.sym->getName();
        case O_TEMP:  out << data.pint; return "T_" + out.str() ;
        case O_INT:   out << data.pint; return out.str();
        case O_CHAR:  return string(1, data.pchar);
        case O_BOOL:  return (data.pbool ? "true" : "false");
        case O_FLOAT: out << data.pfloat; return out.str();
        case O_LABEL: out << data.pint; return "L_" + out.str();
    }

    // registro de spim
    string r = "";
    if (type & O_SL) {
        stringstream out;
        out << data.spim.lab;
        r += out.str();
    }
    if (type & O_SI) {
        if (type & O_SL && data.spim.imm < 0) {
            r += "+";
        }
        stringstream out;
        out << data.spim.imm;
        r += out.str();
    }
    if (type & O_SR) {
        bool p = r.compare("");
        stringstream out;
        out << data.spim.reg;
        r += (p ? "(" : "") + out.str() + (p ? ")" : "");
    }

    return r.compare("") ? r : "UKNOWN_TYPE";
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x390, %rsp            # imm = 0x390
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x208(%rsp), %rdi
callq 0x6220
movzbl 0x10(%r14), %eax
cmpq $0x6, %rax
ja 0x1d4a7
leaq 0x120ac(%rip), %rcx     # 0x2f4e4
movslq (%rcx,%rax,4), %rax
addq %rcx, %rax
jmpq *%rax
movq (%r14), %rsi
movq %rbx, %rdi
callq 0x17ff4
jmp 0x1d90a
leaq 0x218(%rsp), %rdi
cvtss2sd (%r14), %xmm0
callq 0x64c0
jmp 0x1d475
leaq 0x218(%rsp), %rdi
movl (%r14), %esi
callq 0x6540
leaq 0x220(%rsp), %rsi
movq %rbx, %rdi
callq 0x64b0
jmp 0x1d90a
movsbl (%r14), %edx
leaq 0x10(%rbx), %rax
movq %rax, (%rbx)
movl $0x1, %esi
movq %rbx, %rdi
callq 0x6390
jmp 0x1d90a
leaq 0x30(%rsp), %r12
movq %r12, -0x10(%r12)
leaq 0x11eca(%rip), %rdx     # 0x2f382
leaq 0x20(%rsp), %rdi
movq %rdx, %rsi
callq 0x7008
movb 0x10(%r14), %al
testb $0x8, %al
je 0x1d551
leaq 0x80(%rsp), %rdi
callq 0x6220
leaq 0x90(%rsp), %rdi
movl (%r14), %esi
callq 0x6540
leaq 0x98(%rsp), %rsi
movq %rsp, %rdi
callq 0x64b0
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
leaq 0x20(%rsp), %rdi
callq 0x60f0
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x1d52c
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x6300
movq 0x21a55(%rip), %rsi     # 0x3ef88
leaq 0x80(%rsp), %rdi
callq 0x6250
leaq 0x100(%rsp), %rdi
callq 0x6100
movb 0x10(%r14), %al
testb $0x10, %al
je 0x1d5f6
testb $0x8, %al
je 0x1d575
cmpl $0x0, 0x4(%r14)
jns 0x1d575
leaq 0x10000(%rip), %rsi     # 0x2d56b
leaq 0x20(%rsp), %rdi
callq 0x65b0
leaq 0x80(%rsp), %rdi
callq 0x6220
leaq 0x90(%rsp), %rdi
movl 0x4(%r14), %esi
callq 0x6540
leaq 0x98(%rsp), %rsi
movq %rsp, %rdi
callq 0x64b0
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
leaq 0x20(%rsp), %rdi
callq 0x60f0
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x1d5d1
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x6300
movq 0x219b0(%rip), %rsi     # 0x3ef88
leaq 0x80(%rsp), %rdi
callq 0x6250
leaq 0x100(%rsp), %rdi
callq 0x6100
movb 0x10(%r14), %al
testb $0x20, %al
je 0x1d8aa
leaq 0x11d7d(%rip), %r15     # 0x2f382
leaq 0x20(%rsp), %rdi
movq %r15, %rsi
callq 0x60d0
movl %eax, %ebp
leaq 0x80(%rsp), %rdi
callq 0x6220
leaq 0x90(%rsp), %rdi
movl 0x8(%r14), %esi
callq 0x6540
leaq 0x98(%rsp), %rsi
leaq 0x60(%rsp), %rdi
callq 0x64b0
xorl %r8d, %r8d
testl %ebp, %ebp
setne %r8b
leaq 0xfe9c(%rip), %rcx      # 0x2d4f0
cmoveq %r15, %rcx
leaq 0x60(%rsp), %rdi
xorl %esi, %esi
xorl %edx, %edx
callq 0x6360
leaq 0x50(%rsp), %r14
movq %r14, -0x10(%r14)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x1d7b1
movq %rdx, 0x40(%rsp)
movq (%rcx), %rdx
movq %rdx, 0x50(%rsp)
jmp 0x1d7b8
leaq 0x218(%rsp), %rdi
movl (%r14), %esi
callq 0x6540
leaq 0x220(%rsp), %rsi
leaq 0x80(%rsp), %rdi
callq 0x64b0
leaq 0x11f92(%rip), %rcx     # 0x2f652
leaq 0x80(%rsp), %rdi
movl $0x2, %r8d
xorl %esi, %esi
xorl %edx, %edx
callq 0x6360
jmp 0x1d750
movzbl (%r14), %edx
leaq 0xf920(%rip), %rax      # 0x2d004
leaq 0xfed9(%rip), %rsi      # 0x2d5c4
testq %rdx, %rdx
cmovneq %rax, %rsi
leaq 0x10(%rbx), %rax
movq %rax, (%rbx)
xorq $0x5, %rdx
addq %rsi, %rdx
movq %rbx, %rdi
callq 0x7008
jmp 0x1d90a
leaq 0x218(%rsp), %rdi
movl (%r14), %esi
callq 0x6540
leaq 0x220(%rsp), %rsi
leaq 0x80(%rsp), %rdi
callq 0x64b0
leaq 0x11f1c(%rip), %rcx     # 0x2f655
leaq 0x80(%rsp), %rdi
movl $0x2, %r8d
xorl %esi, %esi
xorl %edx, %edx
callq 0x6360
leaq 0x10(%rbx), %rdx
movq %rdx, (%rbx)
movq (%rax), %rsi
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rsi
je 0x1d772
movq %rsi, (%rbx)
movq (%rcx), %rdx
movq %rdx, 0x10(%rbx)
jmp 0x1d778
movups (%rcx), %xmm0
movups %xmm0, (%rdx)
movq 0x8(%rax), %rdx
movq %rdx, 0x8(%rbx)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
leaq 0x90(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x1d90a
movq 0x90(%rsp), %rsi
jmp 0x1d902
movups (%rcx), %xmm0
movups %xmm0, (%r14)
testl %ebp, %ebp
movq 0x8(%rax), %rdx
leaq 0x40(%rsp), %rdi
movq %rdx, 0x8(%rdi)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
leaq 0xfd1b(%rip), %rax      # 0x2d4f8
cmovneq %rax, %r15
movq %r15, %rsi
callq 0x65b0
leaq 0x10(%rsp), %r15
movq %r15, -0x10(%r15)
movq (%rax), %rdx
movq %rax, %rcx
addq $0x10, %rcx
cmpq %rcx, %rdx
je 0x1d80f
movq %rdx, (%rsp)
movq (%rcx), %rdx
movq %rdx, 0x10(%rsp)
jmp 0x1d816
movups (%rcx), %xmm0
movups %xmm0, (%r15)
movq 0x8(%rax), %rdx
movq %rdx, 0x8(%rsp)
movq %rcx, (%rax)
movq $0x0, 0x8(%rax)
movb $0x0, 0x10(%rax)
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
leaq 0x20(%rsp), %rdi
callq 0x60f0
movq (%rsp), %rdi
cmpq %r15, %rdi
je 0x1d857
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x6300
movq 0x40(%rsp), %rdi
cmpq %r14, %rdi
je 0x1d86e
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x6300
leaq 0x70(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x1d889
movq 0x70(%rsp), %rsi
incq %rsi
callq 0x6300
movq 0x216f8(%rip), %rsi     # 0x3ef88
leaq 0x80(%rsp), %rdi
callq 0x6250
leaq 0x100(%rsp), %rdi
callq 0x6100
leaq 0x11ad1(%rip), %rsi     # 0x2f382
leaq 0x20(%rsp), %rdi
callq 0x60d0
leaq 0x10(%rbx), %rcx
movq %rcx, (%rbx)
testl %eax, %eax
je 0x1d8dd
movq 0x20(%rsp), %rsi
movq 0x28(%rsp), %rdx
addq %rsi, %rdx
movq %rbx, %rdi
callq 0x16c68
jmp 0x1d8f3
leaq 0x11d74(%rip), %rsi     # 0x2f658
leaq 0x11d78(%rip), %rdx     # 0x2f663
movq %rbx, %rdi
callq 0x7008
movq 0x20(%rsp), %rdi
cmpq %r12, %rdi
je 0x1d90a
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x6300
movq 0x21677(%rip), %rsi     # 0x3ef88
leaq 0x208(%rsp), %rdi
callq 0x6250
leaq 0x288(%rsp), %rdi
callq 0x6100
movq %rbx, %rax
addq $0x390, %rsp            # imm = 0x390
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
jmp 0x1d9ea
movq %rax, %rbx
movq (%rsp), %rdi
cmpq %r15, %rdi
je 0x1d961
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x6300
jmp 0x1d961
movq %rax, %rbx
movq 0x40(%rsp), %rdi
cmpq %r14, %rdi
je 0x1d97d
movq 0x50(%rsp), %rsi
incq %rsi
callq 0x6300
jmp 0x1d97d
movq %rax, %rbx
leaq 0x70(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x1d9c5
movq 0x70(%rsp), %rsi
jmp 0x1d9b4
jmp 0x1d9c2
jmp 0x1d99e
jmp 0x1d9c2
jmp 0x1d9c2
jmp 0x1d9ea
jmp 0x1d9c2
movq %rax, %rbx
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x1d9c5
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x6300
jmp 0x1d9c5
jmp 0x1d9ea
jmp 0x1d9c2
movq %rax, %rbx
movq 0x215bc(%rip), %rsi     # 0x3ef88
leaq 0x80(%rsp), %rdi
callq 0x6250
leaq 0x100(%rsp), %rdi
callq 0x6100
jmp 0x1d9ed
jmp 0x1d9ea
movq %rax, %rbx
movq 0x20(%rsp), %rdi
cmpq %r12, %rdi
je 0x1da33
movq 0x30(%rsp), %rsi
incq %rsi
callq 0x6300
jmp 0x1da33
jmp 0x1da08
movq %rax, %rbx
leaq 0x90(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x1da33
movq 0x90(%rsp), %rsi
jmp 0x1d9fc
jmp 0x1da30
jmp 0x1da30
jmp 0x1da30
jmp 0x1da30
jmp 0x1da30
movq %rax, %rbx
movq 0x2154e(%rip), %rsi     # 0x3ef88
leaq 0x208(%rsp), %rdi
callq 0x6250
leaq 0x288(%rsp), %rdi
callq 0x6100
movq %rbx, %rdi
callq 0x6560