[clang] 55c2137 - [testcase][OpenMP] Fix the testcase error of check-all when DCLANG_DEFAULT_OPENMP_RUNTIME is not libomp

Zi Xuan Wu via cfe-commits cfe-commits at lists.llvm.org
Wed Oct 19 19:19:59 PDT 2022


Author: Zi Xuan Wu (Zeson)
Date: 2022-10-20T10:19:37+08:00
New Revision: 55c2137939d8e12c064cedcda21108c239dddf8e

URL: https://github.com/llvm/llvm-project/commit/55c2137939d8e12c064cedcda21108c239dddf8e
DIFF: https://github.com/llvm/llvm-project/commit/55c2137939d8e12c064cedcda21108c239dddf8e.diff

LOG: [testcase][OpenMP] Fix the testcase error of check-all when DCLANG_DEFAULT_OPENMP_RUNTIME is not libomp

When DCLANG_DEFAULT_OPENMP_RUNTIME is set to libgomp, there is some check-all error.
The expected CHECK result only displays when fopenmp=libomp is specified explicitly.

Differential Revision: https://reviews.llvm.org/D136239

Added: 
    

Modified: 
    clang/test/Driver/fopenmp.c
    clang/test/Index/openmp-tile.c

Removed: 
    


################################################################################
diff  --git a/clang/test/Driver/fopenmp.c b/clang/test/Driver/fopenmp.c
index aadade101125e..6e31de109912b 100644
--- a/clang/test/Driver/fopenmp.c
+++ b/clang/test/Driver/fopenmp.c
@@ -140,7 +140,7 @@
 // CHECK-LD-STATIC-IOMP5-NO-BDYNAMIC: "-{{B?}}static" {{.*}} "-liomp5"
 // CHECK-LD-STATIC-IOMP5-NO-BDYNAMIC-NOT: "-Bdynamic"
 //
-// RUN: %clang -target x86_64-linux-gnu -fopenmp -fopenmp-enable-irbuilder -c %s -### 2>&1 | FileCheck %s --check-prefix=CHECK-CC1-OPENMPIRBUILDER
+// RUN: %clang -target x86_64-linux-gnu -fopenmp=libomp -fopenmp-enable-irbuilder -c %s -### 2>&1 | FileCheck %s --check-prefix=CHECK-CC1-OPENMPIRBUILDER
 //
 // CHECK-CC1-OPENMPIRBUILDER: "-cc1"
 // CHECK-CC1-OPENMPIRBUILDER-SAME: "-fopenmp"

diff  --git a/clang/test/Index/openmp-tile.c b/clang/test/Index/openmp-tile.c
index a51bc82c228b1..a9e379e0a4b6c 100644
--- a/clang/test/Index/openmp-tile.c
+++ b/clang/test/Index/openmp-tile.c
@@ -1,4 +1,4 @@
-// RUN: c-index-test -test-load-source local %s -fopenmp -fopenmp-version=51 | FileCheck %s
+// RUN: c-index-test -test-load-source local %s -fopenmp=libomp -fopenmp-version=51 | FileCheck %s
 
 void test() {
 #pragma omp tile sizes(5)


        


More information about the cfe-commits mailing list