Skip to content

Conversation

@kroening
Copy link
Collaborator

@kroening kroening commented Oct 8, 2025

This replaces a custom encoding via typecast_exprt used in the Verilog front-end by zero_extend_exprt.

@kroening kroening force-pushed the verilog_zero_extend_exprt branch 2 times, most recently from 9248e11 to cb249de Compare October 8, 2025 19:19
else
return expr;
}
else if(expr.id() == ID_zero_extend)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

So why is this lowering required? Shouldn't the back-end be capable of handling zero_extend?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The back-end is missing some cases; I'll separate.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The non-four-valued cases now work without lowering after updating to cbmc 5.7.1.

Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Will the four-valued cases be covered in a separate PR?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, will do separate PR

@kroening kroening force-pushed the verilog_zero_extend_exprt branch 3 times, most recently from 50c5683 to 43465a0 Compare October 15, 2025 23:46
This replaces a custom encoding via typecast_exprt used in the Verilog
front-end by zero_extend_exprt.

To support --smv-word-level, conversion for zero_extend is added to
expr2smv.
@kroening kroening force-pushed the verilog_zero_extend_exprt branch from 43465a0 to 653b73b Compare October 15, 2025 23:47
@kroening kroening marked this pull request as ready for review October 15, 2025 23:52
@tautschnig tautschnig merged commit edcbc8d into main Oct 16, 2025
11 checks passed
@tautschnig tautschnig deleted the verilog_zero_extend_exprt branch October 16, 2025 08:38
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.

3 participants