#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 uint32_t;

/* Variables and functions */
int is_symbol_char_gen(int);
int /*<<< orphan*/ printf(char *, ...);
int main() {
  printf("static const uint32_t symchars[8] = {\n    ");
  for (int i = 0; i < 256; i += 32) {
    uint32_t block = 0;
    for (int j = 0; j < 32; j++) {
      block |= is_symbol_char_gen(i + j) << j;
    }
    printf("0x%08x%s", block, (i == (256 - 32)) ? "" : ", ");
  }
  printf("\n};\n");
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
lea    0xeca(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
movl   $0x0,-0x8(%rbp)
cmpl   $0x100,-0x8(%rbp)
jge    11c7 <main+0xa7>
movl   $0x0,-0xc(%rbp)
movl   $0x0,-0x10(%rbp)
cmpl   $0x20,-0x10(%rbp)
jge    118d <main+0x6d>
mov    -0x8(%rbp),%edi
add    -0x10(%rbp),%edi
call   1030 <is_symbol_char_gen@plt>
mov    -0x10(%rbp),%ecx
shl    %cl,%eax
or     -0xc(%rbp),%eax
mov    %eax,-0xc(%rbp)
mov    -0x10(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x10(%rbp)
jmp    115f <main+0x3f>
mov    -0xc(%rbp),%esi
mov    -0x8(%rbp),%ecx
lea    0xe9a(%rip),%rdx
lea    0xe9a(%rip),%rax
cmp    $0xe0,%ecx
cmove  %rax,%rdx
lea    0xe79(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
mov    -0x8(%rbp),%eax
add    $0x20,%eax
mov    %eax,-0x8(%rbp)
jmp    1144 <main+0x24>
lea    0xe69(%rip),%rdi
mov    $0x0,%al
call   1040 <printf@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %rbx
push   %rax
lea    0xec6(%rip),%rdi
xor    %ebx,%ebx
xor    %eax,%eax
call   1050 <printf@plt>
xor    %ebp,%ebp
cs nopw 0x0(%rax,%rax,1)
nop
mov    %ebx,%edi
call   1040 <is_symbol_char_gen@plt>
mov    %ebx,%ecx
shl    %cl,%eax
or     %eax,%ebp
add    $0x1,%ebx
cmp    $0x20,%ebx
jne    1150 <main+0x20>
lea    0xebf(%rip),%rdi
lea    0xec1(%rip),%rdx
xor    %ebx,%ebx
mov    %ebp,%esi
xor    %eax,%eax
call   1050 <printf@plt>
xor    %ebp,%ebp
lea    0x20(%rbx),%edi
call   1040 <is_symbol_char_gen@plt>
mov    %ebx,%ecx
shl    %cl,%eax
or     %eax,%ebp
add    $0x1,%ebx
cmp    $0x20,%ebx
jne    1180 <main+0x50>
lea    0xe8e(%rip),%rdi
lea    0xe90(%rip),%rdx
xor    %ebx,%ebx
mov    %ebp,%esi
xor    %eax,%eax
call   1050 <printf@plt>
xor    %ebp,%ebp
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
lea    0x40(%rbx),%edi
call   1040 <is_symbol_char_gen@plt>
mov    %ebx,%ecx
shl    %cl,%eax
or     %eax,%ebp
add    $0x1,%ebx
cmp    $0x20,%ebx
jne    11c0 <main+0x90>
lea    0xe4e(%rip),%rdi
lea    0xe50(%rip),%rdx
xor    %ebx,%ebx
mov    %ebp,%esi
xor    %eax,%eax
call   1050 <printf@plt>
xor    %ebp,%ebp
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
lea    0x60(%rbx),%edi
call   1040 <is_symbol_char_gen@plt>
mov    %ebx,%ecx
shl    %cl,%eax
or     %eax,%ebp
add    $0x1,%ebx
cmp    $0x20,%ebx
jne    1200 <main+0xd0>
lea    0xe0e(%rip),%rdi
lea    0xe10(%rip),%rdx
xor    %ebx,%ebx
mov    %ebp,%esi
xor    %eax,%eax
call   1050 <printf@plt>
xor    %ebp,%ebp
cs nopw 0x0(%rax,%rax,1)
nopl   0x0(%rax,%rax,1)
lea    0x80(%rbx),%edi
call   1040 <is_symbol_char_gen@plt>
mov    %ebx,%ecx
shl    %cl,%eax
or     %eax,%ebp
add    $0x1,%ebx
cmp    $0x20,%ebx
jne    1240 <main+0x110>
lea    0xdcb(%rip),%rdi
lea    0xdcd(%rip),%rdx
xor    %ebx,%ebx
mov    %ebp,%esi
xor    %eax,%eax
call   1050 <printf@plt>
xor    %ebp,%ebp
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
lea    0xa0(%rbx),%edi
call   1040 <is_symbol_char_gen@plt>
mov    %ebx,%ecx
shl    %cl,%eax
or     %eax,%ebp
add    $0x1,%ebx
cmp    $0x20,%ebx
jne    1280 <main+0x150>
lea    0xd8b(%rip),%rdi
lea    0xd8d(%rip),%rdx
xor    %ebx,%ebx
mov    %ebp,%esi
xor    %eax,%eax
call   1050 <printf@plt>
xor    %ebp,%ebp
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
lea    0xc0(%rbx),%edi
call   1040 <is_symbol_char_gen@plt>
mov    %ebx,%ecx
shl    %cl,%eax
or     %eax,%ebp
add    $0x1,%ebx
cmp    $0x20,%ebx
jne    12c0 <main+0x190>
lea    0xd4b(%rip),%rdi
lea    0xd4d(%rip),%rdx
xor    %ebx,%ebx
mov    %ebp,%esi
xor    %eax,%eax
call   1050 <printf@plt>
xor    %ebp,%ebp
cs nopw 0x0(%rax,%rax,1)
xchg   %ax,%ax
lea    0xe0(%rbx),%edi
call   1040 <is_symbol_char_gen@plt>
mov    %ebx,%ecx
shl    %cl,%eax
or     %eax,%ebp
add    $0x1,%ebx
cmp    $0x20,%ebx
jne    1300 <main+0x1d0>
lea    0xd0b(%rip),%rdi
lea    0xd03(%rip),%rdx
mov    %ebp,%esi
xor    %eax,%eax
call   1050 <printf@plt>
lea    0xd00(%rip),%rdi
call   1030 <puts@plt>
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %rbp
ret

LLVM IR (-O0):
@.str = [43 x i8] c"static const uint32_t symchars[8] = {\0A \00"
@.str.1 = [9 x i8] c"0x%08x%s\00"
@.str.2 = [1 x i8] zeroinitializer
@.str.3 = [3 x i8] c", \00"
@.str.4 = [5 x i8] c"\0A};\0A\00"
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
%4 = alloca i32
store i32 0, i32* %1
%5 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([43 x i8], [43 x i8]* @.str, i64 0, i64 0))
store i32 0, i32* %2
br label %6
6: ; preds = %32, %0
%7 = load i32, i32* %2
%8 = icmp slt i32 %7, 256
br i1 %8, label %9, label %35
9: ; preds = %6
store i32 0, i32* %3
store i32 0, i32* %4
br label %10
10: ; preds = %22, %9
%11 = load i32, i32* %4
%12 = icmp slt i32 %11, 32
br i1 %12, label %13, label %25
13: ; preds = %10
%14 = load i32, i32* %2
%15 = load i32, i32* %4
%16 = add nsw i32 %14, %15
%17 = call i32 @is_symbol_char_gen(i32 %16)
%18 = load i32, i32* %4
%19 = shl i32 %17, %18
%20 = load i32, i32* %3
%21 = or i32 %20, %19
store i32 %21, i32* %3
br label %22
22: ; preds = %13
%23 = load i32, i32* %4
%24 = add nsw i32 %23, 1
store i32 %24, i32* %4
br label %10
25: ; preds = %10
%26 = load i32, i32* %3
%27 = load i32, i32* %2
%28 = icmp eq i32 %27, 224
%29 = zext i1 %28 to i64
%30 = select i1 %28, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.2, i64 0, i64 0), i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0)
%31 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0), i32 %26, i8* %30)
br label %32
32: ; preds = %25
%33 = load i32, i32* %2
%34 = add nsw i32 %33, 32
store i32 %34, i32* %2
br label %6
35: ; preds = %6
%36 = call i32 (i8*, ...) @printf(i8* getelementptr inbounds ([5 x i8], [5 x i8]* @.str.4, i64 0, i64 0))
ret i32 0
}

