Files
yosys/docs/source/using_yosys/synthesis/proc.rst
T

68 lines
2.2 KiB
ReStructuredText
Raw Normal View History

2023-12-07 17:14:21 +13:00
Converting process blocks
~~~~~~~~~~~~~~~~~~~~~~~~~
2023-12-07 13:04:46 +13:00
2024-01-24 10:29:40 +13:00
.. role:: yoscrypt(code)
:language: yoscrypt
2023-12-07 17:14:21 +13:00
The Verilog frontend converts ``always``-blocks to RTL netlists for the
2024-05-03 13:38:01 +12:00
expressions and "processess" for the control- and memory elements. The `proc`
command then transforms these "processess" to netlists of RTL multiplexer and
register cells. It also is a macro command that calls the other ``proc_*``
commands in a sensible order:
2023-12-07 17:14:21 +13:00
2024-01-24 10:29:40 +13:00
.. literalinclude:: /code_examples/macro_commands/proc.ys
:language: yoscrypt
:start-after: #end:
2024-05-03 13:16:48 +12:00
:caption: Passes called by `proc`
2024-01-24 10:29:40 +13:00
2024-05-03 13:38:01 +12:00
After all the ``proc_*`` commands, `opt_expr` is called. This can be disabled by
calling :yoscrypt:`proc -noopt`. For more information about `proc`, such as
2025-08-06 13:52:12 +12:00
disabling certain sub commands, see :doc:`/cmd/index_passes_proc`.
2023-12-07 17:14:21 +13:00
Many commands can not operate on modules with "processess" in them. Usually a
2024-05-03 13:38:01 +12:00
call to `proc` is the first command in the actual synthesis procedure after
design elaboration.
2023-12-07 17:14:21 +13:00
Example
^^^^^^^
.. todo:: describe ``proc`` images
2024-01-30 13:31:00 +13:00
|code_examples/synth_flow|_.
.. |code_examples/synth_flow| replace:: :file:`docs/source/code_examples/synth_flow`
2024-03-24 00:41:40 -04:00
.. _code_examples/synth_flow: https://github.com/YosysHQ/yosys/tree/main/docs/source/code_examples/synth_flow
2024-01-30 13:31:00 +13:00
2023-12-07 17:14:21 +13:00
.. literalinclude:: /code_examples/synth_flow/proc_01.v
:language: verilog
2024-01-30 13:31:00 +13:00
:caption: :file:`proc_01.v`
2023-12-07 17:14:21 +13:00
.. literalinclude:: /code_examples/synth_flow/proc_01.ys
:language: yoscrypt
2024-01-30 13:31:00 +13:00
:caption: :file:`proc_01.ys`
2023-12-07 17:14:21 +13:00
.. figure:: /_images/code_examples/synth_flow/proc_01.*
2024-05-11 10:40:54 +12:00
:class: width-helper invert-helper
2023-12-07 17:14:21 +13:00
.. figure:: /_images/code_examples/synth_flow/proc_02.*
2024-05-11 10:40:54 +12:00
:class: width-helper invert-helper
2023-12-07 17:14:21 +13:00
.. literalinclude:: /code_examples/synth_flow/proc_02.v
:language: verilog
2024-01-30 13:31:00 +13:00
:caption: :file:`proc_02.v`
2023-12-07 17:14:21 +13:00
.. literalinclude:: /code_examples/synth_flow/proc_02.ys
:language: yoscrypt
2024-01-30 13:31:00 +13:00
:caption: :file:`proc_02.ys`
2023-12-07 17:14:21 +13:00
.. figure:: /_images/code_examples/synth_flow/proc_03.*
2024-05-11 10:40:54 +12:00
:class: width-helper invert-helper
2023-12-07 17:14:21 +13:00
.. literalinclude:: /code_examples/synth_flow/proc_03.ys
:language: yoscrypt
2024-01-30 13:31:00 +13:00
:caption: :file:`proc_03.ys`
2023-12-07 17:14:21 +13:00
.. literalinclude:: /code_examples/synth_flow/proc_03.v
:language: verilog
2024-01-30 13:31:00 +13:00
:caption: :file:`proc_03.v`