#define NULL ((void *)0)
typedef unsigned long size_t; // Customize by platform.
typedef long intptr_t;
typedef unsigned long uintptr_t;
typedef long scalar_t__; // Either arithmetic or pointer type.
/* By default, we understand bool (as a convenience). */
typedef int bool;
#define false 0
#define true 1

/* Forward declarations */

/* Type definitions */

/* Variables and functions */
int /*<<< orphan*/ COLOR_PAIR(int);
int /*<<< orphan*/ attroff(int /*<<< orphan*/);
int /*<<< orphan*/ attron(int /*<<< orphan*/);
int getmaxx(int /*<<< orphan*/);
int getmaxy(int /*<<< orphan*/);
int /*<<< orphan*/ mvprintw(int, int, char *, ...);
int /*<<< orphan*/ stdscr;
int strlen(char *);
void di_updateBoxing(char *title1, char *title2) {
  int i, j;
  attron(COLOR_PAIR(1));
  mvprintw(0, 0, "+");
  for (i = 1; i < (getmaxx(stdscr) / 2 - strlen(title1)) / 2 - 1 &&
              strlen(title1) + 4 < getmaxx(stdscr) / 2;
       i++)
    mvprintw(0, i, "-");
  mvprintw(0, i++, "|");
  for (j = 0; i < getmaxx(stdscr) / 2 - 2 && j < strlen(title1); j++, i++)
    mvprintw(0, i, "%c", title1[j]);
  mvprintw(0, i++, "|");
  for (; i < getmaxx(stdscr) / 2 - 1; i++)
    mvprintw(0, i, "-");
  mvprintw(0, i++, "+");
  mvprintw(0, i++, "+");
  for (; i < getmaxx(stdscr) / 2 +
                 (getmaxx(stdscr) / 2 + (getmaxx(stdscr) % 2 == 1) -
                  strlen(title2)) /
                     2 -
                 1 &&
         strlen(title2) + 4 < getmaxx(stdscr) / 2 + (getmaxx(stdscr) % 2 == 1);
       i++)
    mvprintw(0, i, "-");
  mvprintw(0, i++, "|");
  for (j = 0; i < getmaxx(stdscr) / 2 + getmaxx(stdscr) / 2 +
                      (getmaxx(stdscr) % 2 == 1) - 2 &&
              j < strlen(title2);
       j++, i++)
    mvprintw(0, i, "%c", title2[j]);
  mvprintw(0, i++, "|");
  for (; i < getmaxx(stdscr) / 2 + getmaxx(stdscr) / 2 +
                 (getmaxx(stdscr) % 2 == 1) - 1;
       i++)
    mvprintw(0, i, "-");
  mvprintw(0, i++, "+");
  for (j = 1; j < getmaxy(stdscr); j++) {
    mvprintw(j, 0, "|");
    mvprintw(j, getmaxx(stdscr) / 2 - 1, "|");
    mvprintw(j, getmaxx(stdscr) / 2, "|");
    mvprintw(j,
             getmaxx(stdscr) / 2 + getmaxx(stdscr) / 2 +
                 (getmaxx(stdscr) % 2 == 1) - 1,
             "|");
  }
  mvprintw(getmaxy(stdscr) - 1, 0, "+");
  for (i = 1; i < getmaxx(stdscr) / 2 - 1; i++)
    mvprintw(getmaxy(stdscr) - 1, i, "-");
  mvprintw(getmaxy(stdscr) - 1, getmaxx(stdscr) / 2 - 1, "+");
  mvprintw(getmaxy(stdscr) - 1, getmaxx(stdscr) / 2, "+");
  for (i = getmaxx(stdscr) / 2 + 1;
       i < getmaxx(stdscr) / 2 + getmaxx(stdscr) / 2 +
               (getmaxx(stdscr) % 2 == 1) - 1;
       i++)
    mvprintw(getmaxy(stdscr) - 1, i, "-");
  mvprintw(getmaxy(stdscr) - 1,
           getmaxx(stdscr) / 2 + getmaxx(stdscr) / 2 +
               (getmaxx(stdscr) % 2 == 1) - 1,
           "+");
  attroff(COLOR_PAIR(1));
}


