Skip to content

Commit b3becd3

Browse files
committed
Added specification on how EBLIF cell parameters should be interpreted.
Signed-off-by: Maciej Kurc <[email protected]>
1 parent 2dc5692 commit b3becd3

File tree

1 file changed

+20
-3
lines changed

1 file changed

+20
-3
lines changed

doc/src/vpr/file_formats.rst

Lines changed: 20 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -391,17 +391,34 @@ The ``.param`` statement allows parameters (e.g. primitive modes) to be tagged o
391391

392392
.. note:: ``.param`` statements apply to the previous primitive instantiation.
393393

394+
Parameters can have one of the three available types. Type is inferred from the format in which a parameter is provided.
395+
396+
* **string**
397+
Whenever a parameter value is quoted it is considered to be a string.
398+
399+
* **binary word**
400+
Binary words are specified using strings of characters ``0`` and ``1``. No other characters are allowed. Number of characters denotes the word length.
401+
402+
* **real number**
403+
Real numbers are stored as decimals where the dot ``.`` character separates the integer and fractional part. Presence of the dot character implies that the value is to be treated as a real number.
404+
394405
For example:
395406

396407
.. code-block:: none
397408
398-
.subckt dsp a=a_in b=b_in cin=c_in cout=c_out s=sum_out
399-
.param mode adder
409+
.subckt pll clk_in=gclk clk_out=pclk
410+
.param feedback "internal"
411+
.param multiplier 0.50
412+
.param power 001101
413+
414+
Would set the parameters ``feedback``, ``multipleir`` and ``power`` of the above ``pll`` ``.subckt`` to ``"internal"``, ``0.50`` and ``001101`` respectively.
400415

401-
Would set the parameter ``mode`` of the above ``dsp`` ``.subckt`` to ``adder``.
416+
Interpretation of parameter values is out of scope of the BLIF format extension.
402417

403418
``.param`` statements propagate to ``<parameter>`` elements in the packed netlist.
404419

420+
Paramerer values propagate also to post-route Verilog netlist. Strings and real numbers are passed directly while binary words are prepended with the ``<N>'b`` prefix where ``N`` denotes a binary word length.
421+
405422
.attr
406423
~~~~~
407424
The ``.attr`` statement allows attributes (e.g. source file/line) to be tagged on BLIF primitives.

0 commit comments

Comments
 (0)