#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 /*<<< orphan*/ printf(char *, ...);
void line(int indent, char *name, uint32_t start, uint32_t end, uint32_t size,
          char *append) {
  int i;
  for (i = 0; i < indent; i++)
    printf("  ");
  printf("%-25s  %08x    %08x    %08x%s\n", name, start, end, size,
         append ? append : "");
}


x86 assembly (clang, -O0):
<line>:
push   %rbp
mov    %rsp,%rbp
sub    $0x50,%rsp
mov    %edi,-0x4(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %edx,-0x14(%rbp)
mov    %ecx,-0x18(%rbp)
mov    %r8d,-0x1c(%rbp)
mov    %r9,-0x28(%rbp)
movl   $0x0,-0x2c(%rbp)
mov    -0x2c(%rbp),%eax
cmp    -0x4(%rbp),%eax
jge    115c <line+0x4c>
lea    0xeb9(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
mov    -0x2c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x2c(%rbp)
jmp    1134 <line+0x24>
mov    -0x10(%rbp),%rax
mov    %rax,-0x40(%rbp)
mov    -0x14(%rbp),%eax
mov    %eax,-0x38(%rbp)
mov    -0x18(%rbp),%eax
mov    %eax,-0x34(%rbp)
mov    -0x1c(%rbp),%eax
mov    %eax,-0x30(%rbp)
cmpq   $0x0,-0x28(%rbp)
je     118e <line+0x7e>
mov    -0x28(%rbp),%rax
mov    %rax,-0x48(%rbp)
jmp    119e <line+0x8e>
lea    0xe8c(%rip),%rax
mov    %rax,-0x48(%rbp)
jmp    119e <line+0x8e>
mov    -0x30(%rbp),%r8d
mov    -0x34(%rbp),%ecx
mov    -0x38(%rbp),%edx
mov    -0x40(%rbp),%rsi
mov    -0x48(%rbp),%r9
lea    0xe4c(%rip),%rdi
mov    $0x0,%al
call   1030 <printf@plt>
add    $0x50,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<line>:
push   %rbp
push   %r15
push   %r14
push   %r13
push   %r12
push   %rbx
push   %rax
mov    %r9,%rbx
mov    %r8d,0x4(%rsp)
mov    %ecx,%r15d
mov    %edx,%r12d
mov    %rsi,%r13
test   %edi,%edi
jle    114f <line+0x3f>
mov    %edi,%ebp
lea    0xec7(%rip),%r14
nopl   0x0(%rax)
mov    %r14,%rdi
xor    %eax,%eax
call   1030 <printf@plt>
add    $0xffffffff,%ebp
jne    1140 <line+0x30>
test   %rbx,%rbx
lea    0xec8(%rip),%r9
cmovne %rbx,%r9
lea    0xe9f(%rip),%rdi
mov    %r13,%rsi
mov    %r12d,%edx
mov    %r15d,%ecx
mov    0x4(%rsp),%r8d
xor    %eax,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r12
pop    %r13
pop    %r14
pop    %r15
pop    %rbp
jmp    1030 <printf@plt>

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

LLVM IR (-O2):
@.str = [3 x i8] c" \00"
@.str.1 = [31 x i8] c"%-25s %08x %08x %08x%s\0A\00"
@.str.2 = [1 x i8] zeroinitializer
define void @line(i32 %0, i8* %1, i32 %2, i32 %3, i32 %4, i8* %5) {
%7 = icmp sgt i32 %0, 0
br i1 %7, label %8, label %13
8: ; preds = %6, %8
%9 = phi i32 [ %11, %8 ], [ 0, %6 ]
%10 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([3 x i8], [3 x i8]* @.str, i64 0, i64 0))
%11 = add nuw nsw i32 %9, 1
%12 = icmp eq i32 %11, %0
br i1 %12, label %13, label %8
13: ; preds = %8, %6
%14 = icmp eq i8* %5, null
%15 = select i1 %14, i8* getelementptr inbounds ([1 x i8], [1 x i8]* @.str.2, i64 0, i64 0), i8* %5
%16 = tail call i32 (i8*, ...) @printf(i8* dereferenceable(1) getelementptr inbounds ([31 x i8], [31 x i8]* @.str.1, i64 0, i64 0), i8* %1, i32 %2, i32 %3, i32 %4, i8* %15)
ret void
}