x86 assembly (clang, -O0):
<di_updateBoxing>:
push   %rbp
mov    %rsp,%rbp
sub    $0xb0,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    $0x1,%edi
call   1070 <COLOR_PAIR@plt>
mov    %eax,%edi
call   1060 <attron@plt>
xor    %esi,%esi
lea    0xe63(%rip),%rdx
mov    %esi,%edi
mov    $0x0,%al
call   1090 <mvprintw@plt>
movl   $0x1,-0x14(%rbp)
mov    -0x14(%rbp),%eax
mov    %eax,-0x24(%rbp)
mov    0x2e2e(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,-0x20(%rbp)
mov    -0x8(%rbp),%rdi
call   1050 <strlen@plt>
mov    -0x24(%rbp),%ecx
mov    %eax,%edx
mov    -0x20(%rbp),%eax
sub    %edx,%eax
mov    $0x2,%esi
cltd
idiv   %esi
mov    %eax,%edx
sub    $0x1,%edx
xor    %eax,%eax
cmp    %edx,%ecx
mov    %al,-0x19(%rbp)
jge    122b <di_updateBoxing+0xbb>
mov    -0x8(%rbp),%rdi
call   1050 <strlen@plt>
add    $0x4,%eax
mov    %eax,-0x28(%rbp)
mov    0x2dd9(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,%ecx
mov    -0x28(%rbp),%eax
cmp    %ecx,%eax
setl   %al
mov    %al,-0x19(%rbp)
mov    -0x19(%rbp),%al
test   $0x1,%al
jne    123b <di_updateBoxing+0xcb>
jmp    125c <di_updateBoxing+0xec>
mov    -0x14(%rbp),%esi
xor    %edi,%edi
lea    0xdbb(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    11ad <di_updateBoxing+0x3d>
mov    -0x14(%rbp),%esi
mov    %esi,%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
xor    %edi,%edi
lea    0xd94(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
movl   $0x0,-0x18(%rbp)
mov    -0x14(%rbp),%eax
mov    %eax,-0x30(%rbp)
mov    0x2d5d(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    -0x30(%rbp),%ecx
mov    $0x2,%esi
cltd
idiv   %esi
mov    %eax,%edx
sub    $0x2,%edx
xor    %eax,%eax
cmp    %edx,%ecx
mov    %al,-0x29(%rbp)
jge    12cb <di_updateBoxing+0x15b>
mov    -0x18(%rbp),%eax
mov    %eax,-0x34(%rbp)
mov    -0x8(%rbp),%rdi
call   1050 <strlen@plt>
mov    %eax,%ecx
mov    -0x34(%rbp),%eax
cmp    %ecx,%eax
setl   %al
mov    %al,-0x29(%rbp)
mov    -0x29(%rbp),%al
test   $0x1,%al
jne    12db <di_updateBoxing+0x16b>
jmp    1311 <di_updateBoxing+0x1a1>
mov    -0x14(%rbp),%esi
mov    -0x8(%rbp),%rax
movslq -0x18(%rbp),%rcx
movsbl (%rax,%rcx,1),%ecx
xor    %edi,%edi
lea    0xd13(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
mov    -0x18(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x18(%rbp)
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    127e <di_updateBoxing+0x10e>
mov    -0x14(%rbp),%esi
mov    %esi,%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
xor    %edi,%edi
lea    0xcdf(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
mov    -0x14(%rbp),%eax
mov    %eax,-0x38(%rbp)
mov    0x2caf(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,%ecx
mov    -0x38(%rbp),%eax
sub    $0x1,%ecx
cmp    %ecx,%eax
jge    1379 <di_updateBoxing+0x209>
mov    -0x14(%rbp),%esi
xor    %edi,%edi
lea    0xc9e(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    132c <di_updateBoxing+0x1bc>
mov    -0x14(%rbp),%esi
mov    %esi,%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
xor    %edi,%edi
lea    0xc73(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
mov    -0x14(%rbp),%esi
mov    %esi,%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
xor    %edi,%edi
lea    0xc58(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
mov    -0x14(%rbp),%eax
mov    %eax,-0x48(%rbp)
mov    0x2c2c(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,-0x40(%rbp)
mov    0x2c13(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,-0x4c(%rbp)
mov    0x2bfa(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    -0x4c(%rbp),%eax
cmp    $0x1,%edx
sete   %cl
and    $0x1,%cl
movzbl %cl,%ecx
add    %ecx,%eax
mov    %eax,-0x44(%rbp)
mov    -0x10(%rbp),%rdi
call   1050 <strlen@plt>
mov    -0x48(%rbp),%ecx
mov    %eax,%edx
mov    -0x44(%rbp),%eax
sub    %edx,%eax
mov    $0x2,%esi
cltd
idiv   %esi
mov    -0x40(%rbp),%edx
add    %eax,%edx
sub    $0x1,%edx
xor    %eax,%eax
cmp    %edx,%ecx
mov    %al,-0x39(%rbp)
jge    149b <di_updateBoxing+0x32b>
mov    -0x10(%rbp),%rdi
call   1050 <strlen@plt>
add    $0x4,%eax
mov    %eax,-0x50(%rbp)
mov    0x2b91(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,-0x54(%rbp)
mov    0x2b78(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    -0x54(%rbp),%ecx
mov    $0x2,%esi
cltd
idiv   %esi
mov    -0x50(%rbp),%eax
cmp    $0x1,%edx
sete   %dl
and    $0x1,%dl
movzbl %dl,%edx
add    %edx,%ecx
cmp    %ecx,%eax
setl   %al
mov    %al,-0x39(%rbp)
mov    -0x39(%rbp),%al
test   $0x1,%al
jne    14ab <di_updateBoxing+0x33b>
jmp    14cc <di_updateBoxing+0x35c>
mov    -0x14(%rbp),%esi
xor    %edi,%edi
lea    0xb4b(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    13af <di_updateBoxing+0x23f>
mov    -0x14(%rbp),%esi
mov    %esi,%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
xor    %edi,%edi
lea    0xb24(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
movl   $0x0,-0x18(%rbp)
mov    -0x14(%rbp),%eax
mov    %eax,-0x60(%rbp)
mov    0x2aed(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,-0x64(%rbp)
mov    0x2ad4(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,%ecx
mov    -0x64(%rbp),%eax
add    %ecx,%eax
mov    %eax,-0x5c(%rbp)
mov    0x2ab4(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    -0x60(%rbp),%ecx
mov    $0x2,%esi
cltd
idiv   %esi
mov    %edx,%eax
mov    -0x5c(%rbp),%edx
cmp    $0x1,%eax
sete   %al
and    $0x1,%al
movzbl %al,%eax
add    %eax,%edx
sub    $0x2,%edx
xor    %eax,%eax
cmp    %edx,%ecx
mov    %al,-0x55(%rbp)
jge    1584 <di_updateBoxing+0x414>
mov    -0x18(%rbp),%eax
mov    %eax,-0x68(%rbp)
mov    -0x10(%rbp),%rdi
call   1050 <strlen@plt>
mov    %eax,%ecx
mov    -0x68(%rbp),%eax
cmp    %ecx,%eax
setl   %al
mov    %al,-0x55(%rbp)
mov    -0x55(%rbp),%al
test   $0x1,%al
jne    1594 <di_updateBoxing+0x424>
jmp    15ca <di_updateBoxing+0x45a>
mov    -0x14(%rbp),%esi
mov    -0x10(%rbp),%rax
movslq -0x18(%rbp),%rcx
movsbl (%rax,%rcx,1),%ecx
xor    %edi,%edi
lea    0xa5a(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
mov    -0x18(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x18(%rbp)
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    14ee <di_updateBoxing+0x37e>
mov    -0x14(%rbp),%esi
mov    %esi,%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
xor    %edi,%edi
lea    0xa26(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
mov    -0x14(%rbp),%eax
mov    %eax,-0x6c(%rbp)
mov    0x29f6(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,-0x74(%rbp)
mov    0x29dd(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,%ecx
mov    -0x74(%rbp),%eax
add    %ecx,%eax
mov    %eax,-0x70(%rbp)
mov    0x29bd(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    -0x70(%rbp),%ecx
mov    $0x2,%esi
cltd
idiv   %esi
mov    -0x6c(%rbp),%eax
cmp    $0x1,%edx
sete   %dl
and    $0x1,%dl
movzbl %dl,%edx
add    %edx,%ecx
sub    $0x1,%ecx
cmp    %ecx,%eax
jge    167a <di_updateBoxing+0x50a>
mov    -0x14(%rbp),%esi
xor    %edi,%edi
lea    0x99d(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    15e5 <di_updateBoxing+0x475>
mov    -0x14(%rbp),%esi
mov    %esi,%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
xor    %edi,%edi
lea    0x972(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
movl   $0x1,-0x18(%rbp)
mov    -0x18(%rbp),%eax
mov    %eax,-0x78(%rbp)
mov    0x293f(%rip),%rax
mov    (%rax),%edi
call   1040 <getmaxy@plt>
mov    %eax,%ecx
mov    -0x78(%rbp),%eax
cmp    %ecx,%eax
jge    17ca <di_updateBoxing+0x65a>
mov    -0x18(%rbp),%edi
xor    %esi,%esi
lea    0x93b(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
mov    -0x18(%rbp),%eax
mov    %eax,-0x8c(%rbp)
mov    0x2908(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    -0x8c(%rbp),%edi
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,%esi
sub    $0x1,%esi
lea    0x903(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
mov    -0x18(%rbp),%eax
mov    %eax,-0x88(%rbp)
mov    0x28d0(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    -0x88(%rbp),%edi
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,%esi
lea    0x8ce(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
mov    -0x18(%rbp),%eax
mov    %eax,-0x7c(%rbp)
mov    0x289e(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,-0x84(%rbp)
mov    0x2882(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,%ecx
mov    -0x84(%rbp),%eax
add    %ecx,%eax
mov    %eax,-0x80(%rbp)
mov    0x285f(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    -0x80(%rbp),%esi
mov    -0x7c(%rbp),%edi
mov    $0x2,%ecx
cltd
idiv   %ecx
cmp    $0x1,%edx
sete   %al
and    $0x1,%al
movzbl %al,%eax
add    %eax,%esi
sub    $0x1,%esi
lea    0x84f(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
mov    -0x18(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x18(%rbp)
jmp    169c <di_updateBoxing+0x52c>
mov    0x2817(%rip),%rax
mov    (%rax),%edi
call   1040 <getmaxy@plt>
mov    %eax,%edi
sub    $0x1,%edi
xor    %esi,%esi
lea    0x81a(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
movl   $0x1,-0x14(%rbp)
mov    -0x14(%rbp),%eax
mov    %eax,-0x90(%rbp)
mov    0x27e4(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,%ecx
mov    -0x90(%rbp),%eax
sub    $0x1,%ecx
cmp    %ecx,%eax
jge    1858 <di_updateBoxing+0x6e8>
mov    0x27bb(%rip),%rax
mov    (%rax),%edi
call   1040 <getmaxy@plt>
mov    %eax,%edi
sub    $0x1,%edi
mov    -0x14(%rbp),%esi
lea    0x7bf(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    17f4 <di_updateBoxing+0x684>
mov    0x2789(%rip),%rax
mov    (%rax),%edi
call   1040 <getmaxy@plt>
sub    $0x1,%eax
mov    %eax,-0x98(%rbp)
mov    0x2772(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    -0x98(%rbp),%edi
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,%esi
sub    $0x1,%esi
lea    0x769(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
mov    0x2743(%rip),%rax
mov    (%rax),%edi
call   1040 <getmaxy@plt>
sub    $0x1,%eax
mov    %eax,-0x94(%rbp)
mov    0x272c(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    -0x94(%rbp),%edi
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,%esi
lea    0x726(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
mov    0x2700(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    $0x2,%ecx
cltd
idiv   %ecx
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
mov    -0x14(%rbp),%eax
mov    %eax,-0x9c(%rbp)
mov    0x26db(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,-0xa4(%rbp)
mov    0x26bf(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,%ecx
mov    -0xa4(%rbp),%eax
add    %ecx,%eax
mov    %eax,-0xa0(%rbp)
mov    0x2699(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    -0xa0(%rbp),%ecx
mov    $0x2,%esi
cltd
idiv   %esi
mov    -0x9c(%rbp),%eax
cmp    $0x1,%edx
sete   %dl
and    $0x1,%dl
movzbl %dl,%edx
add    %edx,%ecx
sub    $0x1,%ecx
cmp    %ecx,%eax
jge    19b5 <di_updateBoxing+0x845>
mov    0x265e(%rip),%rax
mov    (%rax),%edi
call   1040 <getmaxy@plt>
mov    %eax,%edi
sub    $0x1,%edi
mov    -0x14(%rbp),%esi
lea    0x662(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    18fd <di_updateBoxing+0x78d>
mov    0x262c(%rip),%rax
mov    (%rax),%edi
call   1040 <getmaxy@plt>
sub    $0x1,%eax
mov    %eax,-0xa8(%rbp)
mov    0x2615(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,-0xb0(%rbp)
mov    0x25f9(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    $0x2,%ecx
cltd
idiv   %ecx
mov    %eax,%ecx
mov    -0xb0(%rbp),%eax
add    %ecx,%eax
mov    %eax,-0xac(%rbp)
mov    0x25d3(%rip),%rax
mov    (%rax),%edi
call   1080 <getmaxx@plt>
mov    -0xac(%rbp),%esi
mov    -0xa8(%rbp),%edi
mov    $0x2,%ecx
cltd
idiv   %ecx
cmp    $0x1,%edx
sete   %al
and    $0x1,%al
movzbl %al,%eax
add    %eax,%esi
sub    $0x1,%esi
lea    0x5b9(%rip),%rdx
mov    $0x0,%al
call   1090 <mvprintw@plt>
mov    $0x1,%edi
call   1070 <COLOR_PAIR@plt>
mov    %eax,%edi
call   1030 <attroff@plt>
add    $0xb0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<di_updateBoxing>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x18,%rsp
mov    %rsi,0x10(%rsp)
mov    %rdi,%rbx
mov    $0x1,%r15d
mov    $0x1,%edi
call   1070 <COLOR_PAIR@plt>
mov    %eax,%edi
call   1060 <attron@plt>
lea    0xe5c(%rip),%rdx
xor    %edi,%edi
xor    %esi,%esi
xor    %eax,%eax
call   1090 <mvprintw@plt>
mov    0x2e32(%rip),%r13
lea    0xe45(%rip),%r12
nopl   (%rax)
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ebp
shr    $0x1f,%ebp
add    %eax,%ebp
sar    %ebp
mov    %rbx,%rdi
call   1050 <strlen@plt>
sub    %eax,%ebp
mov    %ebp,%eax
shr    $0x1f,%eax
add    %ebp,%eax
sar    %eax
add    $0xffffffff,%eax
cmp    %eax,%r15d
jge    1225 <di_updateBoxing+0xb5>
mov    %rbx,%rdi
call   1050 <strlen@plt>
mov    %eax,%ebp
add    $0x4,%ebp
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ecx
shr    $0x1f,%ecx
add    %eax,%ecx
sar    %ecx
cmp    %ecx,%ebp
jge    1225 <di_updateBoxing+0xb5>
xor    %edi,%edi
mov    %r15d,%esi
mov    %r12,%rdx
xor    %eax,%eax
call   1090 <mvprintw@plt>
add    $0x1,%r15d
jmp    11c0 <di_updateBoxing+0x50>
lea    0xdd8(%rip),%rdx
xor    %edi,%edi
mov    %r15d,%esi
xor    %eax,%eax
call   1090 <mvprintw@plt>
lea    0x1(%r15),%ebp
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ecx
shr    $0x1f,%ecx
add    %eax,%ecx
sar    %ecx
add    $0xfffffffe,%ecx
cmp    %ecx,%ebp
jge    12c1 <di_updateBoxing+0x151>
mov    %rbx,%rdi
call   1050 <strlen@plt>
test   %eax,%eax
jle    12c1 <di_updateBoxing+0x151>
xor    %r12d,%r12d
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
mov    %ebp,%r15d
movsbl (%rbx,%r12,1),%ecx
xor    %edi,%edi
mov    %ebp,%esi
lea    0xd83(%rip),%rdx
xor    %eax,%eax
call   1090 <mvprintw@plt>
lea    0x1(%r15),%r14d
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ecx
shr    $0x1f,%ecx
add    %eax,%ecx
sar    %ecx
add    $0xfffffffe,%ecx
cmp    %ecx,%r14d
jge    12c4 <di_updateBoxing+0x154>
add    $0x1,%r12
mov    %rbx,%rdi
call   1050 <strlen@plt>
cltq
lea    0x1(%r15),%ebp
cmp    %rax,%r12
jl     1270 <di_updateBoxing+0x100>
jmp    12c4 <di_updateBoxing+0x154>
mov    %ebp,%r14d
add    $0x2,%r15d
lea    0xd35(%rip),%rdx
xor    %edi,%edi
mov    %r14d,%esi
xor    %eax,%eax
call   1090 <mvprintw@plt>
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ecx
shr    $0x1f,%ecx
add    %eax,%ecx
sar    %ecx
add    $0xffffffff,%ecx
cmp    %ecx,%r15d
jge    132d <di_updateBoxing+0x1bd>
lea    0xd06(%rip),%rbp
nopl   0x0(%rax)
xor    %edi,%edi
mov    %r15d,%esi
mov    %rbp,%rdx
xor    %eax,%eax
call   1090 <mvprintw@plt>
add    $0x1,%r15d
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ecx
shr    $0x1f,%ecx
add    %eax,%ecx
sar    %ecx
add    $0xffffffff,%ecx
cmp    %ecx,%r15d
jl     1300 <di_updateBoxing+0x190>
lea    0x1(%r15),%ebp
lea    0xcc8(%rip),%rbx
xor    %edi,%edi
mov    %r15d,%esi
mov    %rbx,%rdx
xor    %eax,%eax
call   1090 <mvprintw@plt>
xor    %edi,%edi
mov    %ebp,%esi
mov    %rbx,%rdx
xor    %eax,%eax
call   1090 <mvprintw@plt>
add    $0x4,%r15d
nopl   0x0(%rax)
lea    -0x2(%r15),%eax
mov    %eax,0x8(%rsp)
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ebp
shr    $0x1f,%ebp
add    %eax,%ebp
sar    %ebp
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ebx
shr    $0x1f,%ebx
add    %eax,%ebx
sar    %ebx
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ecx
shr    $0x1f,%ecx
add    %eax,%ecx
and    $0xfffffffe,%ecx
sub    %ecx,%eax
xor    %r14d,%r14d
cmp    $0x1,%eax
sete   %r14b
mov    %r13,%r12
mov    0x10(%rsp),%r13
mov    %r13,%rdi
call   1050 <strlen@plt>
sub    %eax,%ebx
add    %r14d,%ebx
mov    0x8(%rsp),%r14d
mov    %ebx,%eax
shr    $0x1f,%eax
add    %ebx,%eax
sar    %eax
add    %ebp,%eax
add    $0xffffffff,%eax
cmp    %eax,%r14d
jge    1439 <di_updateBoxing+0x2c9>
mov    %r13,%rdi
call   1050 <strlen@plt>
mov    %eax,%ebp
add    $0x4,%ebp
mov    (%r12),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ebx
shr    $0x1f,%ebx
add    %eax,%ebx
sar    %ebx
mov    (%r12),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ecx
shr    $0x1f,%ecx
add    %eax,%ecx
and    $0xfffffffe,%ecx
sub    %ecx,%eax
xor    %ecx,%ecx
cmp    $0x1,%eax
sete   %cl
add    %ebx,%ecx
cmp    %ecx,%ebp
jge    1439 <di_updateBoxing+0x2c9>
xor    %edi,%edi
mov    %r14d,%esi
lea    0xbdc(%rip),%rdx
xor    %eax,%eax
call   1090 <mvprintw@plt>
add    $0x1,%r15d
mov    %r12,%r13
jmp    1360 <di_updateBoxing+0x1f0>
lea    0xbc4(%rip),%rdx
xor    %edi,%edi
mov    %r14d,%esi
xor    %eax,%eax
call   1090 <mvprintw@plt>
xor    %eax,%eax
mov    %rax,0x8(%rsp)
mov    %r12,%r13
cs nopw 0x0(%rax,%rax,1)
lea    -0x1(%r15),%r12d
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ebx
shr    $0x1f,%ebx
add    %eax,%ebx
sar    %ebx
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%r14d
shr    $0x1f,%r14d
add    %eax,%r14d
sar    %r14d
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ecx
shr    $0x1f,%ecx
add    %eax,%ecx
and    $0xfffffffe,%ecx
sub    %ecx,%eax
xor    %ecx,%ecx
cmp    $0x1,%eax
sete   %cl
add    %ebx,%r14d
lea    (%rcx,%r14,1),%eax
add    $0xfffffffe,%eax
cmp    %eax,%r12d
mov    0x10(%rsp),%rbx
mov    0x8(%rsp),%rbp
jge    14fa <di_updateBoxing+0x38a>
mov    %rbx,%rdi
call   1050 <strlen@plt>
cltq
cmp    %rax,%rbp
jge    14fa <di_updateBoxing+0x38a>
movsbl (%rbx,%rbp,1),%ecx
xor    %edi,%edi
mov    %r12d,%esi
lea    0xb25(%rip),%rdx
xor    %eax,%eax
call   1090 <mvprintw@plt>
add    $0x1,%rbp
mov    %rbp,0x8(%rsp)
add    $0x1,%r15d
jmp    1460 <di_updateBoxing+0x2f0>
lea    0xb03(%rip),%rdx
xor    %edi,%edi
mov    %r12d,%esi
xor    %eax,%eax
call   1090 <mvprintw@plt>
lea    0xaee(%rip),%r14
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ebx
shr    $0x1f,%ebx
add    %eax,%ebx
sar    %ebx
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ebp
shr    $0x1f,%ebp
add    %eax,%ebp
sar    %ebp
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ecx
shr    $0x1f,%ecx
add    %eax,%ecx
and    $0xfffffffe,%ecx
sub    %ecx,%eax
xor    %ecx,%ecx
cmp    $0x1,%eax
sete   %cl
add    %ebx,%ebp
lea    (%rcx,%rbp,1),%eax
add    $0xffffffff,%eax
cmp    %eax,%r15d
jge    1583 <di_updateBoxing+0x413>
xor    %edi,%edi
mov    %r15d,%esi
mov    %r14,%rdx
xor    %eax,%eax
call   1090 <mvprintw@plt>
add    $0x1,%r15d
jmp    1520 <di_updateBoxing+0x3b0>
lea    0xa76(%rip),%rdx
xor    %edi,%edi
mov    %r15d,%esi
xor    %eax,%eax
call   1090 <mvprintw@plt>
mov    0x0(%r13),%edi
call   1040 <getmaxy@plt>
cmp    $0x2,%eax
jl     167c <di_updateBoxing+0x50c>
mov    $0x1,%r15d
lea    0xa4f(%rip),%r14
cs nopw 0x0(%rax,%rax,1)
nop
mov    %r15d,%edi
xor    %esi,%esi
mov    %r14,%rdx
xor    %eax,%eax
call   1090 <mvprintw@plt>
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%esi
shr    $0x1f,%esi
add    %eax,%esi
sar    %esi
add    $0xffffffff,%esi
mov    %r15d,%edi
mov    %r14,%rdx
xor    %eax,%eax
call   1090 <mvprintw@plt>
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%esi
shr    $0x1f,%esi
add    %eax,%esi
sar    %esi
mov    %r15d,%edi
mov    %r14,%rdx
xor    %eax,%eax
call   1090 <mvprintw@plt>
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ebp
shr    $0x1f,%ebp
add    %eax,%ebp
sar    %ebp
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ebx
shr    $0x1f,%ebx
add    %eax,%ebx
sar    %ebx
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ecx
shr    $0x1f,%ecx
add    %eax,%ecx
and    $0xfffffffe,%ecx
sub    %ecx,%eax
xor    %ecx,%ecx
cmp    $0x1,%eax
sete   %cl
add    %ebp,%ebx
lea    (%rcx,%rbx,1),%esi
add    $0xffffffff,%esi
mov    %r15d,%edi
mov    %r14,%rdx
xor    %eax,%eax
call   1090 <mvprintw@plt>
add    $0x1,%r15d
mov    0x0(%r13),%edi
call   1040 <getmaxy@plt>
cmp    %eax,%r15d
jl     15c0 <di_updateBoxing+0x450>
mov    0x0(%r13),%edi
call   1040 <getmaxy@plt>
lea    -0x1(%rax),%edi
lea    0x971(%rip),%rdx
xor    %esi,%esi
xor    %eax,%eax
call   1090 <mvprintw@plt>
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
cmp    $0x6,%eax
jl     16f4 <di_updateBoxing+0x584>
mov    $0x1,%ebx
lea    0x950(%rip),%rbp
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax)
mov    0x0(%r13),%edi
call   1040 <getmaxy@plt>
lea    -0x1(%rax),%edi
mov    %ebx,%esi
mov    %rbp,%rdx
xor    %eax,%eax
call   1090 <mvprintw@plt>
add    $0x1,%ebx
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ecx
shr    $0x1f,%ecx
add    %eax,%ecx
sar    %ecx
add    $0xffffffff,%ecx
cmp    %ecx,%ebx
jl     16c0 <di_updateBoxing+0x550>
mov    0x0(%r13),%edi
call   1040 <getmaxy@plt>
lea    -0x1(%rax),%ebp
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%esi
shr    $0x1f,%esi
add    %eax,%esi
sar    %esi
add    $0xffffffff,%esi
lea    0x8e4(%rip),%rbx
mov    %ebp,%edi
mov    %rbx,%rdx
xor    %eax,%eax
call   1090 <mvprintw@plt>
mov    0x0(%r13),%edi
call   1040 <getmaxy@plt>
lea    -0x1(%rax),%ebp
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%esi
shr    $0x1f,%esi
add    %eax,%esi
sar    %esi
mov    %ebp,%edi
mov    %rbx,%rdx
xor    %eax,%eax
call   1090 <mvprintw@plt>
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%r15d
shr    $0x1f,%r15d
add    %eax,%r15d
sar    %r15d
add    $0x1,%r15d
lea    0x88f(%rip),%r14
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ebp
shr    $0x1f,%ebp
add    %eax,%ebp
sar    %ebp
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ebx
shr    $0x1f,%ebx
add    %eax,%ebx
sar    %ebx
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ecx
shr    $0x1f,%ecx
add    %eax,%ecx
and    $0xfffffffe,%ecx
sub    %ecx,%eax
xor    %ecx,%ecx
cmp    $0x1,%eax
sete   %cl
add    %ebp,%ebx
add    %ecx,%ebx
add    $0xffffffff,%ebx
mov    0x0(%r13),%edi
call   1040 <getmaxy@plt>
mov    %eax,%ebp
add    $0xffffffff,%ebp
cmp    %ebx,%r15d
jge    17f0 <di_updateBoxing+0x680>
mov    %ebp,%edi
mov    %r15d,%esi
mov    %r14,%rdx
xor    %eax,%eax
call   1090 <mvprintw@plt>
add    $0x1,%r15d
jmp    1780 <di_updateBoxing+0x610>
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%r14d
shr    $0x1f,%r14d
add    %eax,%r14d
sar    %r14d
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ebx
shr    $0x1f,%ebx
add    %eax,%ebx
sar    %ebx
mov    0x0(%r13),%edi
call   1080 <getmaxx@plt>
mov    %eax,%ecx
shr    $0x1f,%ecx
add    %eax,%ecx
and    $0xfffffffe,%ecx
sub    %ecx,%eax
xor    %ecx,%ecx
cmp    $0x1,%eax
sete   %cl
add    %r14d,%ebx
lea    (%rcx,%rbx,1),%esi
add    $0xffffffff,%esi
lea    0x7bb(%rip),%rdx
mov    %ebp,%edi
xor    %eax,%eax
call   1090 <mvprintw@plt>
mov    $0x1,%edi
call   1070 <COLOR_PAIR@plt>
mov    %eax,%edi
add    $0x18,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
jmp    1030 <attroff@plt>

LLVM IR (-O0):
@.str = [2 x i8] c"+\00"
@stdscr = global i32 0
@.str.1 = [2 x i8] c"-\00"
@.str.2 = [2 x i8] c"|\00"
@.str.3 = [3 x i8] c"%c\00"
define void @di_updateBoxing(i8* %0, i8* %1) {
%3 = alloca i8*
%4 = alloca i8*
%5 = alloca i32
%6 = alloca i32
store i8* %0, i8** %3
store i8* %1, i8** %4
%7 = call i32 @COLOR_PAIR(i32 1)
%8 = call i32 @attron(i32 %7)
%9 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 0, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
store i32 1, i32* %5
br label %10
10: ; preds = %34, %2
%11 = load i32, i32* %5
%12 = load i32, i32* @stdscr
%13 = call i32 @getmaxx(i32 %12)
%14 = sdiv i32 %13, 2
%15 = load i8*, i8** %3
%16 = call i32 @strlen(i8* %15)
%17 = sub nsw i32 %14, %16
%18 = sdiv i32 %17, 2
%19 = sub nsw i32 %18, 1
%20 = icmp slt i32 %11, %19
br i1 %20, label %21, label %29
21: ; preds = %10
%22 = load i8*, i8** %3
%23 = call i32 @strlen(i8* %22)
%24 = add nsw i32 %23, 4
%25 = load i32, i32* @stdscr
%26 = call i32 @getmaxx(i32 %25)
%27 = sdiv i32 %26, 2
%28 = icmp slt i32 %24, %27
br label %29
29: ; preds = %21, %10
%30 = phi i1 [ false, %10 ], [ %28, %21 ]
br i1 %30, label %31, label %37
31: ; preds = %29
%32 = load i32, i32* %5
%33 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %32, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
br label %34
34: ; preds = %31
%35 = load i32, i32* %5
%36 = add nsw i32 %35, 1
store i32 %36, i32* %5
br label %10
37: ; preds = %29
%38 = load i32, i32* %5
%39 = add nsw i32 %38, 1
store i32 %39, i32* %5
%40 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %38, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
store i32 0, i32* %6
br label %41
41: ; preds = %64, %37
%42 = load i32, i32* %5
%43 = load i32, i32* @stdscr
%44 = call i32 @getmaxx(i32 %43)
%45 = sdiv i32 %44, 2
%46 = sub nsw i32 %45, 2
%47 = icmp slt i32 %42, %46
br i1 %47, label %48, label %53
48: ; preds = %41
%49 = load i32, i32* %6
%50 = load i8*, i8** %3
%51 = call i32 @strlen(i8* %50)
%52 = icmp slt i32 %49, %51
br label %53
53: ; preds = %48, %41
%54 = phi i1 [ false, %41 ], [ %52, %48 ]
br i1 %54, label %55, label %69
55: ; preds = %53
%56 = load i32, i32* %5
%57 = load i8*, i8** %3
%58 = load i32, i32* %6
%59 = sext i32 %58 to i64
%60 = getelementptr inbounds i8, i8* %57, i64 %59
%61 = load i8, i8* %60
%62 = sext i8 %61 to i32
%63 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %56, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i32 %62)
br label %64
64: ; preds = %55
%65 = load i32, i32* %6
%66 = add nsw i32 %65, 1
store i32 %66, i32* %6
%67 = load i32, i32* %5
%68 = add nsw i32 %67, 1
store i32 %68, i32* %5
br label %41
69: ; preds = %53
%70 = load i32, i32* %5
%71 = add nsw i32 %70, 1
store i32 %71, i32* %5
%72 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %70, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
br label %73
73: ; preds = %83, %69
%74 = load i32, i32* %5
%75 = load i32, i32* @stdscr
%76 = call i32 @getmaxx(i32 %75)
%77 = sdiv i32 %76, 2
%78 = sub nsw i32 %77, 1
%79 = icmp slt i32 %74, %78
br i1 %79, label %80, label %86
80: ; preds = %73
%81 = load i32, i32* %5
%82 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %81, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
br label %83
83: ; preds = %80
%84 = load i32, i32* %5
%85 = add nsw i32 %84, 1
store i32 %85, i32* %5
br label %73
86: ; preds = %73
%87 = load i32, i32* %5
%88 = add nsw i32 %87, 1
store i32 %88, i32* %5
%89 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %87, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
%90 = load i32, i32* %5
%91 = add nsw i32 %90, 1
store i32 %91, i32* %5
%92 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %90, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
br label %93
93: ; preds = %133, %86
%94 = load i32, i32* %5
%95 = load i32, i32* @stdscr
%96 = call i32 @getmaxx(i32 %95)
%97 = sdiv i32 %96, 2
%98 = load i32, i32* @stdscr
%99 = call i32 @getmaxx(i32 %98)
%100 = sdiv i32 %99, 2
%101 = load i32, i32* @stdscr
%102 = call i32 @getmaxx(i32 %101)
%103 = srem i32 %102, 2
%104 = icmp eq i32 %103, 1
%105 = zext i1 %104 to i32
%106 = add nsw i32 %100, %105
%107 = load i8*, i8** %4
%108 = call i32 @strlen(i8* %107)
%109 = sub nsw i32 %106, %108
%110 = sdiv i32 %109, 2
%111 = add nsw i32 %97, %110
%112 = sub nsw i32 %111, 1
%113 = icmp slt i32 %94, %112
br i1 %113, label %114, label %128
114: ; preds = %93
%115 = load i8*, i8** %4
%116 = call i32 @strlen(i8* %115)
%117 = add nsw i32 %116, 4
%118 = load i32, i32* @stdscr
%119 = call i32 @getmaxx(i32 %118)
%120 = sdiv i32 %119, 2
%121 = load i32, i32* @stdscr
%122 = call i32 @getmaxx(i32 %121)
%123 = srem i32 %122, 2
%124 = icmp eq i32 %123, 1
%125 = zext i1 %124 to i32
%126 = add nsw i32 %120, %125
%127 = icmp slt i32 %117, %126
br label %128
128: ; preds = %114, %93
%129 = phi i1 [ false, %93 ], [ %127, %114 ]
br i1 %129, label %130, label %136
130: ; preds = %128
%131 = load i32, i32* %5
%132 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %131, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
br label %133
133: ; preds = %130
%134 = load i32, i32* %5
%135 = add nsw i32 %134, 1
store i32 %135, i32* %5
br label %93
136: ; preds = %128
%137 = load i32, i32* %5
%138 = add nsw i32 %137, 1
store i32 %138, i32* %5
%139 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %137, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
store i32 0, i32* %6
br label %140
140: ; preds = %173, %136
%141 = load i32, i32* %5
%142 = load i32, i32* @stdscr
%143 = call i32 @getmaxx(i32 %142)
%144 = sdiv i32 %143, 2
%145 = load i32, i32* @stdscr
%146 = call i32 @getmaxx(i32 %145)
%147 = sdiv i32 %146, 2
%148 = add nsw i32 %144, %147
%149 = load i32, i32* @stdscr
%150 = call i32 @getmaxx(i32 %149)
%151 = srem i32 %150, 2
%152 = icmp eq i32 %151, 1
%153 = zext i1 %152 to i32
%154 = add nsw i32 %148, %153
%155 = sub nsw i32 %154, 2
%156 = icmp slt i32 %141, %155
br i1 %156, label %157, label %162
157: ; preds = %140
%158 = load i32, i32* %6
%159 = load i8*, i8** %4
%160 = call i32 @strlen(i8* %159)
%161 = icmp slt i32 %158, %160
br label %162
162: ; preds = %157, %140
%163 = phi i1 [ false, %140 ], [ %161, %157 ]
br i1 %163, label %164, label %178
164: ; preds = %162
%165 = load i32, i32* %5
%166 = load i8*, i8** %4
%167 = load i32, i32* %6
%168 = sext i32 %167 to i64
%169 = getelementptr inbounds i8, i8* %166, i64 %168
%170 = load i8, i8* %169
%171 = sext i8 %170 to i32
%172 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %165, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i32 %171)
br label %173
173: ; preds = %164
%174 = load i32, i32* %6
%175 = add nsw i32 %174, 1
store i32 %175, i32* %6
%176 = load i32, i32* %5
%177 = add nsw i32 %176, 1
store i32 %177, i32* %5
br label %140
178: ; preds = %162
%179 = load i32, i32* %5
%180 = add nsw i32 %179, 1
store i32 %180, i32* %5
%181 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %179, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
br label %182
182: ; preds = %202, %178
%183 = load i32, i32* %5
%184 = load i32, i32* @stdscr
%185 = call i32 @getmaxx(i32 %184)
%186 = sdiv i32 %185, 2
%187 = load i32, i32* @stdscr
%188 = call i32 @getmaxx(i32 %187)
%189 = sdiv i32 %188, 2
%190 = add nsw i32 %186, %189
%191 = load i32, i32* @stdscr
%192 = call i32 @getmaxx(i32 %191)
%193 = srem i32 %192, 2
%194 = icmp eq i32 %193, 1
%195 = zext i1 %194 to i32
%196 = add nsw i32 %190, %195
%197 = sub nsw i32 %196, 1
%198 = icmp slt i32 %183, %197
br i1 %198, label %199, label %205
199: ; preds = %182
%200 = load i32, i32* %5
%201 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %200, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
br label %202
202: ; preds = %199
%203 = load i32, i32* %5
%204 = add nsw i32 %203, 1
store i32 %204, i32* %5
br label %182
205: ; preds = %182
%206 = load i32, i32* %5
%207 = add nsw i32 %206, 1
store i32 %207, i32* %5
%208 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %206, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
store i32 1, i32* %6
br label %209
209: ; preds = %244, %205
%210 = load i32, i32* %6
%211 = load i32, i32* @stdscr
%212 = call i32 @getmaxy(i32 %211)
%213 = icmp slt i32 %210, %212
br i1 %213, label %214, label %247
214: ; preds = %209
%215 = load i32, i32* %6
%216 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 %215, i32 0, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
%217 = load i32, i32* %6
%218 = load i32, i32* @stdscr
%219 = call i32 @getmaxx(i32 %218)
%220 = sdiv i32 %219, 2
%221 = sub nsw i32 %220, 1
%222 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 %217, i32 %221, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
%223 = load i32, i32* %6
%224 = load i32, i32* @stdscr
%225 = call i32 @getmaxx(i32 %224)
%226 = sdiv i32 %225, 2
%227 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 %223, i32 %226, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
%228 = load i32, i32* %6
%229 = load i32, i32* @stdscr
%230 = call i32 @getmaxx(i32 %229)
%231 = sdiv i32 %230, 2
%232 = load i32, i32* @stdscr
%233 = call i32 @getmaxx(i32 %232)
%234 = sdiv i32 %233, 2
%235 = add nsw i32 %231, %234
%236 = load i32, i32* @stdscr
%237 = call i32 @getmaxx(i32 %236)
%238 = srem i32 %237, 2
%239 = icmp eq i32 %238, 1
%240 = zext i1 %239 to i32
%241 = add nsw i32 %235, %240
%242 = sub nsw i32 %241, 1
%243 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 %228, i32 %242, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
br label %244
244: ; preds = %214
%245 = load i32, i32* %6
%246 = add nsw i32 %245, 1
store i32 %246, i32* %6
br label %209
247: ; preds = %209
%248 = load i32, i32* @stdscr
%249 = call i32 @getmaxy(i32 %248)
%250 = sub nsw i32 %249, 1
%251 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 %250, i32 0, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
store i32 1, i32* %5
br label %252
252: ; preds = %265, %247
%253 = load i32, i32* %5
%254 = load i32, i32* @stdscr
%255 = call i32 @getmaxx(i32 %254)
%256 = sdiv i32 %255, 2
%257 = sub nsw i32 %256, 1
%258 = icmp slt i32 %253, %257
br i1 %258, label %259, label %268
259: ; preds = %252
%260 = load i32, i32* @stdscr
%261 = call i32 @getmaxy(i32 %260)
%262 = sub nsw i32 %261, 1
%263 = load i32, i32* %5
%264 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 %262, i32 %263, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
br label %265
265: ; preds = %259
%266 = load i32, i32* %5
%267 = add nsw i32 %266, 1
store i32 %267, i32* %5
br label %252
268: ; preds = %252
%269 = load i32, i32* @stdscr
%270 = call i32 @getmaxy(i32 %269)
%271 = sub nsw i32 %270, 1
%272 = load i32, i32* @stdscr
%273 = call i32 @getmaxx(i32 %272)
%274 = sdiv i32 %273, 2
%275 = sub nsw i32 %274, 1
%276 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 %271, i32 %275, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
%277 = load i32, i32* @stdscr
%278 = call i32 @getmaxy(i32 %277)
%279 = sub nsw i32 %278, 1
%280 = load i32, i32* @stdscr
%281 = call i32 @getmaxx(i32 %280)
%282 = sdiv i32 %281, 2
%283 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 %279, i32 %282, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
%284 = load i32, i32* @stdscr
%285 = call i32 @getmaxx(i32 %284)
%286 = sdiv i32 %285, 2
%287 = add nsw i32 %286, 1
store i32 %287, i32* %5
br label %288
288: ; preds = %311, %268
%289 = load i32, i32* %5
%290 = load i32, i32* @stdscr
%291 = call i32 @getmaxx(i32 %290)
%292 = sdiv i32 %291, 2
%293 = load i32, i32* @stdscr
%294 = call i32 @getmaxx(i32 %293)
%295 = sdiv i32 %294, 2
%296 = add nsw i32 %292, %295
%297 = load i32, i32* @stdscr
%298 = call i32 @getmaxx(i32 %297)
%299 = srem i32 %298, 2
%300 = icmp eq i32 %299, 1
%301 = zext i1 %300 to i32
%302 = add nsw i32 %296, %301
%303 = sub nsw i32 %302, 1
%304 = icmp slt i32 %289, %303
br i1 %304, label %305, label %314
305: ; preds = %288
%306 = load i32, i32* @stdscr
%307 = call i32 @getmaxy(i32 %306)
%308 = sub nsw i32 %307, 1
%309 = load i32, i32* %5
%310 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 %308, i32 %309, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
br label %311
311: ; preds = %305
%312 = load i32, i32* %5
%313 = add nsw i32 %312, 1
store i32 %313, i32* %5
br label %288
314: ; preds = %288
%315 = load i32, i32* @stdscr
%316 = call i32 @getmaxy(i32 %315)
%317 = sub nsw i32 %316, 1
%318 = load i32, i32* @stdscr
%319 = call i32 @getmaxx(i32 %318)
%320 = sdiv i32 %319, 2
%321 = load i32, i32* @stdscr
%322 = call i32 @getmaxx(i32 %321)
%323 = sdiv i32 %322, 2
%324 = add nsw i32 %320, %323
%325 = load i32, i32* @stdscr
%326 = call i32 @getmaxx(i32 %325)
%327 = srem i32 %326, 2
%328 = icmp eq i32 %327, 1
%329 = zext i1 %328 to i32
%330 = add nsw i32 %324, %329
%331 = sub nsw i32 %330, 1
%332 = call i32 (i32, i32, i8*, ...) @mvprintw(i32 %317, i32 %331, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
%333 = call i32 @COLOR_PAIR(i32 1)
%334 = call i32 @attroff(i32 %333)
ret void
}

LLVM IR (-O2):
@.str = [2 x i8] c"+\00"
@stdscr = global i32 0
@.str.1 = [2 x i8] c"-\00"
@.str.2 = [2 x i8] c"|\00"
@.str.3 = [3 x i8] c"%c\00"
define void @di_updateBoxing(i8* %0, i8* %1) {
%3 = tail call i32 @COLOR_PAIR(i32 1)
%4 = tail call i32 @attron(i32 %3)
%5 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 0, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
br label %6
6: ; preds = %23, %2
%7 = phi i32 [ 1, %2 ], [ %25, %23 ]
%8 = load i32, i32* @stdscr
%9 = tail call i32 @getmaxx(i32 %8)
%10 = sdiv i32 %9, 2
%11 = tail call i32 @strlen(i8* %0)
%12 = sub nsw i32 %10, %11
%13 = sdiv i32 %12, 2
%14 = add nsw i32 %13, -1
%15 = icmp slt i32 %7, %14
br i1 %15, label %16, label %26
16: ; preds = %6
%17 = tail call i32 @strlen(i8* %0)
%18 = add nsw i32 %17, 4
%19 = load i32, i32* @stdscr
%20 = tail call i32 @getmaxx(i32 %19)
%21 = sdiv i32 %20, 2
%22 = icmp slt i32 %18, %21
br i1 %22, label %23, label %26
23: ; preds = %16
%24 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %7, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%25 = add nuw nsw i32 %7, 1
br label %6
26: ; preds = %6, %16
%27 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %7, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
%28 = add nuw nsw i32 %7, 1
%29 = load i32, i32* @stdscr
%30 = tail call i32 @getmaxx(i32 %29)
%31 = sdiv i32 %30, 2
%32 = add nsw i32 %31, -2
%33 = icmp slt i32 %28, %32
br i1 %33, label %34, label %55
34: ; preds = %26
%35 = tail call i32 @strlen(i8* %0)
%36 = icmp sgt i32 %35, 0
br i1 %36, label %41, label %55
37: ; preds = %41
%38 = tail call i32 @strlen(i8* %0)
%39 = sext i32 %38 to i64
%40 = icmp slt i64 %48, %39
br i1 %40, label %41, label %55
41: ; preds = %34, %37
%42 = phi i32 [ %49, %37 ], [ %28, %34 ]
%43 = phi i64 [ %48, %37 ], [ 0, %34 ]
%44 = getelementptr inbounds i8, i8* %0, i64 %43
%45 = load i8, i8* %44
%46 = sext i8 %45 to i32
%47 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %42, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i32 %46)
%48 = add nuw nsw i64 %43, 1
%49 = add nuw nsw i32 %42, 1
%50 = load i32, i32* @stdscr
%51 = tail call i32 @getmaxx(i32 %50)
%52 = sdiv i32 %51, 2
%53 = add nsw i32 %52, -2
%54 = icmp slt i32 %49, %53
br i1 %54, label %37, label %55
55: ; preds = %41, %37, %34, %26
%56 = phi i32 [ %7, %26 ], [ %7, %34 ], [ %42, %37 ], [ %42, %41 ]
%57 = phi i32 [ %28, %26 ], [ %28, %34 ], [ %49, %37 ], [ %49, %41 ]
%58 = add nuw nsw i32 %56, 2
%59 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %57, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
%60 = load i32, i32* @stdscr
%61 = tail call i32 @getmaxx(i32 %60)
%62 = sdiv i32 %61, 2
%63 = add nsw i32 %62, -1
%64 = icmp slt i32 %58, %63
br i1 %64, label %65, label %74
65: ; preds = %55, %65
%66 = phi i32 [ %68, %65 ], [ %58, %55 ]
%67 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %66, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%68 = add nuw nsw i32 %66, 1
%69 = load i32, i32* @stdscr
%70 = tail call i32 @getmaxx(i32 %69)
%71 = sdiv i32 %70, 2
%72 = add nsw i32 %71, -1
%73 = icmp slt i32 %68, %72
br i1 %73, label %65, label %74
74: ; preds = %65, %55
%75 = phi i32 [ %58, %55 ], [ %68, %65 ]
%76 = add nuw nsw i32 %75, 1
%77 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %75, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
%78 = add nuw nsw i32 %75, 2
%79 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %76, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
br label %80
80: ; preds = %113, %74
%81 = phi i32 [ %78, %74 ], [ %115, %113 ]
%82 = load i32, i32* @stdscr
%83 = tail call i32 @getmaxx(i32 %82)
%84 = sdiv i32 %83, 2
%85 = load i32, i32* @stdscr
%86 = tail call i32 @getmaxx(i32 %85)
%87 = sdiv i32 %86, 2
%88 = load i32, i32* @stdscr
%89 = tail call i32 @getmaxx(i32 %88)
%90 = srem i32 %89, 2
%91 = icmp eq i32 %90, 1
%92 = zext i1 %91 to i32
%93 = tail call i32 @strlen(i8* %1)
%94 = sub i32 %87, %93
%95 = add i32 %94, %92
%96 = sdiv i32 %95, 2
%97 = add nsw i32 %84, -1
%98 = add i32 %97, %96
%99 = icmp slt i32 %81, %98
br i1 %99, label %100, label %116
100: ; preds = %80
%101 = tail call i32 @strlen(i8* %1)
%102 = add nsw i32 %101, 4
%103 = load i32, i32* @stdscr
%104 = tail call i32 @getmaxx(i32 %103)
%105 = sdiv i32 %104, 2
%106 = load i32, i32* @stdscr
%107 = tail call i32 @getmaxx(i32 %106)
%108 = srem i32 %107, 2
%109 = icmp eq i32 %108, 1
%110 = zext i1 %109 to i32
%111 = add nsw i32 %105, %110
%112 = icmp slt i32 %102, %111
br i1 %112, label %113, label %116
113: ; preds = %100
%114 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %81, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%115 = add nuw nsw i32 %81, 1
br label %80
116: ; preds = %80, %100
%117 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %81, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
br label %118
118: ; preds = %141, %116
%119 = phi i64 [ %146, %141 ], [ 0, %116 ]
%120 = phi i32 [ %121, %141 ], [ %81, %116 ]
%121 = add nsw i32 %120, 1
%122 = load i32, i32* @stdscr
%123 = tail call i32 @getmaxx(i32 %122)
%124 = sdiv i32 %123, 2
%125 = load i32, i32* @stdscr
%126 = tail call i32 @getmaxx(i32 %125)
%127 = sdiv i32 %126, 2
%128 = load i32, i32* @stdscr
%129 = tail call i32 @getmaxx(i32 %128)
%130 = srem i32 %129, 2
%131 = icmp eq i32 %130, 1
%132 = zext i1 %131 to i32
%133 = add nsw i32 %124, -2
%134 = add i32 %133, %127
%135 = add i32 %134, %132
%136 = icmp slt i32 %121, %135
br i1 %136, label %137, label %147
137: ; preds = %118
%138 = tail call i32 @strlen(i8* %1)
%139 = sext i32 %138 to i64
%140 = icmp slt i64 %119, %139
br i1 %140, label %141, label %147
141: ; preds = %137
%142 = getelementptr inbounds i8, i8* %1, i64 %119
%143 = load i8, i8* %142
%144 = sext i8 %143 to i32
%145 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %121, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0), i32 %144)
%146 = add nuw nsw i64 %119, 1
br label %118
147: ; preds = %118, %137
%148 = add nsw i32 %120, 2
%149 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %121, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
br label %150
150: ; preds = %167, %147
%151 = phi i32 [ %148, %147 ], [ %169, %167 ]
%152 = load i32, i32* @stdscr
%153 = tail call i32 @getmaxx(i32 %152)
%154 = sdiv i32 %153, 2
%155 = load i32, i32* @stdscr
%156 = tail call i32 @getmaxx(i32 %155)
%157 = sdiv i32 %156, 2
%158 = load i32, i32* @stdscr
%159 = tail call i32 @getmaxx(i32 %158)
%160 = srem i32 %159, 2
%161 = icmp eq i32 %160, 1
%162 = zext i1 %161 to i32
%163 = add nsw i32 %154, -1
%164 = add i32 %163, %157
%165 = add i32 %164, %162
%166 = icmp slt i32 %151, %165
br i1 %166, label %167, label %170
167: ; preds = %150
%168 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %151, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%169 = add nsw i32 %151, 1
br label %150
170: ; preds = %150
%171 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 0, i32 %151, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
%172 = load i32, i32* @stdscr
%173 = tail call i32 @getmaxy(i32 %172)
%174 = icmp sgt i32 %173, 1
br i1 %174, label %175, label %206
175: ; preds = %170, %175
%176 = phi i32 [ %202, %175 ], [ 1, %170 ]
%177 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 %176, i32 0, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
%178 = load i32, i32* @stdscr
%179 = tail call i32 @getmaxx(i32 %178)
%180 = sdiv i32 %179, 2
%181 = add nsw i32 %180, -1
%182 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 %176, i32 %181, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
%183 = load i32, i32* @stdscr
%184 = tail call i32 @getmaxx(i32 %183)
%185 = sdiv i32 %184, 2
%186 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 %176, i32 %185, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
%187 = load i32, i32* @stdscr
%188 = tail call i32 @getmaxx(i32 %187)
%189 = sdiv i32 %188, 2
%190 = load i32, i32* @stdscr
%191 = tail call i32 @getmaxx(i32 %190)
%192 = sdiv i32 %191, 2
%193 = load i32, i32* @stdscr
%194 = tail call i32 @getmaxx(i32 %193)
%195 = srem i32 %194, 2
%196 = icmp eq i32 %195, 1
%197 = zext i1 %196 to i32
%198 = add nsw i32 %189, -1
%199 = add i32 %198, %192
%200 = add i32 %199, %197
%201 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 %176, i32 %200, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
%202 = add nuw nsw i32 %176, 1
%203 = load i32, i32* @stdscr
%204 = tail call i32 @getmaxy(i32 %203)
%205 = icmp slt i32 %202, %204
br i1 %205, label %175, label %206
206: ; preds = %175, %170
%207 = load i32, i32* @stdscr
%208 = tail call i32 @getmaxy(i32 %207)
%209 = add nsw i32 %208, -1
%210 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 %209, i32 0, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
%211 = load i32, i32* @stdscr
%212 = tail call i32 @getmaxx(i32 %211)
%213 = icmp sgt i32 %212, 5
br i1 %213, label %214, label %226
214: ; preds = %206, %214
%215 = phi i32 [ %220, %214 ], [ 1, %206 ]
%216 = load i32, i32* @stdscr
%217 = tail call i32 @getmaxy(i32 %216)
%218 = add nsw i32 %217, -1
%219 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 %218, i32 %215, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
%220 = add nuw nsw i32 %215, 1
%221 = load i32, i32* @stdscr
%222 = tail call i32 @getmaxx(i32 %221)
%223 = sdiv i32 %222, 2
%224 = add nsw i32 %223, -1
%225 = icmp slt i32 %220, %224
br i1 %225, label %214, label %226
226: ; preds = %214, %206
%227 = load i32, i32* @stdscr
%228 = tail call i32 @getmaxy(i32 %227)
%229 = add nsw i32 %228, -1
%230 = load i32, i32* @stdscr
%231 = tail call i32 @getmaxx(i32 %230)
%232 = sdiv i32 %231, 2
%233 = add nsw i32 %232, -1
%234 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 %229, i32 %233, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
%235 = load i32, i32* @stdscr
%236 = tail call i32 @getmaxy(i32 %235)
%237 = add nsw i32 %236, -1
%238 = load i32, i32* @stdscr
%239 = tail call i32 @getmaxx(i32 %238)
%240 = sdiv i32 %239, 2
%241 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 %237, i32 %240, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
%242 = load i32, i32* @stdscr
%243 = tail call i32 @getmaxx(i32 %242)
%244 = sdiv i32 %243, 2
br label %245
245: ; preds = %266, %226
%246 = phi i32 [ %244, %226 ], [ %247, %266 ]
%247 = add nsw i32 %246, 1
%248 = load i32, i32* @stdscr
%249 = tail call i32 @getmaxx(i32 %248)
%250 = sdiv i32 %249, 2
%251 = load i32, i32* @stdscr
%252 = tail call i32 @getmaxx(i32 %251)
%253 = sdiv i32 %252, 2
%254 = load i32, i32* @stdscr
%255 = tail call i32 @getmaxx(i32 %254)
%256 = srem i32 %255, 2
%257 = icmp eq i32 %256, 1
%258 = zext i1 %257 to i32
%259 = add nsw i32 %250, -1
%260 = add i32 %259, %253
%261 = add i32 %260, %258
%262 = icmp slt i32 %247, %261
%263 = load i32, i32* @stdscr
%264 = tail call i32 @getmaxy(i32 %263)
%265 = add nsw i32 %264, -1
br i1 %262, label %266, label %268
266: ; preds = %245
%267 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 %265, i32 %247, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.1, i64 0, i64 0))
br label %245
268: ; preds = %245
%269 = load i32, i32* @stdscr
%270 = tail call i32 @getmaxx(i32 %269)
%271 = sdiv i32 %270, 2
%272 = load i32, i32* @stdscr
%273 = tail call i32 @getmaxx(i32 %272)
%274 = sdiv i32 %273, 2
%275 = load i32, i32* @stdscr
%276 = tail call i32 @getmaxx(i32 %275)
%277 = srem i32 %276, 2
%278 = icmp eq i32 %277, 1
%279 = zext i1 %278 to i32
%280 = add nsw i32 %271, -1
%281 = add i32 %280, %274
%282 = add i32 %281, %279
%283 = tail call i32 (i32, i32, i8*, ...) @mvprintw(i32 %265, i32 %282, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
%284 = tail call i32 @COLOR_PAIR(i32 1)
%285 = tail call i32 @attroff(i32 %284)
ret void
}