xref: /llvm-project/clang/test/Driver/target-id.cl (revision 12949c952c4fbad776a860c003ccf176973278a0)
1// RUN: %clang -### -target amdgcn-amd-amdhsa \
2// RUN:   -mcpu=gfx908:xnack+:sramecc- \
3// RUN:   -nostdlib %s 2>&1 | FileCheck %s
4
5// RUN: %clang -### -target amdgcn-amd-amdhsa \
6// RUN:   -mcpu=gfx908:xnack+:sramecc- \
7// RUN:   -nostdlib -x ir %s 2>&1 | FileCheck %s
8
9// RUN: %clang -### -target amdgcn-amd-amdhsa \
10// RUN:   -mcpu=gfx908:xnack+:sramecc- \
11// RUN:   -nostdlib -x assembler %s 2>&1 | FileCheck %s
12
13// RUN: %clang -### -target amdgcn-amd-amdpal \
14// RUN:   -mcpu=gfx908:xnack+:sramecc- \
15// RUN:   -nostdlib %s 2>&1 | FileCheck %s
16
17// RUN: %clang -### -target amdgcn--mesa3d \
18// RUN:   -mcpu=gfx908:xnack+:sramecc- \
19// RUN:   -nostdlib %s 2>&1 | FileCheck %s
20
21// RUN: %clang -### -target amdgcn-amd-amdhsa \
22// RUN:   -nostdlib %s 2>&1 | FileCheck -check-prefix=NONE %s
23
24// CHECK: "-target-cpu" "gfx908"
25// CHECK-SAME: "-target-feature" "-sramecc"
26// CHECK-SAME: "-target-feature" "+xnack"
27
28// NONE-NOT: "-target-cpu"
29// NONE-NOT: "-target-feature"
30