zephyr/scripts
Galen Krulce 5ae9f44825 code_relocation: Cache list of obj files
As part of relocation, this script matches each source file to its
corresponding object file. This matching is done inside of get_obj_filename
which is called once per source file.

get_obj_filename traverses the entire build directory on every invocation.
This is unnecessary since built object files don't change. On a
sufficiently large project (like mine), this script takes over a minute and
the majority of that time is spent needlessly traversing the build
directory again and again.

Caching the list of object files enables this script to run in less than a
second.

I tested by building my project (which enables the relocation script) and
comparing memory breakdown before / after.

Signed-off-by: Galen Krulce <gkrulce@meta.com>
2025-03-28 16:17:11 +01:00
..
build code_relocation: Cache list of obj files 2025-03-28 16:17:11 +01:00
checkpatch arch: remove z_arch_esf_t 2025-01-23 16:32:36 +01:00
ci ci: add empty CODEOWNERS file 2025-03-27 09:50:45 +01:00
coccinelle
coredump scripts: coredump: Fix loading coredumps when thread info is enabled. 2024-12-09 22:06:23 +00:00
dts style: edtlib: Remove the redundant keys() method 2025-03-28 12:22:00 +01:00
footprint scripts: footprint: Exclude data section from rom_report if XIP=n 2025-03-08 03:37:27 +01:00
generate_usb_vif python: Format and sort imports 2024-11-25 10:07:13 +01:00
gitlint
kconfig scripts: kconfig: introduce dt_nodelabel_exists 2025-03-11 18:54:57 +01:00
logging/dictionary scripts: logging: dictionary: fix parsing of DWARF v5 2024-12-20 12:36:46 +01:00
native_simulator native_simulator: Get latest from upstream 2025-03-10 06:52:19 +01:00
net
profiling
pylib twister: Add missing spaces 2025-03-27 17:18:04 +01:00
pylint/checkers
release
ruff scripts: Add helper scripts for ruff baseline excludes 2024-11-19 18:36:54 -05:00
schemas twister: config: test on integration plaforms if defined 2025-03-19 08:51:50 -04:00
support
tests twister: Remove unrecognised sections test 2025-03-24 07:53:01 +01:00
tracing tracing: add named event trace 2024-10-17 10:46:52 -04:00
utils scripts: utils: posix: add dry-run option and improve logging 2025-03-12 19:03:52 +01:00
west_commands scripts: west: commands: completion: zsh: add "west shields" completion 2025-03-26 21:56:33 +01:00
.gitignore
check_maintainers.py python: Format and sort imports 2024-11-25 10:07:13 +01:00
checkpatch.pl checkpatch: Allow __BYTE_ORDER__ and __aligned__ in toolchain files 2025-02-14 19:12:44 +00:00
checkstack.pl
coccicheck
dump_bugs_pickle.py
gen_gcov_files.py
get_maintainer.py
github_helpers.py
list_boards.py scripts: Undo Board.{dir -> directories[0]} renames 2024-10-26 17:14:06 +02:00
list_hardware.py scripts: list_hardware: Do not check qualifiers for run once config 2024-10-26 17:14:06 +02:00
list_shields.py
make_bugs_pickle.py
requirements-base.txt scripts: make sure we do not install vulunerable python packages 2025-03-22 14:03:56 -04:00
requirements-build-test.txt scripts: twister: Add CTest harness 2025-01-10 04:12:42 +01:00
requirements-compliance.txt scripts: make sure we do not install vulunerable python packages 2025-03-22 14:03:56 -04:00
requirements-extras.txt scripts: make sure we do not install vulunerable python packages 2025-03-22 14:03:56 -04:00
requirements-run-test.txt scripts: make sure we do not install vulunerable python packages 2025-03-22 14:03:56 -04:00
requirements.txt
series-push-hook.sh
set_assignees.py
snippets.py sysbuild: Add support for snippets 2024-12-27 07:18:13 +01:00
spelling.txt
tags.sh
twister scripts: twister: Python Version Guard 2024-11-04 17:24:24 -05:00
valgrind.supp
west-commands.yml scripts: add "west gtags" command 2025-03-07 19:57:00 +01:00
zephyr_module.py scripts: west_commands: Support out-of-tree runners 2025-01-08 17:02:06 +01:00