#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 */
typedef int /*<<< orphan*/ WINDOW;

/* Variables and functions */
int /*<<< orphan*/ ACS_HLINE;
int /*<<< orphan*/ ACS_VLINE;
int /*<<< orphan*/ A_BOLD;
int /*<<< orphan*/ Continue(int /*<<< orphan*/ *);
int KEY_MIN;
int /*<<< orphan*/ TRUE;
int /*<<< orphan*/ box(int /*<<< orphan*/ *, int /*<<< orphan*/,
                       int /*<<< orphan*/);
int /*<<< orphan*/ delwin(int /*<<< orphan*/ *);
int /*<<< orphan*/ echo();
int /*<<< orphan*/ flash();
int /*<<< orphan*/ flushinp();
int /*<<< orphan*/ getbegyx(int /*<<< orphan*/ *, int, int);
int /*<<< orphan*/ getmaxyx(int /*<<< orphan*/ *, int, int);
scalar_t__ isprint(int);
int keyname(int);
int /*<<< orphan*/ keypad(int /*<<< orphan*/ *, int /*<<< orphan*/);
int /*<<< orphan*/ mvwaddstr(int /*<<< orphan*/ *, int, int, char *);
int /*<<< orphan*/ mvwin(int /*<<< orphan*/ *, int, int);
int /*<<< orphan*/ mvwprintw(int /*<<< orphan*/ *, int, int, char *, ...);
int /*<<< orphan*/ mvwscanw(int /*<<< orphan*/ *, int, int, char *, int *,
                            char *);
int /*<<< orphan*/ napms(int);
int /*<<< orphan*/ nocbreak();
int /*<<< orphan*/ noecho();
int /*<<< orphan*/ raw();
int /*<<< orphan*/ refresh();
int /*<<< orphan*/ *subwin(int /*<<< orphan*/ *, int, int, int, int);
int /*<<< orphan*/ typeahead(int);
int unctrl(int);
int /*<<< orphan*/ wbkgd(int /*<<< orphan*/ *, int /*<<< orphan*/);
int /*<<< orphan*/ wclear(int /*<<< orphan*/ *);
int /*<<< orphan*/ wclrtobot(int /*<<< orphan*/ *);
int /*<<< orphan*/ wdelch(int /*<<< orphan*/ *);
int /*<<< orphan*/ werase(int /*<<< orphan*/ *);
int wgetch(int /*<<< orphan*/ *);
int /*<<< orphan*/ wgetnstr(int /*<<< orphan*/ *, char *, int);
int /*<<< orphan*/ wmove(int /*<<< orphan*/ *, int, int);
int /*<<< orphan*/ wprintw(int /*<<< orphan*/ *, char *, int);
int /*<<< orphan*/ wrefresh(int /*<<< orphan*/ *);
void inputTest(WINDOW *win) {
  int w, h, bx, by, sw, sh, i, c, num;
  char buffer[80];
  WINDOW *subWin;
  wclear(win);
  getmaxyx(win, h, w);
  getbegyx(win, by, bx);
  sw = w / 3;
  sh = h / 3;
  if ((subWin = subwin(win, sh, sw, by + h - sh - 2, bx + w - sw - 2)) == NULL)
    return;
  wbkgd(subWin, A_BOLD);
  box(subWin, ACS_VLINE, ACS_HLINE);
  wrefresh(win);
  nocbreak();
  wclear(win);
  mvwaddstr(win, 1, 1, "Press keys (or mouse buttons) to show their names");
  mvwaddstr(win, 2, 1, "Press spacebar to finish");
  wrefresh(win);
  keypad(win, TRUE);
  raw();
  noecho();
  typeahead(-1);
  while (1) {
    wmove(win, 3, 5);
    c = wgetch(win);
    wclrtobot(win);
    if (c >= KEY_MIN)
      wprintw(win, "Key Pressed: %s", keyname(c));
    else if (isprint(c))
      wprintw(win, "Key Pressed: %c", c);
    else
      wprintw(win, "Key Pressed: %s", unctrl(c));
    wrefresh(win);
    if (c == ' ')
      break;
  }
  wclear(win);
  mvwaddstr(win, 2, 1, "Press some keys for 5 seconds");
  mvwaddstr(win, 1, 1, "Pressing ^C should do nothing");
  wrefresh(win);
  werase(subWin);
  box(subWin, ACS_VLINE, ACS_HLINE);
  for (i = 0; i < 5; i++) {
    mvwprintw(subWin, 1, 1, "Time = %d", i);
    wrefresh(subWin);
    napms(1000);
    flushinp();
  }
  delwin(subWin);
  werase(win);
  flash();
  wrefresh(win);
  napms(500);
  flushinp();
  mvwaddstr(win, 2, 1, "Press a key, followed by ENTER");
  wmove(win, 9, 10);
  wrefresh(win);
  echo();
  keypad(win, TRUE);
  raw();
  wgetnstr(win, buffer, 3);
  flushinp();
  wmove(win, 9, 10);
  wdelch(win);
  mvwaddstr(win, 4, 1, "The character should now have been deleted");
  Continue(win);
  refresh();
  wclear(win);
  echo();
  mvwaddstr(win, 3, 2, "The window should have moved");
  mvwaddstr(win, 4, 2,
            "This text should have appeared without you pressing a key");
  mvwaddstr(win, 6, 2, "Enter a number then a string seperated by space");
  mvwin(win, 2, 1);
  wrefresh(win);
  mvwscanw(win, 7, 6, "%d %s", &num, buffer);
  mvwprintw(win, 8, 6, "String: %s Number: %d", buffer, num);
  Continue(win);
  refresh();
  wclear(win);
  echo();
  mvwaddstr(win, 3, 2, "Enter a 5 character string: ");
  wgetnstr(win, buffer, 5);
  mvwprintw(win, 4, 2, "String: %s", buffer);
  Continue(win);
}


