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] Support const "source" in forces, insert refcast as needed. #5388

Merged
merged 3 commits into from
Jun 13, 2023

Conversation

dtzSiFive
Copy link
Contributor

Better support literal and literal/const-derived sources to "force", and use ref.cast to accommodate supported differences.

This is not required by the current FIRRTL spec, but makes using it a bit easier.

Also this handles various const scenarios re:aggregates, current code seems primarily to get ground types/literals accepted.

@dtzSiFive dtzSiFive added the FIRRTL Involving the `firrtl` dialect label Jun 13, 2023
@dtzSiFive
Copy link
Contributor Author

In addition to supporting const-related situations, this makes examples such as this work: https://github.com/dtzSiFive/reftype-inputs/blob/main/force_infer.fir (well, once #5378 lands).

lib/Dialect/FIRRTL/Import/FIRParser.cpp Outdated Show resolved Hide resolved
@dtzSiFive
Copy link
Contributor Author

Thanks! 😁

@dtzSiFive dtzSiFive merged commit bc58a01 into llvm:main Jun 13, 2023
@dtzSiFive dtzSiFive deleted the feature/force-const-source-and-refcast branch June 13, 2023 20:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
FIRRTL Involving the `firrtl` dialect
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants