llvm-project/llvm/test/tools
Fangrui Song 06cad825cd PrintStackTrace: don't symbolize if LLVM_DISABLE_SYMBOLIZATION is set
See http://lists.llvm.org/pipermail/llvm-dev/2017-June/113975.html for a related previous discussion.
Many tools install signal handlers to print stack traces and optionally
symbolize the addresses with an external program 'llvm-symbolizer' (when
searching for 'llvm-symbolizer', the directory containg the executable
is preferred over PATH).

'llvm-symbolizer' can be slow if the executable is large and/or if
llvm-symbolizer' itself is under-optimized. For example, my 'llvm-lto2' from a
-DCMAKE_BUILD_TYPE=Debug build is 443MiB. The 'llvm-symbolizer' from the same
build takes ~2s to symbolize it. (An optimized 'llvm-symbolizer' takes 0.34s).
A crashed clang may take more than 5s to symbolize a stack trace.

If a test file has several `not --crash` RUN lines. It can be very slow in a Debug build.
This patch makes `not --crash` set an environment variable to suppress symbolization.
This is similar to D33804 which uses a command line option.
I pick 'symbolization' instead of 'symbolication' because the former is
used much more commonly and its stem matches 'llvm-symbolizer'.

Also set LLVM_DISABLE_CRASH_REPORT=1, which is currently only applicable on
`__APPLE__`.

Reviewed By: dblaikie, aganea

Differential Revision: https://reviews.llvm.org/D86170
2020-08-21 11:27:13 -07:00
..
UpdateTestChecks [UpdateTestChecks] Match unnamed values like "@[0-9]+" and "![0-9]+" 2020-08-12 01:04:16 -05:00
dsymutil [dsymutil] Disable dsymutil/X86/reproducer.test on windows. 2020-08-06 12:49:35 +03:00
gold Add test utility 'split-file' 2020-08-03 20:42:09 -07:00
llc
llvm-ar [llvm-ar][test][AIX] Unsupport error-opening-directory.test on AIX 2020-07-13 12:00:07 -04:00
llvm-as [test] Run llvm/test/**/*.yaml & don't run llvm/test/**/*.cxx (not exist) 2020-07-08 10:22:49 -07:00
llvm-cfi-verify
llvm-config
llvm-cov [llvm-cov] reset executation count to 0 after wrapped segment 2020-08-04 18:38:44 -07:00
llvm-cvtres
llvm-cxxdump
llvm-cxxfilt
llvm-cxxmap
llvm-diff
llvm-dlltool [llvm-dlltool] Add a testcase to show the kind of weak external used for import library aliases. NFC. 2020-03-14 14:00:36 +02:00
llvm-dwarfdump [DWARFYAML] Add support for emitting multiple abbrev tables. 2020-08-21 10:12:08 +08:00
llvm-dwp llvm-dwarfdump: Include unit count in DWP index header dumping 2020-06-12 12:40:02 -07:00
llvm-elfabi [yaml2obj] - Set a default value for `PAddr` property of a program header to a value of `VAddr` 2020-03-14 17:44:57 +03:00
llvm-exegesis Reland [llvm-exegesis] Add benchmark latency option on X86 that uses LBR for more precise measurements. 2020-07-27 12:38:05 -04:00
llvm-extract
llvm-gsymutil [DWARFYAML] Add support for emitting multiple abbrev tables. 2020-08-21 10:12:08 +08:00
llvm-ifs [llvm-readobj] Update tests because of changes in llvm-readobj behavior 2020-07-20 10:39:04 +01:00
llvm-isel-fuzzer
llvm-lib [llvm-lib] Support adding short import library objects with llvm-lib 2020-07-24 22:15:08 +03:00
llvm-libtool-darwin [llvm-libtool-darwin] Fix test on all host architectures 2020-08-16 00:18:03 -07:00
llvm-link Fix test that was accidentally adding the llvm-as binary into an 2020-07-14 17:07:40 -07:00
llvm-lipo
llvm-lit
llvm-locstats Reland D73534: [DebugInfo] Enable the debug entry values feature by default 2020-03-19 13:57:30 +01:00
llvm-lto [ThinLTO] Compute the basic block count across modules. 2020-05-28 10:33:05 -07:00
llvm-lto2 Revert "Revert "Reland "[Support] make report_fatal_error `abort` instead of `exit`""" 2020-02-13 10:16:06 -08:00
llvm-mc
llvm-mca [X86] Add mayLoad/mayStore flags to some X87 instructions that don't have isel patterns to infer them from. 2020-06-23 23:40:30 -07:00
llvm-ml [ms] [llvm-ml] Restore omitted changes requested by reviewer 2020-07-13 10:49:19 -04:00
llvm-modextract
llvm-mt
llvm-nm [test] Run llvm/test/**/*.yaml & don't run llvm/test/**/*.cxx (not exist) 2020-07-08 10:22:49 -07:00
llvm-objcopy [DWARFYAML] Add support for emitting multiple abbrev tables. 2020-08-21 10:12:08 +08:00
llvm-objdump Revert "[AMDGPU] Support disassembly for AMDGPU kernel descriptors" 2020-08-19 13:12:29 +05:30
llvm-opt-fuzzer
llvm-opt-report
llvm-pdbutil
llvm-profdata [llvm-profdata] Implement llvm-profdata overlap for sample profiles 2020-08-08 17:49:48 -07:00
llvm-ranlib [llvm-ranlib][test] Fix rwx- after a4f3847f3d 2020-02-14 19:41:55 -08:00
llvm-rc [llvm-rc] Allow string table values split into multiple string literals 2020-08-05 08:59:32 +03:00
llvm-readobj [llvm-readelf][test] - Refine the merged.test 2020-08-21 15:07:37 +03:00
llvm-size [llvm-size] Output REL, RELA and STRTAB sections when allocatable 2020-07-01 12:02:32 +01:00
llvm-split
llvm-strings Add test utility 'split-file' 2020-08-03 20:42:09 -07:00
llvm-symbolizer [llvm-symbolizer] Add back --version and add a -v alias 2020-08-10 08:21:43 -07:00
llvm-xray [XRay] Account: recursion detection 2020-07-27 10:15:44 +03:00
lto
not PrintStackTrace: don't symbolize if LLVM_DISABLE_SYMBOLIZATION is set 2020-08-21 11:27:13 -07:00
obj2yaml [yaml2obj] - Make the 'Machine' key optional. 2020-08-20 11:40:51 +03:00
opt-viewer Fix opt-viewer tests failing after move from cgi.escape to html.escape 2020-04-17 08:37:47 +02:00
sancov [sancov] Accommodate sancov and coverage report server for use under Windows 2020-05-26 14:36:44 -07:00
sanstats
split-file Add test utility 'split-file' 2020-08-03 20:42:09 -07:00
yaml2obj Recommit: [DWARFYAML] Add support for referencing different abbrev tables. 2020-08-21 19:02:10 +08:00