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

[FIRRTL] Register const updates #5074

Merged
merged 2 commits into from
Apr 28, 2023
Merged

Conversation

trilorez
Copy link
Contributor

This disallows register types from being const. Register reset values are allowed to be const or contain const members.

In order to efficiently check if a type is const or contains const members, containsConst has been added to RecursiveTypeProperties.

This commit disallows register types from being const.
Register reset values are allowed to be const or contain const members.

In order to efficiently check if a type is const or contains const members,
containsConst has been added to RecursiveTypeProperties.
@trilorez trilorez requested a review from darthscsi April 25, 2023 05:47
@@ -1148,6 +1152,7 @@ struct circt::firrtl::detail::FVectorTypeStorage

/// This holds the bits for the type's recursive properties, and can hold a
/// pointer to a passive version of the type.
RecursiveTypeProperties props;
Copy link
Contributor

Choose a reason for hiding this comment

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

This is unused and ignored by, e.g., FVectorType::getRecursiveTypeProperties.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Oof, good catch. Fixed with more extensive tests.

Copy link
Contributor

@darthscsi darthscsi left a comment

Choose a reason for hiding this comment

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

LGTM

@trilorez trilorez merged commit ddb11b8 into main Apr 28, 2023
@trilorez trilorez deleted the dev/trilorez/firrtl-const-reg branch April 28, 2023 17:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants