Skip to content

[Verif] Preserve labeled assert/assume ops during canonicalization#10114

Open
fabianschuiki wants to merge 1 commit intomainfrom
fschuiki/preserve-labeled-asserts
Open

[Verif] Preserve labeled assert/assume ops during canonicalization#10114
fabianschuiki wants to merge 1 commit intomainfrom
fschuiki/preserve-labeled-asserts

Conversation

@fabianschuiki
Copy link
Copy Markdown
Contributor

The EraseIfEnableFalse and EraseIfPropertyTrue canonicalization patterns unconditionally erased verif.assert and verif.assume ops (and their clocked variants) when they were trivially true or disabled. This silently dropped user-visible labels that users expect to see in the output regardless of optimizations.

Instead of erasing labeled ops, replace them with trivially-satisfied versions that preserve the label: set the property to constant true, clear the enable, and for clocked ops replace a non-constant clock with constant false.

@fabianschuiki
Copy link
Copy Markdown
Contributor Author

Results of circt-tests run for 55479f4 compared to results for 4f711e2: no change to test results.

@seldridge
Copy link
Copy Markdown
Member

Just get some data from internal designs on this. This was put in specifically to start squashing input only modules. See what you dig up from the internal data.

The EraseIfEnableFalse and EraseIfPropertyTrue canonicalization patterns
unconditionally erased verif.assert and verif.assume ops (and their
clocked variants) when they were trivially true or disabled. This
silently dropped user-visible labels that users expect to see in the
output regardless of optimizations.

Instead of erasing labeled ops, replace them with trivially-satisfied
versions that preserve the label: set the property to constant true,
clear the enable, and for clocked ops replace a non-constant clock with
constant false.

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@fabianschuiki fabianschuiki force-pushed the fschuiki/preserve-labeled-asserts branch from 55479f4 to 4627696 Compare April 7, 2026 15:31
@fabianschuiki
Copy link
Copy Markdown
Contributor Author

Results of circt-tests run for 4627696 compared to results for a4a4f74: no change to test results.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants