twister: Add option for generating rom.json and ram.json
Generate the files via the 'footprint' target for each project. Signed-off-by: Øyvind Rønningstad <oyvind.ronningstad@nordicsemi.no>
This commit is contained in:
parent
f9f0748c96
commit
bb1cfbad19
|
@ -364,6 +364,11 @@ structure in the main Zephyr tree: boards/<arch>/<board_name>/""")
|
|||
parser.add_argument("--enable-size-report", action="store_true",
|
||||
help="Enable expensive computation of RAM/ROM segment sizes.")
|
||||
|
||||
parser.add_argument("--create-rom-ram-report", action="store_true",
|
||||
help="Generate detailed ram/rom json reports for "
|
||||
"each build, via cmake build calls with the "
|
||||
"`--target footprint` argument")
|
||||
|
||||
parser.add_argument(
|
||||
"--filter", choices=['buildable', 'runnable'],
|
||||
default='buildable',
|
||||
|
|
|
@ -1062,6 +1062,8 @@ class ProjectBuilder(FilterBuilder):
|
|||
sys.stdout.flush()
|
||||
|
||||
def gather_metrics(self, instance: TestInstance):
|
||||
if self.options.create_rom_ram_report:
|
||||
self.run_build(['--build', self.build_dir, "--target", "footprint"])
|
||||
if self.options.enable_size_report and not self.options.cmake_only:
|
||||
self.calc_size(instance=instance, from_buildlog=self.options.footprint_from_buildlog)
|
||||
else:
|
||||
|
|
Loading…
Reference in a new issue