Skip to content

Build the bitstream of a session and report it - #2909

Open
ganeshgore wants to merge 1 commit into
design-synthesisfrom
session-bitstream
Open

ganeshgore wants to merge 1 commit into
design-synthesisfrom
session-bitstream

Conversation

@ganeshgore

Copy link
Copy Markdown
Collaborator

Stacked on #2908 (base design-synthesis).

What it adds

  • build_bitstream makes the bitstream of the routed design of the staged flow in one command: analysis when needed, link_openfpga_arch and build_fabric when they are no longer valid (kept while the routing does not change), repack, the architecture and fabric bitstreams, and the file (bitstream/<circuit>.bit, plain text or XML). Link and fabric options and the fix-ups come from the bitstream recipe of the session: the defaults, or what a plugin set with the architectures it read (set_bitstream_recipe). Without simulation settings, fixed ones are written and read.
  • The simulation and bitstream settings are inputs of the session; bitstream settings drop REPACKED and BITSTREAM.
  • report_bitstream (schema bitstream): the file and its SHA-256, the bits, the protocol, the bits per type of block, the settings and the steps. report_session lists the settings and the bitstream file, report_run the stage BITSTREAM.
  • Session.bitstream(), bitstream_report(), read_simulation_setting(), read_bitstream_setting(), repack(), run_flow(bitstream=True); checkpoints keep the settings and the bitstream file; journals replay it.

Tests

  • test_bitstream: the bitstream equals the one of the vpr flow on all golden designs (also flat), what is kept and what is made again, files and formats, refusals, fixed simulation settings, checkpoints and journals. C++: the bitstream state and recipe of OpenFpgaSession.
  • Full openfpga_flow/tasks/python_binding_tests and the ctest subset pass, in a build without plugins.

Not included

  • No bitstream recipe is defined in OpenFPGA beyond the defaults: a plugin provides it.

build_bitstream makes the bitstream of the routed design of the flow run
stage by stage in one command: analysis when it is not reached, then
link_openfpga_arch and build_fabric when they are not valid any more (they
are kept while the routing does not change), then repack, the architecture
and fabric bitstreams, and the file (bitstream/<circuit>.bit by default,
plain text or XML). The options of the link and the fabric and the fix-ups
after the link are those of the recipe of the bitstream (BitstreamRecipe:
the defaults, or what a plugin set with the architectures it read, cleared
when an architecture is read). When the session read no simulation settings,
fixed ones are written next to the file and read, as the bitstream does not
depend on them.

The simulation and bitstream settings are inputs of the session: the files
read are recorded, the bitstream settings drop REPACKED and BITSTREAM, and
both make the link again. report_bitstream answers with the file, its
SHA-256, the bits, the protocol, the bits per type of block, the settings
and the steps (schema bitstream); report_session lists the settings and the
file, and report_run the stage BITSTREAM.

The Session has bitstream(), bitstream_report(), read_simulation_setting(),
read_bitstream_setting(), repack() and run_flow(bitstream=True); a checkpoint
keeps the settings and the file of the bitstream, and the journal replays
it. The bitstream is compared with the one of the vpr flow on the golden
designs.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant