-
Notifications
You must be signed in to change notification settings - Fork 23
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
Sum
and Counter
#89
Sum
and Counter
#89
Conversation
lib/src/component_config/config_knobs/int_optional_config_knob.dart
Outdated
Show resolved
Hide resolved
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good. I did not walk through all logic as it is hairy. I learned some things like using inject and negEdge which I hadn't used before.
One thing I didn't check is if the Counter has good defaults for the common case (single increment, wraparound?)
Yes, the default is wrap-around and requires a list of interfaces. The |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This PR is in great shape. My biggest question is: do we need both max and min in the same Counter. If not, the interface gets way simpler and easier to understand.
Yes, because we could have both incrementing and decrementing inputs, with variable amounts and enables. |
Description & Motivation
A
Sum
andCounter
component. TheSum
adds up all the things input combinationally, and theCounter
adds a flop (essentially). The components are super flexible and generic.Related Issue(s)
Fix #73
Testing
Added new tests
Backwards-compatibility
No
Documentation
Yes