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

Refactor combinational to use SSA, initial implementation of sequential #354

Merged
merged 9 commits into from Feb 21, 2019

Conversation

leonardt
Copy link
Collaborator

  • Changes m.circuit.combinational to use the ssa pass, this resolves the issues in m.circuit.combinational improvements #267. It also makes it easier to debug the output.
  • Adds an initial implementation of m.circuit.sequential with a basic test

Summary:
This creates a directory magma/syntax which will hold all the logic for
the available magma syntax frontends (decorators that inspect the AST)
in preparation for the addition of a new sequential syntax.

Test Plan:

Reviewers:

Subscribers:

Tasks:

Tags:

Blame Revision:

Differential Revision: https://phabricator.intern.facebook.com/D13643831
Summary: This is an initial pass at the logic for m.circuit.sequential.
The intended design is to parse the `__init__` method to determine the
register declarations from the user. The `__call__` method will be
translated into a `m.circuit.combinational` definition that consumes the
inputs to the circuits and the declared registers (contained in self)
and returns the outputs of the circuits. The compiler logic will
generate the surrounding magma circuit definition including an IO list,
a set of register instantiations, a m.circuit.combinational definition
and invocation, and the wiring of the outputs.

Test Plan:

Reviewers:

Subscribers:

Tasks:

Tags:

Blame Revision:

Differential Revision: https://phabricator.intern.facebook.com/D13645206
@coveralls
Copy link

Pull Request Test Coverage Report for Build 1472

  • 163 of 171 (95.32%) changed or added relevant lines in 7 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.06%) to 73.087%

Changes Missing Coverage Covered Lines Changed/Added Lines %
magma/syntax/sequential.py 101 103 98.06%
magma/ssa/ssa.py 46 52 88.46%
Totals Coverage Status
Change from base Build 1464: 0.06%
Covered Lines: 3810
Relevant Lines: 5213

💛 - Coveralls

1 similar comment
@coveralls
Copy link

coveralls commented Feb 14, 2019

Pull Request Test Coverage Report for Build 1472

  • 163 of 171 (95.32%) changed or added relevant lines in 7 files are covered.
  • No unchanged relevant lines lost coverage.
  • Overall coverage increased (+0.06%) to 73.087%

Changes Missing Coverage Covered Lines Changed/Added Lines %
magma/syntax/sequential.py 101 103 98.06%
magma/ssa/ssa.py 46 52 88.46%
Totals Coverage Status
Change from base Build 1464: 0.06%
Covered Lines: 3810
Relevant Lines: 5213

💛 - Coveralls

@leonardt leonardt merged commit f366ca2 into master Feb 21, 2019
@leonardt leonardt deleted the sequential branch February 21, 2019 22:02
@leonardt leonardt restored the sequential branch June 12, 2019 21:59
@leonardt leonardt deleted the sequential branch October 30, 2019 22: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.

None yet

2 participants