// File: /workspace/github_cpp_makefile_star2_O3/Phidelux[P]terminal-table/src/table.cpp
// Function: bornageek::utils::termtab::Table::render[abi:cxx11]() const
const std::string Table::render() const {
        std::stringstream ss;

        std::vector<Row> rowsWithHeadings = this->rowsWithHeadings();
        
        std::string sep = this->renderSeparator(
          this->mStyle.borderLeftMid(), this->mStyle.borderMidMid(), 
          this->mStyle.borderRightMid(), this->mStyle.borderMid());

        if(this->mTitle.length() > 0) {
          std::uint16_t innerWidth = (this->numColumns() - 1) 
              * this->cellSpacing() + this->cellPadding();

          for(std::uint16_t c = 0; c < this->numColumns(); c++) {
            innerWidth += this->columnWidth(c);
          }

          std::uint16_t spaceLeft = innerWidth / 2 - mTitle.length() / 2;

          ss << this->mStyle.borderTopLeft() 
             << std::string(innerWidth, this->mStyle.borderTop())
             << this->mStyle.borderTopRight() << std::endl; 
          ss << this->mStyle.borderLeft() 
             << std::string(spaceLeft, ' ') << std::left 
             << std::setw(innerWidth - spaceLeft) << std::setfill(' ') 
             << this->mTitle; 
          ss << this->mStyle.borderRight() << std::endl << sep;
        } else {
          ss << this->renderSeparator(
            this->mStyle.borderTopLeft(), this->mStyle.borderTopMid(), 
            this->mStyle.borderTopRight(), this->mStyle.borderTop());
        }

        std::for_each(rowsWithHeadings.begin(), --rowsWithHeadings.end(),
          [&ss, sep, rowsWithHeadings](Row row){ 
            if(row.cells().size() > 0) {
              ss << row << sep; 
            }
          });

        if( rowsWithHeadings.size() > 0) {
          ss << rowsWithHeadings.back() << this->renderSeparator(
            this->mStyle.borderBottomLeft(), this->mStyle.borderBottomMid(), 
            this->mStyle.borderBottomRight(), this->mStyle.borderBottom());
        }

        return ss.str();
      }

