#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*/ printList();
int /*<<< orphan*/ printf(char *);
int /*<<< orphan*/ queueappend(int, int, int, int *);
main() {
  int arr1[4] = {0};
  int arr2[1] = {1};
  int arr3[5] = {1, 2, 3, 4, 5};
  queueappend(1, 10, 4, arr1);
  queueappend(2, 20, 1, arr2);
  queueappend(3, 30, 3, arr3);
  printf("Original List: ");
  printList();
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x30,%rsp
lea    -0x10(%rbp),%rdi
xor    %esi,%esi
mov    $0x10,%edx
call   1040 <memset@plt>
mov    0xea2(%rip),%eax
mov    %eax,-0x14(%rbp)
mov    0xea8(%rip),%rax
mov    %rax,-0x30(%rbp)
mov    0xea5(%rip),%rax
mov    %rax,-0x28(%rbp)
mov    0xea3(%rip),%eax
mov    %eax,-0x20(%rbp)
lea    -0x10(%rbp),%rcx
mov    $0x1,%edi
mov    $0xa,%esi
mov    $0x4,%edx
call   1050 <queueappend@plt>
lea    -0x14(%rbp),%rcx
mov    $0x2,%edi
mov    $0x14,%esi
mov    $0x1,%edx
call   1050 <queueappend@plt>
lea    -0x30(%rbp),%rcx
mov    $0x3,%edx
mov    $0x1e,%esi
mov    %edx,%edi
call   1050 <queueappend@plt>
lea    0xe58(%rip),%rdi
call   1030 <printf@plt>
mov    $0x0,%al
call   1060 <printList@plt>
xor    %eax,%eax
add    $0x30,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
sub    $0x48,%rsp
xorps  %xmm0,%xmm0
movaps %xmm0,0x30(%rsp)
movl   $0x1,0xc(%rsp)
mov    0xec6(%rip),%eax
mov    %eax,0x20(%rsp)
movaps 0xeab(%rip),%xmm0
movaps %xmm0,0x10(%rsp)
lea    0x30(%rsp),%rcx
mov    $0x1,%edi
mov    $0xa,%esi
mov    $0x4,%edx
call   1040 <queueappend@plt>
lea    0xc(%rsp),%rcx
mov    $0x2,%edi
mov    $0x14,%esi
mov    $0x1,%edx
call   1040 <queueappend@plt>
lea    0x10(%rsp),%rcx
mov    $0x3,%edi
mov    $0x1e,%esi
mov    $0x3,%edx
call   1040 <queueappend@plt>
lea    0xe68(%rip),%rdi
call   1030 <printf@plt>
xor    %eax,%eax
call   1050 <printList@plt>
xor    %eax,%eax
add    $0x48,%rsp
ret

LLVM IR (-O0):
@__const.main.arr2 = [1 x i32] [i32 1]
@__const.main.arr3 = [5 x i32] [i32 1, i32 2, i32 3, i32 4, i32 5]
@.str = [16 x i8] c"Original List: \00"
define i32 @main() {
%1 = alloca [4 x i32]
%2 = alloca [1 x i32]
%3 = alloca [5 x i32]
%4 = bitcast [4 x i32]* %1 to i8*
%5 = bitcast [1 x i32]* %2 to i8*
%6 = bitcast [5 x i32]* %3 to i8*
%7 = getelementptr inbounds [4 x i32], [4 x i32]* %1, i64 0, i64 0
%8 = call i32 @queueappend(i32 1, i32 10, i32 4, i32* %7)
%9 = getelementptr inbounds [1 x i32], [1 x i32]* %2, i64 0, i64 0
%10 = call i32 @queueappend(i32 2, i32 20, i32 1, i32* %9)
%11 = getelementptr inbounds [5 x i32], [5 x i32]* %3, i64 0, i64 0
%12 = call i32 @queueappend(i32 3, i32 30, i32 3, i32* %11)
%13 = call i32 @printf(i8* getelementptr inbounds ([16 x i8], [16 x i8]* @.str, i64 0, i64 0))
%14 = call i32 (...) @printList()
ret i32 0
}

LLVM IR (-O2):
@__const.main.arr3 = [5 x i32] [i32 1, i32 2, i32 3, i32 4, i32 5]
@.str = [16 x i8] c"Original List: \00"
define i32 @main() {
%1 = alloca [4 x i32]
%2 = alloca [1 x i32]
%3 = alloca [5 x i32]
%4 = bitcast [4 x i32]* %1 to i8*
%5 = bitcast [1 x i32]* %2 to i8*
%6 = getelementptr inbounds [1 x i32], [1 x i32]* %2, i64 0, i64 0
store i32 1, i32* %6
%7 = bitcast [5 x i32]* %3 to i8*
%8 = getelementptr inbounds [4 x i32], [4 x i32]* %1, i64 0, i64 0
%9 = call i32 @queueappend(i32 1, i32 10, i32 4, i32* %8)
%10 = call i32 @queueappend(i32 2, i32 20, i32 1, i32* %6)
%11 = getelementptr inbounds [5 x i32], [5 x i32]* %3, i64 0, i64 0
%12 = call i32 @queueappend(i32 3, i32 30, i32 3, i32* %11)
%13 = call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([16 x i8], [16 x i8]* @.str, i64 0, i64 0))
%14 = call i32 (...) @printList()
ret i32 0
}