signed int createtgafile(char *name, unsigned short int width,
                         unsigned short int height) {
  signed int filesize;
  struct _IO_FILE$link43 *ofp;
  filesize = (3 * (signed int)width * (signed int)height + 18) - 10;
  if (name == ((char *)((void *)0)))
    return 5;
  else {
    ofp = fopen(name, "w+b");
    if (ofp == ((struct _IO_FILE$link43 *)((void *)0))) {
      char msgtxt[2048l];
      sprintf(msgtxt, "Cannot create %s for output!", name);
      rt_ui_message(200, msgtxt);
      rt_ui_message(300, "Rendering Aborted.");
      return 5;
    }
    fputc(0, ofp);
    fputc(0, ofp);
    fputc(2, ofp);
    fputc(0, ofp);
    fputc(0, ofp);
    fputc(0, ofp);
    fputc(0, ofp);
    fputc(0, ofp);
    fputc(0, ofp);
    fputc(0, ofp);
    fputc(0, ofp);
    fputc(0, ofp);
    fputc((signed int)width & 255, ofp);
    fputc((signed int)width >> 8 & 255, ofp);
    fputc((signed int)height & 255, ofp);
    fputc((signed int)height >> 8 & 255, ofp);
    fputc(24, ofp);
    fputc(32, ofp);
    fseek(ofp, (signed long int)filesize, 0);
    fprintf(ofp, "9876543210");
    fclose(ofp);
  }
  return 0;
}


