[PATCH] D95089: [Clang][OpenMP] Use `clang_cc1` test for `declare_target_device_only_compilation.cpp`
Shilei Tian via Phabricator via cfe-commits
cfe-commits at lists.llvm.org
Wed Jan 20 13:55:19 PST 2021
tianshilei1992 created this revision.
tianshilei1992 added a reviewer: echristo.
Herald added subscribers: guansong, yaxunl.
tianshilei1992 requested review of this revision.
Herald added a reviewer: jdoerfert.
Herald added subscribers: cfe-commits, sstefan1.
Herald added a project: clang.
Use `clang_cc1` test for `declare_target_device_only_compilation.cpp`
Repository:
rG LLVM Github Monorepo
https://reviews.llvm.org/D95089
Files:
clang/test/OpenMP/declare_target_device_only_compilation.cpp
Index: clang/test/OpenMP/declare_target_device_only_compilation.cpp
===================================================================
--- clang/test/OpenMP/declare_target_device_only_compilation.cpp
+++ clang/test/OpenMP/declare_target_device_only_compilation.cpp
@@ -1,7 +1,12 @@
-//==========================================================================///
-// RUN: %clang -S -target powerpc64le-ibm-linux-gnu -fopenmp -fopenmp-targets=powerpc64le-ibm-linux-gnu -emit-llvm %s -o - | FileCheck %s
-// RUN: %clang -S -target i386-pc-linux-gnu -fopenmp -fopenmp-targets=i386-pc-linux-gnu -emit-llvm %s -o - | FileCheck %s
-// RUN: %clang -S -target x86_64-unknown-linux-gnu -fopenmp -fopenmp-targets=x86_64-unknown-linux-gnu -emit-llvm %s -o - | FileCheck %s
+// RUN: %clang_cc1 -verify -fopenmp -x c++ -triple powerpc64le-unknown-unknown -fopenmp-targets=powerpc64le-ibm-linux-gnu -emit-llvm-bc %s -o %t-ppc-host.bc
+// RUN: %clang_cc1 -verify -fopenmp -x c++ -triple powerpc64le-unknown-unknown -emit-llvm %s -fopenmp-is-device -fopenmp-host-ir-file-path %t-ppc-host.bc -o - | FileCheck %s
+
+// RUN: %clang_cc1 -verify -fopenmp -x c++ -triple i386-pc-linux-gnu -fopenmp-targets=i386-pc-linux-gnu -emit-llvm-bc %s -o %t-i386-host.bc
+// RUN: %clang_cc1 -verify -fopenmp -x c++ -triple i386-pc-linux-gnu -emit-llvm %s -fopenmp-is-device -fopenmp-host-ir-file-path %t-i386-host.bc -o - | FileCheck %s
+
+// RUN: %clang_cc1 -verify -fopenmp -x c++ -triple x86_64-unknown-linux-gnu -fopenmp-targets=x86_64-unknown-linux-gnu -emit-llvm-bc %s -o %t-x86_64-host.bc
+// RUN: %clang_cc1 -verify -fopenmp -x c++ -triple x86_64-unknown-linux-gnu -emit-llvm %s -fopenmp-is-device -fopenmp-host-ir-file-path %t-x86_64-host.bc -o - | FileCheck %s
+
// expected-no-diagnostics
#pragma omp declare target
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D95089.318000.patch
Type: text/x-patch
Size: 1799 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20210120/1f06b2d4/attachment-0001.bin>
More information about the cfe-commits
mailing list