#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*/ printf(char *);
void format3_line_type1(void) {
  int i;
  for (i = 0; i < 16; i++) {
    if ((i + 1) == 16) {
      printf("|");
    } else if ((i % 8) == 0) {
      printf(
          "|                                                               ");
    }
  }
  printf("\n");
}


x86 assembly (clang, -O0):
<format3_line_type1>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
cmpl   $0x10,-0x4(%rbp)
jge    1181 <format3_line_type1+0x71>
mov    -0x4(%rbp),%eax
add    $0x1,%eax
cmp    $0x10,%eax
jne    1149 <format3_line_type1+0x39>
lea    0xec1(%rip),%rdi
call   1030 <printf@plt>
jmp    116e <format3_line_type1+0x5e>
mov    -0x4(%rbp),%eax
mov    $0x8,%ecx
cltd
idiv   %ecx
cmp    $0x0,%edx
jne    1169 <format3_line_type1+0x59>
lea    0xe9e(%rip),%rdi
call   1030 <printf@plt>
jmp    116e <format3_line_type1+0x5e>
jmp    1173 <format3_line_type1+0x63>
mov    -0x4(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x4(%rbp)
jmp    111f <format3_line_type1+0xf>
lea    0xebb(%rip),%rdi
call   1030 <printf@plt>
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<format3_line_type1>:
push   %rbx
lea    0xed8(%rip),%rbx
mov    %rbx,%rdi
call   1040 <printf@plt>
mov    %rbx,%rdi
call   1040 <printf@plt>
mov    $0x7c,%edi
call   1030 <putchar@plt>
mov    $0xa,%edi
pop    %rbx
jmp    1030 <putchar@plt>

LLVM IR (-O0):
@.str = [2 x i8] c"|\00"
@.str.1 = [65 x i8] c"| \00"
@.str.2 = [2 x i8] c"\0A\00"
define void @format3_line_type1() {
%1 = alloca i32
store i32 0, i32* %1
br label %2
2: ; preds = %19, %0
%3 = load i32, i32* %1
%4 = icmp slt i32 %3, 16
br i1 %4, label %5, label %22
5: ; preds = %2
%6 = load i32, i32* %1
%7 = add nsw i32 %6, 1
%8 = icmp eq i32 %7, 16
br i1 %8, label %9, label %11
9: ; preds = %5
%10 = call i32 @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str, i64 0, i64 0))
br label %18
11: ; preds = %5
%12 = load i32, i32* %1
%13 = srem i32 %12, 8
%14 = icmp eq i32 %13, 0
br i1 %14, label %15, label %17
15: ; preds = %11
%16 = call i32 @printf(i8* getelementptr inbounds ([65 x i8], [65 x i8]* @.str.1, i64 0, i64 0))
br label %17
17: ; preds = %15, %11
br label %18
18: ; preds = %17, %9
br label %19
19: ; preds = %18
%20 = load i32, i32* %1
%21 = add nsw i32 %20, 1
store i32 %21, i32* %1
br label %2
22: ; preds = %2
%23 = call i32 @printf(i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.2, i64 0, i64 0))
ret void
}

LLVM IR (-O2):
@.str.1 = [65 x i8] c"| \00"
define void @format3_line_type1() {
%1 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([65 x i8], [65 x i8]* @.str.1, i64 0, i64 0))
%2 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([65 x i8], [65 x i8]* @.str.1, i64 0, i64 0))
%3 = tail call i32 @putchar(i32 124)
%4 = tail call i32 @putchar(i32 10)
ret void
}