[flang-commits] [flang] [flang][test] Fix Lower/default-initialization-globals.f90 on SPARC (PR #103722)
Rainer Orth via flang-commits
flang-commits at lists.llvm.org
Wed Aug 14 02:03:26 PDT 2024
https://github.com/rorth created https://github.com/llvm/llvm-project/pull/103722
`Flang :: Lower/default-initialization-globals.f90` `FAIL`s on SPARC, both Solaris/sparcv9 and Linux/sparc64.
The failure mode is same as on AIX/PowerPC, so both targets being big-endian, this patch treats them the same.
Tested on `sparcv9-sun-solaris2.11`, `sparc64-unknown-linux-gnu`, `amd64-pc-solaris2.11`, and `x86_64-pc-linux-gnu`.
>From 18588e0fd9b03336b693099e433bd62d311454d4 Mon Sep 17 00:00:00 2001
From: Rainer Orth <ro at gcc.gnu.org>
Date: Wed, 14 Aug 2024 11:00:37 +0200
Subject: [PATCH] [flang][test] Fix Lower/default-initialization-globals.f90 on
SPARC
`Flang :: Lower/default-initialization-globals.f90` `FAIL`s on SPARC, both
Solaris/sparcv9 and Linux/sparc64.
The failure mode is same as on AIX/PowerPC, so both targets being
big-endian, this patch treats them the same.
Tested on `sparcv9-sun-solaris2.11`, `sparc64-unknown-linux-gnu`,
`amd64-pc-solaris2.11`, and `x86_64-pc-linux-gnu`.
---
flang/test/Lower/default-initialization-globals.f90 | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/flang/test/Lower/default-initialization-globals.f90 b/flang/test/Lower/default-initialization-globals.f90
index 384d1cb763ad67..e9611dab467cba 100644
--- a/flang/test/Lower/default-initialization-globals.f90
+++ b/flang/test/Lower/default-initialization-globals.f90
@@ -1,5 +1,5 @@
! Test default initialization of global variables (static init)
-! RUN: bbc -hlfir=false %s -o - | FileCheck %s --check-prefixes=%if system-aix %{"CHECK","CHECK-BE"%} \
+! RUN: bbc -hlfir=false %s -o - | FileCheck %s --check-prefixes=%if target={{.*-aix.*|sparc.*}} %{"CHECK","CHECK-BE"%} \
! RUN: %else %{"CHECK","CHECK-LE"%}
module tinit
More information about the flang-commits
mailing list