Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

SystemVerilog: allow SVA in property ... endproperty #933

Merged
merged 2 commits into from
Jan 21, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions regression/verilog/property/named_property2.desc
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
CORE
named_property2.sv
--bound 20
^\[main\.assert\.1\] always main\.x_is_eventually_ten: PROVED up to bound 20$
^EXIT=0$
^SIGNAL=0$
--
^warning: ignoring
--
12 changes: 12 additions & 0 deletions regression/verilog/property/named_property2.sv
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
module main(input clk);

reg [31:0] x = 0;
always_ff @(posedge clk) x++;

property x_is_eventually_ten;
s_eventually x == 10
endproperty : x_is_eventually_ten

assert property (x_is_eventually_ten);

endmodule
2 changes: 1 addition & 1 deletion src/verilog/verilog_typecheck.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -1770,7 +1770,7 @@ void verilog_typecheckt::convert_property_declaration(
auto base_name = declaration.base_name();
auto full_identifier = hierarchical_identifier(base_name);

convert_expr(declaration.cond());
convert_sva(declaration.cond());
make_boolean(declaration.cond());

auto type = bool_typet{};
Expand Down
Loading