#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*/ printf(char *);
void deleteQueue(int Q[], int *front, int *rear, int *key) {
  if (front == 0) {
    printf("\n\tUnderflow");
    return;
  }
  *key = Q[*front];
  Q[*front] = -9999999;
  if (*front == *rear) {
    *front = -1;
    ;
    *rear = -1;
  } else {
    *front = *front + 1;
  }
}


x86 assembly (clang, -O0):
<deleteQueue>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
mov    %rdi,-0x8(%rbp)
mov    %rsi,-0x10(%rbp)
mov    %rdx,-0x18(%rbp)
mov    %rcx,-0x20(%rbp)
cmpq   $0x0,-0x10(%rbp)
jne    1144 <deleteQueue+0x34>
lea    0xec6(%rip),%rdi
call   1030 <printf@plt>
jmp    11a4 <deleteQueue+0x94>
mov    -0x8(%rbp),%rax
mov    -0x10(%rbp),%rcx
movslq (%rcx),%rcx
mov    (%rax,%rcx,4),%ecx
mov    -0x20(%rbp),%rax
mov    %ecx,(%rax)
mov    -0x8(%rbp),%rax
mov    -0x10(%rbp),%rcx
movslq (%rcx),%rcx
movl   $0xff676981,(%rax,%rcx,4)
mov    -0x10(%rbp),%rax
mov    (%rax),%eax
mov    -0x18(%rbp),%rcx
cmp    (%rcx),%eax
jne    1195 <deleteQueue+0x85>
mov    -0x10(%rbp),%rax
movl   $0xffffffff,(%rax)
mov    -0x18(%rbp),%rax
movl   $0xffffffff,(%rax)
jmp    11a4 <deleteQueue+0x94>
mov    -0x10(%rbp),%rax
mov    (%rax),%ecx
add    $0x1,%ecx
mov    -0x10(%rbp),%rax
mov    %ecx,(%rax)
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<deleteQueue>:
test   %rsi,%rsi
je     113a <deleteQueue+0x2a>
movslq (%rsi),%rax
mov    (%rdi,%rax,4),%eax
mov    %eax,(%rcx)
movslq (%rsi),%rax
movl   $0xff676981,(%rdi,%rax,4)
mov    (%rsi),%eax
cmp    (%rdx),%eax
jne    1146 <deleteQueue+0x36>
movl   $0xffffffff,(%rsi)
movl   $0xffffffff,(%rdx)
ret
lea    0xebf(%rip),%rdi
jmp    1030 <printf@plt>
add    $0x1,%eax
mov    %eax,(%rsi)
ret

LLVM IR (-O0):
@.str = [12 x i8] c"\0A\09Underflow\00"
define void @deleteQueue(i32* %0, i32* %1, i32* %2, i32* %3) {
%5 = alloca i32*
%6 = alloca i32*
%7 = alloca i32*
%8 = alloca i32*
store i32* %0, i32** %5
store i32* %1, i32** %6
store i32* %2, i32** %7
store i32* %3, i32** %8
%9 = load i32*, i32** %6
%10 = icmp eq i32* %9, null
br i1 %10, label %11, label %13
11: ; preds = %4
%12 = call i32 @printf(i8* getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0))
br label %39
13: ; preds = %4
%14 = load i32*, i32** %5
%15 = load i32*, i32** %6
%16 = load i32, i32* %15
%17 = sext i32 %16 to i64
%18 = getelementptr inbounds i32, i32* %14, i64 %17
%19 = load i32, i32* %18
%20 = load i32*, i32** %8
store i32 %19, i32* %20
%21 = load i32*, i32** %5
%22 = load i32*, i32** %6
%23 = load i32, i32* %22
%24 = sext i32 %23 to i64
%25 = getelementptr inbounds i32, i32* %21, i64 %24
store i32 -9999999, i32* %25
%26 = load i32*, i32** %6
%27 = load i32, i32* %26
%28 = load i32*, i32** %7
%29 = load i32, i32* %28
%30 = icmp eq i32 %27, %29
br i1 %30, label %31, label %34
31: ; preds = %13
%32 = load i32*, i32** %6
store i32 -1, i32* %32
%33 = load i32*, i32** %7
store i32 -1, i32* %33
br label %39
34: ; preds = %13
%35 = load i32*, i32** %6
%36 = load i32, i32* %35
%37 = add nsw i32 %36, 1
%38 = load i32*, i32** %6
store i32 %37, i32* %38
br label %39
39: ; preds = %11, %34, %31
ret void
}

LLVM IR (-O2):
@.str = [12 x i8] c"\0A\09Underflow\00"
define void @deleteQueue(i32* nocapture %0, i32* %1, i32* nocapture %2, i32* nocapture writeonly %3) {
%5 = icmp eq i32* %1, null
br i1 %5, label %6, label %8
6: ; preds = %4
%7 = tail call i32 @printf(i8* dereferenceable(1) getelementptr inbounds ([12 x i8], [12 x i8]* @.str, i64 0, i64 0))
br label %22
8: ; preds = %4
%9 = load i32, i32* %1
%10 = sext i32 %9 to i64
%11 = getelementptr inbounds i32, i32* %0, i64 %10
%12 = load i32, i32* %11
store i32 %12, i32* %3
%13 = load i32, i32* %1
%14 = sext i32 %13 to i64
%15 = getelementptr inbounds i32, i32* %0, i64 %14
store i32 -9999999, i32* %15
%16 = load i32, i32* %1
%17 = load i32, i32* %2
%18 = icmp eq i32 %16, %17
br i1 %18, label %19, label %20
19: ; preds = %8
store i32 -1, i32* %1
store i32 -1, i32* %2
br label %22
20: ; preds = %8
%21 = add nsw i32 %16, 1
store i32 %21, i32* %1
br label %22
22: ; preds = %6, %20, %19
ret void
}