#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 fprintf_t(FILE *fID, unsigned int Ntabs, unsigned int includeNewLine,
               const char *String) {
  unsigned int i;
  for (i = 0; i < Ntabs; i++)
    fprintf(fID, "\t");
  fprintf(fID, "%s", String);
  if (includeNewLine)
    fprintf(fID, "\n");
}


x86 assembly (clang, -O0):
<fprintf_t>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %esi,-0xc(%rbp)
mov    %edx,-0x10(%rbp)
mov    %rcx,-0x18(%rbp)
movl   $0x0,-0x1c(%rbp)
mov    -0x1c(%rbp),%eax
cmp    -0xc(%rbp),%eax
jae    1159 <fprintf_t+0x49>
mov    -0x8(%rbp),%rdi
lea    0xebc(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    -0x1c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1c(%rbp)
jmp    112d <fprintf_t+0x1d>
mov    -0x8(%rbp),%rdi
mov    -0x18(%rbp),%rdx
lea    0xe9a(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
cmpl   $0x0,-0x10(%rbp)
je     118b <fprintf_t+0x7b>
mov    -0x8(%rbp),%rdi
lea    0xe81(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<fprintf_t>:
push   %rbp
push   %r15
push   %r14
push   %rbx
push   %rax
mov    %rcx,%r15
mov    %edx,%r14d
mov    %rdi,%rbx
test   %esi,%esi
je     1152 <fprintf_t+0x32>
mov    %esi,%ebp
cs nopw 0x0(%rax,%rax,1)
mov    $0x9,%edi
mov    %rbx,%rsi
call   1040 <fputc@plt>
add    $0xffffffff,%ebp
jne    1140 <fprintf_t+0x20>
mov    %r15,%rdi
mov    %rbx,%rsi
call   1030 <fputs@plt>
test   %r14d,%r14d
je     1179 <fprintf_t+0x59>
mov    $0xa,%edi
mov    %rbx,%rsi
add    $0x8,%rsp
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
jmp    1040 <fputc@plt>
add    $0x8,%rsp
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
ret

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

LLVM IR (-O2):
define void @fprintf_t(i32* nocapture %0, i32 %1, i32 %2, i8* nocapture %3) {
%5 = icmp eq i32 %1, 0
br i1 %5, label %11, label %6
6: ; preds = %4, %6
%7 = phi i32 [ %9, %6 ], [ 0, %4 ]
%8 = tail call i32 @fputc(i32 9, i32* %0)
%9 = add nuw i32 %7, 1
%10 = icmp eq i32 %9, %1
br i1 %10, label %11, label %6
11: ; preds = %6, %4
%12 = tail call i32 @fputs(i8* %3, i32* %0)
%13 = icmp eq i32 %2, 0
br i1 %13, label %16, label %14
14: ; preds = %11
%15 = tail call i32 @fputc(i32 10, i32* %0)
br label %16
16: ; preds = %14, %11
ret void
}