x86 assembly (clang, -O0):
<createtgafile>:
push   %rbp
mov    %rsp,%rbp
sub    $0x820,%rsp
mov    %dx,%ax
mov    %si,%cx
mov    %rdi,-0x10(%rbp)
mov    %cx,-0x12(%rbp)
mov    %ax,-0x14(%rbp)
movzwl -0x12(%rbp),%eax
imul   $0x3,%eax,%eax
movzwl -0x14(%rbp),%ecx
imul   %ecx,%eax
add    $0x12,%eax
sub    $0xa,%eax
mov    %eax,-0x18(%rbp)
cmpq   $0x0,-0x10(%rbp)
jne    11bb <createtgafile+0x4b>
movl   $0x5,-0x4(%rbp)
jmp    1377 <createtgafile+0x207>
mov    -0x10(%rbp),%rdi
lea    0xe3a(%rip),%rsi
mov    $0x0,%al
call   1080 <fopen@plt>
cltq
mov    %rax,-0x20(%rbp)
cmpq   $0x0,-0x20(%rbp)
jne    1229 <createtgafile+0xb9>
lea    -0x820(%rbp),%rdi
mov    -0x10(%rbp),%rdx
lea    0xe14(%rip),%rsi
mov    $0x0,%al
call   1090 <sprintf@plt>
lea    -0x820(%rbp),%rsi
mov    $0xc8,%edi
mov    $0x0,%al
call   1030 <rt_ui_message@plt>
mov    $0x12c,%edi
lea    0xe0b(%rip),%rsi
mov    $0x0,%al
call   1030 <rt_ui_message@plt>
movl   $0x5,-0x4(%rbp)
jmp    1377 <createtgafile+0x207>
mov    -0x20(%rbp),%rsi
xor    %edi,%edi
mov    $0x0,%al
call   1050 <fputc@plt>
mov    -0x20(%rbp),%rsi
xor    %edi,%edi
mov    $0x0,%al
call   1050 <fputc@plt>
mov    -0x20(%rbp),%rsi
mov    $0x2,%edi
mov    $0x0,%al
call   1050 <fputc@plt>
mov    -0x20(%rbp),%rsi
xor    %edi,%edi
mov    $0x0,%al
call   1050 <fputc@plt>
mov    -0x20(%rbp),%rsi
xor    %edi,%edi
mov    $0x0,%al
call   1050 <fputc@plt>
mov    -0x20(%rbp),%rsi
xor    %edi,%edi
mov    $0x0,%al
call   1050 <fputc@plt>
mov    -0x20(%rbp),%rsi
xor    %edi,%edi
mov    $0x0,%al
call   1050 <fputc@plt>
mov    -0x20(%rbp),%rsi
xor    %edi,%edi
mov    $0x0,%al
call   1050 <fputc@plt>
mov    -0x20(%rbp),%rsi
xor    %edi,%edi
mov    $0x0,%al
call   1050 <fputc@plt>
mov    -0x20(%rbp),%rsi
xor    %edi,%edi
mov    $0x0,%al
call   1050 <fputc@plt>
mov    -0x20(%rbp),%rsi
xor    %edi,%edi
mov    $0x0,%al
call   1050 <fputc@plt>
mov    -0x20(%rbp),%rsi
xor    %edi,%edi
mov    $0x0,%al
call   1050 <fputc@plt>
movzwl -0x12(%rbp),%edi
and    $0xff,%edi
mov    -0x20(%rbp),%rsi
mov    $0x0,%al
call   1050 <fputc@plt>
movzwl -0x12(%rbp),%edi
sar    $0x8,%edi
and    $0xff,%edi
mov    -0x20(%rbp),%rsi
mov    $0x0,%al
call   1050 <fputc@plt>
movzwl -0x14(%rbp),%edi
and    $0xff,%edi
mov    -0x20(%rbp),%rsi
mov    $0x0,%al
call   1050 <fputc@plt>
movzwl -0x14(%rbp),%edi
sar    $0x8,%edi
and    $0xff,%edi
mov    -0x20(%rbp),%rsi
mov    $0x0,%al
call   1050 <fputc@plt>
mov    -0x20(%rbp),%rsi
mov    $0x18,%edi
mov    $0x0,%al
call   1050 <fputc@plt>
mov    -0x20(%rbp),%rsi
mov    $0x20,%edi
mov    $0x0,%al
call   1050 <fputc@plt>
mov    -0x20(%rbp),%rdi
movslq -0x18(%rbp),%rsi
xor    %edx,%edx
mov    $0x0,%al
call   1070 <fseek@plt>
mov    -0x20(%rbp),%rdi
lea    0xcd6(%rip),%rsi
mov    $0x0,%al
call   1060 <fprintf@plt>
mov    -0x20(%rbp),%rdi
mov    $0x0,%al
call   1040 <fclose@plt>
movl   $0x0,-0x4(%rbp)
mov    -0x4(%rbp),%eax
add    $0x820,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<createtgafile>:
push   %rbp
push   %r15
push   %r14
push   %rbx
sub    $0x808,%rsp
mov    $0x5,%ebx
test   %rdi,%rdi
je     130f <createtgafile+0x19f>
mov    %edx,%r14d
mov    %esi,%r15d
mov    %rdi,%rbp
lea    0xe65(%rip),%rsi
xor    %eax,%eax
call   1080 <fopen@plt>
test   %eax,%eax
je     12d6 <createtgafile+0x166>
mov    %r15d,%ecx
imul   %r14d,%ecx
lea    (%rcx,%rcx,2),%ebp
add    $0x8,%ebp
movslq %eax,%rbx
xor    %edi,%edi
mov    %rbx,%rsi
xor    %eax,%eax
call   1050 <fputc@plt>
xor    %edi,%edi
mov    %rbx,%rsi
xor    %eax,%eax
call   1050 <fputc@plt>
mov    $0x2,%edi
mov    %rbx,%rsi
xor    %eax,%eax
call   1050 <fputc@plt>
xor    %edi,%edi
mov    %rbx,%rsi
xor    %eax,%eax
call   1050 <fputc@plt>
xor    %edi,%edi
mov    %rbx,%rsi
xor    %eax,%eax
call   1050 <fputc@plt>
xor    %edi,%edi
mov    %rbx,%rsi
xor    %eax,%eax
call   1050 <fputc@plt>
xor    %edi,%edi
mov    %rbx,%rsi
xor    %eax,%eax
call   1050 <fputc@plt>
xor    %edi,%edi
mov    %rbx,%rsi
xor    %eax,%eax
call   1050 <fputc@plt>
xor    %edi,%edi
mov    %rbx,%rsi
xor    %eax,%eax
call   1050 <fputc@plt>
xor    %edi,%edi
mov    %rbx,%rsi
xor    %eax,%eax
call   1050 <fputc@plt>
xor    %edi,%edi
mov    %rbx,%rsi
xor    %eax,%eax
call   1050 <fputc@plt>
xor    %edi,%edi
mov    %rbx,%rsi
xor    %eax,%eax
call   1050 <fputc@plt>
movzbl %r15b,%edi
mov    %rbx,%rsi
xor    %eax,%eax
call   1050 <fputc@plt>
shr    $0x8,%r15d
mov    %r15d,%edi
mov    %rbx,%rsi
xor    %eax,%eax
call   1050 <fputc@plt>
movzbl %r14b,%edi
mov    %rbx,%rsi
xor    %eax,%eax
call   1050 <fputc@plt>
shr    $0x8,%r14d
mov    %r14d,%edi
mov    %rbx,%rsi
xor    %eax,%eax
call   1050 <fputc@plt>
mov    $0x18,%edi
mov    %rbx,%rsi
xor    %eax,%eax
call   1050 <fputc@plt>
mov    $0x20,%edi
mov    %rbx,%rsi
xor    %eax,%eax
call   1050 <fputc@plt>
mov    %ebp,%esi
mov    %rbx,%rdi
xor    %edx,%edx
xor    %eax,%eax
call   1070 <fseek@plt>
lea    0xd76(%rip),%rsi
mov    %rbx,%rdi
xor    %eax,%eax
call   1060 <fprintf@plt>
mov    %rbx,%rdi
xor    %eax,%eax
call   1040 <fclose@plt>
xor    %ebx,%ebx
jmp    130f <createtgafile+0x19f>
lea    0xd27(%rip),%rsi
mov    %rsp,%r14
mov    %r14,%rdi
mov    %rbp,%rdx
xor    %eax,%eax
call   1090 <sprintf@plt>
mov    $0xc8,%edi
mov    %r14,%rsi
xor    %eax,%eax
call   1030 <rt_ui_message@plt>
lea    0xd1e(%rip),%rsi
mov    $0x12c,%edi
xor    %eax,%eax
call   1030 <rt_ui_message@plt>
mov    %ebx,%eax
add    $0x808,%rsp
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
%"struct._IO_FILE$link43" = type opaque
@.str = [4 x i8] c"w+b\00"
@.str.1 = [29 x i8] c"Cannot create %s for output!\00"
@.str.2 = [19 x i8] c"Rendering Aborted.\00"
@.str.3 = [11 x i8] c"9876543210\00"
define i32 @createtgafile(i8* %0, i16 zeroext %1, i16 zeroext %2) {
%4 = alloca i32
%5 = alloca i8*
%6 = alloca i16
%7 = alloca i16
%8 = alloca i32
%9 = alloca %"struct._IO_FILE$link43"*
%10 = alloca [2048 x i8]
store i8* %0, i8** %5
store i16 %1, i16* %6
store i16 %2, i16* %7
%11 = load i16, i16* %6
%12 = zext i16 %11 to i32
%13 = mul nsw i32 3, %12
%14 = load i16, i16* %7
%15 = zext i16 %14 to i32
%16 = mul nsw i32 %13, %15
%17 = add nsw i32 %16, 18
%18 = sub nsw i32 %17, 10
store i32 %18, i32* %8
%19 = load i8*, i8** %5
%20 = icmp eq i8* %19, null
br i1 %20, label %21, label %22
21: ; preds = %3
store i32 5, i32* %4
br label %96
22: ; preds = %3
%23 = load i8*, i8** %5
%24 = call i32 (i8*, i8*, ...) bitcast (i32 (...)* @fopen to i32 (i8*, i8*, ...)*)(i8* %23, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0))
%25 = sext i32 %24 to i64
%26 = inttoptr i64 %25 to %"struct._IO_FILE$link43"*
store %"struct._IO_FILE$link43"* %26, %"struct._IO_FILE$link43"** %9
%27 = load %"struct._IO_FILE$link43"*, %"struct._IO_FILE$link43"** %9
%28 = icmp eq %"struct._IO_FILE$link43"* %27, null
br i1 %28, label %29, label %36
29: ; preds = %22
%30 = getelementptr inbounds [2048 x i8], [2048 x i8]* %10, i64 0, i64 0
%31 = load i8*, i8** %5
%32 = call i32 (i8*, i8*, ...) @sprintf(i8* %30, i8* getelementptr inbounds ([29 x i8], [29 x i8]* @.str.1, i64 0, i64 0), i8* %31)
%33 = getelementptr inbounds [2048 x i8], [2048 x i8]* %10, i64 0, i64 0
%34 = call i32 (i32, i8*, ...) bitcast (i32 (...)* @rt_ui_message to i32 (i32, i8*, ...)*)(i32 200, i8* %33)
%35 = call i32 (i32, i8*, ...) bitcast (i32 (...)* @rt_ui_message to i32 (i32, i8*, ...)*)(i32 300, i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.2, i64 0, i64 0))
store i32 5, i32* %4
br label %96
36: ; preds = %22
%37 = load %"struct._IO_FILE$link43"*, %"struct._IO_FILE$link43"** %9
%38 = call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 0, %"struct._IO_FILE$link43"* %37)
%39 = load %"struct._IO_FILE$link43"*, %"struct._IO_FILE$link43"** %9
%40 = call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 0, %"struct._IO_FILE$link43"* %39)
%41 = load %"struct._IO_FILE$link43"*, %"struct._IO_FILE$link43"** %9
%42 = call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 2, %"struct._IO_FILE$link43"* %41)
%43 = load %"struct._IO_FILE$link43"*, %"struct._IO_FILE$link43"** %9
%44 = call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 0, %"struct._IO_FILE$link43"* %43)
%45 = load %"struct._IO_FILE$link43"*, %"struct._IO_FILE$link43"** %9
%46 = call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 0, %"struct._IO_FILE$link43"* %45)
%47 = load %"struct._IO_FILE$link43"*, %"struct._IO_FILE$link43"** %9
%48 = call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 0, %"struct._IO_FILE$link43"* %47)
%49 = load %"struct._IO_FILE$link43"*, %"struct._IO_FILE$link43"** %9
%50 = call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 0, %"struct._IO_FILE$link43"* %49)
%51 = load %"struct._IO_FILE$link43"*, %"struct._IO_FILE$link43"** %9
%52 = call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 0, %"struct._IO_FILE$link43"* %51)
%53 = load %"struct._IO_FILE$link43"*, %"struct._IO_FILE$link43"** %9
%54 = call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 0, %"struct._IO_FILE$link43"* %53)
%55 = load %"struct._IO_FILE$link43"*, %"struct._IO_FILE$link43"** %9
%56 = call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 0, %"struct._IO_FILE$link43"* %55)
%57 = load %"struct._IO_FILE$link43"*, %"struct._IO_FILE$link43"** %9
%58 = call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 0, %"struct._IO_FILE$link43"* %57)
%59 = load %"struct._IO_FILE$link43"*, %"struct._IO_FILE$link43"** %9
%60 = call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 0, %"struct._IO_FILE$link43"* %59)
%61 = load i16, i16* %6
%62 = zext i16 %61 to i32
%63 = and i32 %62, 255
%64 = load %"struct._IO_FILE$link43"*, %"struct._IO_FILE$link43"** %9
%65 = call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 %63, %"struct._IO_FILE$link43"* %64)
%66 = load i16, i16* %6
%67 = zext i16 %66 to i32
%68 = ashr i32 %67, 8
%69 = and i32 %68, 255
%70 = load %"struct._IO_FILE$link43"*, %"struct._IO_FILE$link43"** %9
%71 = call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 %69, %"struct._IO_FILE$link43"* %70)
%72 = load i16, i16* %7
%73 = zext i16 %72 to i32
%74 = and i32 %73, 255
%75 = load %"struct._IO_FILE$link43"*, %"struct._IO_FILE$link43"** %9
%76 = call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 %74, %"struct._IO_FILE$link43"* %75)
%77 = load i16, i16* %7
%78 = zext i16 %77 to i32
%79 = ashr i32 %78, 8
%80 = and i32 %79, 255
%81 = load %"struct._IO_FILE$link43"*, %"struct._IO_FILE$link43"** %9
%82 = call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 %80, %"struct._IO_FILE$link43"* %81)
%83 = load %"struct._IO_FILE$link43"*, %"struct._IO_FILE$link43"** %9
%84 = call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 24, %"struct._IO_FILE$link43"* %83)
%85 = load %"struct._IO_FILE$link43"*, %"struct._IO_FILE$link43"** %9
%86 = call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 32, %"struct._IO_FILE$link43"* %85)
%87 = load %"struct._IO_FILE$link43"*, %"struct._IO_FILE$link43"** %9
%88 = load i32, i32* %8
%89 = sext i32 %88 to i64
%90 = call i32 (%"struct._IO_FILE$link43"*, i64, i32, ...) bitcast (i32 (...)* @fseek to i32 (%"struct._IO_FILE$link43"*, i64, i32, ...)*)(%"struct._IO_FILE$link43"* %87, i64 %89, i32 0)
%91 = load %"struct._IO_FILE$link43"*, %"struct._IO_FILE$link43"** %9
%92 = call i32 (%"struct._IO_FILE$link43"*, i8*, ...) bitcast (i32 (...)* @fprintf to i32 (%"struct._IO_FILE$link43"*, i8*, ...)*)(%"struct._IO_FILE$link43"* %91, i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.3, i64 0, i64 0))
%93 = load %"struct._IO_FILE$link43"*, %"struct._IO_FILE$link43"** %9
%94 = call i32 (%"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fclose to i32 (%"struct._IO_FILE$link43"*, ...)*)(%"struct._IO_FILE$link43"* %93)
br label %95
95: ; preds = %36
store i32 0, i32* %4
br label %96
96: ; preds = %95, %29, %21
%97 = load i32, i32* %4
ret i32 %97
}

