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

Support a "clocked_by" syntax in BH module instantiations #621

Open
quark17 opened this issue Oct 5, 2023 · 0 comments
Open

Support a "clocked_by" syntax in BH module instantiations #621

quark17 opened this issue Oct 5, 2023 · 0 comments
Labels
enhancement New feature or request

Comments

@quark17
Copy link
Collaborator

quark17 commented Oct 5, 2023

In BSV, the default clock and reset for a module instantiate can be specified using clocked_by and reset_by clauses. BH doesn't have this, but since the BSV syntax just desugars to a primitive function call, you can manually write that call in BH and get the same behavior. Specifically, the BSV parser translates these into a call to changeSpecialWires, which takes maybe a clock and maybe a reset as arguments (and also maybe a power line, but that's unused infrastructure for a potential future). I guess this isn't too ugly, but we might consider whether a simpler syntax is possible.

@quark17 quark17 added the enhancement New feature or request label Oct 5, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant