bench parsing docs
This commit is contained in:
1 parent
c5bdeb4a68
commit
1bc9dc0e9d
1 file changed
+4
@@ -5,6 +5,10 @@ Historically it was first used in the
|
||||
`ISCAS89 benchmark set <https://people.engr.ncsu.edu/brglez/CBL/benchmarks/ISCAS89/>`_.
|
||||
Besides loading these benchmarks, this module is also useful for easily constructing simple circuits:
|
||||
``c = bench.parse('input(x, y) output(a, o, n) a=and(x,y) o=or(x,y) n=not(x)')``.
|
||||
|
||||
This parser automatically translates gate to simulation primitives supported by kyupy.
|
||||
In most cases this means just adding the number of inputs to the name: e.g. NAND -> NAND2, OR -> OR4, INV -> INV1.
|
||||
Since simulators only support at most four-input-gates, gates with more than four inputs are implemented as tree.
|
||||
"""
|
||||
|
||||
from lark import Lark, Transformer
|
||||
|
||||
Reference in new issue
Block a user