LLVM IR (-O2):
%"struct._IO_FILE$link43" = type opaque
@.str = [4 x i8] c"w+b\00"
@.str.1 = [29 x i8] c"Cannot create %s for output!\00"
@.str.2 = [19 x i8] c"Rendering Aborted.\00"
@.str.3 = [11 x i8] c"9876543210\00"
define i32 @createtgafile(i8* %0, i16 zeroext %1, i16 zeroext %2) {
%4 = alloca [2048 x i8]
%5 = zext i16 %1 to i32
%6 = mul nuw nsw i32 %5, 3
%7 = zext i16 %2 to i32
%8 = mul nsw i32 %6, %7
%9 = add nuw nsw i32 %8, 8
%10 = icmp eq i8* %0, null
br i1 %10, label %48, label %11
11: ; preds = %3
%12 = tail call i32 (i8*, i8*, ...) bitcast (i32 (...)* @fopen to i32 (i8*, i8*, ...)*)(i8* %0, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0))
%13 = sext i32 %12 to i64
%14 = inttoptr i64 %13 to %"struct._IO_FILE$link43"*
%15 = icmp eq i32 %12, 0
br i1 %15, label %16, label %21
16: ; preds = %11
%17 = getelementptr inbounds [2048 x i8], [2048 x i8]* %4, i64 0, i64 0
%18 = call i32 (i8*, i8*, ...) @sprintf(i8* %17, i8* dereferenceable(1) getelementptr inbounds ([29 x i8], [29 x i8]* @.str.1, i64 0, i64 0), i8* %0)
%19 = call i32 (i32, i8*, ...) bitcast (i32 (...)* @rt_ui_message to i32 (i32, i8*, ...)*)(i32 200, i8* %17)
%20 = call i32 (i32, i8*, ...) bitcast (i32 (...)* @rt_ui_message to i32 (i32, i8*, ...)*)(i32 300, i8* getelementptr inbounds ([19 x i8], [19 x i8]* @.str.2, i64 0, i64 0))
br label %48
21: ; preds = %11
%22 = tail call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 0, %"struct._IO_FILE$link43"* %14)
%23 = tail call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 0, %"struct._IO_FILE$link43"* %14)
%24 = tail call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 2, %"struct._IO_FILE$link43"* %14)
%25 = tail call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 0, %"struct._IO_FILE$link43"* %14)
%26 = tail call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 0, %"struct._IO_FILE$link43"* %14)
%27 = tail call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 0, %"struct._IO_FILE$link43"* %14)
%28 = tail call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 0, %"struct._IO_FILE$link43"* %14)
%29 = tail call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 0, %"struct._IO_FILE$link43"* %14)
%30 = tail call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 0, %"struct._IO_FILE$link43"* %14)
%31 = tail call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 0, %"struct._IO_FILE$link43"* %14)
%32 = tail call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 0, %"struct._IO_FILE$link43"* %14)
%33 = tail call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 0, %"struct._IO_FILE$link43"* %14)
%34 = and i32 %5, 255
%35 = tail call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 %34, %"struct._IO_FILE$link43"* %14)
%36 = lshr i32 %5, 8
%37 = tail call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 %36, %"struct._IO_FILE$link43"* %14)
%38 = and i32 %7, 255
%39 = tail call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 %38, %"struct._IO_FILE$link43"* %14)
%40 = lshr i32 %7, 8
%41 = tail call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 %40, %"struct._IO_FILE$link43"* %14)
%42 = tail call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 24, %"struct._IO_FILE$link43"* %14)
%43 = tail call i32 (i32, %"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fputc to i32 (i32, %"struct._IO_FILE$link43"*, ...)*)(i32 32, %"struct._IO_FILE$link43"* %14)
%44 = zext i32 %9 to i64
%45 = tail call i32 (%"struct._IO_FILE$link43"*, i64, i32, ...) bitcast (i32 (...)* @fseek to i32 (%"struct._IO_FILE$link43"*, i64, i32, ...)*)(%"struct._IO_FILE$link43"* %14, i64 %44, i32 0)
%46 = tail call i32 (%"struct._IO_FILE$link43"*, i8*, ...) bitcast (i32 (...)* @fprintf to i32 (%"struct._IO_FILE$link43"*, i8*, ...)*)(%"struct._IO_FILE$link43"* %14, i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str.3, i64 0, i64 0))
%47 = tail call i32 (%"struct._IO_FILE$link43"*, ...) bitcast (i32 (...)* @fclose to i32 (%"struct._IO_FILE$link43"*, ...)*)(%"struct._IO_FILE$link43"* %14)
br label %48
48: ; preds = %3, %21, %16
%49 = phi i32 [ 5, %16 ], [ 0, %21 ], [ 5, %3 ]
ret i32 %49
}