#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 /*<<< orphan*/ fprintf(int /*<<< orphan*/ *, char *, ...);
void printhex(FILE *output, const char *buf, size_t size) {
  int i;
  char *ptr;
  char c;
  size_t tmp;
  while (size) {
    if (size > 1) {
      fprintf(output, "%08X-%08X ", (unsigned int)buf,
              (unsigned int)buf + (size > 15 ? 15 : size - 1));
    } else
      fprintf(output, "%08X %8.8s ", (unsigned int)buf, "");
    ptr = (char *)buf;
    tmp = size;
    for (i = 8; i && tmp; i--, tmp--)
      fprintf(output, " %02X", (unsigned char)*ptr++);
    for (; i; i--)
      fprintf(output, "   ");
    fprintf(output, " ");
    if (tmp) {
      for (i = 8; i && tmp; i--, tmp--)
        fprintf(output, " %02X", (unsigned char)*ptr++);
    } else
      i = 8;
    for (; i; i--)
      fprintf(output, "   ");
    fprintf(output, "  ");
    for (i = 16; i && size; i--, size--) {
      c = *buf++;
      fprintf(output, "%c", c < 32 ? '.' : c);
    }
    fprintf(output, "\n");
  }
}


x86 assembly (clang, -O0):
<printhex>:
push   %rbp
mov    %rsp,%rbp
sub    $0x70,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
cmpq   $0x0,-0x18(%rbp)
je     13f7 <printhex+0x2e7>
cmpq   $0x1,-0x18(%rbp)
jbe    119d <printhex+0x8d>
mov    -0x8(%rbp),%rax
mov    %rax,-0x50(%rbp)
mov    -0x10(%rbp),%rax
mov    %eax,-0x44(%rbp)
mov    -0x10(%rbp),%rax
mov    %eax,%eax
mov    %rax,-0x40(%rbp)
cmpq   $0xf,-0x18(%rbp)
jbe    116c <printhex+0x5c>
mov    $0xf,%eax
mov    %rax,-0x58(%rbp)
jmp    1178 <printhex+0x68>
mov    -0x18(%rbp),%rax
sub    $0x1,%rax
mov    %rax,-0x58(%rbp)
mov    -0x44(%rbp),%edx
mov    -0x50(%rbp),%rdi
mov    -0x40(%rbp),%rcx
mov    -0x58(%rbp),%rax
add    %rax,%rcx
lea    0xe6f(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
jmp    11bc <printhex+0xac>
mov    -0x8(%rbp),%rdi
mov    -0x10(%rbp),%rax
mov    %eax,%edx
lea    0xe5d(%rip),%rsi
lea    0xe70(%rip),%rcx
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    -0x10(%rbp),%rax
mov    %rax,-0x28(%rbp)
mov    -0x18(%rbp),%rax
mov    %rax,-0x38(%rbp)
movl   $0x8,-0x1c(%rbp)
xor    %eax,%eax
cmpl   $0x0,-0x1c(%rbp)
mov    %al,-0x59(%rbp)
je     11ed <printhex+0xdd>
cmpq   $0x0,-0x38(%rbp)
setne  %al
mov    %al,-0x59(%rbp)
mov    -0x59(%rbp),%al
test   $0x1,%al
jne    11fd <printhex+0xed>
jmp    123b <printhex+0x12b>
mov    -0x8(%rbp),%rdi
mov    -0x28(%rbp),%rax
mov    %rax,%rcx
add    $0x1,%rcx
mov    %rcx,-0x28(%rbp)
movzbl (%rax),%edx
lea    0xdfd(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    -0x1c(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x1c(%rbp)
mov    -0x38(%rbp),%rax
add    $0xffffffffffffffff,%rax
mov    %rax,-0x38(%rbp)
jmp    11d3 <printhex+0xc3>
jmp    1240 <printhex+0x130>
cmpl   $0x0,-0x1c(%rbp)
je     126a <printhex+0x15a>
mov    -0x8(%rbp),%rdi
lea    0xdc8(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    -0x1c(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x1c(%rbp)
jmp    1240 <printhex+0x130>
mov    -0x8(%rbp),%rdi
lea    0xdaa(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
cmpq   $0x0,-0x38(%rbp)
je     12fb <printhex+0x1eb>
movl   $0x8,-0x1c(%rbp)
xor    %eax,%eax
cmpl   $0x0,-0x1c(%rbp)
mov    %al,-0x5a(%rbp)
je     12a8 <printhex+0x198>
cmpq   $0x0,-0x38(%rbp)
setne  %al
mov    %al,-0x5a(%rbp)
mov    -0x5a(%rbp),%al
test   $0x1,%al
jne    12b8 <printhex+0x1a8>
jmp    12f6 <printhex+0x1e6>
mov    -0x8(%rbp),%rdi
mov    -0x28(%rbp),%rax
mov    %rax,%rcx
add    $0x1,%rcx
mov    %rcx,-0x28(%rbp)
movzbl (%rax),%edx
lea    0xd42(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    -0x1c(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x1c(%rbp)
mov    -0x38(%rbp),%rax
add    $0xffffffffffffffff,%rax
mov    %rax,-0x38(%rbp)
jmp    128e <printhex+0x17e>
jmp    1302 <printhex+0x1f2>
movl   $0x8,-0x1c(%rbp)
jmp    1307 <printhex+0x1f7>
cmpl   $0x0,-0x1c(%rbp)
je     1331 <printhex+0x221>
mov    -0x8(%rbp),%rdi
lea    0xd01(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    -0x1c(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x1c(%rbp)
jmp    1307 <printhex+0x1f7>
mov    -0x8(%rbp),%rdi
lea    0xce2(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
movl   $0x10,-0x1c(%rbp)
xor    %eax,%eax
cmpl   $0x0,-0x1c(%rbp)
mov    %al,-0x5b(%rbp)
je     1364 <printhex+0x254>
cmpq   $0x0,-0x18(%rbp)
setne  %al
mov    %al,-0x5b(%rbp)
mov    -0x5b(%rbp),%al
test   $0x1,%al
jne    1374 <printhex+0x264>
jmp    13e0 <printhex+0x2d0>
mov    -0x10(%rbp),%rax
mov    %rax,%rcx
add    $0x1,%rcx
mov    %rcx,-0x10(%rbp)
mov    (%rax),%al
mov    %al,-0x29(%rbp)
mov    -0x8(%rbp),%rax
mov    %rax,-0x68(%rbp)
movsbl -0x29(%rbp),%eax
cmp    $0x20,%eax
jge    13aa <printhex+0x29a>
mov    $0x2e,%eax
mov    %eax,-0x6c(%rbp)
jmp    13b1 <printhex+0x2a1>
movsbl -0x29(%rbp),%eax
mov    %eax,-0x6c(%rbp)
mov    -0x68(%rbp),%rdi
mov    -0x6c(%rbp),%edx
lea    0xc62(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    -0x1c(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0x1c(%rbp)
mov    -0x18(%rbp),%rax
add    $0xffffffffffffffff,%rax
mov    %rax,-0x18(%rbp)
jmp    134a <printhex+0x23a>
mov    -0x8(%rbp),%rdi
lea    0xc39(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
jmp    1124 <printhex+0x14>
add    $0x70,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<printhex>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
sub    $0x18,%rsp
mov    %rdx,%r12
mov    %rsi,%rbx
mov    %rdi,%r15
jmp    1164 <printhex+0x34>
nopl   0x0(%rax)
xor    %r12d,%r12d
mov    (%rsp),%rbx
mov    $0xa,%edi
mov    %r15,%rsi
call   1030 <fputc@plt>
cmp    $0x1,%r12
je     11a0 <printhex+0x70>
test   %r12,%r12
je     133a <printhex+0x20a>
mov    %ebx,%eax
lea    -0x1(%r12),%rcx
cmp    $0x10,%r12
mov    $0xf,%edx
cmovae %rdx,%rcx
add    %rax,%rcx
mov    %r15,%rdi
lea    0xe6c(%rip),%rsi
mov    %ebx,%edx
jmp    11b3 <printhex+0x83>
nopl   0x0(%rax,%rax,1)
mov    %r15,%rdi
lea    0xe61(%rip),%rsi
mov    %ebx,%edx
lea    0xe6d(%rip),%rcx
xor    %eax,%eax
call   1040 <fprintf@plt>
mov    %r12,0x10(%rsp)
lea    -0x1(%r12),%rax
mov    %rax,0x8(%rsp)
mov    $0xfffffff9,%eax
mov    $0x1,%ecx
xor    %ebp,%ebp
cs nopw 0x0(%rax,%rax,1)
nop
mov    %eax,%r12d
mov    %rcx,%r13
movzbl (%rbx,%rbp,1),%edx
mov    %r15,%rdi
lea    0xe23(%rip),%rsi
xor    %eax,%eax
call   1040 <fprintf@plt>
lea    0x1(%rbp),%r14
cmp    $0x7,%ebp
je     1217 <printhex+0xe7>
lea    0x1(%r12),%eax
lea    0x1(%r13),%rcx
cmp    %rbp,0x8(%rsp)
mov    %r14,%rbp
jne    11e0 <printhex+0xb0>
mov    %rbx,(%rsp)
cmp    $0x8,%r14d
lea    0xdf7(%rip),%rbx
je     124a <printhex+0x11a>
nopl   0x0(%rax,%rax,1)
mov    $0x3,%esi
mov    $0x1,%edx
mov    %rbx,%rdi
mov    %r15,%rcx
call   1050 <fwrite@plt>
inc    %r12d
jne    1230 <printhex+0x100>
mov    $0x20,%edi
mov    %r15,%rsi
call   1030 <fputc@plt>
mov    $0x8,%ebp
mov    0x10(%rsp),%r12
cmp    %r14,%r12
je     12b0 <printhex+0x180>
mov    (%rsp),%r14
mov    $0x8,%ebp
nop
mov    %ebp,%ebx
movzbl (%r14,%r13,1),%edx
mov    %r15,%rdi
lea    0xd96(%rip),%rsi
xor    %eax,%eax
call   1040 <fprintf@plt>
lea    -0x1(%rbx),%ebp
cmp    $0x1,%ebx
je     129e <printhex+0x16e>
lea    0x1(%r13),%rax
cmp    %r13,0x8(%rsp)
mov    %rax,%r13
jne    1270 <printhex+0x140>
test   %ebp,%ebp
lea    0xd76(%rip),%rbx
je     12ca <printhex+0x19a>
nopl   0x0(%rax)
mov    $0x3,%esi
mov    $0x1,%edx
mov    %rbx,%rdi
mov    %r15,%rcx
call   1050 <fwrite@plt>
add    $0xffffffff,%ebp
jne    12b0 <printhex+0x180>
mov    $0x2,%esi
mov    $0x1,%edx
lea    0xd43(%rip),%rdi
mov    %r15,%rcx
call   1050 <fwrite@plt>
test   %r12,%r12
je     1150 <printhex+0x20>
xor    %ebp,%ebp
mov    $0x2e,%ebx
cs nopw 0x0(%rax,%rax,1)
nopl   (%rax)
mov    (%rsp),%rax
movzbl (%rax,%rbp,1),%eax
cmp    $0x20,%al
cmovl  %ebx,%eax
movzbl %al,%edi
mov    %r15,%rsi
call   1030 <fputc@plt>
lea    0x1(%rbp),%rax
cmp    $0xf,%ebp
je     132b <printhex+0x1fb>
cmp    %rbp,0x8(%rsp)
mov    %rax,%rbp
jne    1300 <printhex+0x1d0>
mov    (%rsp),%rbx
add    %rax,%rbx
sub    %rax,%r12
jmp    1157 <printhex+0x27>
add    $0x18,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
ret

LLVM IR (-O0):
@.str = [11 x i8] c"%08X-%08X \00"
@.str.1 = [12 x i8] c"%08X %8.8s \00"
@.str.2 = [1 x i8] zeroinitializer
@.str.3 = [6 x i8] c" %02X\00"
@.str.4 = [4 x i8] c" \00"
@.str.5 = [2 x i8] c" \00"
@.str.6 = [3 x i8] c" \00"
@.str.7 = [3 x i8] c"%c\00"
@.str.8 = [2 x i8] c"\0A\00"
define void @printhex(i32* %0, i8* %1, i64 %2) {
%4 = alloca i32*
%5 = alloca i8*
%6 = alloca i64
%7 = alloca i32
%8 = alloca i8*
%9 = alloca i8
%10 = alloca i64
store i32* %0, i32** %4
store i8* %1, i8** %5
store i64 %2, i64* %6
br label %11
11: ; preds = %141, %3
%12 = load i64, i64* %6
%13 = icmp ne i64 %12, 0
br i1 %13, label %14, label %144
14: ; preds = %11
%15 = load i64, i64* %6
%16 = icmp ugt i64 %15, 1
br i1 %16, label %17, label %34
17: ; preds = %14
%18 = load i32*, i32** %4
%19 = load i8*, i8** %5
%20 = ptrtoint i8* %19 to i32
%21 = load i8*, i8** %5
%22 = ptrtoint i8* %21 to i32
%23 = zext i32 %22 to i64
%24 = load i64, i64* %6
%25 = icmp ugt i64 %24, 15
br i1 %25, label %26, label %27
26: ; preds = %17
br label %30
27: ; preds = %17
%28 = load i64, i64* %6
%29 = sub i64 %28, 1
br label %30
30: ; preds = %27, %26
%31 = phi i64 [ 15, %26 ], [ %29, %27 ]
%32 = add i64 %23, %31
%33 = call i32 (i32*, i8*, ...) @fprintf(i32* %18, i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i64 0, i64 0), i32 %20, i64 %32)
br label %39
34: ; preds = %14
%35 = load i32*, i32** %4
%36 = load i8*, i8** %5
%37 = ptrtoint i8* %36 to i32
%38 = call i32 (i32*, i8*, ...) @fprintf(i32* %35, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 %37, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.2, i64 0, i64 0))
br label %39
39: ; preds = %34, %30
%40 = load i8*, i8** %5
store i8* %40, i8** %8
%41 = load i64, i64* %6
store i64 %41, i64* %10
store i32 8, i32* %7
br label %42
42: ; preds = %57, %39
%43 = load i32, i32* %7
%44 = icmp ne i32 %43, 0
br i1 %44, label %45, label %48
45: ; preds = %42
%46 = load i64, i64* %10
%47 = icmp ne i64 %46, 0
br label %48
48: ; preds = %45, %42
%49 = phi i1 [ false, %42 ], [ %47, %45 ]
br i1 %49, label %50, label %62
50: ; preds = %48
%51 = load i32*, i32** %4
%52 = load i8*, i8** %8
%53 = getelementptr inbounds i8, i8* %52, i32 1
store i8* %53, i8** %8
%54 = load i8, i8* %52
%55 = zext i8 %54 to i32
%56 = call i32 (i32*, i8*, ...) @fprintf(i32* %51, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.3, i64 0, i64 0), i32 %55)
br label %57
57: ; preds = %50
%58 = load i32, i32* %7
%59 = add nsw i32 %58, -1
store i32 %59, i32* %7
%60 = load i64, i64* %10
%61 = add i64 %60, -1
store i64 %61, i64* %10
br label %42
62: ; preds = %48
br label %63
63: ; preds = %69, %62
%64 = load i32, i32* %7
%65 = icmp ne i32 %64, 0
br i1 %65, label %66, label %72
66: ; preds = %63
%67 = load i32*, i32** %4
%68 = call i32 (i32*, i8*, ...) @fprintf(i32* %67, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0))
br label %69
69: ; preds = %66
%70 = load i32, i32* %7
%71 = add nsw i32 %70, -1
store i32 %71, i32* %7
br label %63
72: ; preds = %63
%73 = load i32*, i32** %4
%74 = call i32 (i32*, i8*, ...) @fprintf(i32* %73, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.5, i64 0, i64 0))
%75 = load i64, i64* %10
%76 = icmp ne i64 %75, 0
br i1 %76, label %77, label %99
77: ; preds = %72
store i32 8, i32* %7
br label %78
78: ; preds = %93, %77
%79 = load i32, i32* %7
%80 = icmp ne i32 %79, 0
br i1 %80, label %81, label %84
81: ; preds = %78
%82 = load i64, i64* %10
%83 = icmp ne i64 %82, 0
br label %84
84: ; preds = %81, %78
%85 = phi i1 [ false, %78 ], [ %83, %81 ]
br i1 %85, label %86, label %98
86: ; preds = %84
%87 = load i32*, i32** %4
%88 = load i8*, i8** %8
%89 = getelementptr inbounds i8, i8* %88, i32 1
store i8* %89, i8** %8
%90 = load i8, i8* %88
%91 = zext i8 %90 to i32
%92 = call i32 (i32*, i8*, ...) @fprintf(i32* %87, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.3, i64 0, i64 0), i32 %91)
br label %93
93: ; preds = %86
%94 = load i32, i32* %7
%95 = add nsw i32 %94, -1
store i32 %95, i32* %7
%96 = load i64, i64* %10
%97 = add i64 %96, -1
store i64 %97, i64* %10
br label %78
98: ; preds = %84
br label %100
99: ; preds = %72
store i32 8, i32* %7
br label %100
100: ; preds = %99, %98
br label %101
101: ; preds = %107, %100
%102 = load i32, i32* %7
%103 = icmp ne i32 %102, 0
br i1 %103, label %104, label %110
104: ; preds = %101
%105 = load i32*, i32** %4
%106 = call i32 (i32*, i8*, ...) @fprintf(i32* %105, i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0))
br label %107
107: ; preds = %104
%108 = load i32, i32* %7
%109 = add nsw i32 %108, -1
store i32 %109, i32* %7
br label %101
110: ; preds = %101
%111 = load i32*, i32** %4
%112 = call i32 (i32*, i8*, ...) @fprintf(i32* %111, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0))
store i32 16, i32* %7
br label %113
113: ; preds = %136, %110
%114 = load i32, i32* %7
%115 = icmp ne i32 %114, 0
br i1 %115, label %116, label %119
116: ; preds = %113
%117 = load i64, i64* %6
%118 = icmp ne i64 %117, 0
br label %119
119: ; preds = %116, %113
%120 = phi i1 [ false, %113 ], [ %118, %116 ]
br i1 %120, label %121, label %141
121: ; preds = %119
%122 = load i8*, i8** %5
%123 = getelementptr inbounds i8, i8* %122, i32 1
store i8* %123, i8** %5
%124 = load i8, i8* %122
store i8 %124, i8* %9
%125 = load i32*, i32** %4
%126 = load i8, i8* %9
%127 = sext i8 %126 to i32
%128 = icmp slt i32 %127, 32
br i1 %128, label %129, label %130
129: ; preds = %121
br label %133
130: ; preds = %121
%131 = load i8, i8* %9
%132 = sext i8 %131 to i32
br label %133
133: ; preds = %130, %129
%134 = phi i32 [ 46, %129 ], [ %132, %130 ]
%135 = call i32 (i32*, i8*, ...) @fprintf(i32* %125, i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.7, i64 0, i64 0), i32 %134)
br label %136
136: ; preds = %133
%137 = load i32, i32* %7
%138 = add nsw i32 %137, -1
store i32 %138, i32* %7
%139 = load i64, i64* %6
%140 = add i64 %139, -1
store i64 %140, i64* %6
br label %113
141: ; preds = %119
%142 = load i32*, i32** %4
%143 = call i32 (i32*, i8*, ...) @fprintf(i32* %142, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.8, i64 0, i64 0))
br label %11
144: ; preds = %11
ret void
}

LLVM IR (-O2):
@.str = [11 x i8] c"%08X-%08X \00"
@.str.1 = [12 x i8] c"%08X %8.8s \00"
@.str.2 = [1 x i8] zeroinitializer
@.str.3 = [6 x i8] c" %02X\00"
@.str.4 = [4 x i8] c" \00"
@.str.6 = [3 x i8] c" \00"
define void @printhex(i32* nocapture %0, i8* %1, i64 %2) {
br label %4
4: ; preds = %84, %3
%5 = phi i64 [ %2, %3 ], [ %85, %84 ]
%6 = phi i8* [ %1, %3 ], [ %86, %84 ]
switch i64 %5, label %7 [
i64 0, label %88
i64 1, label %16
]
7: ; preds = %4
%8 = ptrtoint i8* %6 to i64
%9 = trunc i64 %8 to i32
%10 = and i64 %8, 4294967295
%11 = icmp ugt i64 %5, 15
%12 = add i64 %5, -1
%13 = select i1 %11, i64 15, i64 %12
%14 = add nuw nsw i64 %10, %13
%15 = tail call i32 (i32*, i8*, ...) @fprintf(i32* %0, i8* getelementptr inbounds ([11 x i8], [11 x i8]* @.str, i64 0, i64 0), i32 %9, i64 %14)
br label %20
16: ; preds = %4
%17 = ptrtoint i8* %6 to i64
%18 = trunc i64 %17 to i32
%19 = tail call i32 (i32*, i8*, ...) @fprintf(i32* %0, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.1, i64 0, i64 0), i32 %18, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.2, i64 0, i64 0))
br label %20
20: ; preds = %7, %16
br label %23
21: ; preds = %23
%22 = icmp eq i32 %31, 0
br i1 %22, label %41, label %36
23: ; preds = %20, %23
%24 = phi i64 [ %32, %23 ], [ %5, %20 ]
%25 = phi i8* [ %27, %23 ], [ %6, %20 ]
%26 = phi i32 [ %31, %23 ], [ 8, %20 ]
%27 = getelementptr inbounds i8, i8* %25, i64 1
%28 = load i8, i8* %25
%29 = zext i8 %28 to i32
%30 = tail call i32 (i32*, i8*, ...) @fprintf(i32* %0, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.3, i64 0, i64 0), i32 %29)
%31 = add nsw i32 %26, -1
%32 = add i64 %24, -1
%33 = icmp ne i32 %31, 0
%34 = icmp ne i64 %32, 0
%35 = select i1 %33, i1 %34, i1 false
br i1 %35, label %23, label %21
36: ; preds = %21, %36
%37 = phi i32 [ %39, %36 ], [ %31, %21 ]
%38 = tail call i64 @fwrite(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i64 3, i64 1, i32* %0)
%39 = add nsw i32 %37, -1
%40 = icmp eq i32 %39, 0
br i1 %40, label %41, label %36
41: ; preds = %36, %21
%42 = tail call i32 @fputc(i32 32, i32* %0)
%43 = icmp eq i64 %32, 0
br i1 %43, label %59, label %44
44: ; preds = %41, %44
%45 = phi i64 [ %53, %44 ], [ %32, %41 ]
%46 = phi i8* [ %48, %44 ], [ %27, %41 ]
%47 = phi i32 [ %52, %44 ], [ 8, %41 ]
%48 = getelementptr inbounds i8, i8* %46, i64 1
%49 = load i8, i8* %46
%50 = zext i8 %49 to i32
%51 = tail call i32 (i32*, i8*, ...) @fprintf(i32* %0, i8* getelementptr inbounds ([6 x i8], [6 x i8]* @.str.3, i64 0, i64 0), i32 %50)
%52 = add nsw i32 %47, -1
%53 = add i64 %45, -1
%54 = icmp ne i32 %52, 0
%55 = icmp ne i64 %53, 0
%56 = select i1 %54, i1 %55, i1 false
br i1 %56, label %44, label %57
57: ; preds = %44
%58 = icmp eq i32 %52, 0
br i1 %58, label %66, label %59
59: ; preds = %41, %57
%60 = phi i32 [ 8, %41 ], [ %52, %57 ]
br label %61
61: ; preds = %59, %61
%62 = phi i32 [ %64, %61 ], [ %60, %59 ]
%63 = tail call i64 @fwrite(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str.4, i64 0, i64 0), i64 3, i64 1, i32* %0)
%64 = add nsw i32 %62, -1
%65 = icmp eq i32 %64, 0
br i1 %65, label %66, label %61
66: ; preds = %61, %57
%67 = tail call i64 @fwrite(i8* getelementptr inbounds ([3 x i8], [3 x i8]* @.str.6, i64 0, i64 0), i64 2, i64 1, i32* %0)
%68 = icmp eq i64 %5, 0
br i1 %68, label %84, label %69
69: ; preds = %66, %69
%70 = phi i8* [ %73, %69 ], [ %6, %66 ]
%71 = phi i32 [ %79, %69 ], [ 16, %66 ]
%72 = phi i64 [ %80, %69 ], [ %5, %66 ]
%73 = getelementptr inbounds i8, i8* %70, i64 1
%74 = load i8, i8* %70
%75 = icmp slt i8 %74, 32
%76 = select i1 %75, i8 46, i8 %74
%77 = zext i8 %76 to i32
%78 = tail call i32 @fputc(i32 %77, i32* %0)
%79 = add nsw i32 %71, -1
%80 = add i64 %72, -1
%81 = icmp ne i32 %79, 0
%82 = icmp ne i64 %80, 0
%83 = select i1 %81, i1 %82, i1 false
br i1 %83, label %69, label %84
84: ; preds = %69, %66
%85 = phi i64 [ 0, %66 ], [ %80, %69 ]
%86 = phi i8* [ %6, %66 ], [ %73, %69 ]
%87 = tail call i32 @fputc(i32 10, i32* %0)
br label %4
88: ; preds = %4
ret void
}