void foo(int a, int b, int *p, int *q) {
  int i;
#pragma omp parallel if (a)
  ;
#pragma omp parallel if (parallel : a)
  ;
#pragma omp parallel for simd if (a)
  for (i = 0; i < 16; i++)
    ;
#pragma omp parallel for simd if (parallel : a)
  for (i = 0; i < 16; i++)
    ;
#pragma omp task if (a)
  ;
#pragma omp task if (task : a)
  ;
#pragma omp taskloop if (a)
  for (i = 0; i < 16; i++)
    ;
#pragma omp taskloop if (taskloop : a)
  for (i = 0; i < 16; i++)
    ;
#pragma omp target if (a)
  ;
#pragma omp target if (target : a)
  ;
#pragma omp target teams distribute parallel for simd if (a)
  for (i = 0; i < 16; i++)
    ;
#pragma omp target teams distribute parallel for simd if (parallel             \
                                                          : a) if (target      \
                                                                   : b)
  for (i = 0; i < 16; i++)
    ;
#pragma omp target data if (a) map(p [0:2])
  ;
#pragma omp target data if (target data : a) map(p [0:2])
  ;
#pragma omp target enter data if (a) map(to : p [0:2])
#pragma omp target enter data if (target enter data : a) map(to : p [0:2])
#pragma omp target exit data if (a) map(from : p [0:2])
#pragma omp target exit data if (target exit data : a) map(from : p [0:2])
#pragma omp target update if (a) to(q [0:3])
#pragma omp target update if (target update : a) to(q [0:3])
}


x86 assembly (clang, -O0):
<foo>:
push   %rbp
mov    %rsp,%rbp
mov    %edi,-0x4(%rbp)
mov    %esi,-0x8(%rbp)
mov    %rdx,-0x10(%rbp)
mov    %rcx,-0x18(%rbp)
movl   $0x0,-0x1c(%rbp)
cmpl   $0x10,-0x1c(%rbp)
jge    1136 <foo+0x36>
jmp    1128 <foo+0x28>
mov    -0x1c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1c(%rbp)
jmp    1119 <foo+0x19>
movl   $0x0,-0x1c(%rbp)
cmpl   $0x10,-0x1c(%rbp)
jge    115a <foo+0x5a>
jmp    114c <foo+0x4c>
mov    -0x1c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1c(%rbp)
jmp    113d <foo+0x3d>
movl   $0x0,-0x1c(%rbp)
cmpl   $0x10,-0x1c(%rbp)
jge    117e <foo+0x7e>
jmp    1170 <foo+0x70>
mov    -0x1c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1c(%rbp)
jmp    1161 <foo+0x61>
movl   $0x0,-0x1c(%rbp)
cmpl   $0x10,-0x1c(%rbp)
jge    11a2 <foo+0xa2>
jmp    1194 <foo+0x94>
mov    -0x1c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1c(%rbp)
jmp    1185 <foo+0x85>
movl   $0x0,-0x1c(%rbp)
cmpl   $0x10,-0x1c(%rbp)
jge    11c6 <foo+0xc6>
jmp    11b8 <foo+0xb8>
mov    -0x1c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1c(%rbp)
jmp    11a9 <foo+0xa9>
movl   $0x0,-0x1c(%rbp)
cmpl   $0x10,-0x1c(%rbp)
jge    11ea <foo+0xea>
jmp    11dc <foo+0xdc>
mov    -0x1c(%rbp),%eax
add    $0x1,%eax
mov    %eax,-0x1c(%rbp)
jmp    11cd <foo+0xcd>
pop    %rbp
ret

x86 assembly (clang, -O2):
<foo>:
ret

LLVM IR (-O0):
define void @foo(i32 %0, i32 %1, i32* %2, i32* %3) {
%5 = alloca i32
%6 = alloca i32
%7 = alloca i32*
%8 = alloca i32*
%9 = alloca i32
store i32 %0, i32* %5
store i32 %1, i32* %6
store i32* %2, i32** %7
store i32* %3, i32** %8
store i32 0, i32* %9
br label %10
10: ; preds = %14, %4
%11 = load i32, i32* %9
%12 = icmp slt i32 %11, 16
br i1 %12, label %13, label %17
13: ; preds = %10
br label %14
14: ; preds = %13
%15 = load i32, i32* %9
%16 = add nsw i32 %15, 1
store i32 %16, i32* %9
br label %10
17: ; preds = %10
store i32 0, i32* %9
br label %18
18: ; preds = %22, %17
%19 = load i32, i32* %9
%20 = icmp slt i32 %19, 16
br i1 %20, label %21, label %25
21: ; preds = %18
br label %22
22: ; preds = %21
%23 = load i32, i32* %9
%24 = add nsw i32 %23, 1
store i32 %24, i32* %9
br label %18
25: ; preds = %18
store i32 0, i32* %9
br label %26
26: ; preds = %30, %25
%27 = load i32, i32* %9
%28 = icmp slt i32 %27, 16
br i1 %28, label %29, label %33
29: ; preds = %26
br label %30
30: ; preds = %29
%31 = load i32, i32* %9
%32 = add nsw i32 %31, 1
store i32 %32, i32* %9
br label %26
33: ; preds = %26
store i32 0, i32* %9
br label %34
34: ; preds = %38, %33
%35 = load i32, i32* %9
%36 = icmp slt i32 %35, 16
br i1 %36, label %37, label %41
37: ; preds = %34
br label %38
38: ; preds = %37
%39 = load i32, i32* %9
%40 = add nsw i32 %39, 1
store i32 %40, i32* %9
br label %34
41: ; preds = %34
store i32 0, i32* %9
br label %42
42: ; preds = %46, %41
%43 = load i32, i32* %9
%44 = icmp slt i32 %43, 16
br i1 %44, label %45, label %49
45: ; preds = %42
br label %46
46: ; preds = %45
%47 = load i32, i32* %9
%48 = add nsw i32 %47, 1
store i32 %48, i32* %9
br label %42
49: ; preds = %42
store i32 0, i32* %9
br label %50
50: ; preds = %54, %49
%51 = load i32, i32* %9
%52 = icmp slt i32 %51, 16
br i1 %52, label %53, label %57
53: ; preds = %50
br label %54
54: ; preds = %53
%55 = load i32, i32* %9
%56 = add nsw i32 %55, 1
store i32 %56, i32* %9
br label %50
57: ; preds = %50
ret void
}

LLVM IR (-O2):
define void @foo(i32 %0, i32 %1, i32* nocapture %2, i32* nocapture %3) {
ret void
}