Commit Graph

4 Commits

Author SHA1 Message Date
Campbell Barton
5dd91346e1 Cleanup: remove unused imports 2024-01-08 11:40:53 +11:00
Campbell Barton
8974ca8f24 Tools: set the number of jobs to the CPU count for various utilities
Previously this was the double the CPU count because:

- Modern CPU's from AMD & Intel support SMT/hyper-threading which
  present twice as many cores, doubling again has little to no benefit.
- Using 2x or 4x the number of physical cores number can use a lot of
  memory on systems with many cores which are becoming more common.
2023-10-06 21:47:03 +11:00
Campbell Barton
8d58b86228 addr2line_backtrace: fix error printing absolute paths are relative 2023-09-27 16:50:49 +10:00
Campbell Barton
ddf881ad9b Tools: add addr2line_backtrace to extract back-trace info on Unix/Linux
Since hiding symbols on Linux, in many cases only addresses are printed.
This utility can run run on the back-trace to replace addresses
with line & function information.

See: ./tools/utils/addr2line_backtrace.py --help for usage information.

Note that some examples online run addr2line directly and use the output
in the stack-trace, while convenient and acceptable in some cases, in my
tests addr2line can take over 20 seconds to complete for a single
address. Implement this as a post-process instead. Multi-processing to
prevent this taking too long (around ~23 seconds on my system).

Ref !111416.
2023-09-06 22:07:07 +10:00