Pin the sanitizer collector's pattern arms, close its trailing-dir hole - #1416
Open
xroche wants to merge 2 commits into
Open
Pin the sanitizer collector's pattern arms, close its trailing-dir hole#1416xroche wants to merge 2 commits into
xroche wants to merge 2 commits into
Conversation
…r hole tools/ci-sanitizer-report.sh is the only path from a sanitizer finding to a red build, and its pattern also gates `msan`, a required check. Only the UBSan and DEADLYSIGNAL arms had a fixture; mutation testing showed the Leak alternative, the WARNING:(Memory|Thread)Sanitizer arm, and the SUMMARY:.*Sanitizer arm could all be dropped -- singly or in the two combinations that fully blind the collector to LeakSanitizer or MemorySanitizer -- with tests/349_sanitizer-stderr-capture.test staying green throughout. This predates #1404 and is not a regression; it was only newly load-bearing once msan became required. Add an isolated fixture per runtime (ASan, LeakSanitizer, MemorySanitizer, ThreadSanitizer, a SUMMARY-only line) plus two full multi-line reports that pin the LeakSanitizer- and MemorySanitizer-blind combinations. Verified by mutation: each of the seven pattern deletions now turns the test red. need_dir already refused a missing -s STDERR_DIR or LOG_PATH_DIR (#1374), but a missing trailing TEST_LOG_DIR was silently skipped, so a typo'd log path read as a clean run instead of a broken one. Close that the same way, with a test row for it. Closes #1405 Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Signed-off-by: Xavier Roche <roche@httrack.com>
Review of #1416 found three more pattern pieces the fixtures never exercised: DEADLYSIGNAL, and MemorySanitizer/ThreadSanitizer's ERROR-group form. compiler-rt's signal handler is shared, so a crash makes MSan or TSan report through `ERROR: (Memory|Thread)Sanitizer`, not the WARNING form the earlier fixtures pinned -- exactly the shape a real `msan` crash would take. Add isolated fixtures for all three, sourced from real crash reports (a ThreadSanitizer SEGV, a MemorySanitizer SEGV, and the bare "AddressSanitizer:DEADLYSIGNAL" marker a sanitizer writes ahead of its full report). All three now turn the test red when dropped. Also: drop a stale cross-file comment reference, expand an "e.g.", and tighten a run-on comment. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Signed-off-by: Xavier Roche <roche@httrack.com>
xroche
enabled auto-merge (squash)
August 24, 2026 21:23
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
tools/ci-sanitizer-report.shis the only path from a sanitizer finding to a red build, and its pattern also gatesmsan(MemorySanitizer, clang), a required check. Before this PR only theruntime error:arm (gcc's UBSan) had a fixture. Mutation testing againsttests/349_sanitizer-stderr-capture.testfound ten more pattern pieces that could be dropped with the test staying green. That covers every other name in the ERROR-group, the whole WARNING arm, the SUMMARY arm, DEADLYSIGNAL, and the two combinations that fully blind the collector to LeakSanitizer or MemorySanitizer. This predates #1404, so it isn't a regression, just newly load-bearing now that msan is required.Each gap gets its own fixture, carrying only the marker for the arm it pins so a different arm can't catch it and hide the gap. ASan and LeakSanitizer's own ERROR lines and a SUMMARY-only line cover the ERROR-group and SUMMARY arms. MemorySanitizer and ThreadSanitizer get both their WARNING form (their own findings) and their ERROR form, since compiler-rt's crash-reporting path is shared and a crash makes either one report through the ERROR-group instead. A bare
DEADLYSIGNALmarker line comes from a real ASan crash report, where it appears on its own with noERROR:prefix. Two full multi-line reports pin the LeakSanitizer- and MemorySanitizer-blind combinations.ERROR: UndefinedBehaviorSanitizerandERROR: libFuzzerstay unpinned on purpose: gcc's UBSan never emits the former, and the fuzz job never calls this script, so the latter can't fire here either.need_diralready refused a missing-s STDERR_DIRorLOG_PATH_DIR(#1374); a missing trailingTEST_LOG_DIRwas silently skipped instead, so a typo'd log path read as clean rather than broken. Closed the same way, with a test row for it.Closes #1405