-
Notifications
You must be signed in to change notification settings - Fork 11
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Re-use host Python process when compiling from command line (#372)
... instead of spawning a sub-process. This keeps namespaces consistent (in a way that spawning a subprocess wouldn't) and allows the use of a Python debugger. Resolves #362 NOTE FOR DEBUGGING: the IDE (compile-design) does not yet support debugging, so you'll need to create a main stub (like bllinky_skeleton.py, as if running from the command line) and debug from that. But breakpoints do work. Implementation-wise, this 'flips' the client / server role: after sending the design to compile to the server, the Python process then acts as an HDL server until receiving an empty request (denoting end of compilation), then waits for the compilation result. This also restructures the interface structure, notably bringing the core compiler interface structurally closer to the Python implementation, with a dedicated serializer / deserializer class (instead of it being monolithic). This also refactors the compiler to eliminate error suppression, instead moving it into the generator test case (using redirect_stderr) which is the only place this functionality is used. This new structure also un-suppresses a warning in the test suite, which will be addressed separately. Also bumps the compiler version.
- Loading branch information
Showing
9 changed files
with
273 additions
and
302 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.