x86 assembly (clang, -O0):
<inputTest>:
push   %rbp
mov    %rsp,%rbp
sub    $0xa0,%rsp
mov    %rdi,-0x8(%rbp)
mov    -0x8(%rbp),%rdi
call   1180 <wclear@plt>
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%esi
mov    -0xc(%rbp),%edx
call   10c0 <getmaxyx@plt>
mov    -0x8(%rbp),%rdi
mov    -0x18(%rbp),%esi
mov    -0x14(%rbp),%edx
call   10f0 <getbegyx@plt>
mov    -0xc(%rbp),%eax
mov    $0x3,%ecx
cltd
idiv   %ecx
mov    %eax,-0x1c(%rbp)
mov    -0x10(%rbp),%eax
mov    $0x3,%ecx
cltd
idiv   %ecx
mov    %eax,-0x20(%rbp)
mov    -0x8(%rbp),%rdi
mov    -0x20(%rbp),%esi
mov    -0x1c(%rbp),%edx
mov    -0x18(%rbp),%ecx
add    -0x10(%rbp),%ecx
sub    -0x20(%rbp),%ecx
sub    $0x2,%ecx
mov    -0x14(%rbp),%r8d
add    -0xc(%rbp),%r8d
sub    -0x1c(%rbp),%r8d
sub    $0x2,%r8d
call   1090 <subwin@plt>
mov    %rax,-0x88(%rbp)
cmp    $0x0,%rax
jne    13a3 <inputTest+0x93>
jmp    1817 <inputTest+0x507>
mov    -0x88(%rbp),%rdi
mov    0x2c17(%rip),%rax
mov    (%rax),%esi
call   1050 <wbkgd@plt>
mov    -0x88(%rbp),%rdi
mov    0x2bfa(%rip),%rax
mov    (%rax),%esi
mov    0x2c01(%rip),%rax
mov    (%rax),%edx
call   10e0 <box@plt>
mov    -0x8(%rbp),%rdi
call   1060 <wrefresh@plt>
mov    $0x0,%al
call   11a0 <nocbreak@plt>
mov    -0x8(%rbp),%rdi
call   1180 <wclear@plt>
mov    -0x8(%rbp),%rdi
mov    $0x1,%edx
lea    0xc01(%rip),%rcx
mov    %edx,%esi
call   1200 <mvwaddstr@plt>
mov    -0x8(%rbp),%rdi
mov    $0x2,%esi
mov    $0x1,%edx
lea    0xc17(%rip),%rcx
call   1200 <mvwaddstr@plt>
mov    -0x8(%rbp),%rdi
call   1060 <wrefresh@plt>
mov    -0x8(%rbp),%rdi
mov    0x2bb4(%rip),%rax
mov    (%rax),%esi
call   1070 <keypad@plt>
mov    $0x0,%al
call   1080 <raw@plt>
mov    $0x0,%al
call   11b0 <noecho@plt>
mov    $0xffffffff,%edi
call   10b0 <typeahead@plt>
mov    -0x8(%rbp),%rdi
mov    $0x3,%esi
mov    $0x5,%edx
call   11e0 <wmove@plt>
mov    -0x8(%rbp),%rdi
call   1170 <wgetch@plt>
mov    %eax,-0x28(%rbp)
mov    -0x8(%rbp),%rdi
call   1130 <wclrtobot@plt>
mov    -0x28(%rbp),%eax
mov    0x2b53(%rip),%rcx
cmp    (%rcx),%eax
jl     14ba <inputTest+0x1aa>
mov    -0x8(%rbp),%rax
mov    %rax,-0x90(%rbp)
mov    -0x28(%rbp),%edi
call   10d0 <keyname@plt>
mov    -0x90(%rbp),%rdi
mov    %eax,%edx
lea    0xb9b(%rip),%rsi
call   1110 <wprintw@plt>
jmp    1511 <inputTest+0x201>
mov    -0x28(%rbp),%edi
call   1160 <isprint@plt>
cmp    $0x0,%rax
je     14e4 <inputTest+0x1d4>
mov    -0x8(%rbp),%rdi
mov    -0x28(%rbp),%edx
lea    0xb81(%rip),%rsi
call   1110 <wprintw@plt>
jmp    150c <inputTest+0x1fc>
mov    -0x8(%rbp),%rax
mov    %rax,-0x98(%rbp)
mov    -0x28(%rbp),%edi
call   10a0 <unctrl@plt>
mov    -0x98(%rbp),%rdi
mov    %eax,%edx
lea    0xb44(%rip),%rsi
call   1110 <wprintw@plt>
jmp    1511 <inputTest+0x201>
mov    -0x8(%rbp),%rdi
call   1060 <wrefresh@plt>
cmpl   $0x20,-0x28(%rbp)
jne    1529 <inputTest+0x219>
jmp    152e <inputTest+0x21e>
jmp    1453 <inputTest+0x143>
mov    -0x8(%rbp),%rdi
call   1180 <wclear@plt>
mov    -0x8(%rbp),%rdi
mov    $0x2,%esi
mov    $0x1,%edx
lea    0xb1f(%rip),%rcx
call   1200 <mvwaddstr@plt>
mov    -0x8(%rbp),%rdi
mov    $0x1,%edx
lea    0xb28(%rip),%rcx
mov    %edx,%esi
call   1200 <mvwaddstr@plt>
mov    -0x8(%rbp),%rdi
call   1060 <wrefresh@plt>
mov    -0x88(%rbp),%rdi
call   1230 <werase@plt>
mov    -0x88(%rbp),%rdi
mov    0x2a35(%rip),%rax
mov    (%rax),%esi
mov    0x2a3c(%rip),%rax
mov    (%rax),%edx
call   10e0 <box@plt>
movl   $0x0,-0x24(%rbp)
cmpl   $0x5,-0x24(%rbp)
jge    15f7 <inputTest+0x2e7>
mov    -0x88(%rbp),%rdi
mov    -0x24(%rbp),%r8d
mov    $0x1,%edx
lea    0xae4(%rip),%rcx
mov    %edx,%esi
mov    $0x0,%al
call   1190 <mvwprintw@plt>
mov    -0x88(%rbp),%rdi
call   1060 <wrefresh@plt>
mov    $0x3e8,%edi
call   11f0 <napms@plt>
mov    $0x0,%al
call   11d0 <flushinp@plt>
mov    -0x24(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x24(%rbp)
jmp    15a2 <inputTest+0x292>
mov    -0x88(%rbp),%rdi
call   1100 <delwin@plt>
mov    -0x8(%rbp),%rdi
call   1230 <werase@plt>
mov    $0x0,%al
call   1140 <flash@plt>
mov    -0x8(%rbp),%rdi
call   1060 <wrefresh@plt>
mov    $0x1f4,%edi
call   11f0 <napms@plt>
mov    $0x0,%al
call   11d0 <flushinp@plt>
mov    -0x8(%rbp),%rdi
mov    $0x2,%esi
mov    $0x1,%edx
lea    0xa6f(%rip),%rcx
call   1200 <mvwaddstr@plt>
mov    -0x8(%rbp),%rdi
mov    $0x9,%esi
mov    $0xa,%edx
call   11e0 <wmove@plt>
mov    -0x8(%rbp),%rdi
call   1060 <wrefresh@plt>
mov    $0x0,%al
call   1030 <echo@plt>
mov    -0x8(%rbp),%rdi
mov    0x2973(%rip),%rax
mov    (%rax),%esi
call   1070 <keypad@plt>
mov    $0x0,%al
call   1080 <raw@plt>
mov    -0x8(%rbp),%rdi
lea    -0x80(%rbp),%rsi
mov    $0x3,%edx
call   11c0 <wgetnstr@plt>
mov    $0x0,%al
call   11d0 <flushinp@plt>
mov    -0x8(%rbp),%rdi
mov    $0x9,%esi
mov    $0xa,%edx
call   11e0 <wmove@plt>
mov    -0x8(%rbp),%rdi
call   1040 <wdelch@plt>
mov    -0x8(%rbp),%rdi
mov    $0x4,%esi
mov    $0x1,%edx
lea    0xa03(%rip),%rcx
call   1200 <mvwaddstr@plt>
mov    -0x8(%rbp),%rdi
call   1220 <Continue@plt>
mov    $0x0,%al
call   1150 <refresh@plt>
mov    -0x8(%rbp),%rdi
call   1180 <wclear@plt>
mov    $0x0,%al
call   1030 <echo@plt>
mov    -0x8(%rbp),%rdi
mov    $0x3,%esi
mov    $0x2,%edx
lea    0x9f4(%rip),%rcx
call   1200 <mvwaddstr@plt>
mov    -0x8(%rbp),%rdi
mov    $0x4,%esi
mov    $0x2,%edx
lea    0x9f7(%rip),%rcx
call   1200 <mvwaddstr@plt>
mov    -0x8(%rbp),%rdi
mov    $0x6,%esi
mov    $0x2,%edx
lea    0xa17(%rip),%rcx
call   1200 <mvwaddstr@plt>
mov    -0x8(%rbp),%rdi
mov    $0x2,%esi
mov    $0x1,%edx
call   1210 <mvwin@plt>
mov    -0x8(%rbp),%rdi
call   1060 <wrefresh@plt>
mov    -0x8(%rbp),%rdi
lea    -0x80(%rbp),%r9
mov    $0x7,%esi
mov    $0x6,%edx
lea    0xa0d(%rip),%rcx
lea    -0x2c(%rbp),%r8
call   1120 <mvwscanw@plt>
mov    -0x8(%rbp),%rdi
lea    -0x80(%rbp),%r8
mov    -0x2c(%rbp),%r9d
mov    $0x8,%esi
mov    $0x6,%edx
lea    0x9ed(%rip),%rcx
mov    $0x0,%al
call   1190 <mvwprintw@plt>
mov    -0x8(%rbp),%rdi
call   1220 <Continue@plt>
mov    $0x0,%al
call   1150 <refresh@plt>
mov    -0x8(%rbp),%rdi
call   1180 <wclear@plt>
mov    $0x0,%al
call   1030 <echo@plt>
mov    -0x8(%rbp),%rdi
mov    $0x3,%esi
mov    $0x2,%edx
lea    0x9c7(%rip),%rcx
call   1200 <mvwaddstr@plt>
mov    -0x8(%rbp),%rdi
lea    -0x80(%rbp),%rsi
mov    $0x5,%edx
call   11c0 <wgetnstr@plt>
mov    -0x8(%rbp),%rdi
lea    -0x80(%rbp),%r8
mov    $0x4,%esi
mov    $0x2,%edx
lea    0x9b4(%rip),%rcx
mov    $0x0,%al
call   1190 <mvwprintw@plt>
mov    -0x8(%rbp),%rdi
call   1220 <Continue@plt>
add    $0xa0,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<inputTest>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x68,%rsp
mov    %rdi,%rbx
call   1180 <wclear@plt>
mov    %rbx,%rdi
call   10c0 <getmaxyx@plt>
mov    %rbx,%rdi
call   10f0 <getbegyx@plt>
mov    %rbx,%rdi
xor    %esi,%esi
xor    %edx,%edx
call   1090 <subwin@plt>
test   %rax,%rax
je     17f5 <inputTest+0x4e5>
mov    %rax,%r14
mov    0x2c73(%rip),%rax
mov    (%rax),%esi
mov    %r14,%rdi
call   1050 <wbkgd@plt>
mov    0x2c5a(%rip),%rax
mov    (%rax),%esi
mov    0x2c61(%rip),%rax
mov    (%rax),%edx
mov    %r14,%rdi
call   10e0 <box@plt>
mov    %rbx,%rdi
call   1060 <wrefresh@plt>
xor    %eax,%eax
call   11a0 <nocbreak@plt>
mov    %rbx,%rdi
call   1180 <wclear@plt>
lea    0xc69(%rip),%rcx
mov    %rbx,%rdi
mov    $0x1,%esi
mov    $0x1,%edx
call   1200 <mvwaddstr@plt>
lea    0xc82(%rip),%rcx
mov    %rbx,%rdi
mov    $0x2,%esi
mov    $0x1,%edx
call   1200 <mvwaddstr@plt>
mov    %rbx,%rdi
call   1060 <wrefresh@plt>
mov    0x2c17(%rip),%rax
mov    (%rax),%esi
mov    %rbx,%rdi
call   1070 <keypad@plt>
xor    %eax,%eax
call   1080 <raw@plt>
xor    %eax,%eax
call   11b0 <noecho@plt>
mov    $0xffffffff,%edi
call   10b0 <typeahead@plt>
mov    0x2bde(%rip),%r13
lea    0xc4a(%rip),%r15
lea    0xc53(%rip),%r12
jmp    1431 <inputTest+0x121>
nopw   0x0(%rax,%rax,1)
mov    %ebp,%edi
call   10d0 <keyname@plt>
mov    %rbx,%rdi
mov    %r15,%rsi
mov    %eax,%edx
call   1110 <wprintw@plt>
mov    %rbx,%rdi
call   1060 <wrefresh@plt>
cmp    $0x20,%ebp
je     147a <inputTest+0x16a>
mov    %rbx,%rdi
mov    $0x3,%esi
mov    $0x5,%edx
call   11e0 <wmove@plt>
mov    %rbx,%rdi
call   1170 <wgetch@plt>
mov    %eax,%ebp
mov    %rbx,%rdi
call   1130 <wclrtobot@plt>
cmp    0x0(%r13),%ebp
jge    1410 <inputTest+0x100>
mov    %ebp,%edi
call   1160 <isprint@plt>
test   %rax,%rax
je     1471 <inputTest+0x161>
mov    %rbx,%rdi
mov    %r12,%rsi
mov    %ebp,%edx
jmp    141f <inputTest+0x10f>
mov    %ebp,%edi
call   10a0 <unctrl@plt>
jmp    1417 <inputTest+0x107>
mov    %rbx,%rdi
call   1180 <wclear@plt>
lea    0xbe2(%rip),%rcx
mov    %rbx,%rdi
mov    $0x2,%esi
mov    $0x1,%edx
call   1200 <mvwaddstr@plt>
lea    0xbe7(%rip),%rcx
mov    %rbx,%rdi
mov    $0x1,%esi
mov    $0x1,%edx
call   1200 <mvwaddstr@plt>
mov    %rbx,%rdi
call   1060 <wrefresh@plt>
mov    %r14,%rdi
call   1230 <werase@plt>
mov    0x2af5(%rip),%rax
mov    (%rax),%esi
mov    0x2afc(%rip),%rax
mov    (%rax),%edx
mov    %r14,%rdi
call   10e0 <box@plt>
lea    0xbc2(%rip),%r15
mov    %r14,%rdi
mov    $0x1,%esi
mov    $0x1,%edx
mov    %r15,%rcx
xor    %r8d,%r8d
xor    %eax,%eax
call   1190 <mvwprintw@plt>
mov    %r14,%rdi
call   1060 <wrefresh@plt>
mov    $0x3e8,%edi
call   11f0 <napms@plt>
xor    %eax,%eax
call   11d0 <flushinp@plt>
mov    %r14,%rdi
mov    $0x1,%esi
mov    $0x1,%edx
mov    %r15,%rcx
mov    $0x1,%r8d
xor    %eax,%eax
call   1190 <mvwprintw@plt>
mov    %r14,%rdi
call   1060 <wrefresh@plt>
mov    $0x3e8,%edi
call   11f0 <napms@plt>
xor    %eax,%eax
call   11d0 <flushinp@plt>
mov    %r14,%rdi
mov    $0x1,%esi
mov    $0x1,%edx
mov    %r15,%rcx
mov    $0x2,%r8d
xor    %eax,%eax
call   1190 <mvwprintw@plt>
mov    %r14,%rdi
call   1060 <wrefresh@plt>
mov    $0x3e8,%edi
call   11f0 <napms@plt>
xor    %eax,%eax
call   11d0 <flushinp@plt>
mov    %r14,%rdi
mov    $0x1,%esi
mov    $0x1,%edx
mov    %r15,%rcx
mov    $0x3,%r8d
xor    %eax,%eax
call   1190 <mvwprintw@plt>
mov    %r14,%rdi
call   1060 <wrefresh@plt>
mov    $0x3e8,%edi
call   11f0 <napms@plt>
xor    %eax,%eax
call   11d0 <flushinp@plt>
mov    %r14,%rdi
mov    $0x1,%esi
mov    $0x1,%edx
mov    %r15,%rcx
mov    $0x4,%r8d
xor    %eax,%eax
call   1190 <mvwprintw@plt>
mov    %r14,%rdi
call   1060 <wrefresh@plt>
mov    $0x3e8,%edi
call   11f0 <napms@plt>
xor    %eax,%eax
call   11d0 <flushinp@plt>
mov    %r14,%rdi
call   1100 <delwin@plt>
mov    %rbx,%rdi
call   1230 <werase@plt>
xor    %eax,%eax
call   1140 <flash@plt>
mov    %rbx,%rdi
call   1060 <wrefresh@plt>
mov    $0x1f4,%edi
call   11f0 <napms@plt>
xor    %eax,%eax
call   11d0 <flushinp@plt>
lea    0xa8a(%rip),%rcx
mov    %rbx,%rdi
mov    $0x2,%esi
mov    $0x1,%edx
call   1200 <mvwaddstr@plt>
mov    %rbx,%rdi
mov    $0x9,%esi
mov    $0xa,%edx
call   11e0 <wmove@plt>
mov    %rbx,%rdi
call   1060 <wrefresh@plt>
xor    %eax,%eax
call   1030 <echo@plt>
mov    0x2987(%rip),%rax
mov    (%rax),%esi
mov    %rbx,%rdi
call   1070 <keypad@plt>
xor    %eax,%eax
call   1080 <raw@plt>
lea    0x10(%rsp),%r14
mov    %rbx,%rdi
mov    %r14,%rsi
mov    $0x3,%edx
call   11c0 <wgetnstr@plt>
xor    %eax,%eax
call   11d0 <flushinp@plt>
mov    %rbx,%rdi
mov    $0x9,%esi
mov    $0xa,%edx
call   11e0 <wmove@plt>
mov    %rbx,%rdi
call   1040 <wdelch@plt>
lea    0xa21(%rip),%rcx
mov    %rbx,%rdi
mov    $0x4,%esi
mov    $0x1,%edx
call   1200 <mvwaddstr@plt>
mov    %rbx,%rdi
call   1220 <Continue@plt>
xor    %eax,%eax
call   1150 <refresh@plt>
mov    %rbx,%rdi
call   1180 <wclear@plt>
xor    %eax,%eax
call   1030 <echo@plt>
lea    0xa15(%rip),%rcx
mov    %rbx,%rdi
mov    $0x3,%esi
mov    $0x2,%edx
call   1200 <mvwaddstr@plt>
lea    0xa19(%rip),%rcx
mov    %rbx,%rdi
mov    $0x4,%esi
mov    $0x2,%edx
call   1200 <mvwaddstr@plt>
lea    0xa3a(%rip),%rcx
mov    %rbx,%rdi
mov    $0x6,%esi
mov    $0x2,%edx
call   1200 <mvwaddstr@plt>
mov    %rbx,%rdi
mov    $0x2,%esi
mov    $0x1,%edx
call   1210 <mvwin@plt>
mov    %rbx,%rdi
call   1060 <wrefresh@plt>
lea    0xa37(%rip),%rcx
lea    0xc(%rsp),%r8
mov    %rbx,%rdi
mov    $0x7,%esi
mov    $0x6,%edx
mov    %r14,%r9
call   1120 <mvwscanw@plt>
mov    0xc(%rsp),%r9d
lea    0xa17(%rip),%rcx
mov    %rbx,%rdi
mov    $0x8,%esi
mov    $0x6,%edx
mov    %r14,%r8
xor    %eax,%eax
call   1190 <mvwprintw@plt>
mov    %rbx,%rdi
call   1220 <Continue@plt>
xor    %eax,%eax
call   1150 <refresh@plt>
mov    %rbx,%rdi
call   1180 <wclear@plt>
xor    %eax,%eax
call   1030 <echo@plt>
lea    0x9f1(%rip),%rcx
mov    %rbx,%rdi
mov    $0x3,%esi
mov    $0x2,%edx
call   1200 <mvwaddstr@plt>
mov    %rbx,%rdi
mov    %r14,%rsi
mov    $0x5,%edx
call   11c0 <wgetnstr@plt>
lea    0x9e5(%rip),%rcx
mov    %rbx,%rdi
mov    $0x4,%esi
mov    $0x2,%edx
mov    %r14,%r8
xor    %eax,%eax
call   1190 <mvwprintw@plt>
mov    %rbx,%rdi
call   1220 <Continue@plt>
add    $0x68,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@A_BOLD = global i32 0
@ACS_VLINE = global i32 0
@ACS_HLINE = global i32 0
@.str = [50 x i8] c"Press keys (or mouse buttons) to show their names\00"
@.str.1 = [25 x i8] c"Press spacebar to finish\00"
@TRUE = global i32 0
@KEY_MIN = global i32 0
@.str.2 = [16 x i8] c"Key Pressed: %s\00"
@.str.3 = [16 x i8] c"Key Pressed: %c\00"
@.str.4 = [30 x i8] c"Press some keys for 5 seconds\00"
@.str.5 = [30 x i8] c"Pressing ^C should do nothing\00"
@.str.6 = [10 x i8] c"Time = %d\00"
@.str.7 = [31 x i8] c"Press a key, followed by ENTER\00"
@.str.8 = [43 x i8] c"The character should now have been deleted\00"
@.str.9 = [29 x i8] c"The window should have moved\00"
@.str.10 = [58 x i8] c"This text should have appeared without you pressing a key\00"
@.str.11 = [48 x i8] c"Enter a number then a string seperated by space\00"
@.str.12 = [6 x i8] c"%d %s\00"
@.str.13 = [22 x i8] c"String: %s Number: %d\00"
@.str.14 = [29 x i8] c"Enter a 5 character string: \00"
@.str.15 = [11 x i8] c"String: %s\00"
define void @inputTest(i32* %0) {
%2 = alloca i32*
%3 = alloca i32
%4 = alloca i32
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32
%8 = alloca i32
%9 = alloca i32
%10 = alloca i32
%11 = alloca i32
%12 = alloca [80 x i8]
%13 = alloca i32*
store i32* %0, i32** %2
%14 = load i32*, i32** %2
%15 = call i32 @wclear(i32* %14)
%16 = load i32*, i32** %2
%17 = load i32, i32* %4
%18 = load i32, i32* %3
%19 = call i32 @getmaxyx(i32* %16, i32 %17, i32 %18)
%20 = load i32*, i32** %2
%21 = load i32, i32* %6
%22 = load i32, i32* %5
%23 = call i32 @getbegyx(i32* %20, i32 %21, i32 %22)
%24 = load i32, i32* %3
%25 = sdiv i32 %24, 3
store i32 %25, i32* %7
%26 = load i32, i32* %4
%27 = sdiv i32 %26, 3
store i32 %27, i32* %8
%28 = load i32*, i32** %2
%29 = load i32, i32* %8
%30 = load i32, i32* %7
%31 = load i32, i32* %6
%32 = load i32, i32* %4
%33 = add nsw i32 %31, %32
%34 = load i32, i32* %8
%35 = sub nsw i32 %33, %34
%36 = sub nsw i32 %35, 2
%37 = load i32, i32* %5
%38 = load i32, i32* %3
%39 = add nsw i32 %37, %38
%40 = load i32, i32* %7
%41 = sub nsw i32 %39, %40
%42 = sub nsw i32 %41, 2
%43 = call i32* @subwin(i32* %28, i32 %29, i32 %30, i32 %36, i32 %42)
store i32* %43, i32** %13
%44 = icmp eq i32* %43, null
br i1 %44, label %45, label %46
45: ; preds = %1
br label %206
46: ; preds = %1
%47 = load i32*, i32** %13
%48 = load i32, i32* @A_BOLD
%49 = call i32 @wbkgd(i32* %47, i32 %48)
%50 = load i32*, i32** %13
%51 = load i32, i32* @ACS_VLINE
%52 = load i32, i32* @ACS_HLINE
%53 = call i32 @box(i32* %50, i32 %51, i32 %52)
%54 = load i32*, i32** %2
%55 = call i32 @wrefresh(i32* %54)
%56 = call i32 (...) @nocbreak()
%57 = load i32*, i32** %2
%58 = call i32 @wclear(i32* %57)
%59 = load i32*, i32** %2
%60 = call i32 @mvwaddstr(i32* %59, i32 1, i32 1, i8* getelementptr inbounds ([50 x i8], [50 x i8]* @.str, i64 0, i64 0))
%61 = load i32*, i32** %2
%62 = call i32 @mvwaddstr(i32* %61, i32 2, i32 1, i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.1, i64 0, i64 0))
%63 = load i32*, i32** %2
%64 = call i32 @wrefresh(i32* %63)
%65 = load i32*, i32** %2
%66 = load i32, i32* @TRUE
%67 = call i32 @keypad(i32* %65, i32 %66)
%68 = call i32 (...) @raw()
%69 = call i32 (...) @noecho()
%70 = call i32 @typeahead(i32 -1)
br label %71
71: ; preds = %46, %106
%72 = load i32*, i32** %2
%73 = call i32 @wmove(i32* %72, i32 3, i32 5)
%74 = load i32*, i32** %2
%75 = call i32 @wgetch(i32* %74)
store i32 %75, i32* %10
%76 = load i32*, i32** %2
%77 = call i32 @wclrtobot(i32* %76)
%78 = load i32, i32* %10
%79 = load i32, i32* @KEY_MIN
%80 = icmp sge i32 %78, %79
br i1 %80, label %81, label %86
81: ; preds = %71
%82 = load i32*, i32** %2
%83 = load i32, i32* %10
%84 = call i32 @keyname(i32 %83)
%85 = call i32 @wprintw(i32* %82, i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.2, i64 0, i64 0), i32 %84)
br label %100
86: ; preds = %71
%87 = load i32, i32* %10
%88 = call i64 @isprint(i32 %87)
%89 = icmp ne i64 %88, 0
br i1 %89, label %90, label %94
90: ; preds = %86
%91 = load i32*, i32** %2
%92 = load i32, i32* %10
%93 = call i32 @wprintw(i32* %91, i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.3, i64 0, i64 0), i32 %92)
br label %99
94: ; preds = %86
%95 = load i32*, i32** %2
%96 = load i32, i32* %10
%97 = call i32 @unctrl(i32 %96)
%98 = call i32 @wprintw(i32* %95, i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.2, i64 0, i64 0), i32 %97)
br label %99
99: ; preds = %94, %90
br label %100
100: ; preds = %99, %81
%101 = load i32*, i32** %2
%102 = call i32 @wrefresh(i32* %101)
%103 = load i32, i32* %10
%104 = icmp eq i32 %103, 32
br i1 %104, label %105, label %106
105: ; preds = %100
br label %107
106: ; preds = %100
br label %71
107: ; preds = %105
%108 = load i32*, i32** %2
%109 = call i32 @wclear(i32* %108)
%110 = load i32*, i32** %2
%111 = call i32 @mvwaddstr(i32* %110, i32 2, i32 1, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.4, i64 0, i64 0))
%112 = load i32*, i32** %2
%113 = call i32 @mvwaddstr(i32* %112, i32 1, i32 1, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.5, i64 0, i64 0))
%114 = load i32*, i32** %2
%115 = call i32 @wrefresh(i32* %114)
%116 = load i32*, i32** %13
%117 = call i32 @werase(i32* %116)
%118 = load i32*, i32** %13
%119 = load i32, i32* @ACS_VLINE
%120 = load i32, i32* @ACS_HLINE
%121 = call i32 @box(i32* %118, i32 %119, i32 %120)
store i32 0, i32* %9
br label %122
122: ; preds = %133, %107
%123 = load i32, i32* %9
%124 = icmp slt i32 %123, 5
br i1 %124, label %125, label %136
125: ; preds = %122
%126 = load i32*, i32** %13
%127 = load i32, i32* %9
%128 = call i32 (i32*, i32, i32, i8*, ...) @mvwprintw(i32* %126, i32 1, i32 1, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.6, i64 0, i64 0), i32 %127)
%129 = load i32*, i32** %13
%130 = call i32 @wrefresh(i32* %129)
%131 = call i32 @napms(i32 1000)
%132 = call i32 (...) @flushinp()
br label %133
133: ; preds = %125
%134 = load i32, i32* %9
%135 = add nsw i32 %134, 1
store i32 %135, i32* %9
br label %122
136: ; preds = %122
%137 = load i32*, i32** %13
%138 = call i32 @delwin(i32* %137)
%139 = load i32*, i32** %2
%140 = call i32 @werase(i32* %139)
%141 = call i32 (...) @flash()
%142 = load i32*, i32** %2
%143 = call i32 @wrefresh(i32* %142)
%144 = call i32 @napms(i32 500)
%145 = call i32 (...) @flushinp()
%146 = load i32*, i32** %2
%147 = call i32 @mvwaddstr(i32* %146, i32 2, i32 1, i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.7, i64 0, i64 0))
%148 = load i32*, i32** %2
%149 = call i32 @wmove(i32* %148, i32 9, i32 10)
%150 = load i32*, i32** %2
%151 = call i32 @wrefresh(i32* %150)
%152 = call i32 (...) @echo()
%153 = load i32*, i32** %2
%154 = load i32, i32* @TRUE
%155 = call i32 @keypad(i32* %153, i32 %154)
%156 = call i32 (...) @raw()
%157 = load i32*, i32** %2
%158 = getelementptr inbounds [80 x i8], [80 x i8]* %12, i64 0, i64 0
%159 = call i32 @wgetnstr(i32* %157, i8* %158, i32 3)
%160 = call i32 (...) @flushinp()
%161 = load i32*, i32** %2
%162 = call i32 @wmove(i32* %161, i32 9, i32 10)
%163 = load i32*, i32** %2
%164 = call i32 @wdelch(i32* %163)
%165 = load i32*, i32** %2
%166 = call i32 @mvwaddstr(i32* %165, i32 4, i32 1, i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.8, i64 0, i64 0))
%167 = load i32*, i32** %2
%168 = call i32 @Continue(i32* %167)
%169 = call i32 (...) @refresh()
%170 = load i32*, i32** %2
%171 = call i32 @wclear(i32* %170)
%172 = call i32 (...) @echo()
%173 = load i32*, i32** %2
%174 = call i32 @mvwaddstr(i32* %173, i32 3, i32 2, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.9, i64 0, i64 0))
%175 = load i32*, i32** %2
%176 = call i32 @mvwaddstr(i32* %175, i32 4, i32 2, i8* getelementptr inbounds ([58 x i8], [58 x i8]* @.str.10, i64 0, i64 0))
%177 = load i32*, i32** %2
%178 = call i32 @mvwaddstr(i32* %177, i32 6, i32 2, i8* getelementptr inbounds ([48 x i8], [48 x i8]* @.str.11, i64 0, i64 0))
%179 = load i32*, i32** %2
%180 = call i32 @mvwin(i32* %179, i32 2, i32 1)
%181 = load i32*, i32** %2
%182 = call i32 @wrefresh(i32* %181)
%183 = load i32*, i32** %2
%184 = getelementptr inbounds [80 x i8], [80 x i8]* %12, i64 0, i64 0
%185 = call i32 @mvwscanw(i32* %183, i32 7, i32 6, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.12, i64 0, i64 0), i32* %11, i8* %184)
%186 = load i32*, i32** %2
%187 = getelementptr inbounds [80 x i8], [80 x i8]* %12, i64 0, i64 0
%188 = load i32, i32* %11
%189 = call i32 (i32*, i32, i32, i8*, ...) @mvwprintw(i32* %186, i32 8, i32 6, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.13, i64 0, i64 0), i8* %187, i32 %188)
%190 = load i32*, i32** %2
%191 = call i32 @Continue(i32* %190)
%192 = call i32 (...) @refresh()
%193 = load i32*, i32** %2
%194 = call i32 @wclear(i32* %193)
%195 = call i32 (...) @echo()
%196 = load i32*, i32** %2
%197 = call i32 @mvwaddstr(i32* %196, i32 3, i32 2, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.14, i64 0, i64 0))
%198 = load i32*, i32** %2
%199 = getelementptr inbounds [80 x i8], [80 x i8]* %12, i64 0, i64 0
%200 = call i32 @wgetnstr(i32* %198, i8* %199, i32 5)
%201 = load i32*, i32** %2
%202 = getelementptr inbounds [80 x i8], [80 x i8]* %12, i64 0, i64 0
%203 = call i32 (i32*, i32, i32, i8*, ...) @mvwprintw(i32* %201, i32 4, i32 2, i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.15, i64 0, i64 0), i8* %202)
%204 = load i32*, i32** %2
%205 = call i32 @Continue(i32* %204)
br label %206
206: ; preds = %136, %45
ret void
}

