#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*/ buf;

/* Variables and functions */
int /*<<< orphan*/ EXIT_FAILURE;
int /*<<< orphan*/ EXIT_SUCCESS;
int /*<<< orphan*/ exit(int /*<<< orphan*/);
int /*<<< orphan*/ memset(char *, int, int);
int namegen(char *, int, char *, unsigned long *);
int /*<<< orphan*/ printf(char *, ...);
char *strchr(char *, char);
int /*<<< orphan*/ strcmp(char *, char *);
void tests(void) {
  int r;
  char buf[256];
  int count_pass = 0;
  int count_fail = 0;
  unsigned long rng[] = {0xd22bfb3b};
  {
    int i;
    int mismatch = 0;
    int seen[3] = {0, 0, 0};
    for (i = 0; i < 100; i++) {
      memset(buf, 0x5a, sizeof(buf));
      r = namegen(buf, sizeof(buf), "0|1|2", rng);
      if (r != 0 || buf[1] || !strchr("012", buf[0])) {
        mismatch++;
      } else {
        seen[buf[0] - '0']++;
      }
    }
    do {
      if (!mismatch && seen[0] && seen[1] && seen[2]) {
        printf("\033[32;1m"
               "PASS"
               "\033[0m"
               " %s\n",
               "alternation");
        count_pass++;
      } else {
        printf("\033[31;1m"
               "FAIL"
               "\033[0m"
               " %s\n",
               "alternation");
        count_fail++;
      }
    } while (0);
  }
  {
    int i;
    int mismatch = 0;
    int seen[6] = {0, 0, 0};
    for (i = 0; i < 100; i++) {
      memset(buf, 0x5a, sizeof(buf));
      r = namegen(buf, sizeof(buf), "(v)v", rng);
      if (r != 0 || buf[0] != 'v' || !buf[1] || buf[2]) {
        mismatch++;
      } else {
        char *p = "aeiouy";
        char *s = strchr(p, buf[1]);
        if (!s)
          mismatch++;
        else
          seen[s - p]++;
      }
    }
    for (i = 0; i < 6; i++)
      mismatch += !seen[i];
    do {
      if (!mismatch) {
        printf("\033[32;1m"
               "PASS"
               "\033[0m"
               " %s\n",
               "substitution");
        count_pass++;
      } else {
        printf("\033[31;1m"
               "FAIL"
               "\033[0m"
               " %s\n",
               "substitution");
        count_fail++;
      }
    } while (0);
  }
  {
    r = namegen(buf, sizeof(buf), "a>", rng);
    do {
      if (r == 2) {
        printf("\033[32;1m"
               "PASS"
               "\033[0m"
               " %s\n",
               "closing bracket");
        count_pass++;
      } else {
        printf("\033[31;1m"
               "FAIL"
               "\033[0m"
               " %s\n",
               "closing bracket");
        count_fail++;
      }
    } while (0);
  }
  {
    r = namegen(buf, sizeof(buf), "a)", rng);
    do {
      if (r == 2) {
        printf("\033[32;1m"
               "PASS"
               "\033[0m"
               " %s\n",
               "closing paren");
        count_pass++;
      } else {
        printf("\033[31;1m"
               "FAIL"
               "\033[0m"
               " %s\n",
               "closing paren");
        count_fail++;
      }
    } while (0);
  }
  {
    r = namegen(buf, sizeof(buf), "<a)", rng);
    do {
      if (r == 2) {
        printf("\033[32;1m"
               "PASS"
               "\033[0m"
               " %s\n",
               "mismatch paren");
        count_pass++;
      } else {
        printf("\033[31;1m"
               "FAIL"
               "\033[0m"
               " %s\n",
               "mismatch paren");
        count_fail++;
      }
    } while (0);
  }
  {
    r = namegen(buf, sizeof(buf), "(a>", rng);
    do {
      if (r == 2) {
        printf("\033[32;1m"
               "PASS"
               "\033[0m"
               " %s\n",
               "mismatch bracket");
        count_pass++;
      } else {
        printf("\033[31;1m"
               "FAIL"
               "\033[0m"
               " %s\n",
               "mismatch bracket");
        count_fail++;
      }
    } while (0);
  }
  {
    r = namegen(buf, sizeof(buf), "<a", rng);
    do {
      if (r == 2) {
        printf("\033[32;1m"
               "PASS"
               "\033[0m"
               " %s\n",
               "unclosed bracket");
        count_pass++;
      } else {
        printf("\033[31;1m"
               "FAIL"
               "\033[0m"
               " %s\n",
               "unclosed bracket");
        count_fail++;
      }
    } while (0);
  }
  {
    r = namegen(buf, sizeof(buf), "(a", rng);
    do {
      if (r == 2) {
        printf("\033[32;1m"
               "PASS"
               "\033[0m"
               " %s\n",
               "unclosed paren");
        count_pass++;
      } else {
        printf("\033[31;1m"
               "FAIL"
               "\033[0m"
               " %s\n",
               "unclosed paren");
        count_fail++;
      }
    } while (0);
  }
  {
    char *p = "(((((<(((((((((((((((a)))))))))))))))>)))))";
    memset(buf, 0x5a, sizeof(buf));
    r = namegen(buf, sizeof(buf), p, rng);
    do {
      if (r == 0 && !strcmp(buf, "a")) {
        printf("\033[32;1m"
               "PASS"
               "\033[0m"
               " %s\n",
               "deep nesting");
        count_pass++;
      } else {
        printf("\033[31;1m"
               "FAIL"
               "\033[0m"
               " %s\n",
               "deep nesting");
        count_fail++;
      }
    } while (0);
  }
  {
    memset(buf, 0x5a, sizeof(buf));
    r = namegen(buf, 4, "(abcdefg)", rng);
    do {
      if (r == 1 && !strcmp(buf, "abc") && buf[4] == 0x5a) {
        printf("\033[32;1m"
               "PASS"
               "\033[0m"
               " %s\n",
               "truncation 1");
        count_pass++;
      } else {
        printf("\033[31;1m"
               "FAIL"
               "\033[0m"
               " %s\n",
               "truncation 1");
        count_fail++;
      }
    } while (0);
  }
  {
    memset(buf, 0x5a, sizeof(buf));
    r = namegen(buf, 2, "i", rng);
    do {
      if (r == 1 && buf[0] && !buf[1] && buf[2] == 0x5a) {
        printf("\033[32;1m"
               "PASS"
               "\033[0m"
               " %s\n",
               "truncation 2");
        count_pass++;
      } else {
        printf("\033[31;1m"
               "FAIL"
               "\033[0m"
               " %s\n",
               "truncation 2");
        count_fail++;
      }
    } while (0);
  }
  {
    r = namegen(buf, sizeof(buf), "!(foo)", rng);
    do {
      if (r == 0 && !strcmp(buf, "Foo")) {
        printf("\033[32;1m"
               "PASS"
               "\033[0m"
               " %s\n",
               "capitalization 1");
        count_pass++;
      } else {
        printf("\033[31;1m"
               "FAIL"
               "\033[0m"
               " %s\n",
               "capitalization 1");
        count_fail++;
      }
    } while (0);
  }
  {
    r = namegen(buf, sizeof(buf), "(!foo)", rng);
    do {
      if (r == 0 && !strcmp(buf, "Foo")) {
        printf("\033[32;1m"
               "PASS"
               "\033[0m"
               " %s\n",
               "capitalization 2");
        count_pass++;
      } else {
        printf("\033[31;1m"
               "FAIL"
               "\033[0m"
               " %s\n",
               "capitalization 2");
        count_fail++;
      }
    } while (0);
  }
  {
    r = namegen(buf, sizeof(buf), "(f!oo)", rng);
    do {
      if (r == 0 && !strcmp(buf, "fOo")) {
        printf("\033[32;1m"
               "PASS"
               "\033[0m"
               " %s\n",
               "capitalization 3");
        count_pass++;
      } else {
        printf("\033[31;1m"
               "FAIL"
               "\033[0m"
               " %s\n",
               "capitalization 3");
        count_fail++;
      }
    } while (0);
  }
  {
    memset(buf, 0x5a, sizeof(buf));
    r = namegen(buf, sizeof(buf), "", rng);
    do {
      if (r == 0 && !buf[0] && buf[1] == 0x5a) {
        printf("\033[32;1m"
               "PASS"
               "\033[0m"
               " %s\n",
               "empty");
        count_pass++;
      } else {
        printf("\033[31;1m"
               "FAIL"
               "\033[0m"
               " %s\n",
               "empty");
        count_fail++;
      }
    } while (0);
  }
  if (count_fail)
    exit(EXIT_FAILURE);
  printf("All %d tests passed\n", count_pass);
  exit(EXIT_SUCCESS);
}


