3
0
Fork 0
mirror of https://github.com/YosysHQ/yosys synced 2025-04-23 00:55:32 +00:00

Merge pull request #2995 from georgerennie/cover_precond

chformal: Add -coverenable option
This commit is contained in:
Jannis Harder 2023-02-14 17:46:31 +01:00 committed by GitHub
commit ec94703619
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 44 additions and 0 deletions

View file

@ -0,0 +1,25 @@
read_verilog -formal <<EOT
module top(input a, b, c, d);
always @* begin
if (a) assert (b == c);
if (!a) assert (b != c);
if (b) assume (c);
if (c) cover (d);
end
endmodule
EOT
prep -top top
select -assert-count 1 t:$cover
chformal -cover -coverenable
select -assert-count 2 t:$cover
chformal -assert -coverenable
select -assert-count 4 t:$cover
chformal -assume -coverenable
select -assert-count 5 t:$cover