int main(void) {
  unsigned int i, j;
  (*((volatile unsigned long *)0xE002C000)) = 0x00000000;
  (*((volatile unsigned long *)0xE002C004)) = 0x00000000;
  (*((volatile unsigned long *)0xE002C014)) &= 0xFFFFFFF7;
  (*((volatile unsigned long *)0xE0028018)) = 0x000F0000;
  while (1) {
    (*((volatile unsigned long *)0xE0028014)) = 0x000F0000;
    for (j = 2; j > 0; j--) {
      for (i = 0; i < 60000; i++)
        ;
    }
    (*((volatile unsigned long *)0xE002801C)) = 0x000F0000;
    for (j = 2; j > 0; j--) {
      for (i = 0; i < 60000; i++)
        ;
    }
  }
  return (0);
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
movl   $0x0,-0x4(%rbp)
mov    $0xe002c000,%eax
movq   $0x0,(%rax)
mov    $0xe002c004,%eax
movq   $0x0,(%rax)
mov    $0xe002c014,%eax
mov    (%rax),%rcx
movabs $0xfffffff7,%rax
and    %rax,%rcx
mov    $0xe002c014,%eax
mov    %rcx,(%rax)
mov    $0xe0028018,%eax
movq   $0xf0000,(%rax)
mov    $0xe0028014,%eax
movq   $0xf0000,(%rax)
movl   $0x2,-0xc(%rbp)
cmpl   $0x0,-0xc(%rbp)
jbe    11a3 <main+0xa3>
movl   $0x0,-0x8(%rbp)
cmpl   $0xea60,-0x8(%rbp)
jae    1190 <main+0x90>
jmp    1182 <main+0x82>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    1170 <main+0x70>
jmp    1195 <main+0x95>
mov    -0xc(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0xc(%rbp)
jmp    115f <main+0x5f>
mov    $0xe002801c,%eax
movq   $0xf0000,(%rax)
movl   $0x2,-0xc(%rbp)
cmpl   $0x0,-0xc(%rbp)
jbe    11fa <main+0xfa>
movl   $0x0,-0x8(%rbp)
cmpl   $0xea60,-0x8(%rbp)
jae    11e7 <main+0xe7>
jmp    11d9 <main+0xd9>
mov    -0x8(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x8(%rbp)
jmp    11c7 <main+0xc7>
jmp    11ec <main+0xec>
mov    -0xc(%rbp),%eax
add    $0xffffffff,%eax
mov    %eax,-0xc(%rbp)
jmp    11b6 <main+0xb6>
jmp    114c <main+0x4c>

x86 assembly (clang, -O2):
<main>:
mov    $0xe002c014,%eax
movq   $0x0,-0x14(%rax)
movq   $0x0,-0x10(%rax)
mov    $0xfffffff7,%ecx
and    %rcx,(%rax)
movq   $0xf0000,-0x3ffc(%rax)
nopl   0x0(%rax,%rax,1)
movq   $0xf0000,-0x4000(%rax)
movq   $0xf0000,-0x3ff8(%rax)
jmp    1130 <main+0x30>

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
%2 = alloca i32
%3 = alloca i32
store i32 0, i32* %1
store volatile i64 0, i64* inttoptr (i64 3758276608 to i64*)
store volatile i64 0, i64* inttoptr (i64 3758276612 to i64*)
%4 = load volatile i64, i64* inttoptr (i64 3758276628 to i64*)
%5 = and i64 %4, 4294967287
store volatile i64 %5, i64* inttoptr (i64 3758276628 to i64*)
store volatile i64 983040, i64* inttoptr (i64 3758260248 to i64*)
br label %6
6: ; preds = %0, %38
store volatile i64 983040, i64* inttoptr (i64 3758260244 to i64*)
store i32 2, i32* %3
br label %7
7: ; preds = %19, %6
%8 = load i32, i32* %3
%9 = icmp ugt i32 %8, 0
br i1 %9, label %10, label %22
10: ; preds = %7
store i32 0, i32* %2
br label %11
11: ; preds = %15, %10
%12 = load i32, i32* %2
%13 = icmp ult i32 %12, 60000
br i1 %13, label %14, label %18
14: ; preds = %11
br label %15
15: ; preds = %14
%16 = load i32, i32* %2
%17 = add i32 %16, 1
store i32 %17, i32* %2
br label %11
18: ; preds = %11
br label %19
19: ; preds = %18
%20 = load i32, i32* %3
%21 = add i32 %20, -1
store i32 %21, i32* %3
br label %7
22: ; preds = %7
store volatile i64 983040, i64* inttoptr (i64 3758260252 to i64*)
store i32 2, i32* %3
br label %23
23: ; preds = %35, %22
%24 = load i32, i32* %3
%25 = icmp ugt i32 %24, 0
br i1 %25, label %26, label %38
26: ; preds = %23
store i32 0, i32* %2
br label %27
27: ; preds = %31, %26
%28 = load i32, i32* %2
%29 = icmp ult i32 %28, 60000
br i1 %29, label %30, label %34
30: ; preds = %27
br label %31
31: ; preds = %30
%32 = load i32, i32* %2
%33 = add i32 %32, 1
store i32 %33, i32* %2
br label %27
34: ; preds = %27
br label %35
35: ; preds = %34
%36 = load i32, i32* %3
%37 = add i32 %36, -1
store i32 %37, i32* %3
br label %23
38: ; preds = %23
br label %6
}

LLVM IR (-O2):
define i32 @main() {
store volatile i64 0, i64* inttoptr (i64 3758276608 to i64*)
store volatile i64 0, i64* inttoptr (i64 3758276612 to i64*)
%1 = load volatile i64, i64* inttoptr (i64 3758276628 to i64*)
%2 = and i64 %1, 4294967287
store volatile i64 %2, i64* inttoptr (i64 3758276628 to i64*)
store volatile i64 983040, i64* inttoptr (i64 3758260248 to i64*)
br label %3
3: ; preds = %3, %0
store volatile i64 983040, i64* inttoptr (i64 3758260244 to i64*)
store volatile i64 983040, i64* inttoptr (i64 3758260252 to i64*)
br label %3
}