x86 assembly (clang, -O0):
<tests>:
push   %rbp
mov    %rsp,%rbp
sub    $0x180,%rsp
movl   $0x0,-0x114(%rbp)
movl   $0x0,-0x118(%rbp)
mov    0xe7a(%rip),%rax
mov    %rax,-0x120(%rbp)
movl   $0x0,-0x128(%rbp)
lea    -0x134(%rbp),%rdi
xor    %esi,%esi
mov    $0xc,%edx
call   1060 <memset@plt>
movl   $0x0,-0x124(%rbp)
cmpl   $0x64,-0x124(%rbp)
jge    127a <tests+0x11a>
lea    -0x110(%rbp),%rdi
mov    $0x5a,%esi
mov    $0x100,%edx
call   1060 <memset@plt>
lea    -0x110(%rbp),%rdi
lea    -0x120(%rbp),%rcx
mov    $0x100,%esi
lea    0xe17(%rip),%rdx
call   1030 <namegen@plt>
mov    %eax,-0x4(%rbp)
cmpl   $0x0,-0x4(%rbp)
jne    1230 <tests+0xd0>
movsbl -0x10f(%rbp),%eax
cmp    $0x0,%eax
jne    1230 <tests+0xd0>
lea    0xdf4(%rip),%rdi
movsbl -0x110(%rbp),%esi
call   1040 <strchr@plt>
cmp    $0x0,%rax
jne    1244 <tests+0xe4>
mov    -0x128(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x128(%rbp)
jmp    1261 <tests+0x101>
movsbl -0x110(%rbp),%eax
sub    $0x30,%eax
cltq
mov    -0x134(%rbp,%rax,4),%ecx
add    $0x1,%ecx
mov    %ecx,-0x134(%rbp,%rax,4)
jmp    1266 <tests+0x106>
mov    -0x124(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x124(%rbp)
jmp    11b4 <tests+0x54>
jmp    127f <tests+0x11f>
cmpl   $0x0,-0x128(%rbp)
jne    12dc <tests+0x17c>
cmpl   $0x0,-0x134(%rbp)
je     12dc <tests+0x17c>
cmpl   $0x0,-0x130(%rbp)
je     12dc <tests+0x17c>
cmpl   $0x0,-0x12c(%rbp)
je     12dc <tests+0x17c>
lea    0xd58(%rip),%rdi
lea    0xd65(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x114(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x114(%rbp)
jmp    1300 <tests+0x1a0>
lea    0xd4f(%rip),%rdi
lea    0xd3c(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x118(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
jmp    1305 <tests+0x1a5>
movl   $0x0,-0x13c(%rbp)
lea    -0x160(%rbp),%rdi
xor    %esi,%esi
mov    $0x18,%edx
call   1060 <memset@plt>
movl   $0x0,-0x138(%rbp)
cmpl   $0x64,-0x138(%rbp)
jge    1446 <tests+0x2e6>
lea    -0x110(%rbp),%rdi
mov    $0x5a,%esi
mov    $0x100,%edx
call   1060 <memset@plt>
lea    -0x110(%rbp),%rdi
lea    -0x120(%rbp),%rcx
mov    $0x100,%esi
lea    0xcdd(%rip),%rdx
call   1030 <namegen@plt>
mov    %eax,-0x4(%rbp)
cmpl   $0x0,-0x4(%rbp)
jne    13a8 <tests+0x248>
movsbl -0x110(%rbp),%eax
cmp    $0x76,%eax
jne    13a8 <tests+0x248>
cmpb   $0x0,-0x10f(%rbp)
je     13a8 <tests+0x248>
movsbl -0x10e(%rbp),%eax
cmp    $0x0,%eax
je     13bc <tests+0x25c>
mov    -0x13c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x13c(%rbp)
jmp    142d <tests+0x2cd>
lea    0xc88(%rip),%rax
mov    %rax,-0x168(%rbp)
mov    -0x168(%rbp),%rdi
movsbl -0x10f(%rbp),%esi
call   1040 <strchr@plt>
mov    %rax,-0x170(%rbp)
cmpq   $0x0,-0x170(%rbp)
jne    1406 <tests+0x2a6>
mov    -0x13c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x13c(%rbp)
jmp    1428 <tests+0x2c8>
mov    -0x170(%rbp),%rax
mov    -0x168(%rbp),%rcx
sub    %rcx,%rax
mov    -0x160(%rbp,%rax,4),%ecx
add    $0x1,%ecx
mov    %ecx,-0x160(%rbp,%rax,4)
jmp    142d <tests+0x2cd>
jmp    1432 <tests+0x2d2>
mov    -0x138(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x138(%rbp)
jmp    132c <tests+0x1cc>
movl   $0x0,-0x138(%rbp)
cmpl   $0x6,-0x138(%rbp)
jge    1496 <tests+0x336>
movslq -0x138(%rbp),%rax
cmpl   $0x0,-0x160(%rbp,%rax,4)
setne  %al
xor    $0xff,%al
and    $0x1,%al
movzbl %al,%eax
add    -0x13c(%rbp),%eax
mov    %eax,-0x13c(%rbp)
mov    -0x138(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x138(%rbp)
jmp    1450 <tests+0x2f0>
jmp    149b <tests+0x33b>
cmpl   $0x0,-0x13c(%rbp)
jne    14d1 <tests+0x371>
lea    0xb63(%rip),%rdi
lea    0xb9c(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x114(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x114(%rbp)
jmp    14f5 <tests+0x395>
lea    0xb5a(%rip),%rdi
lea    0xb73(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x118(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
jmp    14fa <tests+0x39a>
lea    -0x110(%rbp),%rdi
lea    -0x120(%rbp),%rcx
mov    $0x100,%esi
lea    0xb7d(%rip),%rdx
call   1030 <namegen@plt>
mov    %eax,-0x4(%rbp)
cmpl   $0x2,-0x4(%rbp)
jne    154f <tests+0x3ef>
lea    0xae5(%rip),%rdi
lea    0xb2b(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x114(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x114(%rbp)
jmp    1573 <tests+0x413>
lea    0xadc(%rip),%rdi
lea    0xb02(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x118(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
jmp    1578 <tests+0x418>
lea    -0x110(%rbp),%rdi
lea    -0x120(%rbp),%rcx
mov    $0x100,%esi
lea    0xaec(%rip),%rdx
call   1030 <namegen@plt>
mov    %eax,-0x4(%rbp)
cmpl   $0x2,-0x4(%rbp)
jne    15cd <tests+0x46d>
lea    0xa67(%rip),%rdi
lea    0xabd(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x114(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x114(%rbp)
jmp    15f1 <tests+0x491>
lea    0xa5e(%rip),%rdi
lea    0xa94(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x118(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
jmp    15f6 <tests+0x496>
lea    -0x110(%rbp),%rdi
lea    -0x120(%rbp),%rcx
mov    $0x100,%esi
lea    0xa6d(%rip),%rdx
call   1030 <namegen@plt>
mov    %eax,-0x4(%rbp)
cmpl   $0x2,-0x4(%rbp)
jne    164b <tests+0x4eb>
lea    0x9e9(%rip),%rdi
lea    0xa51(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x114(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x114(%rbp)
jmp    166f <tests+0x50f>
lea    0x9e0(%rip),%rdi
lea    0xa28(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x118(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
jmp    1674 <tests+0x514>
lea    -0x110(%rbp),%rdi
lea    -0x120(%rbp),%rcx
mov    $0x100,%esi
lea    0xa02(%rip),%rdx
call   1030 <namegen@plt>
mov    %eax,-0x4(%rbp)
cmpl   $0x2,-0x4(%rbp)
jne    16c9 <tests+0x569>
lea    0x96b(%rip),%rdi
lea    0x9e6(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x114(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x114(%rbp)
jmp    16ed <tests+0x58d>
lea    0x962(%rip),%rdi
lea    0x9bd(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x118(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
jmp    16f2 <tests+0x592>
lea    -0x110(%rbp),%rdi
lea    -0x120(%rbp),%rcx
mov    $0x100,%esi
lea    0x999(%rip),%rdx
call   1030 <namegen@plt>
mov    %eax,-0x4(%rbp)
cmpl   $0x2,-0x4(%rbp)
jne    1747 <tests+0x5e7>
lea    0x8ed(%rip),%rdi
lea    0x97c(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x114(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x114(%rbp)
jmp    176b <tests+0x60b>
lea    0x8e4(%rip),%rdi
lea    0x953(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x118(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
jmp    1770 <tests+0x610>
lea    -0x110(%rbp),%rdi
lea    -0x120(%rbp),%rcx
mov    $0x100,%esi
lea    0x92f(%rip),%rdx
call   1030 <namegen@plt>
mov    %eax,-0x4(%rbp)
cmpl   $0x2,-0x4(%rbp)
jne    17c5 <tests+0x665>
lea    0x86f(%rip),%rdi
lea    0x912(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x114(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x114(%rbp)
jmp    17e9 <tests+0x689>
lea    0x866(%rip),%rdi
lea    0x8e9(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x118(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
jmp    17ee <tests+0x68e>
lea    0x8d6(%rip),%rax
mov    %rax,-0x178(%rbp)
lea    -0x110(%rbp),%rdi
mov    $0x5a,%esi
mov    $0x100,%edx
call   1060 <memset@plt>
lea    -0x110(%rbp),%rdi
mov    -0x178(%rbp),%rdx
lea    -0x120(%rbp),%rcx
mov    $0x100,%esi
call   1030 <namegen@plt>
mov    %eax,-0x4(%rbp)
cmpl   $0x0,-0x4(%rbp)
jne    1883 <tests+0x723>
lea    -0x110(%rbp),%rdi
lea    0x86e(%rip),%rsi
call   1070 <strcmp@plt>
cmp    $0x0,%eax
jne    1883 <tests+0x723>
lea    0x7b1(%rip),%rdi
lea    0x88f(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x114(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x114(%rbp)
jmp    18a7 <tests+0x747>
lea    0x7a8(%rip),%rdi
lea    0x866(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x118(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
jmp    18ac <tests+0x74c>
lea    -0x110(%rbp),%rdi
mov    $0x5a,%esi
mov    $0x100,%edx
call   1060 <memset@plt>
lea    -0x110(%rbp),%rdi
lea    -0x120(%rbp),%rcx
mov    $0x4,%esi
lea    0x828(%rip),%rdx
call   1030 <namegen@plt>
mov    %eax,-0x4(%rbp)
cmpl   $0x1,-0x4(%rbp)
jne    1943 <tests+0x7e3>
lea    -0x110(%rbp),%rdi
lea    0x812(%rip),%rsi
call   1070 <strcmp@plt>
cmp    $0x0,%eax
jne    1943 <tests+0x7e3>
movsbl -0x10c(%rbp),%eax
cmp    $0x5a,%eax
jne    1943 <tests+0x7e3>
lea    0x6f1(%rip),%rdi
lea    0x7ea(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x114(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x114(%rbp)
jmp    1967 <tests+0x807>
lea    0x6e8(%rip),%rdi
lea    0x7c1(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x118(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
jmp    196c <tests+0x80c>
lea    -0x110(%rbp),%rdi
mov    $0x5a,%esi
mov    $0x100,%edx
call   1060 <memset@plt>
lea    -0x110(%rbp),%rdi
lea    -0x120(%rbp),%rcx
mov    $0x2,%esi
lea    0x783(%rip),%rdx
call   1030 <namegen@plt>
mov    %eax,-0x4(%rbp)
cmpl   $0x1,-0x4(%rbp)
jne    1a04 <tests+0x8a4>
movsbl -0x110(%rbp),%eax
cmp    $0x0,%eax
je     1a04 <tests+0x8a4>
cmpb   $0x0,-0x10f(%rbp)
jne    1a04 <tests+0x8a4>
movsbl -0x10e(%rbp),%eax
cmp    $0x5a,%eax
jne    1a04 <tests+0x8a4>
lea    0x630(%rip),%rdi
lea    0x738(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x114(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x114(%rbp)
jmp    1a28 <tests+0x8c8>
lea    0x627(%rip),%rdi
lea    0x70f(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x118(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
jmp    1a2d <tests+0x8cd>
lea    -0x110(%rbp),%rdi
lea    -0x120(%rbp),%rcx
mov    $0x100,%esi
lea    0x6e7(%rip),%rdx
call   1030 <namegen@plt>
mov    %eax,-0x4(%rbp)
cmpl   $0x0,-0x4(%rbp)
jne    1a9e <tests+0x93e>
lea    -0x110(%rbp),%rdi
lea    0x6ce(%rip),%rsi
call   1070 <strcmp@plt>
cmp    $0x0,%eax
jne    1a9e <tests+0x93e>
lea    0x596(%rip),%rdi
lea    0x6b6(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x114(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x114(%rbp)
jmp    1ac2 <tests+0x962>
lea    0x58d(%rip),%rdi
lea    0x68d(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x118(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
jmp    1ac7 <tests+0x967>
lea    -0x110(%rbp),%rdi
lea    -0x120(%rbp),%rcx
mov    $0x100,%esi
lea    0x669(%rip),%rdx
call   1030 <namegen@plt>
mov    %eax,-0x4(%rbp)
cmpl   $0x0,-0x4(%rbp)
jne    1b38 <tests+0x9d8>
lea    -0x110(%rbp),%rdi
lea    0x634(%rip),%rsi
call   1070 <strcmp@plt>
cmp    $0x0,%eax
jne    1b38 <tests+0x9d8>
lea    0x4fc(%rip),%rdi
lea    0x634(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x114(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x114(%rbp)
jmp    1b5c <tests+0x9fc>
lea    0x4f3(%rip),%rdi
lea    0x60b(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x118(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
jmp    1b61 <tests+0xa01>
lea    -0x110(%rbp),%rdi
lea    -0x120(%rbp),%rcx
mov    $0x100,%esi
lea    0x5e7(%rip),%rdx
call   1030 <namegen@plt>
mov    %eax,-0x4(%rbp)
cmpl   $0x0,-0x4(%rbp)
jne    1bd2 <tests+0xa72>
lea    -0x110(%rbp),%rdi
lea    0x5ce(%rip),%rsi
call   1070 <strcmp@plt>
cmp    $0x0,%eax
jne    1bd2 <tests+0xa72>
lea    0x462(%rip),%rdi
lea    0x5b6(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x114(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x114(%rbp)
jmp    1bf6 <tests+0xa96>
lea    0x459(%rip),%rdi
lea    0x58d(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x118(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
jmp    1bfb <tests+0xa9b>
lea    -0x110(%rbp),%rdi
mov    $0x5a,%esi
mov    $0x100,%edx
call   1060 <memset@plt>
lea    -0x110(%rbp),%rdi
lea    -0x120(%rbp),%rcx
mov    $0x100,%esi
lea    0x56d(%rip),%rdx
call   1030 <namegen@plt>
mov    %eax,-0x4(%rbp)
cmpl   $0x0,-0x4(%rbp)
jne    1c83 <tests+0xb23>
cmpb   $0x0,-0x110(%rbp)
jne    1c83 <tests+0xb23>
movsbl -0x10f(%rbp),%eax
cmp    $0x5a,%eax
jne    1c83 <tests+0xb23>
lea    0x3b1(%rip),%rdi
lea    0x516(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x114(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x114(%rbp)
jmp    1ca7 <tests+0xb47>
lea    0x3a8(%rip),%rdi
lea    0x4ed(%rip),%rsi
mov    $0x0,%al
call   1050 <printf@plt>
mov    -0x118(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
jmp    1cac <tests+0xb4c>
cmpl   $0x0,-0x118(%rbp)
je     1cc7 <tests+0xb67>
mov    0x2320(%rip),%rax
mov    (%rax),%edi
call   1080 <exit@plt>
mov    -0x114(%rbp),%esi
lea    0x4b0(%rip),%rdi
mov    $0x0,%al
call   1050 <printf@plt>
mov    0x22f6(%rip),%rax
mov    (%rax),%edi
call   1080 <exit@plt>

x86 assembly (clang, -O2):
<tests>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x138,%rsp
mov    $0xd22bfb3b,%eax
mov    %rax,(%rsp)
movl   $0x0,0x18(%rsp)
movq   $0x0,0x10(%rsp)
xor    %ebx,%ebx
mov    $0x64,%r15d
lea    0x30(%rsp),%r13
lea    0xe71(%rip),%r14
mov    %rsp,%r12
jmp    11a9 <tests+0x59>
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
add    $0x1,%ebx
add    $0xffffffff,%r15d
je     1202 <tests+0xb2>
mov    %r13,%rdi
mov    $0x5a,%esi
mov    $0x100,%edx
call   1060 <memset@plt>
mov    %r13,%rdi
mov    $0x100,%esi
mov    %r14,%rdx
mov    %r12,%rcx
call   1030 <namegen@plt>
test   %eax,%eax
jne    11a0 <tests+0x50>
cmpb   $0x0,0x31(%rsp)
jne    11a0 <tests+0x50>
movsbl 0x30(%rsp),%ebp
lea    0xe21(%rip),%rdi
mov    %ebp,%esi
call   1040 <strchr@plt>
test   %rax,%rax
je     11a0 <tests+0x50>
movslq %ebp,%rax
addl   $0x1,-0xb0(%rsp,%rax,4)
01
add    $0xffffffff,%r15d
jne    11a9 <tests+0x59>
test   %ebx,%ebx
sete   %al
cmpl   $0x0,0x10(%rsp)
setne  %cl
and    %al,%cl
cmpl   $0x0,0x14(%rsp)
setne  %al
cmpl   $0x0,0x18(%rsp)
setne  %dl
and    %al,%dl
and    %cl,%dl
lea    0xdde(%rip),%rax
lea    0xdf7(%rip),%rdi
cmovne %rax,%rdi
movzbl %dl,%eax
mov    %eax,0xc(%rsp)
xor    $0x1,%dl
movzbl %dl,%eax
mov    %eax,0x2c(%rsp)
lea    0xdcf(%rip),%rsi
xor    %r14d,%r14d
xor    %eax,%eax
call   1050 <printf@plt>
pxor   %xmm0,%xmm0
movdqa %xmm0,0x10(%rsp)
movq   $0x0,0x20(%rsp)
mov    $0x64,%r13d
lea    0x30(%rsp),%rbx
lea    0xdc0(%rip),%r15
mov    %rsp,%rbp
lea    0xdbb(%rip),%r12
jmp    129a <tests+0x14a>
nopw   0x0(%rax,%rax,1)
add    $0x1,%r14d
add    $0xffffffff,%r13d
je     12f8 <tests+0x1a8>
mov    %rbx,%rdi
mov    $0x5a,%esi
mov    $0x100,%edx
call   1060 <memset@plt>
mov    %rbx,%rdi
mov    $0x100,%esi
mov    %r15,%rdx
mov    %rbp,%rcx
call   1030 <namegen@plt>
test   %eax,%eax
jne    1290 <tests+0x140>
cmpb   $0x76,0x30(%rsp)
jne    1290 <tests+0x140>
movzbl 0x31(%rsp),%eax
test   %al,%al
je     1290 <tests+0x140>
cmpb   $0x0,0x32(%rsp)
jne    1290 <tests+0x140>
movsbl %al,%esi
mov    %r12,%rdi
call   1040 <strchr@plt>
test   %rax,%rax
je     1290 <tests+0x140>
sub    %r12,%rax
addl   $0x1,0x10(%rsp,%rax,4)
add    $0xffffffff,%r13d
jne    129a <tests+0x14a>
pxor   %xmm0,%xmm0
pcmpeqd 0x10(%rsp),%xmm0
movmskps %xmm0,%eax
mov    %eax,%ecx
shr    %cl
and    $0x5,%cl
sub    %cl,%al
mov    %eax,%ecx
and    $0x33,%cl
shr    $0x2,%al
and    $0x33,%al
add    %cl,%al
mov    %eax,%ecx
shr    $0x4,%cl
add    %al,%cl
and    $0xf,%cl
movzbl %cl,%eax
cmpl   $0x1,0x20(%rsp)
adc    $0x0,%eax
add    %r14d,%eax
cmpl   $0x1,0x24(%rsp)
sbb    %ecx,%ecx
cmp    %ecx,%eax
jne    1361 <tests+0x211>
lea    0xcc6(%rip),%rdi
lea    0xcff(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
mov    0xc(%rsp),%r14d
add    $0x1,%r14d
mov    0x2c(%rsp),%ebp
jmp    1383 <tests+0x233>
lea    0xcc2(%rip),%rdi
lea    0xcdb(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
mov    $0x2,%ebp
mov    0xc(%rsp),%r14d
sub    %r14d,%ebp
lea    0xcff(%rip),%rdx
lea    0x30(%rsp),%rdi
mov    %rsp,%rcx
mov    $0x100,%esi
call   1030 <namegen@plt>
cmp    $0x2,%eax
jne    13bc <tests+0x26c>
lea    0xc62(%rip),%rdi
lea    0xca8(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%r14d
jmp    13d4 <tests+0x284>
lea    0xc67(%rip),%rdi
lea    0xc8d(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%ebp
lea    0xc9b(%rip),%rdx
lea    0x30(%rsp),%rdi
mov    %rsp,%rcx
mov    $0x100,%esi
call   1030 <namegen@plt>
cmp    $0x2,%eax
jne    140d <tests+0x2bd>
lea    0xc11(%rip),%rdi
lea    0xc67(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%r14d
jmp    1425 <tests+0x2d5>
lea    0xc16(%rip),%rdi
lea    0xc4c(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%ebp
lea    0xc49(%rip),%rdx
lea    0x30(%rsp),%rdi
mov    %rsp,%rcx
mov    $0x100,%esi
call   1030 <namegen@plt>
cmp    $0x2,%eax
jne    145e <tests+0x30e>
lea    0xbc0(%rip),%rdi
lea    0xc28(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%r14d
jmp    1476 <tests+0x326>
lea    0xbc5(%rip),%rdi
lea    0xc0d(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%ebp
lea    0xc0b(%rip),%rdx
lea    0x30(%rsp),%rdi
mov    %rsp,%rcx
mov    $0x100,%esi
call   1030 <namegen@plt>
cmp    $0x2,%eax
jne    14af <tests+0x35f>
lea    0xb6f(%rip),%rdi
lea    0xbea(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%r14d
jmp    14c7 <tests+0x377>
lea    0xb74(%rip),%rdi
lea    0xbcf(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%ebp
lea    0xbcf(%rip),%rdx
lea    0x30(%rsp),%rdi
mov    %rsp,%rcx
mov    $0x100,%esi
call   1030 <namegen@plt>
cmp    $0x2,%eax
jne    1500 <tests+0x3b0>
lea    0xb1e(%rip),%rdi
lea    0xbad(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%r14d
jmp    1518 <tests+0x3c8>
lea    0xb23(%rip),%rdi
lea    0xb92(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%ebp
lea    0xb92(%rip),%rdx
lea    0x30(%rsp),%rdi
mov    %rsp,%rcx
mov    $0x100,%esi
call   1030 <namegen@plt>
cmp    $0x2,%eax
jne    1551 <tests+0x401>
lea    0xacd(%rip),%rdi
lea    0xb70(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%r14d
jmp    1569 <tests+0x419>
lea    0xad2(%rip),%rdi
lea    0xb55(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%ebp
lea    0x30(%rsp),%rbx
mov    %rbx,%rdi
mov    $0x5a,%esi
mov    $0x100,%edx
call   1060 <memset@plt>
lea    0xb3c(%rip),%rdx
mov    %rsp,%rcx
mov    %rbx,%rdi
mov    $0x100,%esi
call   1030 <namegen@plt>
test   %eax,%eax
jne    15be <tests+0x46e>
cmpw   $0x61,0x30(%rsp)
jne    15be <tests+0x46e>
lea    0xa60(%rip),%rdi
lea    0xb3e(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%r14d
jmp    15d6 <tests+0x486>
lea    0xa65(%rip),%rdi
lea    0xb23(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%ebp
lea    0x30(%rsp),%rbx
mov    %rbx,%rdi
mov    $0x5a,%esi
mov    $0x100,%edx
call   1060 <memset@plt>
lea    0xb08(%rip),%rdx
mov    %rsp,%rcx
mov    %rbx,%rdi
mov    $0x4,%esi
call   1030 <namegen@plt>
cmp    $0x1,%eax
jne    1635 <tests+0x4e5>
cmpl   $0x636261,0x30(%rsp)
jne    1635 <tests+0x4e5>
cmpb   $0x5a,0x34(%rsp)
jne    1635 <tests+0x4e5>
lea    0x9e9(%rip),%rdi
lea    0xade(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%r14d
jmp    164d <tests+0x4fd>
lea    0x9ee(%rip),%rdi
lea    0xac3(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%ebp
lea    0x30(%rsp),%rbx
mov    %rbx,%rdi
mov    $0x5a,%esi
mov    $0x100,%edx
call   1060 <memset@plt>
lea    0xaa8(%rip),%rdx
mov    %rsp,%rcx
mov    %rbx,%rdi
mov    $0x2,%esi
call   1030 <namegen@plt>
cmp    $0x1,%eax
jne    16b0 <tests+0x560>
cmpb   $0x0,0x30(%rsp)
je     16b0 <tests+0x560>
cmpb   $0x0,0x31(%rsp)
jne    16b0 <tests+0x560>
cmpb   $0x5a,0x32(%rsp)
jne    16b0 <tests+0x560>
lea    0x96e(%rip),%rdi
lea    0xa72(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%r14d
jmp    16c8 <tests+0x578>
lea    0x973(%rip),%rdi
lea    0xa57(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%ebp
lea    0xa53(%rip),%rdx
lea    0x30(%rsp),%rdi
mov    %rsp,%rcx
mov    $0x100,%esi
call   1030 <namegen@plt>
test   %eax,%eax
jne    170a <tests+0x5ba>
cmpl   $0x6f6f46,0x30(%rsp)
jne    170a <tests+0x5ba>
lea    0x914(%rip),%rdi
lea    0xa2c(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%r14d
jmp    1722 <tests+0x5d2>
lea    0x919(%rip),%rdi
lea    0xa11(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%ebp
lea    0xa11(%rip),%rdx
lea    0x30(%rsp),%rdi
mov    %rsp,%rcx
mov    $0x100,%esi
call   1030 <namegen@plt>
test   %eax,%eax
jne    1764 <tests+0x614>
cmpl   $0x6f6f46,0x30(%rsp)
jne    1764 <tests+0x614>
lea    0x8ba(%rip),%rdi
lea    0x9ea(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%r14d
jmp    177c <tests+0x62c>
lea    0x8bf(%rip),%rdi
lea    0x9cf(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%ebp
lea    0x9cf(%rip),%rdx
lea    0x30(%rsp),%rdi
mov    %rsp,%rcx
mov    $0x100,%esi
call   1030 <namegen@plt>
test   %eax,%eax
jne    17be <tests+0x66e>
cmpl   $0x6f4f66,0x30(%rsp)
jne    17be <tests+0x66e>
lea    0x860(%rip),%rdi
lea    0x9a8(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%r14d
jmp    17d6 <tests+0x686>
lea    0x865(%rip),%rdi
lea    0x98d(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%ebp
lea    0x30(%rsp),%rbx
mov    %rbx,%rdi
mov    $0x5a,%esi
mov    $0x100,%edx
call   1060 <memset@plt>
lea    0x990(%rip),%rdx
mov    %rsp,%rcx
mov    %rbx,%rdi
mov    $0x100,%esi
call   1030 <namegen@plt>
test   %eax,%eax
jne    1841 <tests+0x6f1>
cmpb   $0x0,0x30(%rsp)
jne    1841 <tests+0x6f1>
cmpb   $0x5a,0x31(%rsp)
jne    1841 <tests+0x6f1>
lea    0x7ed(%rip),%rdi
lea    0x946(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%r14d
test   %ebp,%ebp
je     185d <tests+0x70d>
mov    0x27a6(%rip),%rax
mov    (%rax),%edi
call   1070 <exit@plt>
lea    0x7e2(%rip),%rdi
lea    0x91b(%rip),%rsi
xor    %eax,%eax
call   1050 <printf@plt>
add    $0x1,%ebp
test   %ebp,%ebp
jne    1833 <tests+0x6e3>
lea    0x90c(%rip),%rdi
mov    %r14d,%esi
xor    %eax,%eax
call   1050 <printf@plt>
mov    0x2763(%rip),%rax
mov    (%rax),%edi
call   1070 <exit@plt>

LLVM IR (-O0):
@__const.tests.rng = [1 x i64] [i64 3526097723]
@.str = [6 x i8] c"0|1|2\00"
@.str.1 = [4 x i8] c"012\00"
@.str.2 = [20 x i8] c"\1B[32;1mPASS\1B[0m %s\0A\00"
@.str.3 = [12 x i8] c"alternation\00"
@.str.4 = [20 x i8] c"\1B[31;1mFAIL\1B[0m %s\0A\00"
@.str.5 = [5 x i8] c"(v)v\00"
@.str.6 = [7 x i8] c"aeiouy\00"
@.str.7 = [13 x i8] c"substitution\00"
@.str.8 = [3 x i8] c"a>\00"
@.str.9 = [16 x i8] c"closing bracket\00"
@.str.10 = [3 x i8] c"a)\00"
@.str.11 = [14 x i8] c"closing paren\00"
@.str.12 = [4 x i8] c"<a)\00"
@.str.13 = [15 x i8] c"mismatch paren\00"
@.str.14 = [4 x i8] c"(a>\00"
@.str.15 = [17 x i8] c"mismatch bracket\00"
@.str.16 = [3 x i8] c"<a\00"
@.str.17 = [17 x i8] c"unclosed bracket\00"
@.str.18 = [3 x i8] c"(a\00"
@.str.19 = [15 x i8] c"unclosed paren\00"
@.str.20 = [44 x i8] c"(((((<(((((((((((((((a)))))))))))))))>)))))\00"
@.str.21 = [2 x i8] c"a\00"
@.str.22 = [13 x i8] c"deep nesting\00"
@.str.23 = [10 x i8] c"(abcdefg)\00"
@.str.24 = [4 x i8] c"abc\00"
@.str.25 = [13 x i8] c"truncation 1\00"
@.str.26 = [2 x i8] c"i\00"
@.str.27 = [13 x i8] c"truncation 2\00"
@.str.28 = [7 x i8] c"!(foo)\00"
@.str.29 = [4 x i8] c"Foo\00"
@.str.30 = [17 x i8] c"capitalization 1\00"
@.str.31 = [7 x i8] c"(!foo)\00"
@.str.32 = [17 x i8] c"capitalization 2\00"
@.str.33 = [7 x i8] c"(f!oo)\00"
@.str.34 = [4 x i8] c"fOo\00"
@.str.35 = [17 x i8] c"capitalization 3\00"
@.str.36 = [1 x i8] zeroinitializer
@.str.37 = [6 x i8] c"empty\00"
@EXIT_FAILURE = global i32 0
@.str.38 = [21 x i8] c"All %d tests passed\0A\00"
@EXIT_SUCCESS = global i32 0
define void @tests() {
%1 = alloca i32
%2 = alloca [256 x i8]
%3 = alloca i32
%4 = alloca i32
%5 = alloca [1 x i64]
%6 = alloca i32
%7 = alloca i32
%8 = alloca [3 x i32]
%9 = alloca i32
%10 = alloca i32
%11 = alloca [6 x i32]
%12 = alloca i8*
%13 = alloca i8*
%14 = alloca i8*
store i32 0, i32* %3
store i32 0, i32* %4
%15 = bitcast [1 x i64]* %5 to i8*
store i32 0, i32* %7
%16 = bitcast [3 x i32]* %8 to i8*
store i32 0, i32* %6
br label %17
17: ; preds = %51, %0
%18 = load i32, i32* %6
%19 = icmp slt i32 %18, 100
br i1 %19, label %20, label %54
20: ; preds = %17
%21 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%22 = call i32 @memset(i8* %21, i32 90, i32 256)
%23 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%24 = getelementptr inbounds [1 x i64], [1 x i64]* %5, i64 0, i64 0
%25 = call i32 @namegen(i8* %23, i32 256, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i64* %24)
store i32 %25, i32* %1
%26 = load i32, i32* %1
%27 = icmp ne i32 %26, 0
br i1 %27, label %38, label %28
28: ; preds = %20
%29 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 1
%30 = load i8, i8* %29
%31 = sext i8 %30 to i32
%32 = icmp ne i32 %31, 0
br i1 %32, label %38, label %33
33: ; preds = %28
%34 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%35 = load i8, i8* %34
%36 = call i8* @strchr(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8 signext %35)
%37 = icmp ne i8* %36, null
br i1 %37, label %41, label %38
38: ; preds = %33, %28, %20
%39 = load i32, i32* %7
%40 = add nsw i32 %39, 1
store i32 %40, i32* %7
br label %50
41: ; preds = %33
%42 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%43 = load i8, i8* %42
%44 = sext i8 %43 to i32
%45 = sub nsw i32 %44, 48
%46 = sext i32 %45 to i64
%47 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 %46
%48 = load i32, i32* %47
%49 = add nsw i32 %48, 1
store i32 %49, i32* %47
br label %50
50: ; preds = %41, %38
br label %51
51: ; preds = %50
%52 = load i32, i32* %6
%53 = add nsw i32 %52, 1
store i32 %53, i32* %6
br label %17
54: ; preds = %17
br label %55
55: ; preds = %54
%56 = load i32, i32* %7
%57 = icmp ne i32 %56, 0
br i1 %57, label %74, label %58
58: ; preds = %55
%59 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 0
%60 = load i32, i32* %59
%61 = icmp ne i32 %60, 0
br i1 %61, label %62, label %74
62: ; preds = %58
%63 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 1
%64 = load i32, i32* %63
%65 = icmp ne i32 %64, 0
br i1 %65, label %66, label %74
66: ; preds = %62
%67 = getelementptr inbounds [3 x i32], [3 x i32]* %8, i64 0, i64 2
%68 = load i32, i32* %67
%69 = icmp ne i32 %68, 0
br i1 %69, label %70, label %74
70: ; preds = %66
%71 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.3, i64 0, i64 0))
%72 = load i32, i32* %3
%73 = add nsw i32 %72, 1
store i32 %73, i32* %3
br label %78
74: ; preds = %66, %62, %58, %55
%75 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.3, i64 0, i64 0))
%76 = load i32, i32* %4
%77 = add nsw i32 %76, 1
store i32 %77, i32* %4
br label %78
78: ; preds = %74, %70
br label %79
79: ; preds = %78
store i32 0, i32* %10
%80 = bitcast [6 x i32]* %11 to i8*
store i32 0, i32* %9
br label %81
81: ; preds = %130, %79
%82 = load i32, i32* %9
%83 = icmp slt i32 %82, 100
br i1 %83, label %84, label %133
84: ; preds = %81
%85 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%86 = call i32 @memset(i8* %85, i32 90, i32 256)
%87 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%88 = getelementptr inbounds [1 x i64], [1 x i64]* %5, i64 0, i64 0
%89 = call i32 @namegen(i8* %87, i32 256, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i64* %88)
store i32 %89, i32* %1
%90 = load i32, i32* %1
%91 = icmp ne i32 %90, 0
br i1 %91, label %106, label %92
92: ; preds = %84
%93 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%94 = load i8, i8* %93
%95 = sext i8 %94 to i32
%96 = icmp ne i32 %95, 118
br i1 %96, label %106, label %97
97: ; preds = %92
%98 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 1
%99 = load i8, i8* %98
%100 = icmp ne i8 %99, 0
br i1 %100, label %101, label %106
101: ; preds = %97
%102 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 2
%103 = load i8, i8* %102
%104 = sext i8 %103 to i32
%105 = icmp ne i32 %104, 0
br i1 %105, label %106, label %109
106: ; preds = %101, %97, %92, %84
%107 = load i32, i32* %10
%108 = add nsw i32 %107, 1
store i32 %108, i32* %10
br label %129
109: ; preds = %101
store i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.6, i64 0, i64 0), i8** %12
%110 = load i8*, i8** %12
%111 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 1
%112 = load i8, i8* %111
%113 = call i8* @strchr(i8* %110, i8 signext %112)
store i8* %113, i8** %13
%114 = load i8*, i8** %13
%115 = icmp ne i8* %114, null
br i1 %115, label %119, label %116
116: ; preds = %109
%117 = load i32, i32* %10
%118 = add nsw i32 %117, 1
store i32 %118, i32* %10
br label %128
119: ; preds = %109
%120 = load i8*, i8** %13
%121 = load i8*, i8** %12
%122 = ptrtoint i8* %120 to i64
%123 = ptrtoint i8* %121 to i64
%124 = sub i64 %122, %123
%125 = getelementptr inbounds [6 x i32], [6 x i32]* %11, i64 0, i64 %124
%126 = load i32, i32* %125
%127 = add nsw i32 %126, 1
store i32 %127, i32* %125
br label %128
128: ; preds = %119, %116
br label %129
129: ; preds = %128, %106
br label %130
130: ; preds = %129
%131 = load i32, i32* %9
%132 = add nsw i32 %131, 1
store i32 %132, i32* %9
br label %81
133: ; preds = %81
store i32 0, i32* %9
br label %134
134: ; preds = %147, %133
%135 = load i32, i32* %9
%136 = icmp slt i32 %135, 6
br i1 %136, label %137, label %150
137: ; preds = %134
%138 = load i32, i32* %9
%139 = sext i32 %138 to i64
%140 = getelementptr inbounds [6 x i32], [6 x i32]* %11, i64 0, i64 %139
%141 = load i32, i32* %140
%142 = icmp ne i32 %141, 0
%143 = xor i1 %142, true
%144 = zext i1 %143 to i32
%145 = load i32, i32* %10
%146 = add nsw i32 %145, %144
store i32 %146, i32* %10
br label %147
147: ; preds = %137
%148 = load i32, i32* %9
%149 = add nsw i32 %148, 1
store i32 %149, i32* %9
br label %134
150: ; preds = %134
br label %151
151: ; preds = %150
%152 = load i32, i32* %10
%153 = icmp ne i32 %152, 0
br i1 %153, label %158, label %154
154: ; preds = %151
%155 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.7, i64 0, i64 0))
%156 = load i32, i32* %3
%157 = add nsw i32 %156, 1
store i32 %157, i32* %3
br label %162
158: ; preds = %151
%159 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.7, i64 0, i64 0))
%160 = load i32, i32* %4
%161 = add nsw i32 %160, 1
store i32 %161, i32* %4
br label %162
162: ; preds = %158, %154
br label %163
163: ; preds = %162
%164 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%165 = getelementptr inbounds [1 x i64], [1 x i64]* %5, i64 0, i64 0
%166 = call i32 @namegen(i8* %164, i32 256, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.8, i64 0, i64 0), i64* %165)
store i32 %166, i32* %1
br label %167
167: ; preds = %163
%168 = load i32, i32* %1
%169 = icmp eq i32 %168, 2
br i1 %169, label %170, label %174
170: ; preds = %167
%171 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.9, i64 0, i64 0))
%172 = load i32, i32* %3
%173 = add nsw i32 %172, 1
store i32 %173, i32* %3
br label %178
174: ; preds = %167
%175 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.9, i64 0, i64 0))
%176 = load i32, i32* %4
%177 = add nsw i32 %176, 1
store i32 %177, i32* %4
br label %178
178: ; preds = %174, %170
br label %179
179: ; preds = %178
%180 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%181 = getelementptr inbounds [1 x i64], [1 x i64]* %5, i64 0, i64 0
%182 = call i32 @namegen(i8* %180, i32 256, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.10, i64 0, i64 0), i64* %181)
store i32 %182, i32* %1
br label %183
183: ; preds = %179
%184 = load i32, i32* %1
%185 = icmp eq i32 %184, 2
br i1 %185, label %186, label %190
186: ; preds = %183
%187 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.11, i64 0, i64 0))
%188 = load i32, i32* %3
%189 = add nsw i32 %188, 1
store i32 %189, i32* %3
br label %194
190: ; preds = %183
%191 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.11, i64 0, i64 0))
%192 = load i32, i32* %4
%193 = add nsw i32 %192, 1
store i32 %193, i32* %4
br label %194
194: ; preds = %190, %186
br label %195
195: ; preds = %194
%196 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%197 = getelementptr inbounds [1 x i64], [1 x i64]* %5, i64 0, i64 0
%198 = call i32 @namegen(i8* %196, i32 256, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.12, i64 0, i64 0), i64* %197)
store i32 %198, i32* %1
br label %199
199: ; preds = %195
%200 = load i32, i32* %1
%201 = icmp eq i32 %200, 2
br i1 %201, label %202, label %206
202: ; preds = %199
%203 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.13, i64 0, i64 0))
%204 = load i32, i32* %3
%205 = add nsw i32 %204, 1
store i32 %205, i32* %3
br label %210
206: ; preds = %199
%207 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.13, i64 0, i64 0))
%208 = load i32, i32* %4
%209 = add nsw i32 %208, 1
store i32 %209, i32* %4
br label %210
210: ; preds = %206, %202
br label %211
211: ; preds = %210
%212 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%213 = getelementptr inbounds [1 x i64], [1 x i64]* %5, i64 0, i64 0
%214 = call i32 @namegen(i8* %212, i32 256, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.14, i64 0, i64 0), i64* %213)
store i32 %214, i32* %1
br label %215
215: ; preds = %211
%216 = load i32, i32* %1
%217 = icmp eq i32 %216, 2
br i1 %217, label %218, label %222
218: ; preds = %215
%219 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.15, i64 0, i64 0))
%220 = load i32, i32* %3
%221 = add nsw i32 %220, 1
store i32 %221, i32* %3
br label %226
222: ; preds = %215
%223 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.15, i64 0, i64 0))
%224 = load i32, i32* %4
%225 = add nsw i32 %224, 1
store i32 %225, i32* %4
br label %226
226: ; preds = %222, %218
br label %227
227: ; preds = %226
%228 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%229 = getelementptr inbounds [1 x i64], [1 x i64]* %5, i64 0, i64 0
%230 = call i32 @namegen(i8* %228, i32 256, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.16, i64 0, i64 0), i64* %229)
store i32 %230, i32* %1
br label %231
231: ; preds = %227
%232 = load i32, i32* %1
%233 = icmp eq i32 %232, 2
br i1 %233, label %234, label %238
234: ; preds = %231
%235 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.17, i64 0, i64 0))
%236 = load i32, i32* %3
%237 = add nsw i32 %236, 1
store i32 %237, i32* %3
br label %242
238: ; preds = %231
%239 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.17, i64 0, i64 0))
%240 = load i32, i32* %4
%241 = add nsw i32 %240, 1
store i32 %241, i32* %4
br label %242
242: ; preds = %238, %234
br label %243
243: ; preds = %242
%244 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%245 = getelementptr inbounds [1 x i64], [1 x i64]* %5, i64 0, i64 0
%246 = call i32 @namegen(i8* %244, i32 256, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.18, i64 0, i64 0), i64* %245)
store i32 %246, i32* %1
br label %247
247: ; preds = %243
%248 = load i32, i32* %1
%249 = icmp eq i32 %248, 2
br i1 %249, label %250, label %254
250: ; preds = %247
%251 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.19, i64 0, i64 0))
%252 = load i32, i32* %3
%253 = add nsw i32 %252, 1
store i32 %253, i32* %3
br label %258
254: ; preds = %247
%255 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.19, i64 0, i64 0))
%256 = load i32, i32* %4
%257 = add nsw i32 %256, 1
store i32 %257, i32* %4
br label %258
258: ; preds = %254, %250
br label %259
259: ; preds = %258
store i8* getelementptr inbounds ([44 x i8], [44 x i8]* @.str.20, i64 0, i64 0), i8** %14
%260 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%261 = call i32 @memset(i8* %260, i32 90, i32 256)
%262 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%263 = load i8*, i8** %14
%264 = getelementptr inbounds [1 x i64], [1 x i64]* %5, i64 0, i64 0
%265 = call i32 @namegen(i8* %262, i32 256, i8* %263, i64* %264)
store i32 %265, i32* %1
br label %266
266: ; preds = %259
%267 = load i32, i32* %1
%268 = icmp eq i32 %267, 0
br i1 %268, label %269, label %277
269: ; preds = %266
%270 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%271 = call i32 @strcmp(i8* %270, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.21, i64 0, i64 0))
%272 = icmp ne i32 %271, 0
br i1 %272, label %277, label %273
273: ; preds = %269
%274 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.22, i64 0, i64 0))
%275 = load i32, i32* %3
%276 = add nsw i32 %275, 1
store i32 %276, i32* %3
br label %281
277: ; preds = %269, %266
%278 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.22, i64 0, i64 0))
%279 = load i32, i32* %4
%280 = add nsw i32 %279, 1
store i32 %280, i32* %4
br label %281
281: ; preds = %277, %273
br label %282
282: ; preds = %281
%283 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%284 = call i32 @memset(i8* %283, i32 90, i32 256)
%285 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%286 = getelementptr inbounds [1 x i64], [1 x i64]* %5, i64 0, i64 0
%287 = call i32 @namegen(i8* %285, i32 4, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.23, i64 0, i64 0), i64* %286)
store i32 %287, i32* %1
br label %288
288: ; preds = %282
%289 = load i32, i32* %1
%290 = icmp eq i32 %289, 1
br i1 %290, label %291, label %304
291: ; preds = %288
%292 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%293 = call i32 @strcmp(i8* %292, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.24, i64 0, i64 0))
%294 = icmp ne i32 %293, 0
br i1 %294, label %304, label %295
295: ; preds = %291
%296 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 4
%297 = load i8, i8* %296
%298 = sext i8 %297 to i32
%299 = icmp eq i32 %298, 90
br i1 %299, label %300, label %304
300: ; preds = %295
%301 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.25, i64 0, i64 0))
%302 = load i32, i32* %3
%303 = add nsw i32 %302, 1
store i32 %303, i32* %3
br label %308
304: ; preds = %295, %291, %288
%305 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.25, i64 0, i64 0))
%306 = load i32, i32* %4
%307 = add nsw i32 %306, 1
store i32 %307, i32* %4
br label %308
308: ; preds = %304, %300
br label %309
309: ; preds = %308
%310 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%311 = call i32 @memset(i8* %310, i32 90, i32 256)
%312 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%313 = getelementptr inbounds [1 x i64], [1 x i64]* %5, i64 0, i64 0
%314 = call i32 @namegen(i8* %312, i32 2, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.26, i64 0, i64 0), i64* %313)
store i32 %314, i32* %1
br label %315
315: ; preds = %309
%316 = load i32, i32* %1
%317 = icmp eq i32 %316, 1
br i1 %317, label %318, label %336
318: ; preds = %315
%319 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%320 = load i8, i8* %319
%321 = sext i8 %320 to i32
%322 = icmp ne i32 %321, 0
br i1 %322, label %323, label %336
323: ; preds = %318
%324 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 1
%325 = load i8, i8* %324
%326 = icmp ne i8 %325, 0
br i1 %326, label %336, label %327
327: ; preds = %323
%328 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 2
%329 = load i8, i8* %328
%330 = sext i8 %329 to i32
%331 = icmp eq i32 %330, 90
br i1 %331, label %332, label %336
332: ; preds = %327
%333 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.27, i64 0, i64 0))
%334 = load i32, i32* %3
%335 = add nsw i32 %334, 1
store i32 %335, i32* %3
br label %340
336: ; preds = %327, %323, %318, %315
%337 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.27, i64 0, i64 0))
%338 = load i32, i32* %4
%339 = add nsw i32 %338, 1
store i32 %339, i32* %4
br label %340
340: ; preds = %336, %332
br label %341
341: ; preds = %340
%342 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%343 = getelementptr inbounds [1 x i64], [1 x i64]* %5, i64 0, i64 0
%344 = call i32 @namegen(i8* %342, i32 256, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.28, i64 0, i64 0), i64* %343)
store i32 %344, i32* %1
br label %345
345: ; preds = %341
%346 = load i32, i32* %1
%347 = icmp eq i32 %346, 0
br i1 %347, label %348, label %356
348: ; preds = %345
%349 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%350 = call i32 @strcmp(i8* %349, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.29, i64 0, i64 0))
%351 = icmp ne i32 %350, 0
br i1 %351, label %356, label %352
352: ; preds = %348
%353 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.30, i64 0, i64 0))
%354 = load i32, i32* %3
%355 = add nsw i32 %354, 1
store i32 %355, i32* %3
br label %360
356: ; preds = %348, %345
%357 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.30, i64 0, i64 0))
%358 = load i32, i32* %4
%359 = add nsw i32 %358, 1
store i32 %359, i32* %4
br label %360
360: ; preds = %356, %352
br label %361
361: ; preds = %360
%362 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%363 = getelementptr inbounds [1 x i64], [1 x i64]* %5, i64 0, i64 0
%364 = call i32 @namegen(i8* %362, i32 256, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.31, i64 0, i64 0), i64* %363)
store i32 %364, i32* %1
br label %365
365: ; preds = %361
%366 = load i32, i32* %1
%367 = icmp eq i32 %366, 0
br i1 %367, label %368, label %376
368: ; preds = %365
%369 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%370 = call i32 @strcmp(i8* %369, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.29, i64 0, i64 0))
%371 = icmp ne i32 %370, 0
br i1 %371, label %376, label %372
372: ; preds = %368
%373 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.32, i64 0, i64 0))
%374 = load i32, i32* %3
%375 = add nsw i32 %374, 1
store i32 %375, i32* %3
br label %380
376: ; preds = %368, %365
%377 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.32, i64 0, i64 0))
%378 = load i32, i32* %4
%379 = add nsw i32 %378, 1
store i32 %379, i32* %4
br label %380
380: ; preds = %376, %372
br label %381
381: ; preds = %380
%382 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%383 = getelementptr inbounds [1 x i64], [1 x i64]* %5, i64 0, i64 0
%384 = call i32 @namegen(i8* %382, i32 256, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.33, i64 0, i64 0), i64* %383)
store i32 %384, i32* %1
br label %385
385: ; preds = %381
%386 = load i32, i32* %1
%387 = icmp eq i32 %386, 0
br i1 %387, label %388, label %396
388: ; preds = %385
%389 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%390 = call i32 @strcmp(i8* %389, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.34, i64 0, i64 0))
%391 = icmp ne i32 %390, 0
br i1 %391, label %396, label %392
392: ; preds = %388
%393 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.35, i64 0, i64 0))
%394 = load i32, i32* %3
%395 = add nsw i32 %394, 1
store i32 %395, i32* %3
br label %400
396: ; preds = %388, %385
%397 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.35, i64 0, i64 0))
%398 = load i32, i32* %4
%399 = add nsw i32 %398, 1
store i32 %399, i32* %4
br label %400
400: ; preds = %396, %392
br label %401
401: ; preds = %400
%402 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%403 = call i32 @memset(i8* %402, i32 90, i32 256)
%404 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%405 = getelementptr inbounds [1 x i64], [1 x i64]* %5, i64 0, i64 0
%406 = call i32 @namegen(i8* %404, i32 256, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.36, i64 0, i64 0), i64* %405)
store i32 %406, i32* %1
br label %407
407: ; preds = %401
%408 = load i32, i32* %1
%409 = icmp eq i32 %408, 0
br i1 %409, label %410, label %423
410: ; preds = %407
%411 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 0
%412 = load i8, i8* %411
%413 = icmp ne i8 %412, 0
br i1 %413, label %423, label %414
414: ; preds = %410
%415 = getelementptr inbounds [256 x i8], [256 x i8]* %2, i64 0, i64 1
%416 = load i8, i8* %415
%417 = sext i8 %416 to i32
%418 = icmp eq i32 %417, 90
br i1 %418, label %419, label %423
419: ; preds = %414
%420 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.37, i64 0, i64 0))
%421 = load i32, i32* %3
%422 = add nsw i32 %421, 1
store i32 %422, i32* %3
br label %427
423: ; preds = %414, %410, %407
%424 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.37, i64 0, i64 0))
%425 = load i32, i32* %4
%426 = add nsw i32 %425, 1
store i32 %426, i32* %4
br label %427
427: ; preds = %423, %419
br label %428
428: ; preds = %427
%429 = load i32, i32* %4
%430 = icmp ne i32 %429, 0
br i1 %430, label %431, label %434
431: ; preds = %428
%432 = load i32, i32* @EXIT_FAILURE
%433 = call i32 @exit(i32 %432)
unreachable
434: ; preds = %428
%435 = load i32, i32* %3
%436 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([21 x i8], [21 x i8]* @.str.38, i64 0, i64 0), i32 %435)
%437 = load i32, i32* @EXIT_SUCCESS
%438 = call i32 @exit(i32 %437)
unreachable
}

LLVM IR (-O2):
@.str = [6 x i8] c"0|1|2\00"
@.str.1 = [4 x i8] c"012\00"
@.str.2 = [20 x i8] c"\1B[32;1mPASS\1B[0m %s\0A\00"
@.str.3 = [12 x i8] c"alternation\00"
@.str.4 = [20 x i8] c"\1B[31;1mFAIL\1B[0m %s\0A\00"
@.str.5 = [5 x i8] c"(v)v\00"
@.str.6 = [7 x i8] c"aeiouy\00"
@.str.7 = [13 x i8] c"substitution\00"
@.str.8 = [3 x i8] c"a>\00"
@.str.9 = [16 x i8] c"closing bracket\00"
@.str.10 = [3 x i8] c"a)\00"
@.str.11 = [14 x i8] c"closing paren\00"
@.str.12 = [4 x i8] c"<a)\00"
@.str.13 = [15 x i8] c"mismatch paren\00"
@.str.14 = [4 x i8] c"(a>\00"
@.str.15 = [17 x i8] c"mismatch bracket\00"
@.str.16 = [3 x i8] c"<a\00"
@.str.17 = [17 x i8] c"unclosed bracket\00"
@.str.18 = [3 x i8] c"(a\00"
@.str.19 = [15 x i8] c"unclosed paren\00"
@.str.20 = [44 x i8] c"(((((<(((((((((((((((a)))))))))))))))>)))))\00"
@.str.22 = [13 x i8] c"deep nesting\00"
@.str.23 = [10 x i8] c"(abcdefg)\00"
@.str.25 = [13 x i8] c"truncation 1\00"
@.str.26 = [2 x i8] c"i\00"
@.str.27 = [13 x i8] c"truncation 2\00"
@.str.28 = [7 x i8] c"!(foo)\00"
@.str.30 = [17 x i8] c"capitalization 1\00"
@.str.31 = [7 x i8] c"(!foo)\00"
@.str.32 = [17 x i8] c"capitalization 2\00"
@.str.33 = [7 x i8] c"(f!oo)\00"
@.str.35 = [17 x i8] c"capitalization 3\00"
@.str.36 = [1 x i8] zeroinitializer
@.str.37 = [6 x i8] c"empty\00"
@EXIT_FAILURE = global i32 0
@.str.38 = [21 x i8] c"All %d tests passed\0A\00"
@EXIT_SUCCESS = global i32 0
define void @tests() {
%1 = alloca [256 x i8]
%2 = alloca [1 x i64]
%3 = alloca [3 x i32]
%4 = alloca [6 x i32]
%5 = getelementptr inbounds [256 x i8], [256 x i8]* %1, i64 0, i64 0
%6 = bitcast [1 x i64]* %2 to i8*
%7 = getelementptr inbounds [1 x i64], [1 x i64]* %2, i64 0, i64 0
store i64 3526097723, i64* %7
%8 = bitcast [3 x i32]* %3 to i8*
%9 = getelementptr inbounds [256 x i8], [256 x i8]* %1, i64 0, i64 1
br label %10
10: ; preds = %0, %31
%11 = phi i32 [ 0, %0 ], [ %32, %31 ]
%12 = phi i32 [ 0, %0 ], [ %33, %31 ]
%13 = call i32 @memset(i8* %5, i32 90, i32 256)
%14 = call i32 @namegen(i8* %5, i32 256, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str, i64 0, i64 0), i64* %7)
%15 = icmp ne i32 %14, 0
%16 = load i8, i8* %9
%17 = icmp ne i8 %16, 0
%18 = select i1 %15, i1 true, i1 %17
br i1 %18, label %23, label %19
19: ; preds = %10
%20 = load i8, i8* %5
%21 = call i8* @strchr(i8* dereferenceable(4) getelementptr inbounds ([4 x i8], [4 x i8]* @.str.1, i64 0, i64 0), i8 signext %20)
%22 = icmp eq i8* %21, null
br i1 %22, label %23, label %25
23: ; preds = %19, %10
%24 = add nsw i32 %11, 1
br label %31
25: ; preds = %19
%26 = sext i8 %20 to i64
%27 = add nsw i64 %26, -48
%28 = getelementptr inbounds [3 x i32], [3 x i32]* %3, i64 0, i64 %27
%29 = load i32, i32* %28
%30 = add nsw i32 %29, 1
store i32 %30, i32* %28
br label %31
31: ; preds = %23, %25
%32 = phi i32 [ %24, %23 ], [ %11, %25 ]
%33 = add nuw nsw i32 %12, 1
%34 = icmp eq i32 %33, 100
br i1 %34, label %35, label %10
35: ; preds = %31
%36 = icmp eq i32 %32, 0
%37 = getelementptr inbounds [3 x i32], [3 x i32]* %3, i64 0, i64 0
%38 = load i32, i32* %37
%39 = icmp ne i32 %38, 0
%40 = select i1 %36, i1 %39, i1 false
%41 = getelementptr inbounds [3 x i32], [3 x i32]* %3, i64 0, i64 1
%42 = load i32, i32* %41
%43 = icmp ne i32 %42, 0
%44 = select i1 %40, i1 %43, i1 false
%45 = getelementptr inbounds [3 x i32], [3 x i32]* %3, i64 0, i64 2
%46 = load i32, i32* %45
%47 = icmp ne i32 %46, 0
%48 = select i1 %44, i1 %47, i1 false
%49 = select i1 %48, i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0)
%50 = xor i1 %48, true
%51 = zext i1 %50 to i32
%52 = zext i1 %48 to i32
%53 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) %49, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.3, i64 0, i64 0))
%54 = bitcast [6 x i32]* %4 to i8*
%55 = getelementptr inbounds [256 x i8], [256 x i8]* %1, i64 0, i64 2
br label %56
56: ; preds = %35, %84
%57 = phi i32 [ 0, %35 ], [ %85, %84 ]
%58 = phi i32 [ 0, %35 ], [ %86, %84 ]
%59 = call i32 @memset(i8* %5, i32 90, i32 256)
%60 = call i32 @namegen(i8* %5, i32 256, i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.5, i64 0, i64 0), i64* %7)
%61 = icmp ne i32 %60, 0
%62 = load i8, i8* %5
%63 = icmp ne i8 %62, 118
%64 = select i1 %61, i1 true, i1 %63
%65 = load i8, i8* %9
%66 = icmp eq i8 %65, 0
%67 = select i1 %64, i1 true, i1 %66
%68 = load i8, i8* %55
%69 = icmp ne i8 %68, 0
%70 = select i1 %67, i1 true, i1 %69
br i1 %70, label %71, label %73
71: ; preds = %56
%72 = add nsw i32 %57, 1
br label %84
73: ; preds = %56
%74 = call i8* @strchr(i8* dereferenceable(7) getelementptr inbounds ([7 x i8], [7 x i8]* @.str.6, i64 0, i64 0), i8 signext %65)
%75 = icmp eq i8* %74, null
br i1 %75, label %76, label %78
76: ; preds = %73
%77 = add nsw i32 %57, 1
br label %84
78: ; preds = %73
%79 = ptrtoint i8* %74 to i64
%80 = sub i64 %79, ptrtoint ([7 x i8]* @.str.6 to i64)
%81 = getelementptr inbounds [6 x i32], [6 x i32]* %4, i64 0, i64 %80
%82 = load i32, i32* %81
%83 = add nsw i32 %82, 1
store i32 %83, i32* %81
br label %84
84: ; preds = %76, %78, %71
%85 = phi i32 [ %72, %71 ], [ %57, %78 ], [ %77, %76 ]
%86 = add nuw nsw i32 %58, 1
%87 = icmp eq i32 %86, 100
br i1 %87, label %88, label %56
88: ; preds = %84
%89 = bitcast [6 x i32]* %4 to <4 x i32>*
%90 = load <4 x i32>, <4 x i32>* %89
%91 = icmp eq <4 x i32> %90, zeroinitializer
%92 = getelementptr inbounds [6 x i32], [6 x i32]* %4, i64 0, i64 4
%93 = load i32, i32* %92
%94 = icmp eq i32 %93, 0
%95 = zext i1 %94 to i32
%96 = bitcast <4 x i1> %91 to i4
%97 = call i4 @llvm.ctpop.i4(i4 %96)
%98 = zext i4 %97 to i32
%99 = add nuw nsw i32 %98, %95
%100 = add nsw i32 %99, %85
%101 = getelementptr inbounds [6 x i32], [6 x i32]* %4, i64 0, i64 5
%102 = load i32, i32* %101
%103 = icmp eq i32 %102, 0
%104 = sext i1 %103 to i32
%105 = icmp eq i32 %100, %104
br i1 %105, label %106, label %109
106: ; preds = %88
%107 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.7, i64 0, i64 0))
%108 = select i1 %48, i32 2, i32 1
br label %112
109: ; preds = %88
%110 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.7, i64 0, i64 0))
%111 = select i1 %48, i32 1, i32 2
br label %112
112: ; preds = %109, %106
%113 = phi i32 [ %111, %109 ], [ %51, %106 ]
%114 = phi i32 [ %52, %109 ], [ %108, %106 ]
%115 = call i32 @namegen(i8* %5, i32 256, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.8, i64 0, i64 0), i64* %7)
%116 = icmp eq i32 %115, 2
br i1 %116, label %117, label %120
117: ; preds = %112
%118 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.9, i64 0, i64 0))
%119 = add nuw nsw i32 %114, 1
br label %123
120: ; preds = %112
%121 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str.9, i64 0, i64 0))
%122 = add nuw nsw i32 %113, 1
br label %123
123: ; preds = %120, %117
%124 = phi i32 [ %113, %117 ], [ %122, %120 ]
%125 = phi i32 [ %119, %117 ], [ %114, %120 ]
%126 = call i32 @namegen(i8* %5, i32 256, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.10, i64 0, i64 0), i64* %7)
%127 = icmp eq i32 %126, 2
br i1 %127, label %128, label %131
128: ; preds = %123
%129 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.11, i64 0, i64 0))
%130 = add nsw i32 %125, 1
br label %134
131: ; preds = %123
%132 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([14 x i8], [14 x i8]* @.str.11, i64 0, i64 0))
%133 = add nsw i32 %124, 1
br label %134
134: ; preds = %131, %128
%135 = phi i32 [ %124, %128 ], [ %133, %131 ]
%136 = phi i32 [ %130, %128 ], [ %125, %131 ]
%137 = call i32 @namegen(i8* %5, i32 256, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.12, i64 0, i64 0), i64* %7)
%138 = icmp eq i32 %137, 2
br i1 %138, label %139, label %142
139: ; preds = %134
%140 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.13, i64 0, i64 0))
%141 = add nsw i32 %136, 1
br label %145
142: ; preds = %134
%143 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.13, i64 0, i64 0))
%144 = add nsw i32 %135, 1
br label %145
145: ; preds = %142, %139
%146 = phi i32 [ %135, %139 ], [ %144, %142 ]
%147 = phi i32 [ %141, %139 ], [ %136, %142 ]
%148 = call i32 @namegen(i8* %5, i32 256, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.14, i64 0, i64 0), i64* %7)
%149 = icmp eq i32 %148, 2
br i1 %149, label %150, label %153
150: ; preds = %145
%151 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.15, i64 0, i64 0))
%152 = add nsw i32 %147, 1
br label %156
153: ; preds = %145
%154 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.15, i64 0, i64 0))
%155 = add nsw i32 %146, 1
br label %156
156: ; preds = %153, %150
%157 = phi i32 [ %146, %150 ], [ %155, %153 ]
%158 = phi i32 [ %152, %150 ], [ %147, %153 ]
%159 = call i32 @namegen(i8* %5, i32 256, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.16, i64 0, i64 0), i64* %7)
%160 = icmp eq i32 %159, 2
br i1 %160, label %161, label %164
161: ; preds = %156
%162 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.17, i64 0, i64 0))
%163 = add nsw i32 %158, 1
br label %167
164: ; preds = %156
%165 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.17, i64 0, i64 0))
%166 = add nsw i32 %157, 1
br label %167
167: ; preds = %164, %161
%168 = phi i32 [ %157, %161 ], [ %166, %164 ]
%169 = phi i32 [ %163, %161 ], [ %158, %164 ]
%170 = call i32 @namegen(i8* %5, i32 256, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.18, i64 0, i64 0), i64* %7)
%171 = icmp eq i32 %170, 2
br i1 %171, label %172, label %175
172: ; preds = %167
%173 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.19, i64 0, i64 0))
%174 = add nsw i32 %169, 1
br label %178
175: ; preds = %167
%176 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([15 x i8], [15 x i8]* @.str.19, i64 0, i64 0))
%177 = add nsw i32 %168, 1
br label %178
178: ; preds = %175, %172
%179 = phi i32 [ %168, %172 ], [ %177, %175 ]
%180 = phi i32 [ %174, %172 ], [ %169, %175 ]
%181 = call i32 @memset(i8* %5, i32 90, i32 256)
%182 = call i32 @namegen(i8* %5, i32 256, i8* getelementptr inbounds ([44 x i8], [44 x i8]* @.str.20, i64 0, i64 0), i64* %7)
%183 = icmp eq i32 %182, 0
%184 = bitcast [256 x i8]* %1 to i16*
%185 = load i16, i16* %184
%186 = icmp eq i16 %185, 97
%187 = select i1 %183, i1 %186, i1 false
br i1 %187, label %188, label %191
188: ; preds = %178
%189 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.22, i64 0, i64 0))
%190 = add nsw i32 %180, 1
br label %194
191: ; preds = %178
%192 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.22, i64 0, i64 0))
%193 = add nsw i32 %179, 1
br label %194
194: ; preds = %191, %188
%195 = phi i32 [ %193, %191 ], [ %179, %188 ]
%196 = phi i32 [ %180, %191 ], [ %190, %188 ]
%197 = call i32 @memset(i8* %5, i32 90, i32 256)
%198 = call i32 @namegen(i8* %5, i32 4, i8* getelementptr inbounds ([10 x i8], [10 x i8]* @.str.23, i64 0, i64 0), i64* %7)
%199 = icmp eq i32 %198, 1
br i1 %199, label %200, label %211
200: ; preds = %194
%201 = bitcast [256 x i8]* %1 to i32*
%202 = load i32, i32* %201
%203 = icmp eq i32 %202, 6513249
%204 = getelementptr inbounds [256 x i8], [256 x i8]* %1, i64 0, i64 4
%205 = load i8, i8* %204
%206 = icmp eq i8 %205, 90
%207 = select i1 %203, i1 %206, i1 false
br i1 %207, label %208, label %211
208: ; preds = %200
%209 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.25, i64 0, i64 0))
%210 = add nsw i32 %196, 1
br label %214
211: ; preds = %200, %194
%212 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.25, i64 0, i64 0))
%213 = add nsw i32 %195, 1
br label %214
214: ; preds = %211, %208
%215 = phi i32 [ %195, %208 ], [ %213, %211 ]
%216 = phi i32 [ %210, %208 ], [ %196, %211 ]
%217 = call i32 @memset(i8* %5, i32 90, i32 256)
%218 = call i32 @namegen(i8* %5, i32 2, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.26, i64 0, i64 0), i64* %7)
%219 = icmp eq i32 %218, 1
%220 = load i8, i8* %5
%221 = icmp ne i8 %220, 0
%222 = select i1 %219, i1 %221, i1 false
%223 = load i8, i8* %9
%224 = icmp eq i8 %223, 0
%225 = select i1 %222, i1 %224, i1 false
%226 = load i8, i8* %55
%227 = icmp eq i8 %226, 90
%228 = select i1 %225, i1 %227, i1 false
br i1 %228, label %229, label %232
229: ; preds = %214
%230 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.27, i64 0, i64 0))
%231 = add nsw i32 %216, 1
br label %235
232: ; preds = %214
%233 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([13 x i8], [13 x i8]* @.str.27, i64 0, i64 0))
%234 = add nsw i32 %215, 1
br label %235
235: ; preds = %232, %229
%236 = phi i32 [ %215, %229 ], [ %234, %232 ]
%237 = phi i32 [ %231, %229 ], [ %216, %232 ]
%238 = call i32 @namegen(i8* %5, i32 256, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.28, i64 0, i64 0), i64* %7)
%239 = icmp eq i32 %238, 0
%240 = bitcast [256 x i8]* %1 to i32*
%241 = load i32, i32* %240
%242 = icmp eq i32 %241, 7302982
%243 = select i1 %239, i1 %242, i1 false
br i1 %243, label %244, label %247
244: ; preds = %235
%245 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.30, i64 0, i64 0))
%246 = add nsw i32 %237, 1
br label %250
247: ; preds = %235
%248 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.30, i64 0, i64 0))
%249 = add nsw i32 %236, 1
br label %250
250: ; preds = %247, %244
%251 = phi i32 [ %249, %247 ], [ %236, %244 ]
%252 = phi i32 [ %237, %247 ], [ %246, %244 ]
%253 = call i32 @namegen(i8* %5, i32 256, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.31, i64 0, i64 0), i64* %7)
%254 = icmp eq i32 %253, 0
%255 = load i32, i32* %240
%256 = icmp eq i32 %255, 7302982
%257 = select i1 %254, i1 %256, i1 false
br i1 %257, label %258, label %261
258: ; preds = %250
%259 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.32, i64 0, i64 0))
%260 = add nsw i32 %252, 1
br label %264
261: ; preds = %250
%262 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.32, i64 0, i64 0))
%263 = add nsw i32 %251, 1
br label %264
264: ; preds = %261, %258
%265 = phi i32 [ %263, %261 ], [ %251, %258 ]
%266 = phi i32 [ %252, %261 ], [ %260, %258 ]
%267 = call i32 @namegen(i8* %5, i32 256, i8* getelementptr inbounds ([7 x i8], [7 x i8]* @.str.33, i64 0, i64 0), i64* %7)
%268 = icmp eq i32 %267, 0
%269 = load i32, i32* %240
%270 = icmp eq i32 %269, 7294822
%271 = select i1 %268, i1 %270, i1 false
br i1 %271, label %272, label %275
272: ; preds = %264
%273 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.35, i64 0, i64 0))
%274 = add nsw i32 %266, 1
br label %278
275: ; preds = %264
%276 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([17 x i8], [17 x i8]* @.str.35, i64 0, i64 0))
%277 = add nsw i32 %265, 1
br label %278
278: ; preds = %275, %272
%279 = phi i32 [ %277, %275 ], [ %265, %272 ]
%280 = phi i32 [ %266, %275 ], [ %274, %272 ]
%281 = call i32 @memset(i8* %5, i32 90, i32 256)
%282 = call i32 @namegen(i8* %5, i32 256, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.36, i64 0, i64 0), i64* %7)
%283 = icmp eq i32 %282, 0
%284 = load i8, i8* %5
%285 = icmp eq i8 %284, 0
%286 = select i1 %283, i1 %285, i1 false
%287 = load i8, i8* %9
%288 = icmp eq i8 %287, 90
%289 = select i1 %286, i1 %288, i1 false
br i1 %289, label %290, label %293
290: ; preds = %278
%291 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.37, i64 0, i64 0))
%292 = add nsw i32 %280, 1
br label %296
293: ; preds = %278
%294 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([20 x i8], [20 x i8]* @.str.4, i64 0, i64 0), i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.37, i64 0, i64 0))
%295 = add nsw i32 %279, 1
br label %296
296: ; preds = %293, %290
%297 = phi i32 [ %279, %290 ], [ %295, %293 ]
%298 = phi i32 [ %292, %290 ], [ %280, %293 ]
%299 = icmp eq i32 %297, 0
br i1 %299, label %303, label %300
300: ; preds = %296
%301 = load i32, i32* @EXIT_FAILURE
%302 = call i32 @exit(i32 %301)
unreachable
303: ; preds = %296
%304 = call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([21 x i8], [21 x i8]* @.str.38, i64 0, i64 0), i32 %298)
%305 = load i32, i32* @EXIT_SUCCESS
%306 = call i32 @exit(i32 %305)
unreachable
}