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

/* Forward declarations */

/* Type definitions */

/* Variables and functions */
int /*<<< orphan*/ assert(int /*<<< orphan*/);
unsigned char buildStates(int secModel, unsigned char v1, unsigned char v2) {
  unsigned char new = 0;
  switch (secModel) {
  case 3:
    new = v1;
    new = new << 4;
    new = new | v2;
    break;
  case 4: {
    int meaningDNA[256], i;
    const unsigned char allowedStates[6][2] = {
        {'A', 'T'}, {'C', 'G'}, {'G', 'C'}, {'G', 'T'}, {'T', 'A'}, {'T', 'G'}};
    const unsigned char finalBinaryStates[6] = {1, 2, 4, 8, 16, 32};
    unsigned char intermediateBinaryStates[6];
    int length = 6;
    for (i = 0; i < 256; i++)
      meaningDNA[i] = -1;
    meaningDNA['A'] = 1;
    meaningDNA['B'] = 14;
    meaningDNA['C'] = 2;
    meaningDNA['D'] = 13;
    meaningDNA['G'] = 4;
    meaningDNA['H'] = 11;
    meaningDNA['K'] = 12;
    meaningDNA['M'] = 3;
    meaningDNA['N'] = 15;
    meaningDNA['O'] = 15;
    meaningDNA['R'] = 5;
    meaningDNA['S'] = 6;
    meaningDNA['T'] = 8;
    meaningDNA['U'] = 8;
    meaningDNA['V'] = 7;
    meaningDNA['W'] = 9;
    meaningDNA['X'] = 15;
    meaningDNA['Y'] = 10;
    meaningDNA['-'] = 15;
    meaningDNA['?'] = 15;
    for (i = 0; i < length; i++) {
      unsigned char n1 = meaningDNA[allowedStates[i][0]];
      unsigned char n2 = meaningDNA[allowedStates[i][1]];
      new = n1;
      new = new << 4;
      new = new | n2;
      intermediateBinaryStates[i] = new;
    }
    new = v1;
    new = new << 4;
    new = new | v2;
    for (i = 0; i < length; i++) {
      if (new == intermediateBinaryStates[i])
        break;
    }
    if (i < length)
      new = finalBinaryStates[i];
    else {
      new = 0;
      for (i = 0; i < length; i++) {
        if (v1 & meaningDNA[allowedStates[i][0]]) {
          new |= finalBinaryStates[i];
        }
        if (v2 & meaningDNA[allowedStates[i][1]]) {
          new |= finalBinaryStates[i];
        }
      }
    }
  } break;
  case 5: {
    int meaningDNA[256], i;
    const unsigned char allowedStates[6][2] = {
        {'A', 'T'}, {'C', 'G'}, {'G', 'C'}, {'G', 'T'}, {'T', 'A'}, {'T', 'G'}};
    const unsigned char finalBinaryStates[7] = {1, 2, 4, 8, 16, 32, 64};
    unsigned char intermediateBinaryStates[7];
    for (i = 0; i < 256; i++)
      meaningDNA[i] = -1;
    meaningDNA['A'] = 1;
    meaningDNA['B'] = 14;
    meaningDNA['C'] = 2;
    meaningDNA['D'] = 13;
    meaningDNA['G'] = 4;
    meaningDNA['H'] = 11;
    meaningDNA['K'] = 12;
    meaningDNA['M'] = 3;
    meaningDNA['N'] = 15;
    meaningDNA['O'] = 15;
    meaningDNA['R'] = 5;
    meaningDNA['S'] = 6;
    meaningDNA['T'] = 8;
    meaningDNA['U'] = 8;
    meaningDNA['V'] = 7;
    meaningDNA['W'] = 9;
    meaningDNA['X'] = 15;
    meaningDNA['Y'] = 10;
    meaningDNA['-'] = 15;
    meaningDNA['?'] = 15;
    for (i = 0; i < 6; i++) {
      unsigned char n1 = meaningDNA[allowedStates[i][0]];
      unsigned char n2 = meaningDNA[allowedStates[i][1]];
      new = n1;
      new = new << 4;
      new = new | n2;
      intermediateBinaryStates[i] = new;
    }
    new = v1;
    new = new << 4;
    new = new | v2;
    for (i = 0; i < 6; i++) {
      if (new == intermediateBinaryStates[i])
        break;
    }
    if (i < 6)
      new = finalBinaryStates[i];
    else {
      for (i = 0; i < 6; i++)
        if ((v1 & meaningDNA[allowedStates[i][0]]) &&
            (v2 & meaningDNA[allowedStates[i][1]]))
          break;
      if (i < 6) {
        new = 0;
        for (i = 0; i < 6; i++) {
          if ((v1 & meaningDNA[allowedStates[i][0]]) &&
              (v2 & meaningDNA[allowedStates[i][1]])) {
            new |= finalBinaryStates[i];
          } else
            new |= finalBinaryStates[6];
        }
      } else
        new = finalBinaryStates[6];
    }
  } break;
  default:
    assert(0);
  }
  return new;
}


