Skip to content

Commit b3792ae

Browse files
authored
[OpenMP][AIX] Fix test config for AIX (#88272)
This patch fixes the test config so that it works for `tasking/omp50_taskdep_depobj.c` which uses different flags to test with compiler's `omp.h`. * set test environment variable `OBJECT_MODE` to `64` if it is set explicitly to `64` in the AIX environment. `OBJECT_MODE` is default to `32` and is recognized by AIX compilers and toolchain. In this way, we don't need to set `-m64` for all compiler flags for 64-bit mode * add option `-Wl,-bmaxdata` to 32-bit `test_openmp_flags` used by `tasking/omp50_taskdep_depobj.c`
1 parent a6d1366 commit b3792ae

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

openmp/runtime/test/lit.cfg

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -112,13 +112,15 @@ if config.operating_system == 'AIX':
112112
config.available_features.add("aix")
113113
object_mode = os.environ.get('OBJECT_MODE', '32')
114114
if object_mode == '64':
115-
config.test_flags += " -m64"
115+
# Set OBJECT_MODE to 64 for LIT test if it is explicitly set.
116+
config.environment['OBJECT_MODE'] = os.environ['OBJECT_MODE']
116117
elif object_mode == '32':
117118
# Set user data area to 2GB since the default size 256MB in 32-bit mode
118119
# is not sufficient to run LIT tests on systems that have a lot of
119120
# CPUs when creating one worker thread for each CPU and each worker
120121
# thread uses 4MB stack size.
121122
config.test_flags += " -Wl,-bmaxdata:0x80000000"
123+
config.test_openmp_flags += " -Wl,-bmaxdata:0x80000000"
122124

123125
if 'Linux' in config.operating_system:
124126
config.available_features.add("linux")

0 commit comments

Comments
 (0)