// File: /workspace/github_cpp_makefile_star2_O1/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 0x523c
movq %r14, %rdi
callq 0x254c
movb (%rax), %bl
movq %r14, %rdi
callq 0x2564
movb (%rax), %bpl
movq %r14, %rdi
callq 0x257c
movb (%rax), %r15b
movq %r14, %rdi
callq 0x2558
movsbl (%rax), %r9d
movsbl %bl, %edx
movsbl %bpl, %ecx
movsbl %r15b, %r8d
leaq 0x80(%rsp), %rdi
movq %r14, %rsi
callq 0x553c
cmpq $0x0, 0x28(%r14)
je 0x59d1
movq %r14, %rdi
callq 0x4cde
movl %eax, %ebx
movq %r14, %rdi
callq 0x2594
movl %eax, %r12d
movq %r14, %rdi
callq 0x25a2
movl %eax, %r15d
movq %r14, %rdi
callq 0x2594
movl %eax, %r13d
movq %r14, %rdi
callq 0x25a2
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 0x4cde
cmpw %ax, %bx
jae 0x57ce
movzwl %bx, %esi
movq %r14, %rdi
callq 0x507a
addl %ebp, %eax
incl %ebx
movl %eax, %ebp
jmp 0x57ae
movq 0x28(%r14), %r15
movq %r14, %rdi
callq 0x24f8
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 0x24e2
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 0x2504
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 0x5891
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x2180
movq %r14, %rdi
callq 0x2540
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 0x593e
movq %r15, %rdi
movl $0x20, %esi
callq 0x2150
movb %al, 0xe0(%r15)
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 0x596c
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x2180
movq %r14, %rdi
callq 0x2570
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 0x5a44
movq %r14, %rdi
callq 0x24f8
movb (%rax), %bl
movq %r14, %rdi
callq 0x24ec
movb (%rax), %bpl
movq %r14, %rdi
callq 0x2504
movb (%rax), %r15b
movq %r14, %rdi
callq 0x24e2
movsbl (%rax), %r9d
movsbl %bl, %edx
movsbl %bpl, %ecx
movsbl %r15b, %r8d
movq %rsp, %rdi
movq %r14, %rsi
callq 0x553c
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 0x5a44
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 0x3b50
leaq 0x50(%rsp), %rdi
leaq 0x68(%rsp), %rsi
callq 0x60ac
addq $-0x20, %rbx
cmpq %rbx, %r12
je 0x5b42
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 0x625c
movq %rbp, %rdi
callq 0x6a9c
movq 0x8(%rax), %rcx
cmpq (%rax), %rcx
je 0x5b2d
movq 0x28(%rsp), %r15
movq %rsp, %rdi
movq %rbp, %rsi
callq 0x6b8e
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 0x5b1b
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 0x3e66
addq $0x18, %r12
cmpq %rbx, %r12
jne 0x5aac
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 0x5b7d
movq %rax, 0xc8(%rsp)
movq 0x40(%rsp), %rax
movq %rax, 0xd8(%rsp)
jmp 0x5b86
movups (%r12), %xmm0
movups %xmm0, (%r15)
leaq 0x50(%rsp), %r13
movq 0x38(%rsp), %rax
movq 0x50(%rsp), %rcx
leaq 0xe8(%rsp), %rbx
movq %rax, -0x18(%rbx)
movq %r12, 0x30(%rsp)
xorl %eax, %eax
movq %rax, 0x38(%rsp)
movb $0x0, 0x40(%rsp)
movq %rcx, (%rbx)
movups 0x58(%rsp), %xmm0
movups %xmm0, 0x8(%rbx)
movq %rax, 0x10(%r13)
xorps %xmm0, %xmm0
movups %xmm0, (%r13)
movq %rbx, %rdi
callq 0x3e24
movq -0x20(%rbx), %rdi
cmpq %r15, %rdi
je 0x5beb
movq 0xd8(%rsp), %rsi
incq %rsi
callq 0x2180
movq %r13, %rdi
callq 0x3e24
movq 0x30(%rsp), %rdi
cmpq %r12, %rdi
je 0x5c0a
movq 0x40(%rsp), %rsi
incq %rsi
callq 0x2180
movq 0x70(%rsp), %rsi
cmpq 0x68(%rsp), %rsi
je 0x5cc5
addq $-0x20, %rsi
movq %rsp, %rdi
callq 0x6b8e
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 0x5c5a
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x2180
movq %r14, %rdi
callq 0x2528
movb (%rax), %bpl
movq %r14, %rdi
callq 0x251c
movb (%rax), %r12b
movq %r14, %rdi
callq 0x2534
movb (%rax), %r13b
movq %r14, %rdi
callq 0x2510
movsbl (%rax), %r9d
movsbl %bpl, %edx
movsbl %r12b, %ecx
movsbl %r13b, %r8d
movq %rsp, %rdi
movq %r14, %rsi
callq 0x553c
movq (%rsp), %rsi
movq 0x8(%rsp), %rdx
movq %rbx, %rdi
callq 0x21a0
movq (%rsp), %rdi
cmpq %r15, %rdi
je 0x5cc5
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 0x5cf8
movq 0x90(%rsp), %rsi
incq %rsi
callq 0x2180
leaq 0x68(%rsp), %rdi
callq 0x3e24
movq 0x6297(%rip), %rsi      # 0xbfa0
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 0x5d4d
movq %rax, %rbx
movq (%rsp), %rdi
cmpq %r15, %rdi
jne 0x5da2
jmp 0x5df7
movq %rax, %rbx
leaq 0x10(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
jne 0x5da2
jmp 0x5df7
jmp 0x5ddd
jmp 0x5ddd
jmp 0x5ddd
movq %rax, %rbx
movq 0x30(%rsp), %rdi
leaq 0x40(%rsp), %rax
cmpq %rax, %rdi
je 0x5df7
movq 0x40(%rsp), %rsi
jmp 0x5da7
jmp 0x5ddd
movq %rax, %rbx
jmp 0x5e22
jmp 0x5d96
jmp 0x5ddd
jmp 0x5ddd
jmp 0x5ddd
jmp 0x5ddd
movq %rax, %rbx
movq (%rsp), %rdi
cmpq %rbp, %rdi
je 0x5df7
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x2180
jmp 0x5df7
movq %rax, %rbx
jmp 0x5e18
jmp 0x5ddd
movq %rax, %rbx
movq (%rsp), %rdi
leaq 0x10(%rsp), %rax
cmpq %rax, %rdi
je 0x5de5
movq 0x10(%rsp), %rsi
incq %rsi
callq 0x2180
jmp 0x5de5
movq %rax, %rbx
jmp 0x5ded
movq %rax, %rbx
jmp 0x5df7
movq %rax, %rbx
movq %r13, %rdi
callq 0x3e66
leaq 0x28(%rsp), %rdi
callq 0x5e4c
leaq 0x90(%rsp), %rax
movq -0x10(%rax), %rdi
cmpq %rax, %rdi
je 0x5e18
movq 0x90(%rsp), %rsi
incq %rsi
callq 0x2180
leaq 0x68(%rsp), %rdi
callq 0x3e24
movq 0x6177(%rip), %rsi      # 0xbfa0
leaq 0x100(%rsp), %rdi
callq 0x2110
leaq 0x180(%rsp), %rdi
callq 0x2050
movq %rbx, %rdi
callq 0x2260
nop