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

/* Variables and functions */
int EOF;
int /*<<< orphan*/ exit(int);
int /*<<< orphan*/ fclose(int /*<<< orphan*/ *);
int /*<<< orphan*/ *fopen(char *, char *);
int /*<<< orphan*/ fprintf(int /*<<< orphan*/ *, char *, ...);
int getc(int /*<<< orphan*/ *);
int /*<<< orphan*/ putc(char, int /*<<< orphan*/ *);
int /*<<< orphan*/ stderr;
int /*<<< orphan*/ strcat(char *, char *);
int /*<<< orphan*/ strcpy(char *, char *);
char *strrchr(char *, char);
int main(int argc, char *argv[]) {
  char base[100], opath[100], *name, *p;
  FILE *ifp, *ofp;
  int byte, cnt;
  if (argc < 2 || argc > 3) {
    fprintf(stderr, "usage: bin2c <infile> [ <outfile> ]\n");
    exit(1);
  }
  strcpy(base, argv[1]);
  if ((p = strrchr(base, '.')) != NULL)
    *p = '\0';
  if (argc >= 3)
    strcpy(opath, argv[2]);
  else {
    strcpy(opath, base);
    strcat(opath, ".c");
  }
  if ((name = strrchr(base, '/')) != NULL)
    ++name;
  else
    name = base;
  if (!(ifp = fopen(argv[1], "rb"))) {
    fprintf(stderr, "error: can't open: %s\n", argv[1]);
    exit(1);
  }
  if (!(ofp = fopen(opath, "wb"))) {
    fprintf(stderr, "error: can't create: %s\n", argv[2]);
    exit(1);
  }
  fprintf(ofp, "#include <stdint.h>\n\nuint8_t %s_array[] = {\n", name);
  cnt = 0;
  while ((byte = getc(ifp)) != EOF) {
    fprintf(ofp, " 0x%02x,", byte);
    if (++cnt == 8) {
      putc('\n', ofp);
      cnt = 0;
    }
  }
  if (cnt > 0)
    putc('\n', ofp);
  fprintf(ofp, "};\n\nint %s_size = sizeof(%s_array);\n", name, name);
  fclose(ifp);
  fclose(ofp);
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x120,%rsp
movl   $0x0,-0x4(%rbp)
mov    %edi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
cmpl   $0x2,-0x8(%rbp)
jl     11bd <main+0x2d>
cmpl   $0x3,-0x8(%rbp)
jle    11df <main+0x4f>
mov    0x2e14(%rip),%rax
movslq (%rax),%rdi
lea    0xe32(%rip),%rsi
mov    $0x0,%al
call   1070 <fprintf@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>
lea    -0x80(%rbp),%rdi
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rsi
call   1030 <strcpy@plt>
lea    -0x80(%rbp),%rdi
mov    $0x2e,%esi
call   1050 <strrchr@plt>
mov    %rax,-0x100(%rbp)
cmp    $0x0,%rax
je     1219 <main+0x89>
mov    -0x100(%rbp),%rax
movb   $0x0,(%rax)
cmpl   $0x3,-0x8(%rbp)
jl     123c <main+0xac>
lea    -0xf0(%rbp),%rdi
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rsi
call   1030 <strcpy@plt>
jmp    125f <main+0xcf>
lea    -0xf0(%rbp),%rdi
lea    -0x80(%rbp),%rsi
call   1030 <strcpy@plt>
lea    -0xf0(%rbp),%rdi
lea    0xdcb(%rip),%rsi
call   1090 <strcat@plt>
lea    -0x80(%rbp),%rdi
mov    $0x2f,%esi
call   1050 <strrchr@plt>
mov    %rax,-0xf8(%rbp)
cmp    $0x0,%rax
je     1295 <main+0x105>
mov    -0xf8(%rbp),%rax
add    $0x1,%rax
mov    %rax,-0xf8(%rbp)
jmp    12a0 <main+0x110>
lea    -0x80(%rbp),%rax
mov    %rax,-0xf8(%rbp)
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdi
lea    0xd79(%rip),%rsi
call   1080 <fopen@plt>
mov    %rax,-0x108(%rbp)
cmp    $0x0,%rax
jne    12ef <main+0x15f>
mov    0x2d0c(%rip),%rax
movslq (%rax),%rdi
mov    -0x10(%rbp),%rax
mov    0x8(%rax),%rdx
lea    0xd4d(%rip),%rsi
mov    $0x0,%al
call   1070 <fprintf@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>
lea    -0xf0(%rbp),%rdi
lea    0xd45(%rip),%rsi
call   1080 <fopen@plt>
mov    %rax,-0x110(%rbp)
cmp    $0x0,%rax
jne    133d <main+0x1ad>
mov    0x2cbe(%rip),%rax
movslq (%rax),%rdi
mov    -0x10(%rbp),%rax
mov    0x10(%rax),%rdx
lea    0xd19(%rip),%rsi
mov    $0x0,%al
call   1070 <fprintf@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>
mov    -0x110(%rbp),%rdi
mov    -0xf8(%rbp),%rdx
lea    0xd0c(%rip),%rsi
mov    $0x0,%al
call   1070 <fprintf@plt>
movl   $0x0,-0x118(%rbp)
mov    -0x108(%rbp),%rdi
call   10b0 <getc@plt>
mov    %eax,-0x114(%rbp)
mov    0x2c6c(%rip),%rcx
cmp    (%rcx),%eax
je     13d7 <main+0x247>
mov    -0x110(%rbp),%rdi
mov    -0x114(%rbp),%edx
lea    0xcf3(%rip),%rsi
mov    $0x0,%al
call   1070 <fprintf@plt>
mov    -0x118(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x118(%rbp)
cmp    $0x8,%eax
jne    13d2 <main+0x242>
mov    -0x110(%rbp),%rsi
mov    $0xa,%edi
call   1060 <putc@plt>
movl   $0x0,-0x118(%rbp)
jmp    1363 <main+0x1d3>
cmpl   $0x0,-0x118(%rbp)
jle    13f5 <main+0x265>
mov    -0x110(%rbp),%rsi
mov    $0xa,%edi
call   1060 <putc@plt>
mov    -0x110(%rbp),%rdi
mov    -0xf8(%rbp),%rdx
mov    -0xf8(%rbp),%rcx
lea    0xc83(%rip),%rsi
mov    $0x0,%al
call   1070 <fprintf@plt>
mov    -0x108(%rbp),%rdi
call   1040 <fclose@plt>
mov    -0x110(%rbp),%rdi
call   1040 <fclose@plt>
xor    %eax,%eax
add    $0x120,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0xd8,%rsp
mov    %edi,%ebx
lea    -0x4(%rbx),%eax
cmp    $0xfffffffd,%eax
jbe    1322 <main+0x182>
mov    %rsi,%r12
mov    0x8(%rsi),%rsi
lea    0x70(%rsp),%r15
mov    %r15,%rdi
call   1030 <strcpy@plt>
mov    %r15,%rdi
mov    $0x2e,%esi
call   1050 <strrchr@plt>
test   %rax,%rax
je     11e8 <main+0x48>
movb   $0x0,(%rax)
cmp    $0x3,%ebx
jb     11fc <main+0x5c>
mov    0x10(%r12),%rsi
mov    %rsp,%rdi
call   1030 <strcpy@plt>
jmp    121b <main+0x7b>
mov    %rsp,%rbx
lea    0x70(%rsp),%rsi
mov    %rbx,%rdi
call   1030 <strcpy@plt>
lea    0xe12(%rip),%rsi
mov    %rbx,%rdi
call   1090 <strcat@plt>
mov    %r15,%rdi
mov    $0x2f,%esi
call   1050 <strrchr@plt>
lea    0x1(%rax),%r14
test   %rax,%rax
cmove  %r15,%r14
mov    0x8(%r12),%rdi
lea    0xde9(%rip),%rsi
call   1080 <fopen@plt>
test   %rax,%rax
je     134c <main+0x1ac>
mov    %rax,%r15
lea    0xdeb(%rip),%rsi
mov    %rsp,%rdi
call   1080 <fopen@plt>
test   %rax,%rax
je     1364 <main+0x1c4>
mov    %rax,%rbx
lea    0xdec(%rip),%rsi
mov    %rax,%rdi
mov    %r14,%rdx
xor    %eax,%eax
call   1070 <fprintf@plt>
mov    %r15,%rdi
call   10c0 <getc@plt>
mov    0x2d5a(%rip),%r13
cmp    0x0(%r13),%eax
je     12e7 <main+0x147>
lea    0xdf0(%rip),%r12
xor    %ebp,%ebp
jmp    12ae <main+0x10e>
nop
mov    %r15,%rdi
call   10c0 <getc@plt>
cmp    0x0(%r13),%eax
je     12d6 <main+0x136>
mov    %rbx,%rdi
mov    %r12,%rsi
mov    %eax,%edx
xor    %eax,%eax
call   1070 <fprintf@plt>
add    $0x1,%ebp
cmp    $0x8,%ebp
jne    12a0 <main+0x100>
mov    $0xa,%edi
mov    %rbx,%rsi
call   1060 <putc@plt>
xor    %ebp,%ebp
jmp    12a0 <main+0x100>
test   %ebp,%ebp
jle    12e7 <main+0x147>
mov    $0xa,%edi
mov    %rbx,%rsi
call   1060 <putc@plt>
lea    0xda6(%rip),%rsi
mov    %rbx,%rdi
mov    %r14,%rdx
mov    %r14,%rcx
xor    %eax,%eax
call   1070 <fprintf@plt>
mov    %r15,%rdi
call   1040 <fclose@plt>
mov    %rbx,%rdi
call   1040 <fclose@plt>
xor    %eax,%eax
add    $0xd8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret
mov    0x2caf(%rip),%rax
movslq (%rax),%rcx
lea    0xccd(%rip),%rdi
mov    $0x24,%esi
mov    $0x1,%edx
call   10b0 <fwrite@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>
mov    0x2c85(%rip),%rax
movslq (%rax),%rdi
mov    0x8(%r12),%rdx
lea    0xcc9(%rip),%rsi
jmp    137a <main+0x1da>
mov    0x2c6d(%rip),%rax
movslq (%rax),%rdi
mov    0x10(%r12),%rdx
lea    0xccb(%rip),%rsi
xor    %eax,%eax
call   1070 <fprintf@plt>
mov    $0x1,%edi
call   10a0 <exit@plt>

LLVM IR (-O0):
@stderr = global i32 0
@.str = [37 x i8] c"usage: bin2c <infile> [ <outfile> ]\0A\00"
@.str.1 = [3 x i8] c".c\00"
@.str.2 = [3 x i8] c"rb\00"
@.str.3 = [23 x i8] c"error: can't open: %s\0A\00"
@.str.4 = [3 x i8] c"wb\00"
@.str.5 = [25 x i8] c"error: can't create: %s\0A\00"
@.str.6 = [45 x i8] c"#include <stdint.h>\0A\0Auint8_t %s_array[] = {\0A\00"
@EOF = global i32 0
@.str.7 = [9 x i8] c" 0x%02x,\00"
@.str.8 = [37 x i8] c"};\0A\0Aint %s_size = sizeof(%s_array);\0A\00"
define i32 @main(i32 %0, i8** %1) {
%3 = alloca i32
%4 = alloca i32
%5 = alloca i8**
%6 = alloca [100 x i8]
%7 = alloca [100 x i8]
%8 = alloca i8*
%9 = alloca i8*
%10 = alloca i32*
%11 = alloca i32*
%12 = alloca i32
%13 = alloca i32
store i32 0, i32* %3
store i32 %0, i32* %4
store i8** %1, i8*** %5
%14 = load i32, i32* %4
%15 = icmp slt i32 %14, 2
br i1 %15, label %19, label %16
16: ; preds = %2
%17 = load i32, i32* %4
%18 = icmp sgt i32 %17, 3
br i1 %18, label %19, label %25
19: ; preds = %16, %2
%20 = load i32, i32* @stderr
%21 = sext i32 %20 to i64
%22 = inttoptr i64 %21 to i32*
%23 = call i32 (i32*, i8*, ...) @fprintf(i32* %22, i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str, i64 0, i64 0))
%24 = call i32 @exit(i32 1)
unreachable
25: ; preds = %16
%26 = getelementptr inbounds [100 x i8], [100 x i8]* %6, i64 0, i64 0
%27 = load i8**, i8*** %5
%28 = getelementptr inbounds i8*, i8** %27, i64 1
%29 = load i8*, i8** %28
%30 = call i32 @strcpy(i8* %26, i8* %29)
%31 = getelementptr inbounds [100 x i8], [100 x i8]* %6, i64 0, i64 0
%32 = call i8* @strrchr(i8* %31, i8 signext 46)
store i8* %32, i8** %9
%33 = icmp ne i8* %32, null
br i1 %33, label %34, label %36
34: ; preds = %25
%35 = load i8*, i8** %9
store i8 0, i8* %35
br label %36
36: ; preds = %34, %25
%37 = load i32, i32* %4
%38 = icmp sge i32 %37, 3
br i1 %38, label %39, label %45
39: ; preds = %36
%40 = getelementptr inbounds [100 x i8], [100 x i8]* %7, i64 0, i64 0
%41 = load i8**, i8*** %5
%42 = getelementptr inbounds i8*, i8** %41, i64 2
%43 = load i8*, i8** %42
%44 = call i32 @strcpy(i8* %40, i8* %43)
br label %51
45: ; preds = %36
%46 = getelementptr inbounds [100 x i8], [100 x i8]* %7, i64 0, i64 0
%47 = getelementptr inbounds [100 x i8], [100 x i8]* %6, i64 0, i64 0
%48 = call i32 @strcpy(i8* %46, i8* %47)
%49 = getelementptr inbounds [100 x i8], [100 x i8]* %7, i64 0, i64 0
%50 = call i32 @strcat(i8* %49, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0))
br label %51
51: ; preds = %45, %39
%52 = getelementptr inbounds [100 x i8], [100 x i8]* %6, i64 0, i64 0
%53 = call i8* @strrchr(i8* %52, i8 signext 47)
store i8* %53, i8** %8
%54 = icmp ne i8* %53, null
br i1 %54, label %55, label %58
55: ; preds = %51
%56 = load i8*, i8** %8
%57 = getelementptr inbounds i8, i8* %56, i32 1
store i8* %57, i8** %8
br label %60
58: ; preds = %51
%59 = getelementptr inbounds [100 x i8], [100 x i8]* %6, i64 0, i64 0
store i8* %59, i8** %8
br label %60
60: ; preds = %58, %55
%61 = load i8**, i8*** %5
%62 = getelementptr inbounds i8*, i8** %61, i64 1
%63 = load i8*, i8** %62
%64 = call i32* @fopen(i8* %63, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0))
store i32* %64, i32** %10
%65 = icmp ne i32* %64, null
br i1 %65, label %75, label %66
66: ; preds = %60
%67 = load i32, i32* @stderr
%68 = sext i32 %67 to i64
%69 = inttoptr i64 %68 to i32*
%70 = load i8**, i8*** %5
%71 = getelementptr inbounds i8*, i8** %70, i64 1
%72 = load i8*, i8** %71
%73 = call i32 (i32*, i8*, ...) @fprintf(i32* %69, i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.3, i64 0, i64 0), i8* %72)
%74 = call i32 @exit(i32 1)
unreachable
75: ; preds = %60
%76 = getelementptr inbounds [100 x i8], [100 x i8]* %7, i64 0, i64 0
%77 = call i32* @fopen(i8* %76, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.4, i64 0, i64 0))
store i32* %77, i32** %11
%78 = icmp ne i32* %77, null
br i1 %78, label %88, label %79
79: ; preds = %75
%80 = load i32, i32* @stderr
%81 = sext i32 %80 to i64
%82 = inttoptr i64 %81 to i32*
%83 = load i8**, i8*** %5
%84 = getelementptr inbounds i8*, i8** %83, i64 2
%85 = load i8*, i8** %84
%86 = call i32 (i32*, i8*, ...) @fprintf(i32* %82, i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.5, i64 0, i64 0), i8* %85)
%87 = call i32 @exit(i32 1)
unreachable
88: ; preds = %75
%89 = load i32*, i32** %11
%90 = load i8*, i8** %8
%91 = call i32 (i32*, i8*, ...) @fprintf(i32* %89, i8* getelementptr inbounds ([45 x i8], [45 x i8]* @.str.6, i64 0, i64 0), i8* %90)
store i32 0, i32* %13
br label %92
92: ; preds = %107, %88
%93 = load i32*, i32** %10
%94 = call i32 @getc(i32* %93)
store i32 %94, i32* %12
%95 = load i32, i32* @EOF
%96 = icmp ne i32 %94, %95
br i1 %96, label %97, label %108
97: ; preds = %92
%98 = load i32*, i32** %11
%99 = load i32, i32* %12
%100 = call i32 (i32*, i8*, ...) @fprintf(i32* %98, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.7, i64 0, i64 0), i32 %99)
%101 = load i32, i32* %13
%102 = add nsw i32 %101, 1
store i32 %102, i32* %13
%103 = icmp eq i32 %102, 8
br i1 %103, label %104, label %107
104: ; preds = %97
%105 = load i32*, i32** %11
%106 = call i32 @putc(i8 signext 10, i32* %105)
store i32 0, i32* %13
br label %107
107: ; preds = %104, %97
br label %92
108: ; preds = %92
%109 = load i32, i32* %13
%110 = icmp sgt i32 %109, 0
br i1 %110, label %111, label %114
111: ; preds = %108
%112 = load i32*, i32** %11
%113 = call i32 @putc(i8 signext 10, i32* %112)
br label %114
114: ; preds = %111, %108
%115 = load i32*, i32** %11
%116 = load i8*, i8** %8
%117 = load i8*, i8** %8
%118 = call i32 (i32*, i8*, ...) @fprintf(i32* %115, i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str.8, i64 0, i64 0), i8* %116, i8* %117)
%119 = load i32*, i32** %10
%120 = call i32 @fclose(i32* %119)
%121 = load i32*, i32** %11
%122 = call i32 @fclose(i32* %121)
ret i32 0
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [37 x i8] c"usage: bin2c <infile> [ <outfile> ]\0A\00"
@.str.1 = [3 x i8] c".c\00"
@.str.2 = [3 x i8] c"rb\00"
@.str.3 = [23 x i8] c"error: can't open: %s\0A\00"
@.str.4 = [3 x i8] c"wb\00"
@.str.5 = [25 x i8] c"error: can't create: %s\0A\00"
@.str.6 = [45 x i8] c"#include <stdint.h>\0A\0Auint8_t %s_array[] = {\0A\00"
@EOF = global i32 0
@.str.7 = [9 x i8] c" 0x%02x,\00"
@.str.8 = [37 x i8] c"};\0A\0Aint %s_size = sizeof(%s_array);\0A\00"
define i32 @main(i32 %0, i8** nocapture %1) {
%3 = alloca [100 x i8]
%4 = alloca [100 x i8]
%5 = getelementptr inbounds [100 x i8], [100 x i8]* %3, i64 0, i64 0
%6 = getelementptr inbounds [100 x i8], [100 x i8]* %4, i64 0, i64 0
%7 = add i32 %0, -4
%8 = icmp ult i32 %7, -2
br i1 %8, label %9, label %15
9: ; preds = %2
%10 = load i32, i32* @stderr
%11 = sext i32 %10 to i64
%12 = inttoptr i64 %11 to i32*
%13 = tail call i64 @fwrite(i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str, i64 0, i64 0), i64 36, i64 1, i32* %12)
%14 = tail call i32 @exit(i32 1)
unreachable
15: ; preds = %2
%16 = getelementptr inbounds i8*, i8** %1, i64 1
%17 = load i8*, i8** %16
%18 = call i32 @strcpy(i8* %5, i8* %17)
%19 = call i8* @strrchr(i8* %5, i8 signext 46)
%20 = icmp eq i8* %19, null
br i1 %20, label %22, label %21
21: ; preds = %15
store i8 0, i8* %19
br label %22
22: ; preds = %21, %15
%23 = icmp ugt i32 %0, 2
br i1 %23, label %24, label %28
24: ; preds = %22
%25 = getelementptr inbounds i8*, i8** %1, i64 2
%26 = load i8*, i8** %25
%27 = call i32 @strcpy(i8* %6, i8* %26)
br label %31
28: ; preds = %22
%29 = call i32 @strcpy(i8* %6, i8* %5)
%30 = call i32 @strcat(i8* %6, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.1, i64 0, i64 0))
br label %31
31: ; preds = %28, %24
%32 = call i8* @strrchr(i8* %5, i8 signext 47)
%33 = icmp eq i8* %32, null
%34 = getelementptr inbounds i8, i8* %32, i64 1
%35 = select i1 %33, i8* %5, i8* %34
%36 = load i8*, i8** %16
%37 = call i32* @fopen(i8* %36, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.2, i64 0, i64 0))
%38 = icmp eq i32* %37, null
br i1 %38, label %39, label %46
39: ; preds = %31
%40 = load i32, i32* @stderr
%41 = sext i32 %40 to i64
%42 = inttoptr i64 %41 to i32*
%43 = load i8*, i8** %16
%44 = call i32 (i32*, i8*, ...) @fprintf(i32* %42, i8* getelementptr inbounds ([23 x i8], [23 x i8]* @.str.3, i64 0, i64 0), i8* %43)
%45 = call i32 @exit(i32 1)
unreachable
46: ; preds = %31
%47 = call i32* @fopen(i8* %6, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.4, i64 0, i64 0))
%48 = icmp eq i32* %47, null
br i1 %48, label %49, label %57
49: ; preds = %46
%50 = load i32, i32* @stderr
%51 = sext i32 %50 to i64
%52 = inttoptr i64 %51 to i32*
%53 = getelementptr inbounds i8*, i8** %1, i64 2
%54 = load i8*, i8** %53
%55 = call i32 (i32*, i8*, ...) @fprintf(i32* %52, i8* getelementptr inbounds ([25 x i8], [25 x i8]* @.str.5, i64 0, i64 0), i8* %54)
%56 = call i32 @exit(i32 1)
unreachable
57: ; preds = %46
%58 = call i32 (i32*, i8*, ...) @fprintf(i32* %47, i8* getelementptr inbounds ([45 x i8], [45 x i8]* @.str.6, i64 0, i64 0), i8* %35)
%59 = call i32 @getc(i32* %37)
%60 = load i32, i32* @EOF
%61 = icmp eq i32 %59, %60
br i1 %61, label %79, label %62
62: ; preds = %57, %70
%63 = phi i32 [ %72, %70 ], [ %59, %57 ]
%64 = phi i32 [ %71, %70 ], [ 0, %57 ]
%65 = call i32 (i32*, i8*, ...) @fprintf(i32* %47, i8* getelementptr inbounds ([9 x i8], [9 x i8]* @.str.7, i64 0, i64 0), i32 %63)
%66 = add nsw i32 %64, 1
%67 = icmp eq i32 %66, 8
br i1 %67, label %68, label %70
68: ; preds = %62
%69 = call i32 @putc(i8 signext 10, i32* %47)
br label %70
70: ; preds = %68, %62
%71 = phi i32 [ 0, %68 ], [ %66, %62 ]
%72 = call i32 @getc(i32* %37)
%73 = load i32, i32* @EOF
%74 = icmp eq i32 %72, %73
br i1 %74, label %75, label %62
75: ; preds = %70
%76 = icmp sgt i32 %71, 0
br i1 %76, label %77, label %79
77: ; preds = %75
%78 = call i32 @putc(i8 signext 10, i32* %47)
br label %79
79: ; preds = %57, %77, %75
%80 = call i32 (i32*, i8*, ...) @fprintf(i32* %47, i8* getelementptr inbounds ([37 x i8], [37 x i8]* @.str.8, i64 0, i64 0), i8* %35, i8* %35)
%81 = call i32 @fclose(i32* %37)
%82 = call i32 @fclose(i32* %47)
ret i32 0
}