LLM4Binary/decompile-bench-makefile huggingface dataset:
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::padC(unsigned int, char)
GStr& GStr::padC(uint len, char c) {
 if (my_data->length>=len) return *this; //no room for padding
 make_unique(); //edit operation ahead
 uint istart=(len-length())/2;
 Data *data = new_data(len);
 if (istart>0)
      ::memset(data->chars, c, istart);
 ::memcpy(&data->chars[istart], my_data->chars, length());
 uint iend=istart+length();
 if (iend<len)
      ::memset(&data->chars[iend],c,len-iend);
 replace_data(data);
 return *this;
 }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
movq 0x20(%rdi), %rax
cmpl %esi, 0x8(%rax)
jae 0x5ab0
movl %edx, %ebp
movl %esi, %r14d
movq %rbx, %rdi
callq 0x46a4
movq 0x20(%rbx), %rax
movl %r14d, %r12d
subl 0x8(%rax), %r12d
movl %r12d, %r13d
shrl %r13d
movl %r14d, %edi
xorl %esi, %esi
callq 0x44d4
movq %rax, %r15
movzbl %bpl, %ebp
cmpl $0x1, %r12d
ja 0x5a57
movl %r13d, %r12d
jmp 0x5a68
leaq 0xc(%r15), %rdi
movl %r13d, %r12d
movl %ebp, %esi
movq %r12, %rdx
callq 0x2190
leaq (%r15,%r12), %rdi
addq $0xc, %rdi
movq 0x20(%rbx), %rsi
movslq 0x8(%rsi), %rdx
addq $0xc, %rsi
callq 0x21e0
movq 0x20(%rbx), %rax
addl 0x8(%rax), %r13d
subl %r13d, %r14d
jbe 0x5aa5
movq %r15, %rax
addq $0xc, %rax
movl %r13d, %edi
addq %rax, %rdi
movl %ebp, %esi
movq %r14, %rdx
callq 0x2190
movq %rbx, %rdi
movq %r15, %rsi
callq 0x46ea
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: operator+(char const*, GStr const&)
GStr operator+(const char *s1, const GStr& s2) {
    const int s1_length = ::strlen(s1);

    if (s1_length == 0)
        return s2;
    else {
        GStr newstring;
        newstring.prep_data(s1_length + s2.length());
        ::memcpy(newstring.chrs(), s1, s1_length);
        ::memcpy(&(newstring.chrs())[s1_length], s2.chars(), s2.length());
        return newstring;
        }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movq %rsi, %rdi
callq 0x2140
movq %rax, %r12
testl %r12d, %r12d
je 0x5b50
leaq 0xc766(%rip), %rax      # 0x12250
movq %rax, 0x20(%rbx)
andq $0x0, (%rbx)
movabsq $0x100000000, %rax      # imm = 0x100000000
movq %rax, 0x8(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rbx)
movq 0x20(%r14), %rax
movl 0x8(%rax), %esi
addl %r12d, %esi
movq %rbx, %rdi
xorl %edx, %edx
callq 0x45d2
movq 0x20(%rbx), %rdi
addq $0xc, %rdi
movslq %r12d, %r12
movq %r15, %rsi
movq %r12, %rdx
callq 0x21e0
movq 0x20(%rbx), %rax
leaq (%rax,%r12), %rdi
addq $0xc, %rdi
movq 0x20(%r14), %rsi
movslq 0x8(%rsi), %rdx
addq $0xc, %rsi
callq 0x21e0
jmp 0x5b5b
movq %rbx, %rdi
movq %r14, %rsi
callq 0x4816
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rax, %r14
movq %rbx, %rdi
callq 0x49aa
movq %r14, %rdi
callq 0x2400
nop
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::operator+(GStr const&) const
GStr GStr::operator+(const GStr& s) const {
    if (length() == 0)
        return s;
    else if (s.length() == 0)
        return *this;
    else {
        GStr newstring;
        newstring.prep_data(length() + s.length());
        ::memcpy(newstring.chrs(), my_data->chars, length());
        ::memcpy(&(newstring.chrs())[length()], s.chars(), s.length());
        return newstring;
        }
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movq 0x20(%rsi), %rax
movl 0x8(%rax), %esi
testl %esi, %esi
je 0x5c12
movq 0x20(%r14), %rax
cmpl $0x0, 0x8(%rax)
je 0x5c1a
leaq 0xc6a8(%rip), %rcx      # 0x12250
movq %rcx, 0x20(%rbx)
andq $0x0, (%rbx)
movabsq $0x100000000, %rcx      # imm = 0x100000000
movq %rcx, 0x8(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rbx)
addl 0x8(%rax), %esi
movq %rbx, %rdi
xorl %edx, %edx
callq 0x45d2
movq 0x20(%rbx), %rdi
addq $0xc, %rdi
movq 0x20(%r15), %rsi
movslq 0x8(%rsi), %rdx
addq $0xc, %rsi
callq 0x21e0
movq 0x20(%rbx), %rax
movq 0x20(%r15), %rcx
movslq 0x8(%rcx), %rcx
leaq (%rax,%rcx), %rdi
addq $0xc, %rdi
movq 0x20(%r14), %rsi
movslq 0x8(%rsi), %rdx
addq $0xc, %rsi
callq 0x21e0
jmp 0x5c25
movq %rbx, %rdi
movq %r14, %rsi
jmp 0x5c20
movq %rbx, %rdi
movq %r15, %rsi
callq 0x4816
movq %rbx, %rax
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %r14
movq %rbx, %rdi
callq 0x49aa
movq %r14, %rdi
callq 0x2400
nop
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::operator+(char const*) const
GStr GStr::operator+(const char *s) const {

    const int s_length = ::strlen(s);

    if (s_length == 0)
        return *this;
    else {
        GStr newstring;
        newstring.prep_data(length() + s_length);
        ::memcpy(newstring.chrs(), my_data->chars, length());
        ::memcpy(&(newstring.chrs())[length()], s, s_length);
        return newstring;
        }
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
pushq %rax
movq %rdx, %r14
movq %rsi, %r15
movq %rdi, %rbx
movq %rdx, %rdi
callq 0x2140
movq %rax, %r12
testl %r12d, %r12d
je 0x5cd5
leaq 0xc5e6(%rip), %rax      # 0x12250
movq %rax, 0x20(%rbx)
andq $0x0, (%rbx)
movabsq $0x100000000, %rax      # imm = 0x100000000
movq %rax, 0x8(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rbx)
movq 0x20(%r15), %rax
movl 0x8(%rax), %esi
addl %r12d, %esi
movq %rbx, %rdi
xorl %edx, %edx
callq 0x45d2
movq 0x20(%rbx), %rdi
addq $0xc, %rdi
movq 0x20(%r15), %rsi
movslq 0x8(%rsi), %rdx
addq $0xc, %rsi
callq 0x21e0
movq 0x20(%rbx), %rax
movq 0x20(%r15), %rcx
movslq 0x8(%rcx), %rcx
leaq (%rax,%rcx), %rdi
addq $0xc, %rdi
movslq %r12d, %rdx
movq %r14, %rsi
callq 0x21e0
jmp 0x5ce0
movq %rbx, %rdi
movq %r15, %rsi
callq 0x4816
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rax, %r14
movq %rbx, %rdi
callq 0x49aa
movq %r14, %rdi
callq 0x2400
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::operator+(int) const
GStr GStr::operator+(const int i) const {
    char buf[20];
    sprintf(buf, "%d", i);
    const int s_length = ::strlen(buf);
    GStr newstring;
    newstring.prep_data(length() + s_length);
    ::memcpy(newstring.chrs(), my_data->chars, length());
    ::memcpy(&(newstring.chrs())[length()], buf, s_length);
    return newstring;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x645f(%rip), %rsi      # 0xc177
movq %rsp, %r15
movq %r15, %rdi
xorl %eax, %eax
callq 0x2080
movq %r15, %rdi
callq 0x2140
leaq 0xc51c(%rip), %rcx      # 0x12250
movq %rcx, 0x20(%rbx)
andq $0x0, (%rbx)
movq %rax, %r15
movabsq $0x100000000, %rax      # imm = 0x100000000
movq %rax, 0x8(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rbx)
movq 0x20(%r14), %rax
movl 0x8(%rax), %esi
addl %r15d, %esi
movq %rbx, %rdi
xorl %edx, %edx
callq 0x45d2
movq 0x20(%rbx), %rdi
addq $0xc, %rdi
movq 0x20(%r14), %rsi
movslq 0x8(%rsi), %rdx
addq $0xc, %rsi
callq 0x21e0
movq 0x20(%rbx), %rax
movq 0x20(%r14), %rcx
movslq 0x8(%rcx), %rcx
leaq (%rax,%rcx), %rdi
addq $0xc, %rdi
movslq %r15d, %rdx
movq %rsp, %rsi
callq 0x21e0
movq %rbx, %rax
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %r14
movq %rbx, %rdi
callq 0x49aa
movq %r14, %rdi
callq 0x2400
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::operator+(char) const
GStr GStr::operator+(const char c) const {
    char buf[4];
    sprintf(buf, "%c", c);
    const int s_length = ::strlen(buf);
    GStr newstring;
    newstring.prep_data(length() + s_length);
    ::memcpy(newstring.chrs(), my_data->chars, length());
    ::memcpy(&(newstring.chrs())[length()], buf, s_length);
    return newstring;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq 0xc(%rsp), %rdi
movb %dl, (%rdi)
movb $0x0, 0x1(%rdi)
callq 0x2140
leaq 0xc46a(%rip), %rcx      # 0x12250
movq %rcx, 0x20(%rbx)
andq $0x0, (%rbx)
movq %rax, %r15
movabsq $0x100000000, %rax      # imm = 0x100000000
movq %rax, 0x8(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rbx)
movq 0x20(%r14), %rax
movl 0x8(%rax), %esi
addl %r15d, %esi
movq %rbx, %rdi
xorl %edx, %edx
callq 0x45d2
movq 0x20(%rbx), %rdi
addq $0xc, %rdi
movq 0x20(%r14), %rsi
movslq 0x8(%rsi), %rdx
addq $0xc, %rsi
callq 0x21e0
movq 0x20(%rbx), %rax
movq 0x20(%r14), %rcx
movslq 0x8(%rcx), %rcx
leaq (%rax,%rcx), %rdi
addq $0xc, %rdi
movslq %r15d, %rdx
leaq 0xc(%rsp), %rsi
callq 0x21e0
movq %rbx, %rax
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %r14
movq %rbx, %rdi
callq 0x49aa
movq %r14, %rdi
callq 0x2400
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::operator+(double) const
GStr GStr::operator+(const double f) const {
    char buf[30];
    sprintf(buf, "%f", f);
    const int s_length = ::strlen(buf);
    GStr newstring;
    newstring.prep_data(length() + s_length);
    ::memcpy(newstring.chrs(), my_data->chars, length());
    ::memcpy(&(newstring.chrs())[length()], buf, s_length);
    return newstring;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x20, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq 0x62f0(%rip), %rsi      # 0xc17a
movq %rsp, %r15
movq %r15, %rdi
movb $0x1, %al
callq 0x2080
movq %r15, %rdi
callq 0x2140
leaq 0xc3aa(%rip), %rcx      # 0x12250
movq %rcx, 0x20(%rbx)
andq $0x0, (%rbx)
movq %rax, %r15
movabsq $0x100000000, %rax      # imm = 0x100000000
movq %rax, 0x8(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rbx)
movq 0x20(%r14), %rax
movl 0x8(%rax), %esi
addl %r15d, %esi
movq %rbx, %rdi
xorl %edx, %edx
callq 0x45d2
movq 0x20(%rbx), %rdi
addq $0xc, %rdi
movq 0x20(%r14), %rsi
movslq 0x8(%rsi), %rdx
addq $0xc, %rsi
callq 0x21e0
movq 0x20(%rbx), %rax
movq 0x20(%r14), %rcx
movslq 0x8(%rcx), %rcx
leaq (%rax,%rcx), %rdi
addq $0xc, %rdi
movslq %r15d, %rdx
movq %rsp, %rsi
callq 0x21e0
movq %rbx, %rax
addq $0x20, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %r14
movq %rbx, %rdi
callq 0x49aa
movq %r14, %rdi
callq 0x2400
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::is_space() const
bool GStr::is_space() const {

    if (my_data == &null_data)
        return false;

    for (const char *p = my_data->chars; *p; p++)
        if (!isspace(*p))
            return false;

    return true;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq 0x20(%rdi), %r14
leaq 0xc30f(%rip), %rax      # 0x12250
cmpq %rax, %r14
je 0x5f63
addq $0xc, %r14
movsbl (%r14), %edi
testl %edi, %edi
sete %bl
je 0x5f65
callq 0x2050
incq %r14
testl %eax, %eax
jne 0x5f4a
jmp 0x5f65
xorl %ebx, %ebx
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::substr(int, int) const
GStr GStr::substr(int idx, int len) const {
    // A negative idx specifies an idx from the right of the string.
    if (idx < 0)
        idx += length();
    else if (idx>=length()) {
             len=0;
             idx=length();
             }
    if (len) {
      // A length of -1 specifies the rest of the string.
      if (len < 0  || len>length()-idx)
        len = length() - idx;
      if (idx<0 || idx>=length() || len<0 )
        invalid_args_error("substr()");
    }

    GStr newstring;
    if (len) {
      newstring.prep_data(len);
      ::memcpy(newstring.chrs(), &my_data->chars[idx], len);
    }
    return newstring;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %rbx
movq 0x20(%rsi), %rax
movl 0x8(%rax), %eax
testl %edx, %edx
js 0x5f95
cmpl %ebp, %eax
jg 0x5f97
xorl %r15d, %r15d
movl %eax, %ebp
jmp 0x5fd5
addl %eax, %ebp
testl %ecx, %ecx
je 0x5fd2
movl %eax, %edx
subl %ebp, %edx
cmpl %ecx, %edx
movl %ecx, %r15d
cmovll %edx, %r15d
testl %ecx, %ecx
cmovsl %edx, %r15d
testl %ebp, %ebp
js 0x5fc4
cmpl %ebp, %eax
setle %al
testl %r15d, %r15d
sets %cl
orb %al, %cl
cmpb $0x1, %cl
jne 0x5fd5
leaq 0x61c4(%rip), %rdi      # 0xc18f
callq 0x604c
jmp 0x5fd5
xorl %r15d, %r15d
leaq 0xc274(%rip), %rax      # 0x12250
movq %rax, 0x20(%rbx)
andq $0x0, (%rbx)
movabsq $0x100000000, %rax      # imm = 0x100000000
movq %rax, 0x8(%rbx)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rbx)
testl %r15d, %r15d
je 0x602a
movq %rbx, %rdi
movl %r15d, %esi
xorl %edx, %edx
callq 0x45d2
movq 0x20(%rbx), %rdi
addq $0xc, %rdi
movq 0x20(%r14), %rax
movslq %ebp, %rcx
leaq (%rax,%rcx), %rsi
addq $0xc, %rsi
movslq %r15d, %rdx
callq 0x21e0
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
movq %rax, %r14
movq %rbx, %rdi
callq 0x49aa
movq %r14, %rdi
callq 0x2400
nop
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::reverse()
GStr& GStr::reverse() {
  make_unique();
  int l=0;
  int r=my_data->length-1;
  char c;
  while (l<r) {
     c=my_data->chars[l];
     my_data->chars[l]=my_data->chars[r];
     my_data->chars[r]=c;
     l++;r--;
     }
  return *this;
}

// Assembly:
pushq %rbx
movq %rdi, %rbx
callq 0x46a4
movq 0x20(%rbx), %rax
movl 0x8(%rax), %eax
decl %eax
xorl %ecx, %ecx
cltq
cmpq %rax, %rcx
jge 0x609c
movq 0x20(%rbx), %rdx
movb 0xc(%rdx,%rcx), %sil
movb 0xc(%rdx,%rax), %dil
movb %dil, 0xc(%rdx,%rcx)
movq 0x20(%rbx), %rdx
movb %sil, 0xc(%rdx,%rax)
incq %rcx
decl %eax
jmp 0x6072
movq %rbx, %rax
popq %rbx
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::tr(char const*, char const*)
GStr&  GStr::tr(const char *rfrom, const char* rto) {
 if (length() == 0 || rfrom==NULL || strlen(rfrom)==0)
        return *this;
 unsigned int l=strlen(rfrom);
 if (rto!=NULL && rto[0]==0) rto=NULL;
 if (rto!=NULL && strlen(rto)!=l)
      invalid_args_error("tr()");
 make_unique(); //edit operation ahead

 if (rto==NULL) { //delete all characters
   Data *data = new_data(length());
   char* s = my_data->chars;
   char* p=NULL;
   char* dest = data->chars;
   do {
      if ((p=strpbrk(s,rfrom))!=NULL) {
        memcpy(dest,s,p-s);
        dest+=p-s;
        s=p+1;
        }
       else {
        strcpy(dest, s);
        dest+=strlen(s);
        }
      } while (p!=NULL);
   (*dest)='\0';
   data->length=strlen(data->chars);
   replace_data(data);
   }
  else { //char substitution case - easier!
   const char* p=NULL;
   for (int i=0; i<length(); i++) {
    if ((p=strchr(rfrom, my_data->chars[i]))!=NULL)
         my_data->chars[i]=rto[p-rfrom];
    }
   }
 return *this;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x18, %rsp
movq %rdi, %rbx
testq %rsi, %rsi
je 0x61e2
movq 0x20(%rbx), %rax
cmpl $0x0, 0x8(%rax)
je 0x61e2
movq %rdx, %r15
movq %rsi, %r14
movq %rsi, %rdi
callq 0x2140
testq %rax, %rax
je 0x61e2
movb $0x1, %bpl
testq %r15, %r15
je 0x6112
cmpb $0x0, (%r15)
je 0x6112
movq %rax, %r12
movq %r15, %rdi
callq 0x2140
movl %r12d, %ecx
cmpq %rcx, %rax
je 0x610e
leaq 0x608a(%rip), %rdi      # 0xc193
callq 0x604c
xorl %ebp, %ebp
jmp 0x6115
xorl %r15d, %r15d
movq %rbx, %rdi
callq 0x46a4
testb %bpl, %bpl
je 0x617b
movq 0x20(%rbx), %rax
movl 0x8(%rax), %edi
xorl %esi, %esi
callq 0x44d4
movq %rax, %r13
movq 0x20(%rbx), %r15
addq $0xc, %r15
movq %rax, 0x10(%rsp)
addq $0xc, %r13
movq %r13, 0x8(%rsp)
movq %r15, %rdi
movq %r14, %rsi
callq 0x23f0
testq %rax, %rax
je 0x61af
movq %rax, %rbp
movq %rax, %r12
subq %r15, %r12
movq %r13, %rdi
movq %r15, %rsi
movq %r12, %rdx
callq 0x21e0
incq %rbp
addq %r12, %r13
movq %rbp, %r15
jmp 0x6149
xorl %r12d, %r12d
movq 0x20(%rbx), %r13
movslq 0x8(%r13), %rax
cmpq %rax, %r12
jge 0x61e2
movsbl 0xc(%r13,%r12), %esi
movq %r14, %rdi
callq 0x2100
testq %rax, %rax
je 0x61aa
subq %r14, %rax
movb (%r15,%rax), %al
movb %al, 0xc(%r13,%r12)
incq %r12
jmp 0x617e
movq %r13, %rdi
movq %r15, %rsi
callq 0x2220
movq %r15, %rdi
callq 0x2140
movb $0x0, (%r13,%rax)
movq 0x8(%rsp), %rdi
callq 0x2140
movq 0x10(%rsp), %rsi
movl %eax, 0x8(%rsi)
movq %rbx, %rdi
callq 0x46ea
movq %rbx, %rax
addq $0x18, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::cut(int, int)
GStr&  GStr::cut(int idx, int len) {

    if (len == 0)
        return *this;
    make_unique(); //edit operation ahead

    // A negative idx specifies an idx from the right of the string,
    // so the left part will be cut out
    if (idx < 0)
        idx += length();

    // A length of -1 specifies the rest of the string.
    if (len == -1)
        len = length() - idx;

    if (idx<0 || idx>=length() || len<0 || len>length()-idx)
        invalid_args_error("cut()");

    Data *data = new_data(length() - len);
    if (idx > 0)
        ::memcpy(data->chars, my_data->chars, idx);
    ::strcpy(&data->chars[idx], &my_data->chars[idx+len]);
    replace_data(data);

    return *this;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
testl %edx, %edx
je 0x6494
movl %edx, %r14d
movl %esi, %ebp
movq %rbx, %rdi
callq 0x46a4
testl %ebp, %ebp
jns 0x6404
movq 0x20(%rbx), %rax
addl 0x8(%rax), %ebp
cmpl $-0x1, %r14d
jne 0x6415
movq 0x20(%rbx), %rax
movl 0x8(%rax), %r14d
subl %ebp, %r14d
testl %ebp, %ebp
js 0x6430
movq 0x20(%rbx), %rax
movl 0x8(%rax), %edi
movl %edi, %eax
subl %ebp, %eax
jle 0x6430
testl %r14d, %r14d
js 0x6430
cmpl %eax, %r14d
jle 0x6443
leaq 0x5d61(%rip), %rdi      # 0xc198
callq 0x604c
movq 0x20(%rbx), %rax
movl 0x8(%rax), %edi
subl %r14d, %edi
xorl %esi, %esi
callq 0x44d4
movq %rax, %r15
testl %ebp, %ebp
jle 0x6467
leaq 0xc(%r15), %rdi
movq 0x20(%rbx), %rsi
addq $0xc, %rsi
movl %ebp, %edx
callq 0x21e0
movslq %ebp, %rax
leaq (%r15,%rax), %rdi
addq $0xc, %rdi
movq 0x20(%rbx), %rax
addl %ebp, %r14d
movslq %r14d, %rcx
leaq (%rax,%rcx), %rsi
addq $0xc, %rsi
callq 0x2220
movq %rbx, %rdi
movq %r15, %rsi
callq 0x46ea
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::paste(GStr const&, int, int)
GStr&  GStr::paste(const GStr& s, int idx, int len) {
    // A negative idx specifies an idx from the right of the string.
    if (idx < 0)
        idx += length();
    make_unique(); //edit operation ahead

    // A length of -1 specifies the rest of the string.
    if (len == -1)
        len = length() - idx;

    if (idx<0 || idx>=length() || len<0 || len>length()-idx)
        invalid_args_error("replace()");

    if (len == s.length() && my_data->ref_count == 1)
        ::memcpy(&chrs()[idx], s.chars(), len);
    else {
        Data *data = new_data(length() - len + s.length());
        if (idx > 0)
            ::memcpy(data->chars, my_data->chars, idx);
        if (s.length() > 0)
            ::memcpy(&data->chars[idx], s.chars(), s.length());
        ::strcpy(&data->chars[idx+s.length()], &my_data->chars[idx+len]);
        replace_data(data);
    }

    return *this;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %ecx, %ebp
movl %edx, %r14d
movq %rsi, %r15
movq %rdi, %rbx
testl %edx, %edx
jns 0x64c1
movq 0x20(%rbx), %rax
addl 0x8(%rax), %r14d
movq %rbx, %rdi
callq 0x46a4
cmpl $-0x1, %ebp
jne 0x64d8
movq 0x20(%rbx), %rax
movl 0x8(%rax), %ebp
subl %r14d, %ebp
testl %r14d, %r14d
js 0x64f1
movq 0x20(%rbx), %rax
movl 0x8(%rax), %eax
subl %r14d, %eax
jle 0x64f1
testl %ebp, %ebp
js 0x64f1
cmpl %eax, %ebp
jle 0x64fd
leaq 0x5ca6(%rip), %rdi      # 0xc19e
callq 0x604c
movq 0x20(%r15), %rsi
movl 0x8(%rsi), %edi
movq 0x20(%rbx), %rax
subl %ebp, %edi
jne 0x652a
cmpl $0x1, (%rax)
jne 0x652a
movslq %r14d, %rcx
leaq (%rax,%rcx), %rdi
addq $0xc, %rdi
addq $0xc, %rsi
movslq %ebp, %rdx
callq 0x21e0
jmp 0x65a9
addl 0x8(%rax), %edi
xorl %esi, %esi
callq 0x44d4
movq %rax, %r12
testl %r14d, %r14d
jle 0x6551
leaq 0xc(%r12), %rdi
movq 0x20(%rbx), %rsi
addq $0xc, %rsi
movl %r14d, %edx
callq 0x21e0
movq 0x20(%r15), %rsi
movslq 0x8(%rsi), %rdx
testq %rdx, %rdx
jle 0x6579
movslq %r14d, %rax
leaq (%r12,%rax), %rdi
addq $0xc, %rdi
addq $0xc, %rsi
callq 0x21e0
movq 0x20(%r15), %rax
movl 0x8(%rax), %edx
addl %r14d, %edx
movslq %edx, %rax
leaq (%r12,%rax), %rdi
addq $0xc, %rdi
movq 0x20(%rbx), %rax
addl %r14d, %ebp
movslq %ebp, %rcx
leaq (%rax,%rcx), %rsi
addq $0xc, %rsi
callq 0x2220
movq %rbx, %rdi
movq %r12, %rsi
callq 0x46ea
movq %rbx, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::paste(char const*, int, int)
GStr& GStr::paste(const char *s, int idx, int len) {

    // A negative idx specifies an idx from the right of the string.
    make_unique(); //edit operation ahead
    if (idx < 0)
        idx += length();

    // A length of -1 specifies the rest of the string.
    if (len == -1)
        len = length() - idx;

    if (idx<0 || idx>=length() || len<0 || len>length()-idx)
        invalid_args_error("replace()");

    const int s_length = ::strlen(s);

    if (len == s_length && my_data->ref_count == 1)
        ::memcpy(&chrs()[idx], s, len);
    else {
        Data *data = new_data(length() - len + s_length);
        if (idx > 0)
            ::memcpy(data->chars, my_data->chars, idx);
        if (s_length > 0)
            ::memcpy(&data->chars[idx], s, s_length);
        ::strcpy(&data->chars[idx+s_length], &my_data->chars[idx+len]);
        replace_data(data);
    }

    return *this;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %ecx, %ebp
movl %edx, %r14d
movq %rsi, %r15
movq %rdi, %rbx
callq 0x46a4
testl %r14d, %r14d
jns 0x65de
movq 0x20(%rbx), %rax
addl 0x8(%rax), %r14d
cmpl $-0x1, %ebp
jne 0x65ed
movq 0x20(%rbx), %rax
movl 0x8(%rax), %ebp
subl %r14d, %ebp
testl %r14d, %r14d
js 0x6606
movq 0x20(%rbx), %rax
movl 0x8(%rax), %eax
subl %r14d, %eax
jle 0x6606
testl %ebp, %ebp
js 0x6606
cmpl %eax, %ebp
jle 0x6612
leaq 0x5b91(%rip), %rdi      # 0xc19e
callq 0x604c
movq %r15, %rdi
callq 0x2140
movq %rax, %r12
movl %r12d, %edi
movq 0x20(%rbx), %rax
subl %ebp, %edi
jne 0x6645
cmpl $0x1, (%rax)
jne 0x6645
movslq %r14d, %rcx
leaq (%rax,%rcx), %rdi
addq $0xc, %rdi
movslq %ebp, %rdx
movq %r15, %rsi
callq 0x21e0
jmp 0x66bc
addl 0x8(%rax), %edi
xorl %esi, %esi
callq 0x44d4
movq %rax, %r13
testl %r14d, %r14d
jle 0x666b
leaq 0xc(%r13), %rdi
movq 0x20(%rbx), %rsi
addq $0xc, %rsi
movl %r14d, %edx
callq 0x21e0
testl %r12d, %r12d
jle 0x668c
movslq %r14d, %rax
leaq (%rax,%r13), %rdi
addq $0xc, %rdi
movl %r12d, %edx
andl $0x7fffffff, %edx       # imm = 0x7FFFFFFF
movq %r15, %rsi
callq 0x21e0
leal (%r14,%r12), %eax
cltq
leaq (%rax,%r13), %rdi
addq $0xc, %rdi
movq 0x20(%rbx), %rax
addl %r14d, %ebp
movslq %ebp, %rcx
leaq (%rax,%rcx), %rsi
addq $0xc, %rsi
callq 0x2220
movq %rbx, %rdi
movq %r13, %rsi
callq 0x46ea
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::insert(GStr const&, int)
GStr& GStr::insert(const GStr& s, int idx) {
    make_unique(); //edit operation ahead

    // A negative idx specifies an idx from the right of the string.
    if (idx < 0)
        idx += length();

    if (idx < 0 || idx >= length())
        invalid_index_error("insert()");

    if (s.length() > 0) {
        Data *data = new_data(length() + s.length());
        if (idx > 0)
            ::memcpy(data->chars, my_data->chars, idx);
        ::memcpy(&data->chars[idx], s.chars(), s.length());
        ::strcpy(&data->chars[idx+s.length()], &my_data->chars[idx]);
        replace_data(data);
    }

    return *this;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %rbx
callq 0x46a4
movq 0x20(%rbx), %rax
movl 0x8(%rax), %eax
testl %ebp, %ebp
jns 0x66f2
addl %eax, %ebp
js 0x66f6
cmpl %eax, %ebp
jl 0x6702
leaq 0x5aab(%rip), %rdi      # 0xc1a8
callq 0x4a30
movq 0x20(%r14), %rax
movl 0x8(%rax), %edi
testl %edi, %edi
jle 0x6780
movq 0x20(%rbx), %rax
addl 0x8(%rax), %edi
xorl %esi, %esi
callq 0x44d4
movq %rax, %r15
testl %ebp, %ebp
jle 0x6735
leaq 0xc(%r15), %rdi
movq 0x20(%rbx), %rsi
addq $0xc, %rsi
movl %ebp, %edx
callq 0x21e0
movslq %ebp, %r12
leaq (%r15,%r12), %rdi
addq $0xc, %rdi
movq 0x20(%r14), %rsi
movslq 0x8(%rsi), %rdx
addq $0xc, %rsi
callq 0x21e0
movq 0x20(%r14), %rax
movslq 0x8(%rax), %rax
addq %r12, %rax
leaq (%r15,%rax), %rdi
addq $0xc, %rdi
movq 0x20(%rbx), %rax
leaq (%rax,%r12), %rsi
addq $0xc, %rsi
callq 0x2220
movq %rbx, %rdi
movq %r15, %rsi
callq 0x46ea
movq %rbx, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::insert(char const*, int)
GStr& GStr::insert(const char *s, int idx) {
    // A negative idx specifies an idx from the right of the string.
    make_unique(); //edit operation ahead
    if (idx < 0)
        idx += length();

    if (idx < 0 || idx >= length())
        invalid_index_error("insert()");

    const int s_length = ::strlen(s);

    if (s_length > 0) {
        Data *data = new_data(length() + s_length);
        if (idx > 0)
            ::memcpy(data->chars, my_data->chars, idx);
        ::memcpy(&data->chars[idx], s, s_length);
        ::strcpy(&data->chars[idx+s_length], &my_data->chars[idx]);
        replace_data(data);
    }

    return *this;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movl %edx, %r14d
movq %rsi, %r15
movq %rdi, %rbx
callq 0x46a4
movq 0x20(%rbx), %rax
movl 0x8(%rax), %eax
testl %r14d, %r14d
jns 0x67b6
addl %eax, %r14d
js 0x67bb
cmpl %eax, %r14d
jl 0x67c7
leaq 0x59e6(%rip), %rdi      # 0xc1a8
callq 0x4a30
movq %r15, %rdi
callq 0x2140
movq %rax, %r12
testl %r12d, %r12d
jle 0x684d
movq 0x20(%rbx), %rax
movl 0x8(%rax), %edi
addl %r12d, %edi
xorl %esi, %esi
callq 0x44d4
movq %rax, %r13
testl %r14d, %r14d
jle 0x6804
leaq 0xc(%r13), %rdi
movq 0x20(%rbx), %rsi
addq $0xc, %rsi
movl %r14d, %edx
callq 0x21e0
movslq %r14d, %rbp
leaq 0xc(,%rbp), %rdi
addq %r13, %rdi
movl %r12d, %edx
andl $0x7fffffff, %edx       # imm = 0x7FFFFFFF
movq %r15, %rsi
callq 0x21e0
leal (%r12,%r14), %eax
cltq
leaq (%rax,%r13), %rdi
addq $0xc, %rdi
movq 0x20(%rbx), %rax
leaq (%rax,%rbp), %rsi
addq $0xc, %rsi
callq 0x2220
movq %rbx, %rdi
movq %r13, %rsi
callq 0x46ea
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::append(char)
GStr& GStr::append(char c) {
  make_unique(); //edit operation ahead
  uint newlen=my_data->length+1;
  if (my_data->cap==0) {
    prep_data(1, 6);
    my_data->chars[0]=c;
    return *this;
  }
  if (newlen>my_data->cap) {
	  //not enough room to append this char
	  GREALLOC(my_data, sizeof(Data)+newlen);
	  my_data->cap=newlen;
  }
  my_data->chars[my_data->length]=c;
  my_data->length++;
  my_data->chars[my_data->length]='\0';
  return *this;
 }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %esi, %ebp
movq %rdi, %rbx
callq 0x46a4
movq 0x20(%rbx), %rax
movl 0x4(%rax), %edx
testl %edx, %edx
je 0x68d0
leaq 0x20(%rbx), %r14
movl 0x8(%rax), %ecx
leal 0x1(%rcx), %r15d
cmpl %edx, %r15d
jbe 0x68b7
movl %r15d, %esi
addq $0x10, %rsi
movq %r14, %rdi
callq 0x43e9
testb %al, %al
jne 0x68ad
leaq 0x577a(%rip), %rdi      # 0xc020
xorl %eax, %eax
callq 0x25ca
movq (%r14), %rax
movl %r15d, 0x4(%rax)
movl 0x8(%rax), %ecx
movl %ecx, %ecx
movb %bpl, 0xc(%rax,%rcx)
movq (%r14), %rax
movl 0x8(%rax), %ecx
incl %ecx
movl %ecx, 0x8(%rax)
movb $0x0, 0xc(%rax,%rcx)
jmp 0x68e6
pushq $0x1
popq %rsi
pushq $0x6
popq %rdx
movq %rbx, %rdi
callq 0x45d2
movq 0x20(%rbx), %rax
movb %bpl, 0xc(%rax)
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::appendQuoted(char const*, char, bool)
GStr& GStr::appendQuoted(const char* s, char q, bool onlyIfSpaced) {
	if (onlyIfSpaced) {
		if (strpbrk(s, "\t ")==NULL)
			return this->append(s);
	}
	char qend=q;
	if (q=='[' || q=='{' || q=='<')
		qend=q+2;
	else if (q=='(')
		qend=')';
	this->append(q);
	this->append(s);
	this->append(qend);
	return *this;
}

// Assembly:
pushq %rbp
pushq %r14
pushq %rbx
movl %edx, %ebp
movq %rsi, %r14
movq %rdi, %rbx
testl %ecx, %ecx
je 0x6918
leaq 0x58a6(%rip), %rsi      # 0xc1b1
movq %r14, %rdi
callq 0x23f0
testq %rax, %rax
je 0x6969
movsbl %bpl, %esi
leal -0x3c(%rsi), %eax
cmpl $0x3f, %eax
ja 0x693a
movabsq $-0x7fffffff7fffffff, %rcx # imm = 0x8000000080000001
btq %rax, %rcx
jae 0x693a
addb $0x2, %bpl
jmp 0x6942
cmpl $0x28, %esi
jne 0x6942
movb $0x29, %bpl
movq %rbx, %rdi
callq 0x6860
movq %rbx, %rdi
movq %r14, %rsi
callq 0x4ed4
movsbl %bpl, %esi
movq %rbx, %rdi
callq 0x6860
movq %rbx, %rax
popq %rbx
popq %r14
popq %rbp
retq
movq %rbx, %rdi
movq %r14, %rsi
callq 0x4ed4
jmp 0x6961
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::append(char const*, int)
GStr& GStr::append(const char* s, int len) {
  make_unique(); //edit operation ahead
  //uint len=::strlen(s);
  uint newlen=len+my_data->length;
  if (newlen<=my_data->length) return *this;
  if (my_data->length==0 && my_data->cap<newlen) {
    prep_data(len,4);
    ::strncpy(my_data->chars, s, len);
    return *this;
   }
  if (newlen>=my_data->cap) {
	  //not enough room to append these chars
	  GREALLOC(my_data, sizeof(Data)+newlen+1);
	  my_data->cap=newlen+1;
  }
  //strncpy(my_data->chars+my_data->length, s, len);
  newlen=my_data->length;
  for (int i=0;s[i]!='\0' && i<len;++i) {
	my_data->chars[my_data->length+i]=s[i];
	++newlen;
  }
  my_data->length=newlen;
  my_data->chars[newlen]='\0';
  return *this;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movl %edx, %r15d
movq %rsi, %r14
movq %rdi, %rbx
callq 0x46a4
movq 0x20(%rbx), %rcx
movl 0x8(%rcx), %eax
leal (%rax,%r15), %ebp
cmpl %eax, %ebp
jbe 0x6a3f
testl %eax, %eax
sete %dl
movl 0x4(%rcx), %ecx
cmpl %ebp, %ecx
setb %sil
andb %dl, %sil
cmpb $0x1, %sil
jne 0x69d9
pushq $0x4
popq %rdx
movq %rbx, %rdi
movl %r15d, %esi
callq 0x45d2
movq 0x20(%rbx), %rdi
addq $0xc, %rdi
movslq %r15d, %rdx
movq %r14, %rsi
callq 0x2180
jmp 0x6a3f
leaq 0x20(%rbx), %r12
cmpl %ecx, %ebp
jb 0x6a0d
movl %ebp, %esi
addq $0x11, %rsi
movq %r12, %rdi
callq 0x43e9
testb %al, %al
jne 0x6a01
leaq 0x5626(%rip), %rdi      # 0xc020
xorl %eax, %eax
callq 0x25ca
incl %ebp
movq (%r12), %rax
movl %ebp, 0x4(%rax)
movl 0x8(%rax), %eax
movslq %r15d, %rdx
xorl %ecx, %ecx
movq (%r12), %rsi
cmpq %rdx, %rcx
jge 0x6a35
movb (%r14,%rcx), %dil
testb %dil, %dil
je 0x6a35
movl 0x8(%rsi), %r8d
addl %ecx, %r8d
movb %dil, 0xc(%rsi,%r8)
incq %rcx
jmp 0x6a12
addl %ecx, %eax
movl %eax, 0x8(%rsi)
movb $0x0, 0xc(%rsi,%rax)
movq %rbx, %rax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::appendmem(char const*, int)
GStr& GStr::appendmem(const char* m, int len) {
  if (len<=0) return *this;
  make_unique(); //edit operation ahead
  uint newlen=len+my_data->length;
  //if (newlength<=my_data->length) return *this;
  if (my_data->length==0) {
    prep_data(len);
    ::memcpy(my_data->chars, m, len);
    return *this;
   }
  //faster solution with realloc
  if (newlen>=my_data->cap) {
	  //not enough room to append these chars
	  GREALLOC(my_data, sizeof(Data)+newlen+1);
	  my_data->cap=newlen+1;
  }
  ::memcpy(my_data->chars + my_data->length, m, len);
  my_data->length=newlen;
  my_data->chars[newlen]='\0';
  return *this;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
movq %rdi, %rbx
testl %edx, %edx
jle 0x6afc
movl %edx, %r15d
movq %rsi, %r14
movq %rbx, %rdi
callq 0x46a4
movq 0x20(%rbx), %rax
movl 0x8(%rax), %ecx
testl %ecx, %ecx
je 0x6adc
leaq 0x20(%rbx), %r12
leal (%rcx,%r15), %r13d
movl %r13d, %ebp
cmpl 0x4(%rax), %r13d
jb 0x6ab8
leaq 0x11(%rbp), %rsi
movq %r12, %rdi
callq 0x43e9
testb %al, %al
jne 0x6aaa
leaq 0x557d(%rip), %rdi      # 0xc020
xorl %eax, %eax
callq 0x25ca
leal 0x1(%r13), %ecx
movq (%r12), %rax
movl %ecx, 0x4(%rax)
movl 0x8(%rax), %ecx
movl %ecx, %ecx
leaq (%rax,%rcx), %rdi
addq $0xc, %rdi
movl %r15d, %edx
movq %r14, %rsi
callq 0x21e0
movq (%r12), %rax
movl %r13d, 0x8(%rax)
movb $0x0, 0xc(%rax,%rbp)
jmp 0x6afc
movq %rbx, %rdi
movl %r15d, %esi
xorl %edx, %edx
callq 0x45d2
movq 0x20(%rbx), %rdi
addq $0xc, %rdi
movl %r15d, %edx
movq %r14, %rsi
callq 0x21e0
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::upper()
GStr& GStr::upper() {
  make_unique(); //edit operation ahead
  for (char *p = chrs(); *p; p++)
            *p = (char) toupper(*p);

    return *this;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
callq 0x46a4
movq 0x20(%rbx), %r14
addq $0xc, %r14
movsbl (%r14), %edi
testl %edi, %edi
je 0x6b47
callq 0x2430
movb %al, (%r14)
incq %r14
jmp 0x6b32
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::lower()
GStr& GStr::lower() {
    make_unique();

    for (char *p = chrs(); *p; p++)
          *p = (char) tolower(*p);

    return *this;
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %rbx
callq 0x46a4
movq 0x20(%rbx), %r14
addq $0xc, %r14
movsbl (%r14), %edi
testl %edi, %edi
je 0x6b7b
callq 0x2380
movb %al, (%r14)
incq %r14
jmp 0x6b66
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::rindex(char, int) const
int GStr::rindex(char c, int end_index) const {
    if (c == 0 || length()==0 || end_index>=length()) return -1;
    if (end_index<0) end_index=my_data->length-1;
    for (int i=end_index;i>=0;i--) {
      if (my_data->chars[i]==c) return i;
      }
    return -1;
}

// Assembly:
pushq $-0x1
popq %rax
testb %sil, %sil
je 0x6bc0
movq 0x20(%rdi), %rdi
movl 0x8(%rdi), %ecx
testl %ecx, %ecx
sete %r8b
cmpl %edx, %ecx
setle %r9b
orb %r8b, %r9b
jne 0x6bc0
decl %ecx
testl %edx, %edx
cmovnsl %edx, %ecx
testl %ecx, %ecx
js 0x6bc0
movl %ecx, %edx
cmpb %sil, 0xc(%rdi,%rdx)
je 0x6bbe
decl %ecx
jmp 0x6bad
movl %ecx, %eax
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::rindex(char const*, int) const
int GStr::rindex(const char* str, int end_index) const {
    if (str==NULL || *str == '\0' || length()==0 || end_index>=length())
        return -1;
    int slen=strlen(str);
    if (end_index<0) end_index=my_data->length-1;
    //end_index is the index of the right-side boundary
    //the scanning starts at the end
    if (end_index>=0 && end_index<slen-1) return -1;
    for (int i=end_index-slen+1;i>=0;i--) {
       if (memcmp((void*)(my_data->chars+i),(void*)str, slen)==0)
           return i;
       }
    return -1;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
pushq %rax
pushq $-0x1
popq %rbx
testq %rsi, %rsi
je 0x6c4a
movq %rsi, %r14
cmpb $0x0, (%rsi)
je 0x6c4a
movl %edx, %ebp
movq 0x20(%rdi), %r13
movl 0x8(%r13), %r12d
testl %r12d, %r12d
sete %al
cmpl %edx, %r12d
setle %cl
orb %al, %cl
jne 0x6c4a
movq %r14, %rdi
callq 0x2140
decl %r12d
testl %ebp, %ebp
cmovnsl %ebp, %r12d
testl %r12d, %r12d
setns %cl
leal -0x1(%rax), %edx
cmpl %edx, %r12d
setl %dl
testb %dl, %cl
jne 0x6c4a
subl %eax, %r12d
incl %r12d
addq $0xc, %r13
movslq %eax, %r15
testl %r12d, %r12d
js 0x6c4a
movl %r12d, %edi
addq %r13, %rdi
movq %r14, %rsi
movq %r15, %rdx
callq 0x2260
testl %eax, %eax
je 0x6c47
decl %r12d
jmp 0x6c28
movl %r12d, %ebx
movl %ebx, %eax
addq $0x8, %rsp
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::split(char const*)
GStr GStr::split(const char* delim) {
           /* splits "this" in two parts, at the first (left)
                 encounter of delim:
                 1st would stay in "this",
                 2nd part will be returned
                 as a new string!
           */
 GStr result;
 int i=index(delim);
 if (i>=0){
      result=substr(i+strlen(delim));
      cut(i);
      return result;
      }
 return result;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdx, %r12
movq %rsi, %r14
movq %rdi, %rbx
leaq 0xb5d9(%rip), %rax      # 0x12250
movq %rax, 0x20(%rdi)
andq $0x0, (%rdi)
movabsq $0x100000000, %rax      # imm = 0x100000000
movq %rax, 0x8(%rdi)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rdi)
movq %rsi, %rdi
movq %rdx, %rsi
xorl %edx, %edx
callq 0x50a8
movl %eax, %r15d
testl %eax, %eax
js 0x6ce3
movq %r12, %rdi
callq 0x2140
leal (%rax,%r15), %edx
movq %rsp, %rdi
pushq $-0x1
popq %rcx
movq %r14, %rsi
callq 0x5f70
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x4a7e
movq %rsp, %rdi
callq 0x49aa
pushq $-0x1
popq %rdx
movq %r14, %rdi
movl %r15d, %esi
callq 0x63da
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
movq %rax, %r14
movq %rsp, %rdi
callq 0x49aa
jmp 0x6d04
jmp 0x6d01
movq %rax, %r14
movq %rbx, %rdi
callq 0x49aa
movq %r14, %rdi
callq 0x2400
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::split(char)
GStr GStr::split(char c) {
           /* splits "this" in two parts, at the first (left)
                 encounter of delim:
                 1st would stay in "this",
                 2nd part will be returned
                 as a new string!
           */
 GStr result;
 int i=index(c);
 if (i>=0){
      result=substr(i+1);
      cut(i);
      return result;
      }
 return result;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq 0xb526(%rip), %rax      # 0x12250
movq %rax, 0x20(%rdi)
andq $0x0, (%rdi)
movabsq $0x100000000, %rax      # imm = 0x100000000
movq %rax, 0x8(%rdi)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rdi)
movq %rsi, %rdi
movl %edx, %esi
xorl %edx, %edx
callq 0x519a
movl %eax, %r15d
testl %eax, %eax
js 0x6d93
leal 0x1(%r15), %edx
leaq 0x8(%rsp), %rdi
pushq $-0x1
popq %rcx
movq %r14, %rsi
callq 0x5f70
leaq 0x8(%rsp), %rsi
movq %rbx, %rdi
callq 0x4a7e
leaq 0x8(%rsp), %rdi
callq 0x49aa
pushq $-0x1
popq %rdx
movq %r14, %rdi
movl %r15d, %esi
callq 0x63da
movq %rbx, %rax
addq $0x30, %rsp
popq %rbx
popq %r14
popq %r15
retq
movq %rax, %r14
leaq 0x8(%rsp), %rdi
callq 0x49aa
jmp 0x6db4
jmp 0x6db1
movq %rax, %r14
movq %rbx, %rdi
callq 0x49aa
movq %r14, %rdi
callq 0x2400
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::splitr(char const*)
GStr GStr::splitr(const char* delim) {
 GStr result;
 int i=rindex(delim);
 if (i>=0){
      result=substr(i+strlen(delim));
      cut(i);
      return result;
      }
 return result;
}

// Assembly:
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
subq $0x28, %rsp
movq %rdx, %r12
movq %rsi, %r14
movq %rdi, %rbx
leaq 0xb471(%rip), %rax      # 0x12250
movq %rax, 0x20(%rdi)
andq $0x0, (%rdi)
movabsq $0x100000000, %rax      # imm = 0x100000000
movq %rax, 0x8(%rdi)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rdi)
pushq $-0x1
popq %rdx
movq %rsi, %rdi
movq %r12, %rsi
callq 0x6bc2
testl %eax, %eax
js 0x6e4c
movl %eax, %r15d
movq %r12, %rdi
callq 0x2140
leal (%rax,%r15), %edx
movq %rsp, %rdi
pushq $-0x1
popq %rcx
movq %r14, %rsi
callq 0x5f70
movq %rsp, %rsi
movq %rbx, %rdi
callq 0x4a7e
movq %rsp, %rdi
callq 0x49aa
pushq $-0x1
popq %rdx
movq %r14, %rdi
movl %r15d, %esi
callq 0x63da
movq %rbx, %rax
addq $0x28, %rsp
popq %rbx
popq %r12
popq %r14
popq %r15
retq
jmp 0x6e6a
movq %rax, %r14
movq %rsp, %rdi
callq 0x49aa
jmp 0x6e6d
movq %rax, %r14
movq %rbx, %rdi
callq 0x49aa
movq %r14, %rdi
callq 0x2400
nop
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::splitr(char)
GStr GStr::splitr(char c) {
 GStr result;
 int i=rindex(c);
 if (i>=0){
      result=substr(i+1);
      cut(i);
      return result;
      }
 return result;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x30, %rsp
movq %rsi, %r14
movq %rdi, %rbx
leaq 0xb3bc(%rip), %rax      # 0x12250
movq %rax, 0x20(%rdi)
andq $0x0, (%rdi)
movabsq $0x100000000, %rax      # imm = 0x100000000
movq %rax, 0x8(%rdi)
xorps %xmm0, %xmm0
movups %xmm0, 0x10(%rdi)
pushq $-0x1
popq %rax
movq %rsi, %rdi
movl %edx, %esi
movl %eax, %edx
callq 0x6b86
testl %eax, %eax
js 0x6f00
movl %eax, %r15d
leal 0x1(%r15), %edx
leaq 0x8(%rsp), %rdi
pushq $-0x1
popq %rcx
movq %r14, %rsi
callq 0x5f70
leaq 0x8(%rsp), %rsi
movq %rbx, %rdi
callq 0x4a7e
leaq 0x8(%rsp), %rdi
callq 0x49aa
pushq $-0x1
popq %rdx
movq %r14, %rdi
movl %r15d, %esi
callq 0x63da
movq %rbx, %rax
addq $0x30, %rsp
popq %rbx
popq %r14
popq %r15
retq
jmp 0x6f1e
movq %rax, %r14
leaq 0x8(%rsp), %rdi
callq 0x49aa
jmp 0x6f21
movq %rax, %r14
movq %rbx, %rdi
callq 0x49aa
movq %r14, %rdi
callq 0x2400
nop
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::startTokenize(char const*, enTokenizeMode)
void GStr::startTokenize(const char* delimiter, enTokenizeMode tokenizemode) {
 GFREE(fTokenDelimiter);
 if (delimiter) {
    GMALLOC(fTokenDelimiter,strlen(delimiter)+1);
    strcpy(fTokenDelimiter, delimiter);
    }
 fLastTokenStart=0;
 fTokenizeMode=tokenizemode;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
movl %edx, %ebx
movq %rsi, %r15
movq %rdi, %r14
callq 0x420d
testq %r15, %r15
je 0x6f7a
movq %r15, %rdi
callq 0x2140
leaq 0x1(%rax), %rsi
movq %r14, %rdi
callq 0x415c
testb %al, %al
jne 0x6f6f
leaq 0x50b8(%rip), %rdi      # 0xc020
xorl %eax, %eax
callq 0x25ca
movq (%r14), %rdi
movq %r15, %rsi
callq 0x2220
andl $0x0, 0x8(%r14)
movl %ebx, 0xc(%r14)
popq %rbx
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::asInt(int&, int)
bool GStr::asInt(int& r, int base) {
 errno=0;
 char*endptr;
 long val=strtol(text(), &endptr, base);
 if (errno!=0) return false;
 if (endptr == text()) return false;
 /* If we got here, strtol() successfully parsed a number */
 r=val;
 return true;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %rbx
pushq %rax
movl %edx, %ebp
movq %rsi, %rbx
movq %rdi, %r14
callq 0x2040
movq %rax, %r15
andl $0x0, (%rax)
movq 0x20(%r14), %rdi
addq $0xc, %rdi
movq %rsp, %rsi
movl %ebp, %edx
callq 0x2360
cmpl $0x0, (%r15)
je 0x73e4
xorl %eax, %eax
jmp 0x73f6
movq 0x20(%r14), %rcx
addq $0xc, %rcx
cmpq %rcx, (%rsp)
je 0x73e0
movl %eax, (%rbx)
movb $0x1, %al
addq $0x8, %rsp
popq %rbx
popq %r14
popq %r15
popq %rbp
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::asReal(double&)
bool GStr::asReal(double& r) {
  errno=0;
  char* endptr;
  double val=strtod(text(), &endptr);
  if (errno!=0) return false;
  if (endptr == text()) return false; //no digits to parse
  r=val;
  return true;
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
subq $0x10, %rsp
movq %rsi, %rbx
movq %rdi, %r14
callq 0x2040
movq %rax, %r15
andl $0x0, (%rax)
movq 0x20(%r14), %rdi
addq $0xc, %rdi
leaq 0x8(%rsp), %rsi
callq 0x21d0
cmpl $0x0, (%r15)
je 0x7448
xorl %eax, %eax
jmp 0x745d
movq 0x20(%r14), %rax
addq $0xc, %rax
cmpq %rax, 0x8(%rsp)
je 0x7444
movsd %xmm0, (%rbx)
movb $0x1, %al
addq $0x10, %rsp
popq %rbx
popq %r14
popq %r15
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::to(char)
GStr GStr::to(char c) { //return the first part up to first occurence of c
 int i=index(c);
 if (i>=0) return substr(0,i);
      else return (*this);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
movq %rsi, %rdi
movl %edx, %esi
xorl %edx, %edx
callq 0x519a
movq %rbx, %rdi
movq %r14, %rsi
testl %eax, %eax
js 0x75db
xorl %edx, %edx
movl %eax, %ecx
callq 0x5f70
jmp 0x75e0
callq 0x4816
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::from(char)
GStr GStr::from(char c) { //same as to, but starting from the right side
 int i=rindex(c);
 if (i>=0) return substr(i+1);
      else return (*this);
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rsi, %r14
movq %rdi, %rbx
pushq $-0x1
popq %rax
movq %rsi, %rdi
movl %edx, %esi
movl %eax, %edx
callq 0x6b86
testl %eax, %eax
js 0x761d
incl %eax
pushq $-0x1
popq %rcx
movq %rbx, %rdi
movq %r14, %rsi
movl %eax, %edx
callq 0x5f70
jmp 0x7628
movq %rbx, %rdi
movq %r14, %rsi
callq 0x4816
movq %rbx, %rax
addq $0x8, %rsp
popq %rbx
popq %r14
retq
nop
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GStr.cpp
// Function: GStr::count(char)
int GStr::count(char c){
 //return the number of occurences of char c within the string
 int result=0;
 for (int i=0;i<length();i++)
    if (my_data->chars[i]==c) result++;
 return result;
 }

// Assembly:
movq 0x20(%rdi), %rcx
movl 0x8(%rcx), %edx
xorl %edi, %edi
testl %edx, %edx
cmovlel %edi, %edx
xorl %eax, %eax
cmpq %rdi, %rdx
je 0x765d
xorl %r8d, %r8d
cmpb %sil, 0xc(%rcx,%rdi)
sete %r8b
addl %r8d, %eax
incq %rdi
jmp 0x7644
retq
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GArgs.cpp
// Function: dbg_dequote(char*&)
void dbg_dequote(char* &p) {
   int alen=strlen(p);
   if (alen>1 && p[0]=='\'' && p[alen-1]=='\'') {
	 p++;
	 p[alen-2 ]='\0';
   }
}

// Assembly:
pushq %r14
pushq %rbx
pushq %rax
movq %rdi, %r14
movq (%rdi), %rbx
movq %rbx, %rdi
callq 0x2140
cmpl $0x2, %eax
jl 0x7d98
cmpb $0x27, (%rbx)
jne 0x7d98
leal -0x1(%rax), %ecx
cmpb $0x27, (%rbx,%rcx)
jne 0x7d98
movl $0xfffffffe, %ecx       # imm = 0xFFFFFFFE
leaq 0x1(%rbx), %rdx
movq %rdx, (%r14)
addl %ecx, %eax
movb $0x0, 0x1(%rbx,%rax)
addq $0x8, %rsp
popq %rbx
popq %r14
retq
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GArgs.cpp
// Function: GArgs::validLongOpt(char*, char*)
int GArgs::validLongOpt(char* o, char* to) {
 char* pstr=Gstrdup(o,to);
 for (int i=0; i<fmtcount; i++) {
  if (fmt[i].longopt && strcmp(fmt[i].longopt, pstr)==0) {
       GFREE(pstr);
       return i;
       }
  }
 GFREE(pstr); 
 return -1;
}

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r12
pushq %rbx
movq %rdi, %r14
movq %rsi, %rdi
movq %rdx, %rsi
callq 0x2788
movq %rax, %rbx
movl (%r14), %r15d
movq 0x8(%r14), %r12
xorl %r14d, %r14d
testl %r15d, %r15d
cmovlel %r14d, %r15d
pushq $-0x1
popq %rbp
cmpq %r14, %r15
je 0x7e1d
movq (%r12), %rdi
testq %rdi, %rdi
je 0x7e11
movq %rbx, %rsi
callq 0x2350
testl %eax, %eax
je 0x7e1a
incq %r14
addq $0x10, %r12
jmp 0x7df7
movl %r14d, %ebp
movq %rbx, %rdi
callq 0x22e0
movl %ebp, %eax
popq %rbx
popq %r12
popq %r14
popq %r15
popq %rbp
retq
// File: /workspace/github_cpp_makefile_star2_O2/gpertea[P]gclib/GArgs.cpp
// Function: GArgs::printError(_IO_FILE*, char const*, bool)
void GArgs::printError(FILE* fout, const char* usage, bool exitProgram) {
 if (errarg==0) return;
 if (usage) fprintf(fout, "%s\n", usage);
 if (err_valmissing) 
     fprintf(fout, "Error: value required for option '%s'\n", _argv[errarg]);
    else 
     fprintf(fout, "Error: invalid argument '%s'\n", _argv[errarg]);
 if (exitProgram)
     exit(1);
}

// Assembly:
pushq %r15
pushq %r14
pushq %rbx
cmpl $0x0, 0x38(%rdi)
je 0x7e8a
movl %ecx, %ebx
movq %rsi, %r14
movq %rdi, %r15
testq %rdx, %rdx
je 0x7e59
leaq 0x4269(%rip), %rsi      # 0xc0b8
movq %r14, %rdi
xorl %eax, %eax
callq 0x2370
movq 0x18(%r15), %rax
movslq 0x38(%r15), %rcx
movq (%rax,%rcx,8), %rdx
leaq 0x43d8(%rip), %rax      # 0xc244
leaq 0x43f8(%rip), %rsi      # 0xc26b
cmpb $0x0, 0x3c(%r15)
cmovneq %rax, %rsi
movq %r14, %rdi
xorl %eax, %eax
callq 0x2370
testb %bl, %bl
jne 0x7e90
popq %rbx
popq %r14
popq %r15
retq
pushq $0x1
popq %rdi
callq 0x22f0