#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*/ benchmark();
int /*<<< orphan*/ initialise_board();
int /*<<< orphan*/ start_trigger();
int /*<<< orphan*/ stop_trigger();
int main(void) {
  int i;
  initialise_board();
  start_trigger();
  for (i = 0; i < (4096 >> 7); i++)
    benchmark();
  stop_trigger();
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x10,%rsp
movl   $0x0,-0x4(%rbp)
mov    $0x0,%al
call   1060 <initialise_board@plt>
mov    $0x0,%al
call   1030 <start_trigger@plt>
movl   $0x0,-0x8(%rbp)
cmpl   $0x20,-0x8(%rbp)
jge    1183 <main+0x43>
mov    $0x0,%al
call   1050 <benchmark@plt>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    1164 <main+0x24>
mov    $0x0,%al
call   1040 <stop_trigger@plt>
xor    %eax,%eax
add    $0x10,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rax
xor    %eax,%eax
call   1060 <initialise_board@plt>
xor    %eax,%eax
call   1030 <start_trigger@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1050 <benchmark@plt>
xor    %eax,%eax
call   1040 <stop_trigger@plt>
xor    %eax,%eax
pop    %rcx
ret

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
store i32 0, i32* %1
%3 = call i32 (...) @initialise_board()
%4 = call i32 (...) @start_trigger()
store i32 0, i32* %2
br label %5
5: ; preds = %10, %0
%6 = load i32, i32* %2
%7 = icmp slt i32 %6, 32
br i1 %7, label %8, label %13
8: ; preds = %5
%9 = call i32 (...) @benchmark()
br label %10
10: ; preds = %8
%11 = load i32, i32* %2
%12 = add nsw i32 %11, 1
store i32 %12, i32* %2
br label %5
13: ; preds = %5
%14 = call i32 (...) @stop_trigger()
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
%1 = tail call i32 (...) @initialise_board()
%2 = tail call i32 (...) @start_trigger()
%3 = tail call i32 (...) @benchmark()
%4 = tail call i32 (...) @benchmark()
%5 = tail call i32 (...) @benchmark()
%6 = tail call i32 (...) @benchmark()
%7 = tail call i32 (...) @benchmark()
%8 = tail call i32 (...) @benchmark()
%9 = tail call i32 (...) @benchmark()
%10 = tail call i32 (...) @benchmark()
%11 = tail call i32 (...) @benchmark()
%12 = tail call i32 (...) @benchmark()
%13 = tail call i32 (...) @benchmark()
%14 = tail call i32 (...) @benchmark()
%15 = tail call i32 (...) @benchmark()
%16 = tail call i32 (...) @benchmark()
%17 = tail call i32 (...) @benchmark()
%18 = tail call i32 (...) @benchmark()
%19 = tail call i32 (...) @benchmark()
%20 = tail call i32 (...) @benchmark()
%21 = tail call i32 (...) @benchmark()
%22 = tail call i32 (...) @benchmark()
%23 = tail call i32 (...) @benchmark()
%24 = tail call i32 (...) @benchmark()
%25 = tail call i32 (...) @benchmark()
%26 = tail call i32 (...) @benchmark()
%27 = tail call i32 (...) @benchmark()
%28 = tail call i32 (...) @benchmark()
%29 = tail call i32 (...) @benchmark()
%30 = tail call i32 (...) @benchmark()
%31 = tail call i32 (...) @benchmark()
%32 = tail call i32 (...) @benchmark()
%33 = tail call i32 (...) @benchmark()
%34 = tail call i32 (...) @benchmark()
%35 = tail call i32 (...) @stop_trigger()
ret i32 0
}