[all-commits] [llvm/llvm-project] 911163: [test] Fix asan/scudo -shared-libsan tests with -D...

Fangrui Song via All-commits all-commits at lists.llvm.org
Wed Sep 15 09:07:59 PDT 2021


  Branch: refs/heads/main
  Home:   https://github.com/llvm/llvm-project
  Commit: 9111635cb78e4a134364319e2728ff8dd69d36a8
      https://github.com/llvm/llvm-project/commit/9111635cb78e4a134364319e2728ff8dd69d36a8
  Author: Fangrui Song <i at maskray.me>
  Date:   2021-09-15 (Wed, 15 Sep 2021)

  Changed paths:
    M compiler-rt/test/lit.common.cfg.py

  Log Message:
  -----------
  [test] Fix asan/scudo -shared-libsan tests with -DLLVM_ENABLE_PER_TARGET_RUNTIME_DIR=on

On x86_64-unknown-linux-gnu, `-m32` tests set LD_LIBRARY_PATH to
`config.compiler_rt_libdir` (`$build/lib/clang/14.0.0/lib/x86_64-unknown-linux-gnu`)
instead of i386-unknown-linux-gnu, so `-shared-libsan` executables
cannot find their runtime (e.g. `TestCases/replaceable_new_delete.cpp`).

Detect -m32 and -m64 in config.target_cflags, and adjust `config.compiler_rt_libdir`.

Reviewed By: vitalybuka

Differential Revision: https://reviews.llvm.org/D108859




More information about the All-commits mailing list