LLVM IR (-O2):
@A_BOLD = global i32 0
@ACS_VLINE = global i32 0
@ACS_HLINE = global i32 0
@.str = [50 x i8] c"Press keys (or mouse buttons) to show their names\00"
@.str.1 = [25 x i8] c"Press spacebar to finish\00"
@TRUE = global i32 0
@KEY_MIN = global i32 0
@.str.2 = [16 x i8] c"Key Pressed: %s\00"
@.str.3 = [16 x i8] c"Key Pressed: %c\00"
@.str.4 = [30 x i8] c"Press some keys for 5 seconds\00"
@.str.5 = [30 x i8] c"Pressing ^C should do nothing\00"
@.str.6 = [10 x i8] c"Time = %d\00"
@.str.7 = [31 x i8] c"Press a key, followed by ENTER\00"
@.str.8 = [43 x i8] c"The character should now have been deleted\00"
@.str.9 = [29 x i8] c"The window should have moved\00"
@.str.10 = [58 x i8] c"This text should have appeared without you pressing a key\00"
@.str.11 = [48 x i8] c"Enter a number then a string seperated by space\00"
@.str.12 = [6 x i8] c"%d %s\00"
@.str.13 = [22 x i8] c"String: %s Number: %d\00"
@.str.14 = [29 x i8] c"Enter a 5 character string: \00"
@.str.15 = [11 x i8] c"String: %s\00"
define void @inputTest(i32* %0) {
%2 = alloca i32
%3 = alloca [80 x i8]
%4 = bitcast i32* %2 to i8*
%5 = getelementptr inbounds [80 x i8], [80 x i8]* %3, i64 0, i64 0
%6 = tail call i32 @wclear(i32* %0)
%7 = tail call i32 @getmaxyx(i32* %0, i32 undef, i32 undef)
%8 = tail call i32 @getbegyx(i32* %0, i32 undef, i32 undef)
%9 = tail call i32* @subwin(i32* %0, i32 0, i32 0, i32 undef, i32 undef)
%10 = icmp eq i32* %9, null
br i1 %10, label %115, label %11
11: ; preds = %1
%12 = load i32, i32* @A_BOLD
%13 = tail call i32 @wbkgd(i32* %9, i32 %12)
%14 = load i32, i32* @ACS_VLINE
%15 = load i32, i32* @ACS_HLINE
%16 = tail call i32 @box(i32* %9, i32 %14, i32 %15)
%17 = tail call i32 @wrefresh(i32* %0)
%18 = tail call i32 (...) @nocbreak()
%19 = tail call i32 @wclear(i32* %0)
%20 = tail call i32 @mvwaddstr(i32* %0, i32 1, i32 1, i8* getelementptr inbounds ([50 x i8], [50 x i8]* @.str, i64 0, i64 0))
%21 = tail call i32 @mvwaddstr(i32* %0, i32 2, i32 1, i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.1, i64 0, i64 0))
%22 = tail call i32 @wrefresh(i32* %0)
%23 = load i32, i32* @TRUE
%24 = tail call i32 @keypad(i32* %0, i32 %23)
%25 = tail call i32 (...) @raw()
%26 = tail call i32 (...) @noecho()
%27 = tail call i32 @typeahead(i32 -1)
br label %28
28: ; preds = %45, %11
%29 = tail call i32 @wmove(i32* %0, i32 3, i32 5)
%30 = tail call i32 @wgetch(i32* %0)
%31 = tail call i32 @wclrtobot(i32* %0)
%32 = load i32, i32* @KEY_MIN
%33 = icmp slt i32 %30, %32
br i1 %33, label %37, label %34
34: ; preds = %28
%35 = tail call i32 @keyname(i32 %30)
%36 = tail call i32 @wprintw(i32* %0, i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.2, i64 0, i64 0), i32 %35)
br label %45
37: ; preds = %28
%38 = tail call i64 @isprint(i32 %30)
%39 = icmp eq i64 %38, 0
br i1 %39, label %42, label %40
40: ; preds = %37
%41 = tail call i32 @wprintw(i32* %0, i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.3, i64 0, i64 0), i32 %30)
br label %45
42: ; preds = %37
%43 = tail call i32 @unctrl(i32 %30)
%44 = tail call i32 @wprintw(i32* %0, i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.2, i64 0, i64 0), i32 %43)
br label %45
45: ; preds = %40, %42, %34
%46 = tail call i32 @wrefresh(i32* %0)
%47 = icmp eq i32 %30, 32
br i1 %47, label %48, label %28
48: ; preds = %45
%49 = tail call i32 @wclear(i32* %0)
%50 = tail call i32 @mvwaddstr(i32* %0, i32 2, i32 1, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.4, i64 0, i64 0))
%51 = tail call i32 @mvwaddstr(i32* %0, i32 1, i32 1, i8* getelementptr inbounds ([30 x i8], [30 x i8]* @.str.5, i64 0, i64 0))
%52 = tail call i32 @wrefresh(i32* %0)
%53 = tail call i32 @werase(i32* %9)
%54 = load i32, i32* @ACS_VLINE
%55 = load i32, i32* @ACS_HLINE
%56 = tail call i32 @box(i32* %9, i32 %54, i32 %55)
%57 = tail call i32 (i32*, i32, i32, i8*, ...) @mvwprintw(i32* %9, i32 1, i32 1, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.6, i64 0, i64 0), i32 0)
%58 = tail call i32 @wrefresh(i32* %9)
%59 = tail call i32 @napms(i32 1000)
%60 = tail call i32 (...) @flushinp()
%61 = tail call i32 (i32*, i32, i32, i8*, ...) @mvwprintw(i32* %9, i32 1, i32 1, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.6, i64 0, i64 0), i32 1)
%62 = tail call i32 @wrefresh(i32* %9)
%63 = tail call i32 @napms(i32 1000)
%64 = tail call i32 (...) @flushinp()
%65 = tail call i32 (i32*, i32, i32, i8*, ...) @mvwprintw(i32* %9, i32 1, i32 1, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.6, i64 0, i64 0), i32 2)
%66 = tail call i32 @wrefresh(i32* %9)
%67 = tail call i32 @napms(i32 1000)
%68 = tail call i32 (...) @flushinp()
%69 = tail call i32 (i32*, i32, i32, i8*, ...) @mvwprintw(i32* %9, i32 1, i32 1, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.6, i64 0, i64 0), i32 3)
%70 = tail call i32 @wrefresh(i32* %9)
%71 = tail call i32 @napms(i32 1000)
%72 = tail call i32 (...) @flushinp()
%73 = tail call i32 (i32*, i32, i32, i8*, ...) @mvwprintw(i32* %9, i32 1, i32 1, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.6, i64 0, i64 0), i32 4)
%74 = tail call i32 @wrefresh(i32* %9)
%75 = tail call i32 @napms(i32 1000)
%76 = tail call i32 (...) @flushinp()
%77 = tail call i32 @delwin(i32* %9)
%78 = tail call i32 @werase(i32* %0)
%79 = tail call i32 (...) @flash()
%80 = tail call i32 @wrefresh(i32* %0)
%81 = tail call i32 @napms(i32 500)
%82 = tail call i32 (...) @flushinp()
%83 = tail call i32 @mvwaddstr(i32* %0, i32 2, i32 1, i8* getelementptr inbounds ([31 x i8], [31 x i8]* @.str.7, i64 0, i64 0))
%84 = tail call i32 @wmove(i32* %0, i32 9, i32 10)
%85 = tail call i32 @wrefresh(i32* %0)
%86 = tail call i32 (...) @echo()
%87 = load i32, i32* @TRUE
%88 = tail call i32 @keypad(i32* %0, i32 %87)
%89 = tail call i32 (...) @raw()
%90 = call i32 @wgetnstr(i32* %0, i8* %5, i32 3)
%91 = call i32 (...) @flushinp()
%92 = call i32 @wmove(i32* %0, i32 9, i32 10)
%93 = call i32 @wdelch(i32* %0)
%94 = call i32 @mvwaddstr(i32* %0, i32 4, i32 1, i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str.8, i64 0, i64 0))
%95 = call i32 @Continue(i32* %0)
%96 = call i32 (...) @refresh()
%97 = call i32 @wclear(i32* %0)
%98 = call i32 (...) @echo()
%99 = call i32 @mvwaddstr(i32* %0, i32 3, i32 2, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.9, i64 0, i64 0))
%100 = call i32 @mvwaddstr(i32* %0, i32 4, i32 2, i8* getelementptr inbounds ([58 x i8], [58 x i8]* @.str.10, i64 0, i64 0))
%101 = call i32 @mvwaddstr(i32* %0, i32 6, i32 2, i8* getelementptr inbounds ([48 x i8], [48 x i8]* @.str.11, i64 0, i64 0))
%102 = call i32 @mvwin(i32* %0, i32 2, i32 1)
%103 = call i32 @wrefresh(i32* %0)
%104 = call i32 @mvwscanw(i32* %0, i32 7, i32 6, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.12, i64 0, i64 0), i32* %2, i8* %5)
%105 = load i32, i32* %2
%106 = call i32 (i32*, i32, i32, i8*, ...) @mvwprintw(i32* %0, i32 8, i32 6, i8* getelementptr inbounds ([22 x i8], [22 x i8]* @.str.13, i64 0, i64 0), i8* %5, i32 %105)
%107 = call i32 @Continue(i32* %0)
%108 = call i32 (...) @refresh()
%109 = call i32 @wclear(i32* %0)
%110 = call i32 (...) @echo()
%111 = call i32 @mvwaddstr(i32* %0, i32 3, i32 2, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.14, i64 0, i64 0))
%112 = call i32 @wgetnstr(i32* %0, i8* %5, i32 5)
%113 = call i32 (i32*, i32, i32, i8*, ...) @mvwprintw(i32* %0, i32 4, i32 2, i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.15, i64 0, i64 0), i8* %5)
%114 = call i32 @Continue(i32* %0)
br label %115
115: ; preds = %1, %48
ret void
}