// Assembly:
pushq %rbp
pushq %r15
pushq %r14
pushq %r13
pushq %r12
pushq %rbx
subq $0x288, %rsp            # imm = 0x288
movq %rsi, %r14
movq %rdi, 0x20(%rsp)
leaq 0x100(%rsp), %rdi
callq 0x20e0
leaq 0x68(%rsp), %rdi
movq %r14, %rsi
callq 0x503c
movq %r14, %rdi
callq 0x2508
movb (%rax), %bl
movq %r14, %rdi
callq 0x2520
movb (%rax), %bpl
movq %r14, %rdi
callq 0x2538
movb (%rax), %r15b
movq %r14, %rdi
callq 0x2514
movsbl (%rax), %r9d
movsbl %bl, %edx
movsbl %bpl, %ecx
movsbl %r15b, %r8d
leaq 0x80(%rsp), %rdi
movq %r14, %rsi
callq 0x532e
cmpq $0x0, 0x28(%r14)
je 0x57bc
movq %r14, %rdi
callq 0x4ab4
movl %eax, %ebx
movq %r14, %rdi
callq 0x2550
movl %eax, %r12d
movq %r14, %rdi
callq 0x255e
movl %eax, %r15d
movq %r14, %rdi
callq 0x2550
movl %eax, %r13d
movq %r14, %rdi
callq 0x255e
movl %eax, %ebp
leal (%r12,%r15), %eax
incl %eax
decl %ebx
imull %ebx, %eax
addl %r13d, %ebp
addl %eax, %ebp
xorl %ebx, %ebx
movq %r14, %rdi
callq 0x4ab4
cmpw %ax, %bx
jae 0x55c0
movzwl %bx, %esi
movq %r14, %rdi
callq 0x4e66
addl %ebp, %eax
incl %ebx
movl %eax, %ebp
jmp 0x55a0
movq 0x28(%r14), %r15
movq %r14, %rdi
callq 0x24b4
leaq 0x110(%rsp), %r13
movb (%rax), %al
movq %rsp, %rsi
movb %al, (%rsi)
movl $0x1, %edx
movq %r13, %rdi
callq 0x21a0
movq %rax, %rbx
movq %r14, %rdi
callq 0x249e
movzwl %bp, %r12d
movsbl (%rax), %edx
leaq 0x10(%rsp), %rbp
movq %rbp, -0x10(%rbp)
movq %rsp, %rdi
movq %r12, %rsi
callq 0x21b0
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
movq %rbx, %rdi
callq 0x21a0
movq %rax, %rbx
movq %r14, %rdi
callq 0x24c0
movb (%rax), %al
leaq 0xa0(%rsp), %rsi
movb %al, (%rsi)
movl $0x1, %edx
movq %rbx, %rdi
callq 0x21a0
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x2150
movsbl %al, %esi
movq %rbx, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x20d0
movq (%rsp), %rdi
cmpq %rbp, %rdi
je 0x5683
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x2180
movq %r14, %rdi
callq 0x24fc
movb (%rax), %al
movq %rsp, %rsi
movb %al, (%rsi)
movl $0x1, %edx
movq %r13, %rdi
callq 0x21a0
movq %rax, %rbx
movl %r12d, %r13d
shrl %r13d
shrq %r15
subq %r15, %r13
movzwl %r13w, %esi
movq %rsp, %rdi
movq %rbp, (%rdi)
movl $0x20, %edx
callq 0x21b0
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
movq %rbx, %rdi
callq 0x21a0
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rcx
movl $0xffffff4f, %edx       # imm = 0xFFFFFF4F
andl 0x18(%rbx,%rcx), %edx
orl $0x20, %edx
movl %edx, 0x18(%rbx,%rcx)
movzwl %r13w, %ecx
subl %ecx, %r12d
movq -0x18(%rax), %rcx
movslq %r12d, %rdx
movq %rdx, 0x10(%rbx,%rcx)
movq -0x18(%rax), %rax
movq %rbx, %r15
addq %rax, %r15
cmpb $0x0, 0xe1(%rbx,%rax)
jne 0x5729
movq %r15, %rdi
movl $0x20, %esi
callq 0x2150
movb $0x1, 0xe1(%r15)
movb $0x20, 0xe0(%r15)
movq 0x20(%r14), %rsi
movq 0x28(%r14), %rdx
movq %rbx, %rdi
callq 0x21a0
movq (%rsp), %rdi
cmpq %rbp, %rdi
je 0x5757
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x2180
movq %r14, %rdi
callq 0x252c
leaq 0x110(%rsp), %rdi
movb (%rax), %al
movq %rsp, %rsi
movb %al, (%rsi)
movl $0x1, %edx
callq 0x21a0
movq %rax, %rbx
movq (%rax), %rax
movq -0x18(%rax), %rdi
addq %rbx, %rdi
movl $0xa, %esi
callq 0x2150
movsbl %al, %esi
movq %rbx, %rdi
callq 0x2030
movq %rax, %rdi
callq 0x20d0
movq 0x80(%rsp), %rsi
movq 0x88(%rsp), %rdx
movq %rax, %rdi
callq 0x21a0
jmp 0x582f
movq %r14, %rdi
callq 0x24b4
movb (%rax), %bl
movq %r14, %rdi
callq 0x24a8
movb (%rax), %bpl
movq %r14, %rdi
callq 0x24c0
movb (%rax), %r15b
movq %r14, %rdi
callq 0x249e
movsbl (%rax), %r9d
movsbl %bl, %edx
movsbl %bpl, %ecx
movsbl %r15b, %r8d
movq %rsp, %rdi
movq %r14, %rsi
callq 0x532e
leaq 0x110(%rsp), %rdi
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
callq 0x21a0
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x582f
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x2180
movq 0x68(%rsp), %r12
movq 0x70(%rsp), %rbx
leaq 0x30(%rsp), %rdi
leaq 0x100(%rsp), %rax
movq %rax, -0x8(%rdi)
leaq 0x40(%rsp), %rax
movq %rax, -0x10(%rax)
movq 0x80(%rsp), %rsi
movq 0x88(%rsp), %rdx
addq %rsi, %rdx
callq 0x3932
leaq 0x50(%rsp), %rdi
leaq 0x68(%rsp), %rsi
callq 0x5e96
addq $-0x20, %rbx
cmpq %rbx, %r12
je 0x592d
leaq 0xa8(%rsp), %r13
leaq 0xa0(%rsp), %rbp
movq (%r12), %rax
movq %rax, 0xa0(%rsp)
addq $0x8, %r12
movq %r13, %rdi
movq %r12, %rsi
callq 0x6046
movq %rbp, %rdi
callq 0x6858
movq 0x8(%rax), %rcx
cmpq (%rax), %rcx
je 0x5918
movq 0x28(%rsp), %r15
movq %rsp, %rdi
movq %rbp, %rsi
callq 0x694a
addq $0x10, %r15
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
movq %r15, %rdi
callq 0x21a0
movq %rax, %r15
movq (%rsp), %rdi
leaq 0x10(%rsp), %rax
cmpq %rax, %rdi
je 0x5906
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x2180
movq 0x30(%rsp), %rsi
movq 0x38(%rsp), %rdx
movq %r15, %rdi
callq 0x21a0
movq %r13, %rdi
callq 0x3c54
addq $0x18, %r12
cmpq %rbx, %r12
jne 0x5897
movq 0x28(%rsp), %rcx
movq 0x30(%rsp), %rax
leaq 0xd8(%rsp), %r15
movq %rcx, -0x18(%r15)
movq %r15, -0x10(%r15)
leaq 0x40(%rsp), %r12
cmpq %r12, %rax
je 0x5968
movq %rax, 0xc8(%rsp)
movq 0x40(%rsp), %rax
movq %rax, 0xd8(%rsp)
jmp 0x5971
movups (%r12), %xmm0
movups %xmm0, (%r15)
leaq 0x50(%rsp), %r13
movq 0x38(%rsp), %rax
leaq 0xe8(%rsp), %rbx
movq %rax, -0x18(%rbx)
movq %r12, 0x30(%rsp)
xorl %eax, %eax
movq %rax, 0x38(%rsp)
movb $0x0, 0x40(%rsp)
movups 0x50(%rsp), %xmm0
movups %xmm0, (%rbx)
movq 0x60(%rsp), %rcx
movq %rcx, 0x10(%rbx)
movq %rax, 0x10(%r13)
xorps %xmm0, %xmm0
movups %xmm0, (%r13)
movq %rbx, %rdi
callq 0x3c0c
movq -0x20(%rbx), %rdi
cmpq %r15, %rdi
je 0x59d6
movq 0xd8(%rsp), %rsi
incq %rsi
callq 0x2180
movq %r13, %rdi
callq 0x3c0c
movq 0x30(%rsp), %rdi
cmpq %r12, %rdi
je 0x59f5
movq 0x40(%rsp), %rsi
incq %rsi
callq 0x2180
movq 0x70(%rsp), %rsi
cmpq 0x68(%rsp), %rsi
je 0x5ab0
addq $-0x20, %rsi
movq %rsp, %rdi
callq 0x694a
leaq 0x110(%rsp), %rdi
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
callq 0x21a0
movq %rax, %rbx
leaq 0x10(%rsp), %r15
movq -0x10(%r15), %rdi
cmpq %r15, %rdi
je 0x5a45
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x2180
movq %r14, %rdi
callq 0x24e4
movb (%rax), %bpl
movq %r14, %rdi
callq 0x24d8
movb (%rax), %r12b
movq %r14, %rdi
callq 0x24f0
movb (%rax), %r13b
movq %r14, %rdi
callq 0x24cc
movsbl (%rax), %r9d
movsbl %bpl, %edx
movsbl %r12b, %ecx
movsbl %r13b, %r8d
movq %rsp, %rdi
movq %r14, %rsi
callq 0x532e
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
movq %rbx, %rdi
callq 0x21a0
movq (%rsp), %rdi
cmpq %r15, %rdi
je 0x5ab0
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x2180
leaq 0x118(%rsp), %rsi
movq 0x20(%rsp), %rdi
callq 0x2220
leaq 0x90(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x5ae3
movq 0x90(%rsp), %rsi
incq %rsi
callq 0x2180
leaq 0x68(%rsp), %rdi
callq 0x3c0c
movq 0x54ac(%rip), %rsi      # 0xafa0
leaq 0x100(%rsp), %rdi
callq 0x2110
leaq 0x180(%rsp), %rdi
callq 0x2050
movq 0x20(%rsp), %rax
addq $0x288, %rsp            # imm = 0x288
popq %rbx
popq %r12
popq %r13
popq %r14
popq %r15
popq %rbp
retq
jmp 0x5b38
movq %rax, %rbx
movq (%rsp), %rdi
cmpq %r15, %rdi
jne 0x5b8d
jmp 0x5be2
movq %rax, %rbx
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
jne 0x5b8d
jmp 0x5be2
jmp 0x5bc8
jmp 0x5bc8
jmp 0x5bc8
movq %rax, %rbx
movq 0x30(%rsp), %rdi
leaq 0x40(%rsp), %rax
cmpq %rax, %rdi
je 0x5be2
movq 0x40(%rsp), %rsi
jmp 0x5b92
jmp 0x5bc8
movq %rax, %rbx
jmp 0x5c0d
jmp 0x5b81
jmp 0x5bc8
jmp 0x5bc8
jmp 0x5bc8
jmp 0x5bc8
movq %rax, %rbx
movq (%rsp), %rdi
cmpq %rbp, %rdi
je 0x5be2
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x2180
jmp 0x5be2
movq %rax, %rbx
jmp 0x5c03
jmp 0x5bc8
movq %rax, %rbx
movq (%rsp), %rdi
leaq 0x10(%rsp), %rax
cmpq %rax, %rdi
je 0x5bd0
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x2180
jmp 0x5bd0
movq %rax, %rbx
jmp 0x5bd8
movq %rax, %rbx
jmp 0x5be2
movq %rax, %rbx
movq %r13, %rdi
callq 0x3c54
leaq 0x28(%rsp), %rdi
callq 0x5c36
leaq 0x90(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x5c03
movq 0x90(%rsp), %rsi
incq %rsi
callq 0x2180
leaq 0x68(%rsp), %rdi
callq 0x3c0c
movq 0x538c(%rip), %rsi      # 0xafa0
leaq 0x100(%rsp), %rdi
callq 0x2110
leaq 0x180(%rsp), %rdi
callq 0x2050
movq %rbx, %rdi
callq 0x2260