[Openmp-commits] [openmp] [OpenMP] Mark Failing OpenMP Tests as XFAIL on Windows (PR #129040)
Omair Javaid via Openmp-commits
openmp-commits at lists.llvm.org
Thu Mar 6 03:48:19 PST 2025
https://github.com/omjavaid updated https://github.com/llvm/llvm-project/pull/129040
>From 49b7226b51d598b3dacc7001a61819413a524221 Mon Sep 17 00:00:00 2001
From: Muhammad Omair Javaid <omair.javaid at linaro.org>
Date: Thu, 27 Feb 2025 13:55:06 +0500
Subject: [PATCH 1/3] [OpenMP] Mark Failing OpenMP Tests as XFAIL on Windows
This patch marks specific OpenMP runtime tests as XFAIL on Windows
due to failures reported in #129023
---
openmp/runtime/test/lit.cfg | 3 +++
openmp/runtime/test/transform/interchange/iterfor.cpp | 1 +
openmp/runtime/test/transform/tile/iterfor.cpp | 1 +
.../worksharing/for/omp_for_collapse_LowerTriangularLess.c | 1 +
.../for/omp_for_collapse_LowerTriangularLessEqual.c | 1 +
.../test/worksharing/for/omp_for_collapse_UpperTriangular.c | 1 +
6 files changed, 8 insertions(+)
diff --git a/openmp/runtime/test/lit.cfg b/openmp/runtime/test/lit.cfg
index 14c7468982137..300ac7a7e9444 100644
--- a/openmp/runtime/test/lit.cfg
+++ b/openmp/runtime/test/lit.cfg
@@ -137,6 +137,9 @@ if config.operating_system in ['Windows', 'Linux', 'FreeBSD', 'NetBSD', 'DragonF
if config.operating_system in ['Linux']:
config.available_features.add('hidden-helper')
+if config.operating_system == 'Windows':
+ config.available_features.add("windows")
+
target_arch = getattr(config, 'target_arch', None)
if target_arch:
config.available_features.add(target_arch + '-target-arch')
diff --git a/openmp/runtime/test/transform/interchange/iterfor.cpp b/openmp/runtime/test/transform/interchange/iterfor.cpp
index 51219a07402e3..de344d17b4b2a 100644
--- a/openmp/runtime/test/transform/interchange/iterfor.cpp
+++ b/openmp/runtime/test/transform/interchange/iterfor.cpp
@@ -1,3 +1,4 @@
+// XFAIL: windows
// RUN: %libomp-cxx20-compile-and-run | FileCheck %s --match-full-lines
#ifndef HEADER
diff --git a/openmp/runtime/test/transform/tile/iterfor.cpp b/openmp/runtime/test/transform/tile/iterfor.cpp
index 12613544f6e5b..94f7b958886bb 100644
--- a/openmp/runtime/test/transform/tile/iterfor.cpp
+++ b/openmp/runtime/test/transform/tile/iterfor.cpp
@@ -1,3 +1,4 @@
+// XFAIL: windows
// RUN: %libomp-cxx20-compile-and-run | FileCheck %s --match-full-lines
#ifndef HEADER
diff --git a/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLess.c b/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLess.c
index 9d742066cf1fc..0ce3f515a4f9d 100644
--- a/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLess.c
+++ b/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLess.c
@@ -1,3 +1,4 @@
+// XFAIL: windows
// RUN: %libomp-compile-and-run
#include <stdio.h>
#include <stdlib.h>
diff --git a/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLessEqual.c b/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLessEqual.c
index 154ee0f69daa5..8b341aa57dc09 100644
--- a/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLessEqual.c
+++ b/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLessEqual.c
@@ -1,3 +1,4 @@
+// XFAIL: windows
// RUN: %libomp-compile-and-run
#include <stdio.h>
#include <stdlib.h>
diff --git a/openmp/runtime/test/worksharing/for/omp_for_collapse_UpperTriangular.c b/openmp/runtime/test/worksharing/for/omp_for_collapse_UpperTriangular.c
index 452410025be0c..0a886091a482c 100644
--- a/openmp/runtime/test/worksharing/for/omp_for_collapse_UpperTriangular.c
+++ b/openmp/runtime/test/worksharing/for/omp_for_collapse_UpperTriangular.c
@@ -1,3 +1,4 @@
+// XFAIL: windows
// RUN: %libomp-compile-and-run
#include <stdio.h>
#include <stdlib.h>
>From c0533b67f3561ea30de8343fce83137c80e3976b Mon Sep 17 00:00:00 2001
From: Muhammad Omair Javaid <omair.javaid at linaro.org>
Date: Mon, 3 Mar 2025 14:37:21 +0500
Subject: [PATCH 2/3] Fix suggestions by David
---
openmp/runtime/test/transform/interchange/iterfor.cpp | 1 +
openmp/runtime/test/transform/tile/iterfor.cpp | 1 +
.../test/worksharing/for/omp_for_collapse_LowerTriangularLess.c | 1 +
.../worksharing/for/omp_for_collapse_LowerTriangularLessEqual.c | 1 +
.../test/worksharing/for/omp_for_collapse_UpperTriangular.c | 1 +
5 files changed, 5 insertions(+)
diff --git a/openmp/runtime/test/transform/interchange/iterfor.cpp b/openmp/runtime/test/transform/interchange/iterfor.cpp
index de344d17b4b2a..931b7351f2391 100644
--- a/openmp/runtime/test/transform/interchange/iterfor.cpp
+++ b/openmp/runtime/test/transform/interchange/iterfor.cpp
@@ -1,4 +1,5 @@
// XFAIL: windows
+// Fails on windows due to issue #129023
// RUN: %libomp-cxx20-compile-and-run | FileCheck %s --match-full-lines
#ifndef HEADER
diff --git a/openmp/runtime/test/transform/tile/iterfor.cpp b/openmp/runtime/test/transform/tile/iterfor.cpp
index 94f7b958886bb..5fc9f972f3afb 100644
--- a/openmp/runtime/test/transform/tile/iterfor.cpp
+++ b/openmp/runtime/test/transform/tile/iterfor.cpp
@@ -1,4 +1,5 @@
// XFAIL: windows
+// Fails on windows due to issue #129023
// RUN: %libomp-cxx20-compile-and-run | FileCheck %s --match-full-lines
#ifndef HEADER
diff --git a/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLess.c b/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLess.c
index 0ce3f515a4f9d..65d0c4134c516 100644
--- a/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLess.c
+++ b/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLess.c
@@ -1,4 +1,5 @@
// XFAIL: windows
+// Fails on windows due to issue #129023
// RUN: %libomp-compile-and-run
#include <stdio.h>
#include <stdlib.h>
diff --git a/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLessEqual.c b/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLessEqual.c
index 8b341aa57dc09..d2da5c4656bfb 100644
--- a/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLessEqual.c
+++ b/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLessEqual.c
@@ -1,4 +1,5 @@
// XFAIL: windows
+// Fails on windows due to issue #129023
// RUN: %libomp-compile-and-run
#include <stdio.h>
#include <stdlib.h>
diff --git a/openmp/runtime/test/worksharing/for/omp_for_collapse_UpperTriangular.c b/openmp/runtime/test/worksharing/for/omp_for_collapse_UpperTriangular.c
index 0a886091a482c..f54556bace251 100644
--- a/openmp/runtime/test/worksharing/for/omp_for_collapse_UpperTriangular.c
+++ b/openmp/runtime/test/worksharing/for/omp_for_collapse_UpperTriangular.c
@@ -1,4 +1,5 @@
// XFAIL: windows
+// Fails on windows due to issue #129023
// RUN: %libomp-compile-and-run
#include <stdio.h>
#include <stdlib.h>
>From 7ed6c3de79c636cfbdae488edcd975a52a9c7892 Mon Sep 17 00:00:00 2001
From: Muhammad Omair Javaid <omair.javaid at linaro.org>
Date: Thu, 6 Mar 2025 16:43:11 +0500
Subject: [PATCH 3/3] XFAIL only for MSVC frontend
---
openmp/runtime/test/lit.cfg | 4 ++--
openmp/runtime/test/lit.site.cfg.in | 1 +
openmp/runtime/test/transform/interchange/iterfor.cpp | 2 +-
openmp/runtime/test/transform/tile/iterfor.cpp | 2 +-
.../worksharing/for/omp_for_collapse_LowerTriangularLess.c | 2 +-
.../for/omp_for_collapse_LowerTriangularLessEqual.c | 2 +-
.../test/worksharing/for/omp_for_collapse_UpperTriangular.c | 2 +-
7 files changed, 8 insertions(+), 7 deletions(-)
diff --git a/openmp/runtime/test/lit.cfg b/openmp/runtime/test/lit.cfg
index 300ac7a7e9444..83a463cfc6057 100644
--- a/openmp/runtime/test/lit.cfg
+++ b/openmp/runtime/test/lit.cfg
@@ -137,8 +137,8 @@ if config.operating_system in ['Windows', 'Linux', 'FreeBSD', 'NetBSD', 'DragonF
if config.operating_system in ['Linux']:
config.available_features.add('hidden-helper')
-if config.operating_system == 'Windows':
- config.available_features.add("windows")
+if config.compiler_frontend_variant == 'MSVC':
+ config.available_features.add("msvc")
target_arch = getattr(config, 'target_arch', None)
if target_arch:
diff --git a/openmp/runtime/test/lit.site.cfg.in b/openmp/runtime/test/lit.site.cfg.in
index d6c259280619b..15021ed3eab53 100644
--- a/openmp/runtime/test/lit.site.cfg.in
+++ b/openmp/runtime/test/lit.site.cfg.in
@@ -21,6 +21,7 @@ config.has_libatomic = @LIBOMP_HAVE_LIBATOMIC@
config.is_standalone_build = @OPENMP_STANDALONE_BUILD@
config.has_omit_frame_pointer_flag = @OPENMP_TEST_COMPILER_HAS_OMIT_FRAME_POINTER_FLAGS@
config.target_arch = "@LIBOMP_ARCH@"
+config.compiler_frontend_variant="@CMAKE_C_COMPILER_FRONTEND_VARIANT@"
# Let the main config do the real work.
lit_config.load_config(config, "@LIBOMP_BASE_DIR@/test/lit.cfg")
diff --git a/openmp/runtime/test/transform/interchange/iterfor.cpp b/openmp/runtime/test/transform/interchange/iterfor.cpp
index 931b7351f2391..98a398fe8925e 100644
--- a/openmp/runtime/test/transform/interchange/iterfor.cpp
+++ b/openmp/runtime/test/transform/interchange/iterfor.cpp
@@ -1,4 +1,4 @@
-// XFAIL: windows
+// XFAIL: msvc
// Fails on windows due to issue #129023
// RUN: %libomp-cxx20-compile-and-run | FileCheck %s --match-full-lines
diff --git a/openmp/runtime/test/transform/tile/iterfor.cpp b/openmp/runtime/test/transform/tile/iterfor.cpp
index 5fc9f972f3afb..05b5677bf9c4f 100644
--- a/openmp/runtime/test/transform/tile/iterfor.cpp
+++ b/openmp/runtime/test/transform/tile/iterfor.cpp
@@ -1,4 +1,4 @@
-// XFAIL: windows
+// XFAIL: msvc
// Fails on windows due to issue #129023
// RUN: %libomp-cxx20-compile-and-run | FileCheck %s --match-full-lines
diff --git a/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLess.c b/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLess.c
index 65d0c4134c516..c11e9ec43f4c0 100644
--- a/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLess.c
+++ b/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLess.c
@@ -1,4 +1,4 @@
-// XFAIL: windows
+// XFAIL: msvc
// Fails on windows due to issue #129023
// RUN: %libomp-compile-and-run
#include <stdio.h>
diff --git a/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLessEqual.c b/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLessEqual.c
index d2da5c4656bfb..3249594664489 100644
--- a/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLessEqual.c
+++ b/openmp/runtime/test/worksharing/for/omp_for_collapse_LowerTriangularLessEqual.c
@@ -1,4 +1,4 @@
-// XFAIL: windows
+// XFAIL: msvc
// Fails on windows due to issue #129023
// RUN: %libomp-compile-and-run
#include <stdio.h>
diff --git a/openmp/runtime/test/worksharing/for/omp_for_collapse_UpperTriangular.c b/openmp/runtime/test/worksharing/for/omp_for_collapse_UpperTriangular.c
index f54556bace251..cc10ddb0e9104 100644
--- a/openmp/runtime/test/worksharing/for/omp_for_collapse_UpperTriangular.c
+++ b/openmp/runtime/test/worksharing/for/omp_for_collapse_UpperTriangular.c
@@ -1,4 +1,4 @@
-// XFAIL: windows
+// XFAIL: msvc
// Fails on windows due to issue #129023
// RUN: %libomp-compile-and-run
#include <stdio.h>
More information about the Openmp-commits
mailing list