[flang-commits] [flang] [flang] Update a test case for AIX (NFC) (PR #201865)

Kelvin Li via flang-commits flang-commits at lists.llvm.org
Fri Jun 5 08:41:23 PDT 2026


https://github.com/kkwli created https://github.com/llvm/llvm-project/pull/201865

-fdata-sections is specified by default on AIX. This patch is to adjust the testing for the case that the option is off and on by default.

>From e7cd034268cb4cf2bf84c8cbea1086968734e25c Mon Sep 17 00:00:00 2001
From: Kelvin Li <kli at ca.ibm.com>
Date: Fri, 5 Jun 2026 11:37:22 -0400
Subject: [PATCH] [flang] Update a test case for AIX (NFC)

-fdata-sections is specified by default on AIX. This
patch is to adjust the testing for the case that the option
is off and on by default.
---
 flang/test/Driver/function-sections.f90 | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/flang/test/Driver/function-sections.f90 b/flang/test/Driver/function-sections.f90
index 7072d62a9d3e2..b40d2cbda11c0 100644
--- a/flang/test/Driver/function-sections.f90
+++ b/flang/test/Driver/function-sections.f90
@@ -5,9 +5,12 @@
 ! CHECK-DS: "-fdata-sections"
 ! CHECK-NODS-NOT: "-fdata-sections"
 
-! RUN: %flang -### %s 2>&1 \
+! RUN: %flang -### -target x86_64-none-linux-gnu %s 2>&1 \
 ! RUN:   | FileCheck %s --check-prefix=CHECK-NOFS --check-prefix=CHECK-NODS
 
+! RUN: %flang -### -target powerpc64-ibm-aix-xcoff %s 2>&1 \
+! RUN:   | FileCheck %s --check-prefix=CHECK-NOFS
+
 ! RUN: %flang -### %s -ffunction-sections 2>&1 \
 ! RUN:   | FileCheck %s --check-prefix=CHECK-FS
 



More information about the flang-commits mailing list