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

Adds register with update_state semantics, with a hierarchical test #212

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

rdaly525
Copy link
Collaborator

Using this PR as a new feature review (eg not meant to be merged)

Goal: Add precise verilator-like simulation semantics for peak classes and registers

Under this paradigm (only using Register3 for any state), __call__(...) does not ever update state, but only evaluates the combinational logic defined in Peak. The Peak.update_state() method does the state update exactly analogous to toggling the clock in verilator.

To evaluate multiple cycles:

peak_obj(...)
peak_obj.update_state()
peak_obv(...)
peak_obj.update_state()
...

In addition, there are set() and get() methods for Regsister3 for to dynamically peak and poke the state.

One ultimate goal is to treat state input/outputs similar to peak outputs/inputs (respectively)for the automatic rewrite rule generation cod generation.

@rdaly525 rdaly525 requested a review from cdonovick January 27, 2021 00:13
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.

1 participant