LLVM IR (-O2):
@.str = [43 x i8] c"static const uint32_t symchars[8] = {\0A \00"
@.str.1 = [9 x i8] c"0x%08x%s\00"
@.str.2 = [1 x i8] zeroinitializer
@.str.3 = [3 x i8] c", \00"
@str = [4 x i8] c"\0A};\00"
define i32 @main() {
%1 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([43 x i8], [43 x i8]* @.str, i64 0, i64 0))
br label %82
2: ; preds = %82
%3 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0), i32 %87, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0))
br label %4
4: ; preds = %4, %2
%5 = phi i32 [ 0, %2 ], [ %11, %4 ]
%6 = phi i32 [ 0, %2 ], [ %10, %4 ]
%7 = add nuw nsw i32 %5, 32
%8 = tail call i32 @is_symbol_char_gen(i32 %7)
%9 = shl i32 %8, %5
%10 = or i32 %9, %6
%11 = add nuw nsw i32 %5, 1
%12 = icmp eq i32 %11, 32
br i1 %12, label %13, label %4
13: ; preds = %4
%14 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0), i32 %10, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0))
br label %15
15: ; preds = %15, %13
%16 = phi i32 [ 0, %13 ], [ %22, %15 ]
%17 = phi i32 [ 0, %13 ], [ %21, %15 ]
%18 = add nuw nsw i32 %16, 64
%19 = tail call i32 @is_symbol_char_gen(i32 %18)
%20 = shl i32 %19, %16
%21 = or i32 %20, %17
%22 = add nuw nsw i32 %16, 1
%23 = icmp eq i32 %22, 32
br i1 %23, label %24, label %15
24: ; preds = %15
%25 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0), i32 %21, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0))
br label %26
26: ; preds = %26, %24
%27 = phi i32 [ 0, %24 ], [ %33, %26 ]
%28 = phi i32 [ 0, %24 ], [ %32, %26 ]
%29 = add nuw nsw i32 %27, 96
%30 = tail call i32 @is_symbol_char_gen(i32 %29)
%31 = shl i32 %30, %27
%32 = or i32 %31, %28
%33 = add nuw nsw i32 %27, 1
%34 = icmp eq i32 %33, 32
br i1 %34, label %35, label %26
35: ; preds = %26
%36 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0), i32 %32, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0))
br label %37
37: ; preds = %37, %35
%38 = phi i32 [ 0, %35 ], [ %44, %37 ]
%39 = phi i32 [ 0, %35 ], [ %43, %37 ]
%40 = add nuw nsw i32 %38, 128
%41 = tail call i32 @is_symbol_char_gen(i32 %40)
%42 = shl i32 %41, %38
%43 = or i32 %42, %39
%44 = add nuw nsw i32 %38, 1
%45 = icmp eq i32 %44, 32
br i1 %45, label %46, label %37
46: ; preds = %37
%47 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0), i32 %43, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0))
br label %48
48: ; preds = %48, %46
%49 = phi i32 [ 0, %46 ], [ %55, %48 ]
%50 = phi i32 [ 0, %46 ], [ %54, %48 ]
%51 = add nuw nsw i32 %49, 160
%52 = tail call i32 @is_symbol_char_gen(i32 %51)
%53 = shl i32 %52, %49
%54 = or i32 %53, %50
%55 = add nuw nsw i32 %49, 1
%56 = icmp eq i32 %55, 32
br i1 %56, label %57, label %48
57: ; preds = %48
%58 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0), i32 %54, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0))
br label %59
59: ; preds = %59, %57
%60 = phi i32 [ 0, %57 ], [ %66, %59 ]
%61 = phi i32 [ 0, %57 ], [ %65, %59 ]
%62 = add nuw nsw i32 %60, 192
%63 = tail call i32 @is_symbol_char_gen(i32 %62)
%64 = shl i32 %63, %60
%65 = or i32 %64, %61
%66 = add nuw nsw i32 %60, 1
%67 = icmp eq i32 %66, 32
br i1 %67, label %68, label %59
68: ; preds = %59
%69 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0), i32 %65, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.3, i64 0, i64 0))
br label %70
70: ; preds = %70, %68
%71 = phi i32 [ 0, %68 ], [ %77, %70 ]
%72 = phi i32 [ 0, %68 ], [ %76, %70 ]
%73 = add nuw nsw i32 %71, 224
%74 = tail call i32 @is_symbol_char_gen(i32 %73)
%75 = shl i32 %74, %71
%76 = or i32 %75, %72
%77 = add nuw nsw i32 %71, 1
%78 = icmp eq i32 %77, 32
br i1 %78, label %79, label %70
79: ; preds = %70
%80 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([9 x i8], [9 x i8]* @.str.1, i64 0, i64 0), i32 %76, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.2, i64 0, i64 0))
%81 = tail call i32 @puts(i8* dereferenceable(1) getelementptr inbounds ([4 x i8], [4 x i8]* @str, i64 0, i64 0))
ret i32 0
82: ; preds = %0, %82
%83 = phi i32 [ 0, %0 ], [ %88, %82 ]
%84 = phi i32 [ 0, %0 ], [ %87, %82 ]
%85 = tail call i32 @is_symbol_char_gen(i32 %83)
%86 = shl i32 %85, %83
%87 = or i32 %86, %84
%88 = add nuw nsw i32 %83, 1
%89 = icmp eq i32 %88, 32
br i1 %89, label %2, label %82
}