#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 dequeue();
int /*<<< orphan*/ enqueue(int);
int /*<<< orphan*/ printf(char *, int);
void main() {
  enqueue(10);
  enqueue(20);
  enqueue(30);
  enqueue(40);
  printf("%d ", dequeue());
  printf("%d ", dequeue());
  enqueue(50);
  enqueue(-10);
  enqueue(-11);
  printf("%d ", dequeue());
  printf("%d ", dequeue());
  printf("%d ", dequeue());
  printf("%d ", dequeue());
  printf("%d ", dequeue());
  printf("%d ", dequeue());
  printf("%d ", dequeue());
  printf("%d ", dequeue());
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
mov    $0xa,%edi
call   1050 <enqueue@plt>
mov    $0x14,%edi
call   1050 <enqueue@plt>
mov    $0x1e,%edi
call   1050 <enqueue@plt>
mov    $0x28,%edi
call   1050 <enqueue@plt>
mov    $0x0,%al
call   1040 <dequeue@plt>
mov    %eax,%esi
lea    0xe94(%rip),%rdi
call   1030 <printf@plt>
mov    $0x0,%al
call   1040 <dequeue@plt>
mov    %eax,%esi
lea    0xe7f(%rip),%rdi
call   1030 <printf@plt>
mov    $0x32,%edi
call   1050 <enqueue@plt>
mov    $0xfffffff6,%edi
call   1050 <enqueue@plt>
mov    $0xfffffff5,%edi
call   1050 <enqueue@plt>
mov    $0x0,%al
call   1040 <dequeue@plt>
mov    %eax,%esi
lea    0xe4c(%rip),%rdi
call   1030 <printf@plt>
mov    $0x0,%al
call   1040 <dequeue@plt>
mov    %eax,%esi
lea    0xe37(%rip),%rdi
call   1030 <printf@plt>
mov    $0x0,%al
call   1040 <dequeue@plt>
mov    %eax,%esi
lea    0xe22(%rip),%rdi
call   1030 <printf@plt>
mov    $0x0,%al
call   1040 <dequeue@plt>
mov    %eax,%esi
lea    0xe0d(%rip),%rdi
call   1030 <printf@plt>
mov    $0x0,%al
call   1040 <dequeue@plt>
mov    %eax,%esi
lea    0xdf8(%rip),%rdi
call   1030 <printf@plt>
mov    $0x0,%al
call   1040 <dequeue@plt>
mov    %eax,%esi
lea    0xde3(%rip),%rdi
call   1030 <printf@plt>
mov    $0x0,%al
call   1040 <dequeue@plt>
mov    %eax,%esi
lea    0xdce(%rip),%rdi
call   1030 <printf@plt>
mov    $0x0,%al
call   1040 <dequeue@plt>
mov    %eax,%esi
lea    0xdb9(%rip),%rdi
call   1030 <printf@plt>
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
push   %rbx
mov    $0xa,%edi
call   1050 <enqueue@plt>
mov    $0x14,%edi
call   1050 <enqueue@plt>
mov    $0x1e,%edi
call   1050 <enqueue@plt>
mov    $0x28,%edi
call   1050 <enqueue@plt>
xor    %eax,%eax
call   1040 <dequeue@plt>
lea    0xe99(%rip),%rbx
mov    %rbx,%rdi
mov    %eax,%esi
call   1030 <printf@plt>
xor    %eax,%eax
call   1040 <dequeue@plt>
mov    %rbx,%rdi
mov    %eax,%esi
call   1030 <printf@plt>
mov    $0x32,%edi
call   1050 <enqueue@plt>
mov    $0xfffffff6,%edi
call   1050 <enqueue@plt>
mov    $0xfffffff5,%edi
call   1050 <enqueue@plt>
xor    %eax,%eax
call   1040 <dequeue@plt>
mov    %rbx,%rdi
mov    %eax,%esi
call   1030 <printf@plt>
xor    %eax,%eax
call   1040 <dequeue@plt>
mov    %rbx,%rdi
mov    %eax,%esi
call   1030 <printf@plt>
xor    %eax,%eax
call   1040 <dequeue@plt>
mov    %rbx,%rdi
mov    %eax,%esi
call   1030 <printf@plt>
xor    %eax,%eax
call   1040 <dequeue@plt>
mov    %rbx,%rdi
mov    %eax,%esi
call   1030 <printf@plt>
xor    %eax,%eax
call   1040 <dequeue@plt>
mov    %rbx,%rdi
mov    %eax,%esi
call   1030 <printf@plt>
xor    %eax,%eax
call   1040 <dequeue@plt>
mov    %rbx,%rdi
mov    %eax,%esi
call   1030 <printf@plt>
xor    %eax,%eax
call   1040 <dequeue@plt>
mov    %rbx,%rdi
mov    %eax,%esi
call   1030 <printf@plt>
xor    %eax,%eax
call   1040 <dequeue@plt>
mov    %rbx,%rdi
mov    %eax,%esi
pop    %rbx
jmp    1030 <printf@plt>

LLVM IR (-O0):
@.str = [4 x i8] c"%d \00"
define void @main() {
%1 = call i32 @enqueue(i32 10)
%2 = call i32 @enqueue(i32 20)
%3 = call i32 @enqueue(i32 30)
%4 = call i32 @enqueue(i32 40)
%5 = call i32 (...) @dequeue()
%6 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %5)
%7 = call i32 (...) @dequeue()
%8 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %7)
%9 = call i32 @enqueue(i32 50)
%10 = call i32 @enqueue(i32 -10)
%11 = call i32 @enqueue(i32 -11)
%12 = call i32 (...) @dequeue()
%13 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %12)
%14 = call i32 (...) @dequeue()
%15 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %14)
%16 = call i32 (...) @dequeue()
%17 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %16)
%18 = call i32 (...) @dequeue()
%19 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %18)
%20 = call i32 (...) @dequeue()
%21 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %20)
%22 = call i32 (...) @dequeue()
%23 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %22)
%24 = call i32 (...) @dequeue()
%25 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %24)
%26 = call i32 (...) @dequeue()
%27 = call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %26)
ret void
}

LLVM IR (-O2):
@.str = [4 x i8] c"%d \00"
define void @main() {
%1 = tail call i32 @enqueue(i32 10)
%2 = tail call i32 @enqueue(i32 20)
%3 = tail call i32 @enqueue(i32 30)
%4 = tail call i32 @enqueue(i32 40)
%5 = tail call i32 (...) @dequeue()
%6 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %5)
%7 = tail call i32 (...) @dequeue()
%8 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %7)
%9 = tail call i32 @enqueue(i32 50)
%10 = tail call i32 @enqueue(i32 -10)
%11 = tail call i32 @enqueue(i32 -11)
%12 = tail call i32 (...) @dequeue()
%13 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %12)
%14 = tail call i32 (...) @dequeue()
%15 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %14)
%16 = tail call i32 (...) @dequeue()
%17 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %16)
%18 = tail call i32 (...) @dequeue()
%19 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %18)
%20 = tail call i32 (...) @dequeue()
%21 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %20)
%22 = tail call i32 (...) @dequeue()
%23 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %22)
%24 = tail call i32 (...) @dequeue()
%25 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %24)
%26 = tail call i32 (...) @dequeue()
%27 = tail call i32 @printf(i8* getelementptr inbounds ([4 x i8], [4 x i8]* @.str, i64 0, i64 0), i32 %26)
ret void
}