#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*/ abort();
int /*<<< orphan*/ foo(long long *, long long *);
int main() {
  long long int p = 1LL, q = 1LL;
  foo(&p, &q);
  if (p != 6LL * 6LL * 6LL * 6LL * 6LL * 2LL || q != 6LL * 6LL * 6LL * 6LL)
    abort();
  p = 1LL;
  q = 1LL;
#pragma omp taskgroup
  foo(&p, &q);
  if (p != 6LL * 6LL * 6LL * 6LL * 6LL * 2LL || q != 6LL * 6LL * 6LL * 6LL)
    abort();
  p = 1LL;
  q = 1LL;
#pragma omp parallel
#pragma omp single
  foo(&p, &q);
  if (p != 6LL * 6LL * 6LL * 6LL * 6LL * 2LL || q != 6LL * 6LL * 6LL * 6LL)
    abort();
  return 0;
}


x86 assembly (clang, -O0):
<main>:
push   %rbp
mov    %rsp,%rbp
sub    $0x20,%rsp
movl   $0x0,-0x4(%rbp)
movq   $0x1,-0x10(%rbp)
movq   $0x1,-0x18(%rbp)
lea    -0x10(%rbp),%rdi
lea    -0x18(%rbp),%rsi
call   1040 <foo@plt>
cmpq   $0x3cc0,-0x10(%rbp)
jne    1168 <main+0x48>
cmpq   $0x510,-0x18(%rbp)
je     116f <main+0x4f>
mov    $0x0,%al
call   1030 <abort@plt>
movq   $0x1,-0x10(%rbp)
movq   $0x1,-0x18(%rbp)
lea    -0x10(%rbp),%rdi
lea    -0x18(%rbp),%rsi
call   1040 <foo@plt>
cmpq   $0x3cc0,-0x10(%rbp)
jne    11a8 <main+0x88>
cmpq   $0x510,-0x18(%rbp)
je     11af <main+0x8f>
mov    $0x0,%al
call   1030 <abort@plt>
movq   $0x1,-0x10(%rbp)
movq   $0x1,-0x18(%rbp)
lea    -0x10(%rbp),%rdi
lea    -0x18(%rbp),%rsi
call   1040 <foo@plt>
cmpq   $0x3cc0,-0x10(%rbp)
jne    11e8 <main+0xc8>
cmpq   $0x510,-0x18(%rbp)
je     11ef <main+0xcf>
mov    $0x0,%al
call   1030 <abort@plt>
xor    %eax,%eax
add    $0x20,%rsp
pop    %rbp
ret

x86 assembly (clang, -O2):
<main>:
sub    $0x18,%rsp
movq   $0x1,0x10(%rsp)
movq   $0x1,0x8(%rsp)
lea    0x10(%rsp),%rdi
lea    0x8(%rsp),%rsi
call   1040 <foo@plt>
cmpq   $0x3cc0,0x10(%rsp)
jne    11d4 <main+0xb4>
cmpq   $0x510,0x8(%rsp)
jne    11d4 <main+0xb4>
movq   $0x1,0x10(%rsp)
movq   $0x1,0x8(%rsp)
lea    0x10(%rsp),%rdi
lea    0x8(%rsp),%rsi
call   1040 <foo@plt>
cmpq   $0x3cc0,0x10(%rsp)
jne    11d4 <main+0xb4>
cmpq   $0x510,0x8(%rsp)
jne    11d4 <main+0xb4>
movq   $0x1,0x10(%rsp)
movq   $0x1,0x8(%rsp)
lea    0x10(%rsp),%rdi
lea    0x8(%rsp),%rsi
call   1040 <foo@plt>
cmpq   $0x3cc0,0x10(%rsp)
jne    11d4 <main+0xb4>
cmpq   $0x510,0x8(%rsp)
jne    11d4 <main+0xb4>
xor    %eax,%eax
add    $0x18,%rsp
ret
xor    %eax,%eax
call   1030 <abort@plt>

LLVM IR (-O0):
define i32 @main() {
%1 = alloca i32
%2 = alloca i64
%3 = alloca i64
store i32 0, i32* %1
store i64 1, i64* %2
store i64 1, i64* %3
%4 = call i32 @foo(i64* %2, i64* %3)
%5 = load i64, i64* %2
%6 = icmp ne i64 %5, 15552
br i1 %6, label %10, label %7
7: ; preds = %0
%8 = load i64, i64* %3
%9 = icmp ne i64 %8, 1296
br i1 %9, label %10, label %12
10: ; preds = %7, %0
%11 = call i32 (...) @abort()
unreachable
12: ; preds = %7
store i64 1, i64* %2
store i64 1, i64* %3
%13 = call i32 @foo(i64* %2, i64* %3)
%14 = load i64, i64* %2
%15 = icmp ne i64 %14, 15552
br i1 %15, label %19, label %16
16: ; preds = %12
%17 = load i64, i64* %3
%18 = icmp ne i64 %17, 1296
br i1 %18, label %19, label %21
19: ; preds = %16, %12
%20 = call i32 (...) @abort()
unreachable
21: ; preds = %16
store i64 1, i64* %2
store i64 1, i64* %3
%22 = call i32 @foo(i64* %2, i64* %3)
%23 = load i64, i64* %2
%24 = icmp ne i64 %23, 15552
br i1 %24, label %28, label %25
25: ; preds = %21
%26 = load i64, i64* %3
%27 = icmp ne i64 %26, 1296
br i1 %27, label %28, label %30
28: ; preds = %25, %21
%29 = call i32 (...) @abort()
unreachable
30: ; preds = %25
ret i32 0
}

LLVM IR (-O2):
define i32 @main() {
%1 = alloca i64
%2 = alloca i64
%3 = bitcast i64* %1 to i8*
store i64 1, i64* %1
%4 = bitcast i64* %2 to i8*
store i64 1, i64* %2
%5 = call i32 @foo(i64* %1, i64* %2)
%6 = load i64, i64* %1
%7 = icmp ne i64 %6, 15552
%8 = load i64, i64* %2
%9 = icmp ne i64 %8, 1296
%10 = select i1 %7, i1 true, i1 %9
br i1 %10, label %11, label %13
11: ; preds = %0
%12 = call i32 (...) @abort()
unreachable
13: ; preds = %0
store i64 1, i64* %1
store i64 1, i64* %2
%14 = call i32 @foo(i64* %1, i64* %2)
%15 = load i64, i64* %1
%16 = icmp ne i64 %15, 15552
%17 = load i64, i64* %2
%18 = icmp ne i64 %17, 1296
%19 = select i1 %16, i1 true, i1 %18
br i1 %19, label %20, label %22
20: ; preds = %13
%21 = call i32 (...) @abort()
unreachable
22: ; preds = %13
store i64 1, i64* %1
store i64 1, i64* %2
%23 = call i32 @foo(i64* %1, i64* %2)
%24 = load i64, i64* %1
%25 = icmp ne i64 %24, 15552
%26 = load i64, i64* %2
%27 = icmp ne i64 %26, 1296
%28 = select i1 %25, i1 true, i1 %27
br i1 %28, label %29, label %31
29: ; preds = %22
%30 = call i32 (...) @abort()
unreachable
31: ; preds = %22
ret i32 0
}