Tests: expand low_va integration tests for PE header and directory invariants #2157
Loading…
Reference in a new issue
No description provided.
Delete branch "upstream-pr/2167"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Imported from ivall/xcl. Originally posted by heditrigui on 2026-11-25T07:01:00Z.
Summary
Expands link-time validation in
crates/xcl/tests/low_va.rsto verify essential PE characteristics ofxcl.exe:xcl.exeis built withIMAGE_FILE_LARGE_ADDRESS_AWARE(0x0020) and configured withIMAGE_SUBSYSTEM_WINDOWS_CUI(3) for the AMD64 architecture.DIR_TLS= 9) is present and non-empty, ensuring the host mode TLS callback (.CRT$XLY) is preserved by the linker.DIR_EXCEPTION= 3) is present and non-empty for x64 stack unwinding.Tested
python -m pytest scripts/(25 passed in 0.58s).scripts/pr_check.py --local.Not tested
tests/integration suites are non-runtime code).AI use
Imported from ivall/xcl. Originally posted by DavidM1911 on 2026-11-25T07:20:38Z.
Verification on RTX 3060 Ti (Windows 11), branch merged with current
main:cargo test -p xcl --lib: all passed, 0 failed, ~26 ignored. (Intermittent single-test flake / 0xc0000005 abort under parallel scheduling — tracked in #1978; clean on single-threaded rerun.)Thanks!
Imported from ivall/xcl. Originally posted by raylitebull on 2026-11-25T10:48:33Z.
Code review on
fa26aa7:xcl_exe_is_linked_with_large_address_aware_and_cui_subsystemandxcl_exe_contains_valid_tls_and_exception_directoriesincrates/xcl/tests/low_va.rscleanly verifies PE link characteristics (LARGE_ADDRESS_AWARE, CUI subsystem,.CRT$XLYTLS,.pdataexception directory), with both CI checks green.Remaining before merge: Independent verification on
fa26aa7(currently has@DavidM1911--libonly, which doesn't execute integration test targets like--test low_va).Imported from ivall/xcl. Originally posted by tiagonleal on 2026-11-25T12:32:58Z.
Verification on NVIDIA RTX 5070 Ti (Windows 11), head
fa26aa785d51878afc6b95087fefd5253c0d58afTested
fa26aa785d51878afc6b95087fefd5253c0d58af(git rev-parse HEADof a clean worktree, no local changes, built as is). The PR was open and the head unchanged when I started and again before writing this.cargo testdefault).crates/xcl/tests/low_va.rs, so I ran that target and not--lib:cargo test -p xcl --test low_va -- --test-threads=4 --nocapture: 3 passed, 0 failed, 0 ignored (about 20 s including an incremental build). Tests:xcl_exe_is_linked_with_large_address_aware_and_cui_subsystem,xcl_exe_is_linked_without_high_entropy_va,xcl_exe_contains_valid_tls_and_exception_directories. The earlier verification in the thread ran only--lib, which does not execute this target.SKIPPEDlines in the output.Not tested
cargo test --workspace,--liband the other test targets; release profile; Developer Mode on (off here); the retail game andxcl-smoke.AI use
Run and written with Claude Code (Claude Fable 5.2 and Claude Sonnet 5.5).
Imported from ivall/xcl. Originally posted by Decodere on 2026-11-27T10:03:46Z.
Independent desktop NVIDIA verification of PR #2167 at head
fa26aa785d51878afc6b95087fefd5253c0d58af(1commit; exact parent & merge-base:568e7db7729c8fa6c8f0f4b32d798faaf11462bb, pre-#2555ancestor ofmain).Environment
7956 MiBreported by D3D12, Wave32-only Ada), driver32.0.16.2114(NVIDIA621.14, WDDM 3.2)31.9 GiBusable), Windows 11 Home26200(Developer Mode off)rustc 1.100.0 (0ef1bc386 2026-11-09)MSVC, DXC1.9.2609.5,--releaseTargeted tests & build (
fa26aa78)cargo build --release -p xcl0.07sincremental--releasebuild, exit0,0new warnings)cargo test --release -p xcl --test low_va -- --nocapture(3 consecutive runs)3 passed; 0 failed; 0 ignored; 0 filtered out× 3 (0.01s,0.01s,0.01s,0skipped; verifiedxcl_exe_is_linked_without_high_entropy_va,xcl_exe_is_linked_with_large_address_aware_and_cui_subsystem, andxcl_exe_contains_valid_tls_and_exception_directoriesagainst the freshly built--releasexcl.exe)Paired quiet 60 s retail smoke (
title: 29640639)Exact parent & merge-base (
568e7db7729c8fa6c8f0f4b32d798faaf11462bb, cached baseline on the same machine):PR #2167 (
fa26aa785d51878afc6b95087fefd5253c0d58af):Limits of coverage
crates/xcl/tests/low_va.rs,0production-code changes); all 3 PE header and directory invariant tests passed3/3against the MSVC--releasexcl.exebinary.AI disclosure: test execution and report drafting assisted by Google Antigravity (Gemini 4 Neon).
Imported from ivall/xcl. Originally posted by throny on 2026-11-29T00:47:37Z.
merge-check claim
head:
fa26aa785dImported from ivall/xcl. Originally posted by throny on 2026-11-29T01:02:09Z.
merge-check
base:
fa204595head:
fa26aa785dmerge: clean
build: cargo build --workspace -> ok
tests: cargo test --workspace --no-fail-fast -- --test-threads=4 -> 2610 passed, 0 failed, 49 ignored (27 SKIPPED lines). Base alone at
fa204595: 2608 passed, 0 failed, 49 ignored.review: no blocking finding; tests only, all hunks read. The tests read only the built xcl.exe (no game binary) and are deterministic. The TLS directory they expect exists because the program registers a thread callback. Minor: a constant rewritten in a longer form and the file header reworded; machine and subsystem are checked twice. Not verified: the large-address flag on GNU-target builds some testers use.
performance: none (tests only).
verdict: safe to merge
hardware / tool and model: RTX 4080 16 GB (621.40), i9-12900K, Windows 11 26300, Rust 1.100.0, debug. Claude Code; merge, build and suite run by Claude Fable 5.2, diff review by Claude Opus 5.5 (every hunk read; nothing run on the GPU beyond the suite).
Imported from ivall/xcl. Originally posted by Parakeet-Wheat on 2026-11-30T02:18:14Z.
merge-check claim released (we will not check head
fa26aa7now; the slot is free)Imported from ivall/xcl. Originally posted by relativespace2K on 2026-11-30T02:21:00Z.
merge-check
base:
53e85fb1head:
fa26aa785dmerge: clean
build: cargo build --workspace -> ok
tests: cargo test --workspace --no-fail-fast -- --test-threads=4 -> 2790 passed, 6 failed, 49 ignored; failing: gpu::dxil::compact_tests::gpu_compact_form_with_micro_blocks_and_literal_table_runs_as_the_plain_form, gpu::recomp::pso::shader_cache_tests::console_mesh_caches_hlsl_compute_pass_in_memory_and_on_disk, hle::d3d12x::standin::tests::concurrent_shell_miss_reuses_winner_and_releases_loser_pipeline, ram_budget::tests::windows_takes_a_working_set_maximum_and_lifts_it, and two_pass_driver_cache_reuses_both_passes_and_recovers_corrupt_blobs (in
--test gpu_two_pass_cache_e2e, so 5 failing tests give 6 failures). The same five fail on base53e85fb1alone (2788 passed, 6 failed, 49 ignored there), so none comes from this PR; its two new tests passed. 13 SKIPPED lines, all environmental: no D3D12 debug layer / d3d12SDKLayers.dll, no heap windows, no GPU_UPLOAD, per-lane f16/f32 forms refused.review: no blocking finding; tests only,
crates/xcl/tests/low_va.rs, every hunk read. The added checks readxcl.exeand pin machine0x8664,IMAGE_FILE_LARGE_ADDRESS_AWAREset, subsystemIMAGE_SUBSYSTEM_WINDOWS_CUI, a non-empty TLS directory and a non-empty exception directory, the last two through the crate's ownpe::Peparser rather than by hand, which is the right tool here. They fail loudly if a linker or profile change ever drops any of them, andHIGH_ENTROPY_VAkeeping the value0x20(now written0x0020) means the existing assertion still tests the same bit. One note, not blocking: the header offsets in the first test (pe + 22,optional + 68) are spelled out instead of taken fromxcl::pe, so a PE layout change would break this test before the parser; the second test already covers the same fields through the parser. No duplicate: the only otherlow_vawork is this file's existing high-entropy test.performance: none: tests only.
verdict: safe to merge
hardware / tool and model: AMD Radeon RX 6800 XT 16 GB (RDNA2, wave64), driver 32.0.21045.29003; Ryzen 5 5600, 32 GB RAM; Windows 10 IoT Enterprise LTSC 2024, 10.0.26100 build 26100.9974; Rust 1.100.0; DXC 1.9.2602.17; debug build. DeepSeek Harness coding agent, model DeepSeek V4.1 Flash.