Commit Graph

3 Commits

Author SHA1 Message Date
8755879c0d Harden vs_layout_census BOM/limit validation and atomic --json writes 2026-11-26 18:45:12 +08:00
ad136ffb9c vs_layout_census: refuse a --json that is an input or a directory before survey() (BUILD-589)
--json was checked with a raw os.path.samefile against index.json only, so
naming an indexed .dxbc container or a disasm/*.s listing overwrote that
input, and a directory ran survey() (llvm-mc over the corpus) before the
write failed.

main() now refuses, before survey() runs, a --json that is an existing
directory, and one that tools/report_paths.same_report_path matches against
index.json or any container or listing the index names (input_paths(), which
shares load_index() with survey()). Each refusal is one error line and exit 2.

Synthetic tests in tests/test_vs_layout_census.py: a listing, a container and
index.json refuse and stay unchanged; a directory refuses with survey() and
default_disasm mocked and never called; a ../ spelling, a symlink, a hard link
and (on a case-folding volume) another case refuse; a separate --json still runs.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-11-24 08:00:13 -05:00
4cd82fe3fa vs_layout_census: confirm legacy non-NGG VS per PAL hardware stage; measure the 195 ES variants (#6558)
Squash-merged after diff review of PR #6558
2026-11-23 12:45:04 -06:00