[PATCH] D134284: [AIX] change the clang tests with llvm-nm -Xany

Digger Lin via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Tue Sep 20 09:50:46 PDT 2022


DiggerLin updated this revision to Diff 461598.
DiggerLin added a comment.

address comment


Repository:
  rG LLVM Github Monorepo

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D134284/new/

https://reviews.llvm.org/D134284

Files:
  clang/test/lit.cfg.py


Index: clang/test/lit.cfg.py
===================================================================
--- clang/test/lit.cfg.py
+++ clang/test/lit.cfg.py
@@ -283,3 +283,13 @@
     config.environment['AIXTHREAD_STK'] = os.environ['AIXTHREAD_STK']
 elif platform.system() == 'AIX':
     config.environment['AIXTHREAD_STK'] = '4194304'
+
+# llvm-nm tools support an environment variable "OBJECT_MODE" on AIX OS, which
+# controls the kind of objects they will support. If there is no "OBJECT_MODE"
+# environment variable specified, the default behaviour is to support 32-bit
+# objects only. In order to not affect most test cases, which expect to support
+# 32-bit and 64-bit objects by default, set the environment variable
+# "OBJECT_MODE" to 'any' for llvm-nm on AIX OS.
+
+if 'system-aix' in config.available_features:
+    config.substitutions.append(('llvm-nm', 'env OBJECT_MODE=any llvm-nm'))


-------------- next part --------------
A non-text attachment was scrubbed...
Name: D134284.461598.patch
Type: text/x-patch
Size: 894 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/cfe-commits/attachments/20220920/e99c2913/attachment.bin>


More information about the cfe-commits mailing list