[PATCH] D122869: [lit] Fix setup of sanitizer environment

Yuanfang Chen via Phabricator via cfe-commits cfe-commits at lists.llvm.org
Fri Apr 1 15:56:06 PDT 2022


ychen accepted this revision.
ychen added a comment.
This revision is now accepted and ready to land.

I'm looking at relevant code recently. This LGTM.



================
Comment at: clang/test/Unit/lit.cfg.py:33
 
-# Propagate path to symbolizer for ASan/MSan.
-for symbolizer in ['ASAN_SYMBOLIZER_PATH', 'MSAN_SYMBOLIZER_PATH']:
-    if symbolizer in os.environ:
-        config.environment[symbolizer] = os.environ[symbolizer]
+# Propagate sanitizer options.
+for var in [
----------------
vitalybuka wrote:
> ychen wrote:
> > How about initializing an `LLVMConfig` instance instead of replicating this for each project? Although `LLVMConfig` does some extra handling, I guess it shouldn't hurt anything.
> This is /Unit/, not a regular lit test, maybe it will work, but it should be a different patch.
> I can try as followup?
yeah, sounds good to me.


Repository:
  rG LLVM Github Monorepo

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

https://reviews.llvm.org/D122869



More information about the cfe-commits mailing list