#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*/ putchar(char);
void main() {
  char input[] = "SSSWILTECH1\1\1";
  int i, c;
  for (i = 2; (c = input[i]) != '\0'; i++) {
    switch (c) {
    case 'a':
      putchar('i');
      continue;
    case '1':
      break;
    case 1:
      while ((c = input[++i]) != '\1' && c != '\0')
        ;
    case 9:
      putchar('S');
    case 'E':
    case 'L':
      continue;
    default:
      putchar(c);
      continue;
    }
    putchar(' ');
  }
  putchar('\n');
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    0xee1(%rip),%rax
mov    %rax,-0xe(%rbp)
mov    0xedf(%rip),%eax
mov    %eax,-0x6(%rbp)
mov    0xed9(%rip),%ax
mov    %ax,-0x2(%rbp)
movl   $0x2,-0x14(%rbp)
movslq -0x14(%rbp),%rax
movsbl -0xe(%rbp,%rax,1),%eax
mov    %eax,-0x18(%rbp)
cmp    $0x0,%eax
je     1251 <main+0x141>
mov    -0x18(%rbp),%eax
mov    %eax,-0x1c(%rbp)
sub    $0x1,%eax
je     11d0 <main+0xc0>
jmp    1167 <main+0x57>
mov    -0x1c(%rbp),%eax
sub    $0x9,%eax
je     121a <main+0x10a>
jmp    1178 <main+0x68>
mov    -0x1c(%rbp),%eax
sub    $0x31,%eax
je     11cb <main+0xbb>
jmp    1189 <main+0x79>
mov    -0x1c(%rbp),%eax
sub    $0x45,%eax
je     1224 <main+0x114>
jmp    119a <main+0x8a>
mov    -0x1c(%rbp),%eax
sub    $0x4c,%eax
je     1224 <main+0x114>
jmp    11ab <main+0x9b>
mov    -0x1c(%rbp),%eax
sub    $0x61,%eax
jne    1229 <main+0x119>
jmp    11bc <main+0xac>
mov    $0x69,%edi
call   1030 <putchar@plt>
jmp    1243 <main+0x133>
jmp    1239 <main+0x129>
jmp    11d5 <main+0xc5>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
cltq
movsbl -0xe(%rbp,%rax,1),%ecx
mov    %ecx,-0x18(%rbp)
xor    %eax,%eax
cmp    $0x1,%ecx
mov    %al,-0x1d(%rbp)
je     1200 <main+0xf0>
cmpl   $0x0,-0x18(%rbp)
setne  %al
mov    %al,-0x1d(%rbp)
mov    -0x1d(%rbp),%al
test   $0x1,%al
jne    1210 <main+0x100>
jmp    1215 <main+0x105>
jmp    11d5 <main+0xc5>
jmp    121a <main+0x10a>
mov    $0x53,%edi
call   1030 <putchar@plt>
jmp    1243 <main+0x133>
mov    -0x18(%rbp),%eax
movsbl %al,%edi
call   1030 <putchar@plt>
jmp    1243 <main+0x133>
mov    $0x20,%edi
call   1030 <putchar@plt>
mov    -0x14(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x14(%rbp)
jmp    113e <main+0x2e>
mov    $0xa,%edi
call   1030 <putchar@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r14
push   %rbx
mov    $0x2,%ebx
mov    $0x53,%al
mov    $0xfffffffe,%r14d
lea    0xed8(%rip),%rbp
jmp    116a <main+0x5a>
lea    -0xc(%rbx),%eax
cmp    $0xffffffff,%eax
cmovb  %r14d,%eax
sub    %ebx,%eax
add    $0xc,%eax
mov    $0xc,%ecx
sub    %ebx,%ecx
cmp    %eax,%ecx
cmovae %eax,%ecx
test   %eax,%eax
cmove  %eax,%ecx
add    %ecx,%ebx
add    $0x1,%ebx
mov    $0x53,%al
movsbl %al,%edi
call   1030 <putchar@plt>
movslq %ebx,%rbx
movzbl 0x1(%rbx,%rbp,1),%eax
add    $0x1,%rbx
cmp    $0xd,%ebx
je     11a3 <main+0x93>
movsbl %al,%ecx
cmp    $0x44,%ecx
jg     1190 <main+0x80>
cmp    $0x1,%ecx
je     112a <main+0x1a>
cmp    $0x9,%ecx
je     114f <main+0x3f>
cmp    $0x31,%ecx
jne    1151 <main+0x41>
mov    $0x20,%al
jmp    1151 <main+0x41>
cs nopw 0x0(%rax,%rax,1)
nop
cmp    $0x45,%ecx
je     1159 <main+0x49>
cmp    $0x4c,%ecx
je     1159 <main+0x49>
cmp    $0x61,%ecx
jne    1151 <main+0x41>
mov    $0x69,%al
jmp    1151 <main+0x41>
mov    $0xa,%edi
pop    %rbx
pop    %r14
pop    %rbp
jmp    1030 <putchar@plt>

LLVM IR (-O0):
@__const.main.input = [14 x i8] c"SSSWILTECH1\01\01\00"
define void @main() {
%1 = alloca [14 x i8]
%2 = alloca i32
%3 = alloca i32
%4 = bitcast [14 x i8]* %1 to i8*
store i32 2, i32* %2
br label %5
5: ; preds = %42, %0
%6 = load i32, i32* %2
%7 = sext i32 %6 to i64
%8 = getelementptr inbounds [14 x i8], [14 x i8]* %1, i64 0, i64 %7
%9 = load i8, i8* %8
%10 = sext i8 %9 to i32
store i32 %10, i32* %3
%11 = icmp ne i32 %10, 0
br i1 %11, label %12, label %45
12: ; preds = %5
%13 = load i32, i32* %3
switch i32 %13, label %36 [
i32 97, label %14
i32 49, label %16
i32 1, label %17
i32 9, label %33
i32 69, label %35
i32 76, label %35
]
14: ; preds = %12
%15 = call i32 @putchar(i8 signext 105)
br label %42
16: ; preds = %12
br label %40
17: ; preds = %12
br label %18
18: ; preds = %31, %17
%19 = load i32, i32* %2
%20 = add nsw i32 %19, 1
store i32 %20, i32* %2
%21 = sext i32 %20 to i64
%22 = getelementptr inbounds [14 x i8], [14 x i8]* %1, i64 0, i64 %21
%23 = load i8, i8* %22
%24 = sext i8 %23 to i32
store i32 %24, i32* %3
%25 = icmp ne i32 %24, 1
br i1 %25, label %26, label %29
26: ; preds = %18
%27 = load i32, i32* %3
%28 = icmp ne i32 %27, 0
br label %29
29: ; preds = %26, %18
%30 = phi i1 [ false, %18 ], [ %28, %26 ]
br i1 %30, label %31, label %32
31: ; preds = %29
br label %18
32: ; preds = %29
br label %33
33: ; preds = %12, %32
%34 = call i32 @putchar(i8 signext 83)
br label %35
35: ; preds = %12, %12, %33
br label %42
36: ; preds = %12
%37 = load i32, i32* %3
%38 = trunc i32 %37 to i8
%39 = call i32 @putchar(i8 signext %38)
br label %42
40: ; preds = %16
%41 = call i32 @putchar(i8 signext 32)
br label %42
42: ; preds = %40, %36, %35, %14
%43 = load i32, i32* %2
%44 = add nsw i32 %43, 1
store i32 %44, i32* %2
br label %5
45: ; preds = %5
%46 = call i32 @putchar(i8 signext 10)
ret void
}

LLVM IR (-O2):
@__const.main.input = [14 x i8] c"SSSWILTECH1\01\01\00"
define void @main() {
br label %1
1: ; preds = %0, %24
%2 = phi i8 [ 83, %0 ], [ %29, %24 ]
%3 = phi i32 [ 2, %0 ], [ %26, %24 ]
%4 = sext i8 %2 to i32
switch i32 %4, label %18 [
i32 97, label %20
i32 49, label %19
i32 1, label %5
i32 9, label %16
i32 69, label %24
i32 76, label %24
]
5: ; preds = %1
%6 = add i32 %3, -12
%7 = call i32 @llvm.umax.i32(i32 %6, i32 -2)
%8 = add nsw i32 %7, 12
%9 = sub i32 %8, %3
%10 = sub i32 12, %3
%11 = icmp eq i32 %9, 0
%12 = call i32 @llvm.umin.i32(i32 %10, i32 %9)
%13 = select i1 %11, i32 0, i32 %12
%14 = add i32 %3, 1
%15 = add i32 %14, %13
br label %16
16: ; preds = %5, %1
%17 = phi i32 [ %3, %1 ], [ %15, %5 ]
br label %20
18: ; preds = %1
br label %20
19: ; preds = %1
br label %20
20: ; preds = %1, %18, %19, %16
%21 = phi i8 [ 83, %16 ], [ 32, %19 ], [ %2, %18 ], [ 105, %1 ]
%22 = phi i32 [ %17, %16 ], [ %3, %19 ], [ %3, %18 ], [ %3, %1 ]
%23 = tail call i32 @putchar(i8 signext %21)
br label %24
24: ; preds = %20, %1, %1
%25 = phi i32 [ %3, %1 ], [ %3, %1 ], [ %22, %20 ]
%26 = add nsw i32 %25, 1
%27 = sext i32 %26 to i64
%28 = getelementptr inbounds [14 x i8], [14 x i8]* @__const.main.input, i64 0, i64 %27
%29 = load i8, i8* %28
%30 = icmp eq i32 %26, 13
br i1 %30, label %31, label %1
31: ; preds = %24
%32 = tail call i32 @putchar(i8 signext 10)
ret void
}