x86 assembly (clang, -O0):
<buildStates>:
push   %rbp
mov    %rsp,%rbp
sub    $0x870,%rsp
mov    %dl,%al
mov    %sil,%cl
mov    %edi,-0x4(%rbp)
mov    %cl,-0x5(%rbp)
mov    %al,-0x6(%rbp)
movb   $0x0,-0x7(%rbp)
mov    -0x4(%rbp),%eax
mov    %eax,-0x864(%rbp)
sub    $0x3,%eax
je     116c <buildStates+0x5c>
jmp    1144 <buildStates+0x34>
mov    -0x864(%rbp),%eax
sub    $0x4,%eax
je     118e <buildStates+0x7e>
jmp    1158 <buildStates+0x48>
mov    -0x864(%rbp),%eax
sub    $0x5,%eax
je     14c3 <buildStates+0x3b3>
jmp    1879 <buildStates+0x769>
mov    -0x5(%rbp),%al
mov    %al,-0x7(%rbp)
movzbl -0x7(%rbp),%eax
shl    $0x4,%eax
mov    %al,-0x7(%rbp)
movzbl -0x7(%rbp),%eax
movzbl -0x6(%rbp),%ecx
or     %ecx,%eax
mov    %al,-0x7(%rbp)
jmp    1880 <buildStates+0x770>
mov    0xe6b(%rip),%rax
mov    %rax,-0x420(%rbp)
mov    0xe66(%rip),%eax
mov    %eax,-0x418(%rbp)
mov    0xe5e(%rip),%eax
mov    %eax,-0x426(%rbp)
mov    0xe55(%rip),%ax
mov    %ax,-0x422(%rbp)
movl   $0x6,-0x430(%rbp)
movl   $0x0,-0x414(%rbp)
cmpl   $0x100,-0x414(%rbp)
jge    120c <buildStates+0xfc>
movslq -0x414(%rbp),%rax
movl   $0xffffffff,-0x410(%rbp,%rax,4)
ff ff ff ff
mov    -0x414(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x414(%rbp)
jmp    11d6 <buildStates+0xc6>
movl   $0x1,-0x30c(%rbp)
movl   $0xe,-0x308(%rbp)
movl   $0x2,-0x304(%rbp)
movl   $0xd,-0x300(%rbp)
movl   $0x4,-0x2f4(%rbp)
movl   $0xb,-0x2f0(%rbp)
movl   $0xc,-0x2e4(%rbp)
movl   $0x3,-0x2dc(%rbp)
movl   $0xf,-0x2d8(%rbp)
movl   $0xf,-0x2d4(%rbp)
movl   $0x5,-0x2c8(%rbp)
movl   $0x6,-0x2c4(%rbp)
movl   $0x8,-0x2c0(%rbp)
movl   $0x8,-0x2bc(%rbp)
movl   $0x7,-0x2b8(%rbp)
movl   $0x9,-0x2b4(%rbp)
movl   $0xf,-0x2b0(%rbp)
movl   $0xa,-0x2ac(%rbp)
movl   $0xf,-0x35c(%rbp)
movl   $0xf,-0x314(%rbp)
movl   $0x0,-0x414(%rbp)
mov    -0x414(%rbp),%eax
cmp    -0x430(%rbp),%eax
jge    1370 <buildStates+0x260>
movslq -0x414(%rbp),%rax
movzbl -0x420(%rbp,%rax,2),%eax
ff
mov    -0x410(%rbp,%rax,4),%eax
mov    %al,-0x431(%rbp)
movslq -0x414(%rbp),%rax
movzbl -0x41f(%rbp,%rax,2),%eax
ff
mov    -0x410(%rbp,%rax,4),%eax
mov    %al,-0x432(%rbp)
mov    -0x431(%rbp),%al
mov    %al,-0x7(%rbp)
movzbl -0x7(%rbp),%eax
shl    $0x4,%eax
mov    %al,-0x7(%rbp)
movzbl -0x7(%rbp),%eax
movzbl -0x432(%rbp),%ecx
or     %ecx,%eax
mov    %al,-0x7(%rbp)
mov    -0x7(%rbp),%cl
movslq -0x414(%rbp),%rax
mov    %cl,-0x42c(%rbp,%rax,1)
mov    -0x414(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x414(%rbp)
jmp    12de <buildStates+0x1ce>
mov    -0x5(%rbp),%al
mov    %al,-0x7(%rbp)
movzbl -0x7(%rbp),%eax
shl    $0x4,%eax
mov    %al,-0x7(%rbp)
movzbl -0x7(%rbp),%eax
movzbl -0x6(%rbp),%ecx
or     %ecx,%eax
mov    %al,-0x7(%rbp)
movl   $0x0,-0x414(%rbp)
mov    -0x414(%rbp),%eax
cmp    -0x430(%rbp),%eax
jge    13e2 <buildStates+0x2d2>
movzbl -0x7(%rbp),%eax
movslq -0x414(%rbp),%rcx
movzbl -0x42c(%rbp,%rcx,1),%ecx
ff
cmp    %ecx,%eax
jne    13c9 <buildStates+0x2b9>
jmp    13e2 <buildStates+0x2d2>
jmp    13ce <buildStates+0x2be>
mov    -0x414(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x414(%rbp)
jmp    1397 <buildStates+0x287>
mov    -0x414(%rbp),%eax
cmp    -0x430(%rbp),%eax
jge    140a <buildStates+0x2fa>
movslq -0x414(%rbp),%rax
mov    -0x426(%rbp,%rax,1),%al
mov    %al,-0x7(%rbp)
jmp    14be <buildStates+0x3ae>
movb   $0x0,-0x7(%rbp)
movl   $0x0,-0x414(%rbp)
mov    -0x414(%rbp),%eax
cmp    -0x430(%rbp),%eax
jge    14b9 <buildStates+0x3a9>
movzbl -0x5(%rbp),%eax
movslq -0x414(%rbp),%rcx
movzbl -0x420(%rbp,%rcx,2),%ecx
ff
and    -0x410(%rbp,%rcx,4),%eax
cmp    $0x0,%eax
je     1465 <buildStates+0x355>
movslq -0x414(%rbp),%rax
movzbl -0x426(%rbp,%rax,1),%ecx
ff
movzbl -0x7(%rbp),%eax
or     %ecx,%eax
mov    %al,-0x7(%rbp)
movzbl -0x6(%rbp),%eax
movslq -0x414(%rbp),%rcx
movzbl -0x41f(%rbp,%rcx,2),%ecx
ff
and    -0x410(%rbp,%rcx,4),%eax
cmp    $0x0,%eax
je     14a0 <buildStates+0x390>
movslq -0x414(%rbp),%rax
movzbl -0x426(%rbp,%rax,1),%ecx
ff
movzbl -0x7(%rbp),%eax
or     %ecx,%eax
mov    %al,-0x7(%rbp)
jmp    14a5 <buildStates+0x395>
mov    -0x414(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x414(%rbp)
jmp    1418 <buildStates+0x308>
jmp    14be <buildStates+0x3ae>
jmp    1880 <buildStates+0x770>
mov    0xb48(%rip),%rax
mov    %rax,-0x850(%rbp)
mov    0xb43(%rip),%eax
mov    %eax,-0x848(%rbp)
mov    0xb3b(%rip),%eax
mov    %eax,-0x857(%rbp)
mov    0xb32(%rip),%ax
mov    %ax,-0x853(%rbp)
mov    0xb27(%rip),%al
mov    %al,-0x851(%rbp)
movl   $0x0,-0x844(%rbp)
cmpl   $0x100,-0x844(%rbp)
jge    1543 <buildStates+0x433>
movslq -0x844(%rbp),%rax
movl   $0xffffffff,-0x840(%rbp,%rax,4)
ff ff ff ff
mov    -0x844(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x844(%rbp)
jmp    150d <buildStates+0x3fd>
movl   $0x1,-0x73c(%rbp)
movl   $0xe,-0x738(%rbp)
movl   $0x2,-0x734(%rbp)
movl   $0xd,-0x730(%rbp)
movl   $0x4,-0x724(%rbp)
movl   $0xb,-0x720(%rbp)
movl   $0xc,-0x714(%rbp)
movl   $0x3,-0x70c(%rbp)
movl   $0xf,-0x708(%rbp)
movl   $0xf,-0x704(%rbp)
movl   $0x5,-0x6f8(%rbp)
movl   $0x6,-0x6f4(%rbp)
movl   $0x8,-0x6f0(%rbp)
movl   $0x8,-0x6ec(%rbp)
movl   $0x7,-0x6e8(%rbp)
movl   $0x9,-0x6e4(%rbp)
movl   $0xf,-0x6e0(%rbp)
movl   $0xa,-0x6dc(%rbp)
movl   $0xf,-0x78c(%rbp)
movl   $0xf,-0x744(%rbp)
movl   $0x0,-0x844(%rbp)
cmpl   $0x6,-0x844(%rbp)
jge    16a2 <buildStates+0x592>
movslq -0x844(%rbp),%rax
movzbl -0x850(%rbp,%rax,2),%eax
ff
mov    -0x840(%rbp,%rax,4),%eax
mov    %al,-0x85f(%rbp)
movslq -0x844(%rbp),%rax
movzbl -0x84f(%rbp,%rax,2),%eax
ff
mov    -0x840(%rbp,%rax,4),%eax
mov    %al,-0x860(%rbp)
mov    -0x85f(%rbp),%al
mov    %al,-0x7(%rbp)
movzbl -0x7(%rbp),%eax
shl    $0x4,%eax
mov    %al,-0x7(%rbp)
movzbl -0x7(%rbp),%eax
movzbl -0x860(%rbp),%ecx
or     %ecx,%eax
mov    %al,-0x7(%rbp)
mov    -0x7(%rbp),%cl
movslq -0x844(%rbp),%rax
mov    %cl,-0x85e(%rbp,%rax,1)
mov    -0x844(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x844(%rbp)
jmp    1615 <buildStates+0x505>
mov    -0x5(%rbp),%al
mov    %al,-0x7(%rbp)
movzbl -0x7(%rbp),%eax
shl    $0x4,%eax
mov    %al,-0x7(%rbp)
movzbl -0x7(%rbp),%eax
movzbl -0x6(%rbp),%ecx
or     %ecx,%eax
mov    %al,-0x7(%rbp)
movl   $0x0,-0x844(%rbp)
cmpl   $0x6,-0x844(%rbp)
jge    170f <buildStates+0x5ff>
movzbl -0x7(%rbp),%eax
movslq -0x844(%rbp),%rcx
movzbl -0x85e(%rbp,%rcx,1),%ecx
ff
cmp    %ecx,%eax
jne    16f6 <buildStates+0x5e6>
jmp    170f <buildStates+0x5ff>
jmp    16fb <buildStates+0x5eb>
mov    -0x844(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x844(%rbp)
jmp    16c9 <buildStates+0x5b9>
cmpl   $0x6,-0x844(%rbp)
jge    1732 <buildStates+0x622>
movslq -0x844(%rbp),%rax
mov    -0x857(%rbp,%rax,1),%al
mov    %al,-0x7(%rbp)
jmp    1874 <buildStates+0x764>
movl   $0x0,-0x844(%rbp)
cmpl   $0x6,-0x844(%rbp)
jge    17ad <buildStates+0x69d>
movzbl -0x5(%rbp),%eax
movslq -0x844(%rbp),%rcx
movzbl -0x850(%rbp,%rcx,2),%ecx
ff
and    -0x840(%rbp,%rcx,4),%eax
cmp    $0x0,%eax
je     1794 <buildStates+0x684>
movzbl -0x6(%rbp),%eax
movslq -0x844(%rbp),%rcx
movzbl -0x84f(%rbp,%rcx,2),%ecx
ff
and    -0x840(%rbp,%rcx,4),%eax
cmp    $0x0,%eax
je     1794 <buildStates+0x684>
jmp    17ad <buildStates+0x69d>
jmp    1799 <buildStates+0x689>
mov    -0x844(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x844(%rbp)
jmp    173c <buildStates+0x62c>
cmpl   $0x6,-0x844(%rbp)
jge    1866 <buildStates+0x756>
movb   $0x0,-0x7(%rbp)
movl   $0x0,-0x844(%rbp)
cmpl   $0x6,-0x844(%rbp)
jge    1861 <buildStates+0x751>
movzbl -0x5(%rbp),%eax
movslq -0x844(%rbp),%rcx
movzbl -0x850(%rbp,%rcx,2),%ecx
ff
and    -0x840(%rbp,%rcx,4),%eax
cmp    $0x0,%eax
je     1838 <buildStates+0x728>
movzbl -0x6(%rbp),%eax
movslq -0x844(%rbp),%rcx
movzbl -0x84f(%rbp,%rcx,2),%ecx
ff
and    -0x840(%rbp,%rcx,4),%eax
cmp    $0x0,%eax
je     1838 <buildStates+0x728>
movslq -0x844(%rbp),%rax
movzbl -0x857(%rbp,%rax,1),%ecx
ff
movzbl -0x7(%rbp),%eax
or     %ecx,%eax
mov    %al,-0x7(%rbp)
jmp    1848 <buildStates+0x738>
movzbl -0x851(%rbp),%ecx
movzbl -0x7(%rbp),%eax
or     %ecx,%eax
mov    %al,-0x7(%rbp)
jmp    184d <buildStates+0x73d>
mov    -0x844(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x844(%rbp)
jmp    17c8 <buildStates+0x6b8>
jmp    186f <buildStates+0x75f>
mov    -0x851(%rbp),%al
mov    %al,-0x7(%rbp)
jmp    1874 <buildStates+0x764>
jmp    1880 <buildStates+0x770>
xor    %edi,%edi
call   1030 <assert@plt>
movzbl -0x7(%rbp),%eax
add    $0x870,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<buildStates>:
push   %rbx
cmp    $0x5,%edi
je     112e <buildStates+0x1e>
cmp    $0x4,%edi
je     114d <buildStates+0x3d>
cmp    $0x3,%edi
jne    116f <buildStates+0x5f>
shl    $0x4,%sil
or     %dl,%sil
mov    %esi,%ebx
jmp    1214 <buildStates+0x104>
mov    %esi,%eax
shl    $0x4,%al
or     %dl,%al
cmp    $0x23,%al
jg     117d <buildStates+0x6d>
cmp    $0x81,%al
je     11a3 <buildStates+0x93>
cmp    $0x84,%al
je     11aa <buildStates+0x9a>
cmp    $0x18,%al
jne    11d4 <buildStates+0xc4>
xor    %eax,%eax
jmp    11cb <buildStates+0xbb>
mov    %esi,%eax
shl    $0x4,%al
or     %dl,%al
cmp    $0x23,%al
jg     1190 <buildStates+0x80>
cmp    $0x81,%al
je     11b1 <buildStates+0xa1>
cmp    $0x84,%al
je     11b8 <buildStates+0xa8>
cmp    $0x18,%al
jne    1218 <buildStates+0x108>
xor    %eax,%eax
jmp    120a <buildStates+0xfa>
xor    %ebx,%ebx
xor    %edi,%edi
call   1030 <assert@plt>
jmp    1214 <buildStates+0x104>
cmp    $0x24,%al
je     11bf <buildStates+0xaf>
cmp    $0x42,%al
je     11c6 <buildStates+0xb6>
cmp    $0x48,%al
jne    11d4 <buildStates+0xc4>
mov    $0x3,%eax
jmp    11cb <buildStates+0xbb>
cmp    $0x24,%al
je     11fe <buildStates+0xee>
cmp    $0x42,%al
je     1205 <buildStates+0xf5>
cmp    $0x48,%al
jne    1218 <buildStates+0x108>
mov    $0x3,%eax
jmp    120a <buildStates+0xfa>
mov    $0x4,%eax
jmp    11cb <buildStates+0xbb>
mov    $0x5,%eax
jmp    11cb <buildStates+0xbb>
mov    $0x4,%eax
jmp    120a <buildStates+0xfa>
mov    $0x5,%eax
jmp    120a <buildStates+0xfa>
mov    $0x1,%eax
jmp    11cb <buildStates+0xbb>
mov    $0x2,%eax
lea    0xe34(%rip),%rcx
jmp    1211 <buildStates+0x101>
movzbl %dl,%ecx
mov    %ecx,%eax
and    $0x8,%eax
test   $0x1,%sil
je     12a1 <buildStates+0x191>
test   %eax,%eax
je     12a1 <buildStates+0x191>
mov    $0x40,%bl
test   $0x8,%dl
jne    12dc <buildStates+0x1cc>
jmp    12de <buildStates+0x1ce>
mov    $0x1,%eax
jmp    120a <buildStates+0xfa>
mov    $0x2,%eax
lea    0xdef(%rip),%rcx
mov    (%rax,%rcx,1),%bl
mov    %ebx,%eax
pop    %rbx
ret
movzbl %sil,%r10d
mov    %esi,%ebx
and    $0x1,%bl
mov    %esi,%ecx
and    $0x2,%cl
and    $0x4,%sil
lea    (%rsi,%rsi,1),%r8d
and    $0x8,%r10d
lea    0x0(,%r10,4),%r9d
test   $0x4,%dl
movzbl %cl,%ecx
mov    $0x2,%edi
cmove  %ecx,%edi
movzbl %r9b,%eax
mov    $0x20,%r9d
cmove  %eax,%r9d
test   $0x8,%dl
movzbl %bl,%eax
mov    $0x1,%ebx
cmove  %eax,%ebx
movzbl %r8b,%eax
mov    $0x8,%ecx
cmove  %eax,%ecx
movzbl %dl,%eax
or     %edi,%ebx
test   $0x2,%dl
movzbl %sil,%edx
mov    $0x4,%esi
cmove  %edx,%esi
or     %ebx,%esi
or     %ecx,%esi
mov    %esi,%ecx
or     $0x10,%cl
and    $0x1,%eax
or     %r10d,%eax
movzbl %cl,%ebx
cmove  %esi,%ebx
or     %r9d,%ebx
jmp    1214 <buildStates+0x104>
test   $0x2,%sil
je     12ae <buildStates+0x19e>
mov    %ecx,%edi
and    $0x4,%edi
jne    12d0 <buildStates+0x1c0>
test   $0x4,%sil
je     12bb <buildStates+0x1ab>
mov    %ecx,%edi
and    $0xa,%edi
jne    12d0 <buildStates+0x1c0>
mov    $0x40,%bl
test   $0x8,%sil
je     1214 <buildStates+0x104>
and    $0x5,%ecx
je     1214 <buildStates+0x104>
mov    $0x40,%bl
test   $0x1,%sil
je     12de <buildStates+0x1ce>
test   %eax,%eax
je     12de <buildStates+0x1ce>
mov    $0x1,%bl
test   $0x4,%dl
mov    $0x40,%r8d
mov    $0x2,%ecx
cmove  %r8d,%ecx
test   $0x2,%sil
cmove  %r8d,%ecx
or     %bl,%cl
mov    $0x40,%bl
mov    $0x40,%al
mov    $0x40,%dil
test   $0x4,%sil
je     131f <buildStates+0x20f>
test   $0x2,%dl
mov    $0x4,%eax
cmove  %r8d,%eax
test   $0x8,%dl
mov    $0x8,%edi
cmove  %r8d,%edi
or     %cl,%al
or     %dil,%al
mov    $0x40,%cl
test   $0x8,%sil
je     1348 <buildStates+0x238>
test   $0x1,%dl
mov    $0x40,%ecx
mov    $0x10,%ebx
cmove  %ecx,%ebx
test   $0x4,%dl
sete   %cl
shl    $0x5,%cl
add    $0x20,%cl
or     %al,%bl
or     %cl,%bl
jmp    1214 <buildStates+0x104>

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

LLVM IR (-O2):
@__const.buildStates.finalBinaryStates = [6 x i8] c"\01\02\04\08\10 "
@__const.buildStates.finalBinaryStates.2 = [7 x i8] c"\01\02\04\08\10 @"
define zeroext i8 @buildStates(i32 %0, i8 zeroext %1, i8 zeroext %2) {
switch i32 %0, label %134 [
i32 3, label %4
i32 4, label %7
i32 5, label %51
]
4: ; preds = %3
%5 = shl i8 %1, 4
%6 = or i8 %5, %2
br label %136
7: ; preds = %3
%8 = zext i8 %1 to i32
%9 = shl i8 %1, 4
%10 = zext i8 %2 to i32
%11 = or i8 %9, %2
switch i8 %11, label %12 [
i8 24, label %47
i8 36, label %42
i8 66, label %43
i8 72, label %44
i8 -127, label %45
i8 -124, label %46
]
12: ; preds = %7
%13 = and i8 %1, 1
%14 = and i32 %10, 8
%15 = icmp eq i32 %14, 0
%16 = select i1 %15, i8 %13, i8 1
%17 = and i8 %1, 2
%18 = and i32 %10, 4
%19 = icmp eq i32 %18, 0
%20 = select i1 %19, i8 %17, i8 2
%21 = or i8 %16, %20
%22 = and i32 %8, 4
%23 = trunc i32 %22 to i8
%24 = and i32 %10, 2
%25 = icmp eq i32 %24, 0
%26 = select i1 %25, i8 %23, i8 4
%27 = or i8 %21, %26
%28 = trunc i32 %22 to i8
%29 = shl nuw nsw i8 %28, 1
%30 = select i1 %15, i8 %29, i8 8
%31 = or i8 %27, %30
%32 = and i32 %8, 8
%33 = or i8 %31, 16
%34 = and i32 %10, 1
%35 = or i32 %34, %32
%36 = icmp eq i32 %35, 0
%37 = select i1 %36, i8 %31, i8 %33
%38 = trunc i32 %32 to i8
%39 = shl nuw nsw i8 %38, 2
%40 = select i1 %19, i8 %39, i8 32
%41 = or i8 %37, %40
br label %136
42: ; preds = %7
br label %47
43: ; preds = %7
br label %47
44: ; preds = %7
br label %47
45: ; preds = %7
br label %47
46: ; preds = %7
br label %47
47: ; preds = %7, %46, %45, %44, %43, %42
%48 = phi i64 [ 0, %7 ], [ 1, %42 ], [ 2, %43 ], [ 3, %44 ], [ 4, %45 ], [ 5, %46 ]
%49 = getelementptr inbounds [6 x i8], [6 x i8]* @__const.buildStates.finalBinaryStates, i64 0, i64 %48
%50 = load i8, i8* %49
br label %136
51: ; preds = %3
%52 = zext i8 %1 to i32
%53 = shl i8 %1, 4
%54 = zext i8 %2 to i32
%55 = or i8 %53, %2
switch i8 %55, label %56 [
i8 24, label %67
i8 36, label %62
i8 66, label %63
i8 72, label %64
i8 -127, label %65
i8 -124, label %66
]
56: ; preds = %51
%57 = and i32 %52, 1
%58 = icmp eq i32 %57, 0
%59 = and i32 %54, 8
%60 = icmp eq i32 %59, 0
%61 = or i1 %58, %60
br i1 %61, label %75, label %93
62: ; preds = %51
br label %67
63: ; preds = %51
br label %67
64: ; preds = %51
br label %67
65: ; preds = %51
br label %67
66: ; preds = %51
br label %67
67: ; preds = %51, %66, %65, %64, %63, %62
%68 = phi i64 [ 0, %51 ], [ 1, %62 ], [ 2, %63 ], [ 3, %64 ], [ 4, %65 ], [ 5, %66 ]
%69 = getelementptr inbounds [7 x i8], [7 x i8]* @__const.buildStates.finalBinaryStates.2, i64 0, i64 %68
%70 = load i8, i8* %69
br label %136
71: ; preds = %87, %81, %75
%72 = and i32 %54, 8
%73 = icmp eq i32 %72, 0
%74 = or i1 %58, %73
br i1 %74, label %97, label %96
75: ; preds = %56
%76 = and i32 %52, 2
%77 = icmp eq i32 %76, 0
%78 = and i32 %54, 4
%79 = icmp eq i32 %78, 0
%80 = or i1 %77, %79
br i1 %80, label %81, label %71
81: ; preds = %75
%82 = and i32 %52, 4
%83 = icmp eq i32 %82, 0
%84 = and i32 %54, 10
%85 = icmp eq i32 %84, 0
%86 = or i1 %83, %85
br i1 %86, label %87, label %71
87: ; preds = %81
%88 = and i32 %52, 8
%89 = icmp eq i32 %88, 0
%90 = and i32 %54, 5
%91 = icmp eq i32 %90, 0
%92 = or i1 %89, %91
br i1 %92, label %136, label %71
93: ; preds = %56
%94 = and i32 %54, 8
%95 = icmp eq i32 %94, 0
br i1 %95, label %97, label %96
96: ; preds = %71, %93
br label %97
97: ; preds = %71, %93, %96
%98 = phi i8 [ 1, %96 ], [ 64, %93 ], [ 64, %71 ]
%99 = and i32 %52, 2
%100 = icmp eq i32 %99, 0
%101 = and i32 %54, 4
%102 = icmp eq i32 %101, 0
%103 = or i1 %100, %102
%104 = select i1 %103, i8 64, i8 2
%105 = or i8 %104, %98
%106 = and i32 %52, 4
%107 = icmp eq i32 %106, 0
br i1 %107, label %115, label %108
108: ; preds = %97
%109 = and i32 %54, 2
%110 = icmp eq i32 %109, 0
%111 = select i1 %110, i8 64, i8 4
%112 = and i32 %54, 8
%113 = icmp eq i32 %112, 0
%114 = select i1 %113, i8 64, i8 8
br label %115
115: ; preds = %97, %108
%116 = phi i8 [ %111, %108 ], [ 64, %97 ]
%117 = phi i8 [ %114, %108 ], [ 64, %97 ]
%118 = or i8 %116, %105
%119 = or i8 %117, %118
%120 = and i32 %52, 8
%121 = icmp eq i32 %120, 0
br i1 %121, label %129, label %122
122: ; preds = %115
%123 = and i32 %54, 1
%124 = icmp eq i32 %123, 0
%125 = select i1 %124, i8 64, i8 16
%126 = and i32 %54, 4
%127 = icmp eq i32 %126, 0
%128 = select i1 %127, i8 64, i8 32
br label %129
129: ; preds = %115, %122
%130 = phi i8 [ %125, %122 ], [ 64, %115 ]
%131 = phi i8 [ %128, %122 ], [ 64, %115 ]
%132 = or i8 %130, %119
%133 = or i8 %131, %132
br label %136
134: ; preds = %3
%135 = tail call i32 @assert(i32 0)
br label %136
136: ; preds = %12, %87, %67, %129, %47, %134, %4
%137 = phi i8 [ 0, %134 ], [ %6, %4 ], [ %50, %47 ], [ %70, %67 ], [ %133, %129 ], [ 64, %87 ], [ %41, %12 ]
ret i8 %137
}