#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*/ exit(int);
scalar_t__ fprintf(int /*<<< orphan*/, char *, ...);
int /*<<< orphan*/ stderr;
int /*<<< orphan*/ stdout;
int printSpace(int i, int indent) {
  do {
    if (i <= indent)
      ;
    else {
      fprintf(stderr, "\e[35m\e[1massertion failed:\e[0m%s:%d> %s\n",
              "/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/"
              "2022-01-22/02-19-57/repos/qc1iu/turkeyVM/refs/heads/master/src/"
              "control/command-line.c",
              172, "i <= indent");
      exit(1);
    }
  } while (0);
  while (i < indent) {
    i += fprintf(stdout, " ");
  }
  return i;
}


x86 assembly (clang, -O0):
<printSpace>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    -0x4(%rbp),%eax
cmp    -0x8(%rbp),%eax
jg     113f <printSpace+0x1f>
jmp    1173 <printSpace+0x53>
mov    0x2e9a(%rip),%rax
mov    (%rax),%edi
lea    0xeb1(%rip),%rsi
lea    0xed3(%rip),%rdx
mov    $0xac,%ecx
lea    0xf5d(%rip),%r8
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    $0x1,%edi
call   1040 <exit@plt>
jmp    1178 <printSpace+0x58>
jmp    117d <printSpace+0x5d>
mov    -0x4(%rbp),%eax
cmp    -0x8(%rbp),%eax
jge    11b2 <printSpace+0x92>
mov    0x2e48(%rip),%rax
mov    (%rax),%edi
lea    0xf32(%rip),%rsi
mov    $0x0,%al
call   1030 <fprintf@plt>
mov    %rax,%rcx
movslq -0x4(%rbp),%rax
add    %rcx,%rax
mov    %eax,-0x4(%rbp)
jmp    117d <printSpace+0x5d>
mov    -0x4(%rbp),%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<printSpace>:
push   %rbp
push   %r15
push   %r14
push   %rbx
push   %rax
cmp    %esi,%edi
jg     1160 <printSpace+0x40>
mov    %edi,%ebx
jge    1153 <printSpace+0x33>
mov    %esi,%ebp
mov    0x2ea0(%rip),%r15
lea    0xf8c(%rip),%r14
nop
mov    (%r15),%edi
mov    %r14,%rsi
xor    %eax,%eax
call   1030 <fprintf@plt>
add    %eax,%ebx
cmp    %ebp,%ebx
jl     1140 <printSpace+0x20>
mov    %ebx,%eax
add    $0x8,%rsp
pop    %rbx
pop    %r14
pop    %r15
pop    %rbp
ret
mov    0x2e79(%rip),%rax
mov    (%rax),%edi
lea    0xe90(%rip),%rsi
lea    0xeb2(%rip),%rdx
lea    0xf41(%rip),%r8
mov    $0xac,%ecx
xor    %eax,%eax
call   1030 <fprintf@plt>
mov    $0x1,%edi
call   1040 <exit@plt>

LLVM IR (-O0):
@stderr = global i32 0
@.str = [41 x i8] c"\1B[35m\1B[1massertion failed:\1B[0m%s:%d> %s\0A\00"
@.str.1 = [150 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/qc1iu/turkeyVM/refs/heads/master/src/control/command-line.c\00"
@.str.2 = [12 x i8] c"i <= indent\00"
@stdout = global i32 0
@.str.3 = [2 x i8] c" \00"
define i32 @printSpace(i32 %0, i32 %1) {
%3 = alloca i32
%4 = alloca i32
store i32 %0, i32* %3
store i32 %1, i32* %4
br label %5
5: ; preds = %2
%6 = load i32, i32* %3
%7 = load i32, i32* %4
%8 = icmp sle i32 %6, %7
br i1 %8, label %9, label %10
9: ; preds = %5
br label %14
10: ; preds = %5
%11 = load i32, i32* @stderr
%12 = call i64 (i32, i8*, ...) @fprintf(i32 %11, i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([150 x i8], [150 x i8]* @.str.1, i64 0, i64 0), i32 172, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.2, i64 0, i64 0))
%13 = call i32 @exit(i32 1)
unreachable
14: ; preds = %9
br label %15
15: ; preds = %14
br label %16
16: ; preds = %20, %15
%17 = load i32, i32* %3
%18 = load i32, i32* %4
%19 = icmp slt i32 %17, %18
br i1 %19, label %20, label %27
20: ; preds = %16
%21 = load i32, i32* @stdout
%22 = call i64 (i32, i8*, ...) @fprintf(i32 %21, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.3, i64 0, i64 0))
%23 = load i32, i32* %3
%24 = sext i32 %23 to i64
%25 = add nsw i64 %24, %22
%26 = trunc i64 %25 to i32
store i32 %26, i32* %3
br label %16
27: ; preds = %16
%28 = load i32, i32* %3
ret i32 %28
}

LLVM IR (-O2):
@stderr = global i32 0
@.str = [41 x i8] c"\1B[35m\1B[1massertion failed:\1B[0m%s:%d> %s\0A\00"
@.str.1 = [150 x i8] c"/scratch/repos/new/home/jordi_armengol_estape/c-scraper/outputs/2022-01-22/02-19-57/repos/qc1iu/turkeyVM/refs/heads/master/src/control/command-line.c\00"
@.str.2 = [12 x i8] c"i <= indent\00"
@stdout = global i32 0
@.str.3 = [2 x i8] c" \00"
define i32 @printSpace(i32 %0, i32 %1) {
%3 = icmp sgt i32 %0, %1
br i1 %3, label %6, label %4
4: ; preds = %2
%5 = icmp slt i32 %0, %1
br i1 %5, label %10, label %17
6: ; preds = %2
%7 = load i32, i32* @stderr
%8 = tail call i64 (i32, i8*, ...) @fprintf(i32 %7, i8* getelementptr inbounds ([41 x i8], [41 x i8]* @.str, i64 0, i64 0), i8* getelementptr inbounds ([150 x i8], [150 x i8]* @.str.1, i64 0, i64 0), i32 172, i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str.2, i64 0, i64 0))
%9 = tail call i32 @exit(i32 1)
unreachable
10: ; preds = %4, %10
%11 = phi i32 [ %15, %10 ], [ %0, %4 ]
%12 = load i32, i32* @stdout
%13 = tail call i64 (i32, i8*, ...) @fprintf(i32 %12, i8* getelementptr inbounds ([2 x i8], [2 x i8]* @.str.3, i64 0, i64 0))
%14 = trunc i64 %13 to i32
%15 = add i32 %11, %14
%16 = icmp slt i32 %15, %1
br i1 %16, label %10, label %17
17: ; preds = %10, %4
%18 = phi i32 [ %0, %4 ], [ %15, %10 ]
ret i32 %18
}