siliconcompiler 0.26.5__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- siliconcompiler/__init__.py +24 -0
- siliconcompiler/__main__.py +12 -0
- siliconcompiler/_common.py +49 -0
- siliconcompiler/_metadata.py +36 -0
- siliconcompiler/apps/__init__.py +0 -0
- siliconcompiler/apps/_common.py +76 -0
- siliconcompiler/apps/sc.py +92 -0
- siliconcompiler/apps/sc_dashboard.py +94 -0
- siliconcompiler/apps/sc_issue.py +178 -0
- siliconcompiler/apps/sc_remote.py +199 -0
- siliconcompiler/apps/sc_server.py +39 -0
- siliconcompiler/apps/sc_show.py +142 -0
- siliconcompiler/apps/smake.py +232 -0
- siliconcompiler/checklists/__init__.py +0 -0
- siliconcompiler/checklists/oh_tapeout.py +41 -0
- siliconcompiler/core.py +3221 -0
- siliconcompiler/data/RobotoMono/LICENSE.txt +202 -0
- siliconcompiler/data/RobotoMono/RobotoMono-Regular.ttf +0 -0
- siliconcompiler/data/heartbeat.v +18 -0
- siliconcompiler/data/logo.png +0 -0
- siliconcompiler/flowgraph.py +570 -0
- siliconcompiler/flows/__init__.py +0 -0
- siliconcompiler/flows/_common.py +67 -0
- siliconcompiler/flows/asicflow.py +180 -0
- siliconcompiler/flows/asictopflow.py +38 -0
- siliconcompiler/flows/dvflow.py +86 -0
- siliconcompiler/flows/fpgaflow.py +202 -0
- siliconcompiler/flows/generate_openroad_rcx.py +66 -0
- siliconcompiler/flows/lintflow.py +35 -0
- siliconcompiler/flows/screenshotflow.py +51 -0
- siliconcompiler/flows/showflow.py +59 -0
- siliconcompiler/flows/signoffflow.py +53 -0
- siliconcompiler/flows/synflow.py +128 -0
- siliconcompiler/fpgas/__init__.py +0 -0
- siliconcompiler/fpgas/lattice_ice40.py +42 -0
- siliconcompiler/fpgas/vpr_example.py +109 -0
- siliconcompiler/issue.py +300 -0
- siliconcompiler/libs/__init__.py +0 -0
- siliconcompiler/libs/asap7sc7p5t.py +8 -0
- siliconcompiler/libs/gf180mcu.py +8 -0
- siliconcompiler/libs/nangate45.py +8 -0
- siliconcompiler/libs/sky130hd.py +8 -0
- siliconcompiler/libs/sky130io.py +8 -0
- siliconcompiler/package.py +412 -0
- siliconcompiler/pdks/__init__.py +0 -0
- siliconcompiler/pdks/asap7.py +8 -0
- siliconcompiler/pdks/freepdk45.py +8 -0
- siliconcompiler/pdks/gf180.py +8 -0
- siliconcompiler/pdks/skywater130.py +8 -0
- siliconcompiler/remote/__init__.py +36 -0
- siliconcompiler/remote/client.py +891 -0
- siliconcompiler/remote/schema.py +106 -0
- siliconcompiler/remote/server.py +507 -0
- siliconcompiler/remote/server_schema/requests/cancel_job.json +51 -0
- siliconcompiler/remote/server_schema/requests/check_progress.json +61 -0
- siliconcompiler/remote/server_schema/requests/check_server.json +38 -0
- siliconcompiler/remote/server_schema/requests/delete_job.json +51 -0
- siliconcompiler/remote/server_schema/requests/get_results.json +48 -0
- siliconcompiler/remote/server_schema/requests/remote_run.json +40 -0
- siliconcompiler/remote/server_schema/responses/cancel_job.json +18 -0
- siliconcompiler/remote/server_schema/responses/check_progress.json +30 -0
- siliconcompiler/remote/server_schema/responses/check_server.json +32 -0
- siliconcompiler/remote/server_schema/responses/delete_job.json +18 -0
- siliconcompiler/remote/server_schema/responses/get_results.json +21 -0
- siliconcompiler/remote/server_schema/responses/remote_run.json +25 -0
- siliconcompiler/report/__init__.py +13 -0
- siliconcompiler/report/html_report.py +74 -0
- siliconcompiler/report/report.py +355 -0
- siliconcompiler/report/streamlit_report.py +137 -0
- siliconcompiler/report/streamlit_viewer.py +944 -0
- siliconcompiler/report/summary_image.py +117 -0
- siliconcompiler/report/summary_table.py +105 -0
- siliconcompiler/report/utils.py +163 -0
- siliconcompiler/scheduler/__init__.py +2092 -0
- siliconcompiler/scheduler/docker_runner.py +253 -0
- siliconcompiler/scheduler/run_node.py +138 -0
- siliconcompiler/scheduler/send_messages.py +178 -0
- siliconcompiler/scheduler/slurm.py +208 -0
- siliconcompiler/scheduler/validation/email_credentials.json +54 -0
- siliconcompiler/schema/__init__.py +7 -0
- siliconcompiler/schema/schema_cfg.py +4014 -0
- siliconcompiler/schema/schema_obj.py +1841 -0
- siliconcompiler/schema/utils.py +93 -0
- siliconcompiler/sphinx_ext/__init__.py +0 -0
- siliconcompiler/sphinx_ext/dynamicgen.py +1006 -0
- siliconcompiler/sphinx_ext/schemagen.py +221 -0
- siliconcompiler/sphinx_ext/utils.py +166 -0
- siliconcompiler/targets/__init__.py +0 -0
- siliconcompiler/targets/asap7_demo.py +68 -0
- siliconcompiler/targets/asic_demo.py +38 -0
- siliconcompiler/targets/fpgaflow_demo.py +47 -0
- siliconcompiler/targets/freepdk45_demo.py +59 -0
- siliconcompiler/targets/gf180_demo.py +77 -0
- siliconcompiler/targets/skywater130_demo.py +70 -0
- siliconcompiler/templates/email/general.j2 +66 -0
- siliconcompiler/templates/email/summary.j2 +43 -0
- siliconcompiler/templates/issue/README.txt +26 -0
- siliconcompiler/templates/issue/run.sh +6 -0
- siliconcompiler/templates/report/bootstrap.min.css +7 -0
- siliconcompiler/templates/report/bootstrap.min.js +7 -0
- siliconcompiler/templates/report/bootstrap_LICENSE.md +24 -0
- siliconcompiler/templates/report/sc_report.j2 +427 -0
- siliconcompiler/templates/slurm/run.sh +9 -0
- siliconcompiler/templates/tcl/manifest.tcl.j2 +137 -0
- siliconcompiler/tools/__init__.py +0 -0
- siliconcompiler/tools/_common/__init__.py +432 -0
- siliconcompiler/tools/_common/asic.py +115 -0
- siliconcompiler/tools/_common/sdc/sc_constraints.sdc +76 -0
- siliconcompiler/tools/_common/tcl/sc_pin_constraints.tcl +63 -0
- siliconcompiler/tools/bambu/bambu.py +32 -0
- siliconcompiler/tools/bambu/convert.py +77 -0
- siliconcompiler/tools/bluespec/bluespec.py +40 -0
- siliconcompiler/tools/bluespec/convert.py +103 -0
- siliconcompiler/tools/builtin/_common.py +155 -0
- siliconcompiler/tools/builtin/builtin.py +26 -0
- siliconcompiler/tools/builtin/concatenate.py +85 -0
- siliconcompiler/tools/builtin/join.py +27 -0
- siliconcompiler/tools/builtin/maximum.py +46 -0
- siliconcompiler/tools/builtin/minimum.py +57 -0
- siliconcompiler/tools/builtin/mux.py +70 -0
- siliconcompiler/tools/builtin/nop.py +38 -0
- siliconcompiler/tools/builtin/verify.py +83 -0
- siliconcompiler/tools/chisel/SCDriver.scala +10 -0
- siliconcompiler/tools/chisel/build.sbt +27 -0
- siliconcompiler/tools/chisel/chisel.py +37 -0
- siliconcompiler/tools/chisel/convert.py +140 -0
- siliconcompiler/tools/execute/exec_input.py +41 -0
- siliconcompiler/tools/execute/execute.py +17 -0
- siliconcompiler/tools/genfasm/bitstream.py +61 -0
- siliconcompiler/tools/genfasm/genfasm.py +40 -0
- siliconcompiler/tools/ghdl/convert.py +87 -0
- siliconcompiler/tools/ghdl/ghdl.py +41 -0
- siliconcompiler/tools/icarus/compile.py +87 -0
- siliconcompiler/tools/icarus/icarus.py +36 -0
- siliconcompiler/tools/icepack/bitstream.py +20 -0
- siliconcompiler/tools/icepack/icepack.py +43 -0
- siliconcompiler/tools/klayout/export.py +117 -0
- siliconcompiler/tools/klayout/klayout.py +119 -0
- siliconcompiler/tools/klayout/klayout_export.py +205 -0
- siliconcompiler/tools/klayout/klayout_operations.py +363 -0
- siliconcompiler/tools/klayout/klayout_show.py +242 -0
- siliconcompiler/tools/klayout/klayout_utils.py +176 -0
- siliconcompiler/tools/klayout/operations.py +194 -0
- siliconcompiler/tools/klayout/screenshot.py +98 -0
- siliconcompiler/tools/klayout/show.py +101 -0
- siliconcompiler/tools/magic/drc.py +49 -0
- siliconcompiler/tools/magic/extspice.py +19 -0
- siliconcompiler/tools/magic/magic.py +85 -0
- siliconcompiler/tools/magic/sc_drc.tcl +96 -0
- siliconcompiler/tools/magic/sc_extspice.tcl +54 -0
- siliconcompiler/tools/magic/sc_magic.tcl +47 -0
- siliconcompiler/tools/montage/montage.py +30 -0
- siliconcompiler/tools/montage/tile.py +66 -0
- siliconcompiler/tools/netgen/count_lvs.py +132 -0
- siliconcompiler/tools/netgen/lvs.py +90 -0
- siliconcompiler/tools/netgen/netgen.py +36 -0
- siliconcompiler/tools/netgen/sc_lvs.tcl +46 -0
- siliconcompiler/tools/nextpnr/apr.py +24 -0
- siliconcompiler/tools/nextpnr/nextpnr.py +59 -0
- siliconcompiler/tools/openfpgaloader/openfpgaloader.py +39 -0
- siliconcompiler/tools/openroad/__init__.py +0 -0
- siliconcompiler/tools/openroad/cts.py +45 -0
- siliconcompiler/tools/openroad/dfm.py +66 -0
- siliconcompiler/tools/openroad/export.py +131 -0
- siliconcompiler/tools/openroad/floorplan.py +70 -0
- siliconcompiler/tools/openroad/openroad.py +977 -0
- siliconcompiler/tools/openroad/physyn.py +27 -0
- siliconcompiler/tools/openroad/place.py +41 -0
- siliconcompiler/tools/openroad/rcx_bench.py +95 -0
- siliconcompiler/tools/openroad/rcx_extract.py +34 -0
- siliconcompiler/tools/openroad/route.py +45 -0
- siliconcompiler/tools/openroad/screenshot.py +60 -0
- siliconcompiler/tools/openroad/scripts/sc_apr.tcl +499 -0
- siliconcompiler/tools/openroad/scripts/sc_cts.tcl +64 -0
- siliconcompiler/tools/openroad/scripts/sc_dfm.tcl +20 -0
- siliconcompiler/tools/openroad/scripts/sc_export.tcl +98 -0
- siliconcompiler/tools/openroad/scripts/sc_floorplan.tcl +413 -0
- siliconcompiler/tools/openroad/scripts/sc_metrics.tcl +158 -0
- siliconcompiler/tools/openroad/scripts/sc_physyn.tcl +7 -0
- siliconcompiler/tools/openroad/scripts/sc_place.tcl +84 -0
- siliconcompiler/tools/openroad/scripts/sc_procs.tcl +423 -0
- siliconcompiler/tools/openroad/scripts/sc_rcx.tcl +63 -0
- siliconcompiler/tools/openroad/scripts/sc_rcx_bench.tcl +20 -0
- siliconcompiler/tools/openroad/scripts/sc_rcx_extract.tcl +12 -0
- siliconcompiler/tools/openroad/scripts/sc_route.tcl +133 -0
- siliconcompiler/tools/openroad/scripts/sc_screenshot.tcl +21 -0
- siliconcompiler/tools/openroad/scripts/sc_write.tcl +5 -0
- siliconcompiler/tools/openroad/scripts/sc_write_images.tcl +361 -0
- siliconcompiler/tools/openroad/show.py +94 -0
- siliconcompiler/tools/openroad/templates/pex.tcl +8 -0
- siliconcompiler/tools/opensta/__init__.py +101 -0
- siliconcompiler/tools/opensta/report_libraries.py +28 -0
- siliconcompiler/tools/opensta/scripts/sc_procs.tcl +47 -0
- siliconcompiler/tools/opensta/scripts/sc_report_libraries.tcl +74 -0
- siliconcompiler/tools/opensta/scripts/sc_timing.tcl +268 -0
- siliconcompiler/tools/opensta/timing.py +214 -0
- siliconcompiler/tools/slang/__init__.py +49 -0
- siliconcompiler/tools/slang/lint.py +101 -0
- siliconcompiler/tools/surelog/__init__.py +123 -0
- siliconcompiler/tools/surelog/parse.py +183 -0
- siliconcompiler/tools/surelog/templates/output.v +7 -0
- siliconcompiler/tools/sv2v/convert.py +46 -0
- siliconcompiler/tools/sv2v/sv2v.py +37 -0
- siliconcompiler/tools/template/template.py +125 -0
- siliconcompiler/tools/verilator/compile.py +139 -0
- siliconcompiler/tools/verilator/lint.py +19 -0
- siliconcompiler/tools/verilator/parse.py +27 -0
- siliconcompiler/tools/verilator/verilator.py +172 -0
- siliconcompiler/tools/vivado/__init__.py +7 -0
- siliconcompiler/tools/vivado/bitstream.py +21 -0
- siliconcompiler/tools/vivado/place.py +21 -0
- siliconcompiler/tools/vivado/route.py +21 -0
- siliconcompiler/tools/vivado/scripts/sc_bitstream.tcl +6 -0
- siliconcompiler/tools/vivado/scripts/sc_place.tcl +2 -0
- siliconcompiler/tools/vivado/scripts/sc_route.tcl +4 -0
- siliconcompiler/tools/vivado/scripts/sc_run.tcl +45 -0
- siliconcompiler/tools/vivado/scripts/sc_syn_fpga.tcl +25 -0
- siliconcompiler/tools/vivado/syn_fpga.py +20 -0
- siliconcompiler/tools/vivado/vivado.py +147 -0
- siliconcompiler/tools/vpr/_json_constraint.py +63 -0
- siliconcompiler/tools/vpr/_xml_constraint.py +109 -0
- siliconcompiler/tools/vpr/place.py +137 -0
- siliconcompiler/tools/vpr/route.py +124 -0
- siliconcompiler/tools/vpr/screenshot.py +54 -0
- siliconcompiler/tools/vpr/show.py +88 -0
- siliconcompiler/tools/vpr/vpr.py +357 -0
- siliconcompiler/tools/xyce/xyce.py +36 -0
- siliconcompiler/tools/yosys/lec.py +56 -0
- siliconcompiler/tools/yosys/prepareLib.py +59 -0
- siliconcompiler/tools/yosys/sc_lec.tcl +84 -0
- siliconcompiler/tools/yosys/sc_syn.tcl +79 -0
- siliconcompiler/tools/yosys/syn_asic.py +565 -0
- siliconcompiler/tools/yosys/syn_asic.tcl +377 -0
- siliconcompiler/tools/yosys/syn_asic_fpga_shared.tcl +31 -0
- siliconcompiler/tools/yosys/syn_fpga.py +146 -0
- siliconcompiler/tools/yosys/syn_fpga.tcl +233 -0
- siliconcompiler/tools/yosys/syn_strategies.tcl +81 -0
- siliconcompiler/tools/yosys/techmaps/lcu_kogge_stone.v +39 -0
- siliconcompiler/tools/yosys/templates/abc.const +2 -0
- siliconcompiler/tools/yosys/yosys.py +147 -0
- siliconcompiler/units.py +259 -0
- siliconcompiler/use.py +177 -0
- siliconcompiler/utils/__init__.py +423 -0
- siliconcompiler/utils/asic.py +158 -0
- siliconcompiler/utils/showtools.py +25 -0
- siliconcompiler-0.26.5.dist-info/LICENSE +190 -0
- siliconcompiler-0.26.5.dist-info/METADATA +195 -0
- siliconcompiler-0.26.5.dist-info/RECORD +251 -0
- siliconcompiler-0.26.5.dist-info/WHEEL +5 -0
- siliconcompiler-0.26.5.dist-info/entry_points.txt +12 -0
- siliconcompiler-0.26.5.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,221 @@
|
|
|
1
|
+
import os
|
|
2
|
+
from docutils import nodes
|
|
3
|
+
from sphinx.util.nodes import nested_parse_with_titles
|
|
4
|
+
from docutils.statemachine import ViewList
|
|
5
|
+
from sphinx.util.docutils import SphinxDirective
|
|
6
|
+
|
|
7
|
+
import siliconcompiler
|
|
8
|
+
from siliconcompiler.schema import Schema
|
|
9
|
+
from siliconcompiler.sphinx_ext.utils import (
|
|
10
|
+
strong,
|
|
11
|
+
code,
|
|
12
|
+
para,
|
|
13
|
+
keypath,
|
|
14
|
+
build_table,
|
|
15
|
+
build_section_with_target,
|
|
16
|
+
build_list
|
|
17
|
+
)
|
|
18
|
+
from siliconcompiler.schema import utils
|
|
19
|
+
|
|
20
|
+
|
|
21
|
+
# Main Sphinx plugin
|
|
22
|
+
class SchemaGen(SphinxDirective):
|
|
23
|
+
|
|
24
|
+
def run(self):
|
|
25
|
+
cfg_path = os.path.dirname(siliconcompiler.__file__)
|
|
26
|
+
self.env.note_dependency(os.path.join(cfg_path, 'schema', 'schema_cfg.py'))
|
|
27
|
+
self.env.note_dependency(__file__)
|
|
28
|
+
self.env.note_dependency(utils.__file__)
|
|
29
|
+
|
|
30
|
+
schema = Schema().cfg
|
|
31
|
+
|
|
32
|
+
return self.process_schema(schema)
|
|
33
|
+
|
|
34
|
+
def process_schema(self, schema, parents=[]):
|
|
35
|
+
if 'help' in schema:
|
|
36
|
+
entries = [[strong('Description'), para(schema['shorthelp'])],
|
|
37
|
+
[strong('Type'), para(schema['type'])]]
|
|
38
|
+
|
|
39
|
+
if schema['pernode'] != 'never':
|
|
40
|
+
entries.append([strong('Per step/index'), para(schema['pernode'])])
|
|
41
|
+
|
|
42
|
+
if 'enum' in schema['type']:
|
|
43
|
+
entries.append([strong('Allowed Values'),
|
|
44
|
+
build_list([code(val) for val in schema['enum']])])
|
|
45
|
+
|
|
46
|
+
if 'unit' in schema:
|
|
47
|
+
entries.append([strong('Unit'), para(schema['unit'])])
|
|
48
|
+
|
|
49
|
+
defvalue = schema['node']['default']['default']['value']
|
|
50
|
+
switch_list = [code(switch) for switch in schema['switch']]
|
|
51
|
+
entries.extend([[strong('Default Value'), para(defvalue)],
|
|
52
|
+
[strong('CLI Switch'), build_list(switch_list)]])
|
|
53
|
+
|
|
54
|
+
examples = {}
|
|
55
|
+
for example in schema['example']:
|
|
56
|
+
name, ex = example.split(':', 1)
|
|
57
|
+
examples.setdefault(name, []).append(ex)
|
|
58
|
+
|
|
59
|
+
for name, exs in examples.items():
|
|
60
|
+
examples = [code(ex.strip()) for ex in exs]
|
|
61
|
+
p = None
|
|
62
|
+
for ex in examples:
|
|
63
|
+
if not p:
|
|
64
|
+
p = para("")
|
|
65
|
+
else:
|
|
66
|
+
p += para("")
|
|
67
|
+
p += ex
|
|
68
|
+
entries.append([strong(f'Example ({name.upper()})'), p])
|
|
69
|
+
|
|
70
|
+
table = build_table(entries, colwidths=[25, 75])
|
|
71
|
+
body = self.parse_rst(utils.trim(schema['help']))
|
|
72
|
+
|
|
73
|
+
return [table, body]
|
|
74
|
+
else:
|
|
75
|
+
sections = []
|
|
76
|
+
for key in schema.keys():
|
|
77
|
+
if key == 'default':
|
|
78
|
+
for n in self.process_schema(schema['default'], parents=parents):
|
|
79
|
+
sections.append(n)
|
|
80
|
+
elif key not in ('history', 'library'):
|
|
81
|
+
section_key = 'param-' + '-'.join(parents + [key])
|
|
82
|
+
section = build_section_with_target(key, section_key, self.state.document)
|
|
83
|
+
for n in self.process_schema(schema[key], parents=parents + [key]):
|
|
84
|
+
section += n
|
|
85
|
+
sections.append(section)
|
|
86
|
+
|
|
87
|
+
# Sort all sections alphabetically by title. We may also have nodes
|
|
88
|
+
# in this list that aren't sections if `schema` has a 'default'
|
|
89
|
+
# entry that's a leaf. In this case, we sort this as an empty string
|
|
90
|
+
# in order to put this node at the beginning of the list.
|
|
91
|
+
return sorted(sections, key=lambda s: s[0][0] if isinstance(s, nodes.section) else '')
|
|
92
|
+
|
|
93
|
+
def parse_rst(self, content):
|
|
94
|
+
rst = ViewList()
|
|
95
|
+
# use fake filename 'inline' for error # reporting
|
|
96
|
+
for i, line in enumerate(content.split('\n')):
|
|
97
|
+
rst.append(line, 'inline', i)
|
|
98
|
+
body = nodes.paragraph()
|
|
99
|
+
nested_parse_with_titles(self.state, rst, body)
|
|
100
|
+
|
|
101
|
+
return body
|
|
102
|
+
|
|
103
|
+
|
|
104
|
+
class CategorySummary(SphinxDirective):
|
|
105
|
+
|
|
106
|
+
option_spec = {'category': str}
|
|
107
|
+
|
|
108
|
+
def run(self):
|
|
109
|
+
self.env.note_dependency(__file__)
|
|
110
|
+
category = self.options['category']
|
|
111
|
+
|
|
112
|
+
# List of documentation objects to return.
|
|
113
|
+
new_doc = []
|
|
114
|
+
section = nodes.section(ids=[nodes.make_id(f'{category}_summary')])
|
|
115
|
+
|
|
116
|
+
chip = siliconcompiler.Chip('<design>')
|
|
117
|
+
|
|
118
|
+
table = [[strong('parameter'), strong('description')]]
|
|
119
|
+
|
|
120
|
+
# Descend through defaults until we find the real items
|
|
121
|
+
prefix = [category]
|
|
122
|
+
while 'default' in chip.getdict(*prefix).keys():
|
|
123
|
+
prefix.append('default')
|
|
124
|
+
|
|
125
|
+
for item in chip.getkeys(*prefix):
|
|
126
|
+
key = para('')
|
|
127
|
+
key += keypath([*prefix, item], self.env.docname)
|
|
128
|
+
if 'shorthelp' in chip.getkeys(*prefix, item):
|
|
129
|
+
shorthelp = chip.get(*prefix, item, field='shorthelp')
|
|
130
|
+
table.append([key, para(shorthelp)])
|
|
131
|
+
else:
|
|
132
|
+
table.append([key, para("Contains sub-tree of parameters. See Schema.")])
|
|
133
|
+
section += build_table(table)
|
|
134
|
+
new_doc += section
|
|
135
|
+
|
|
136
|
+
return new_doc
|
|
137
|
+
|
|
138
|
+
|
|
139
|
+
class CategoryGroupTable(SphinxDirective):
|
|
140
|
+
|
|
141
|
+
def count_keys(self, schema, *keypath):
|
|
142
|
+
cfgs = schema.getdict(*keypath)
|
|
143
|
+
count = 0
|
|
144
|
+
for key, cfg in cfgs.items():
|
|
145
|
+
if schema._is_leaf(cfg):
|
|
146
|
+
count += 1
|
|
147
|
+
else:
|
|
148
|
+
count += self.count_keys(schema, *keypath, key)
|
|
149
|
+
|
|
150
|
+
return count
|
|
151
|
+
|
|
152
|
+
def run(self):
|
|
153
|
+
self.env.note_dependency(__file__)
|
|
154
|
+
|
|
155
|
+
desc = {
|
|
156
|
+
"option": "Compilation options",
|
|
157
|
+
"tool": "Individual tool settings",
|
|
158
|
+
"flowgraph": "Execution flow definition",
|
|
159
|
+
"pdk": "PDK related settings",
|
|
160
|
+
"asic": "ASIC related settings",
|
|
161
|
+
"fpga": "FPGA related settings",
|
|
162
|
+
"checklist": "Checklist related settings",
|
|
163
|
+
"constraint": "Design constraint settings",
|
|
164
|
+
"metric": "Metric tracking",
|
|
165
|
+
"record": "Compilation history tracking",
|
|
166
|
+
"package": "Packaging manifest",
|
|
167
|
+
"datasheet": "Design interface specifications",
|
|
168
|
+
|
|
169
|
+
# Nothing to document
|
|
170
|
+
"library": "",
|
|
171
|
+
"history": "",
|
|
172
|
+
"input": "",
|
|
173
|
+
"output": "",
|
|
174
|
+
"schemaversion": "",
|
|
175
|
+
"design": "",
|
|
176
|
+
"arg": "",
|
|
177
|
+
}
|
|
178
|
+
|
|
179
|
+
schema = Schema()
|
|
180
|
+
|
|
181
|
+
# Check if all groups have desc
|
|
182
|
+
for group in schema.getkeys():
|
|
183
|
+
if group not in desc:
|
|
184
|
+
raise ValueError(f"{group} not found in group descriptions")
|
|
185
|
+
|
|
186
|
+
# Check if all groups have schema
|
|
187
|
+
for group in desc.keys():
|
|
188
|
+
if group not in schema.getkeys():
|
|
189
|
+
raise ValueError(f"{group} not found in schema")
|
|
190
|
+
|
|
191
|
+
table = [[strong('Group'), strong('Parameters'), strong('Description')]]
|
|
192
|
+
|
|
193
|
+
total = 0
|
|
194
|
+
for group in schema.getkeys():
|
|
195
|
+
text = desc[group]
|
|
196
|
+
if len(text) == 0:
|
|
197
|
+
continue
|
|
198
|
+
|
|
199
|
+
key = para('')
|
|
200
|
+
key += keypath([group], self.env.docname)
|
|
201
|
+
|
|
202
|
+
count = self.count_keys(schema, group)
|
|
203
|
+
total += count
|
|
204
|
+
|
|
205
|
+
table.append([key, para(f'{count}'), para(text)])
|
|
206
|
+
|
|
207
|
+
table.append([strong('Total'), para(f'{total}'), para('')])
|
|
208
|
+
|
|
209
|
+
return build_table(table)
|
|
210
|
+
|
|
211
|
+
|
|
212
|
+
def setup(app):
|
|
213
|
+
app.add_directive('schemagen', SchemaGen)
|
|
214
|
+
app.add_directive('schema_category_summary', CategorySummary)
|
|
215
|
+
app.add_directive('schema_group_summary', CategoryGroupTable)
|
|
216
|
+
|
|
217
|
+
return {
|
|
218
|
+
'version': '0.1',
|
|
219
|
+
'parallel_read_safe': True,
|
|
220
|
+
'parallel_write_safe': True,
|
|
221
|
+
}
|
|
@@ -0,0 +1,166 @@
|
|
|
1
|
+
from docutils import nodes
|
|
2
|
+
import sphinx.addnodes
|
|
3
|
+
|
|
4
|
+
from siliconcompiler.schema import Schema
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
# Docutils helpers
|
|
8
|
+
def build_table(items, colwidths=None, colspec=None):
|
|
9
|
+
'''Create table node.
|
|
10
|
+
|
|
11
|
+
Args:
|
|
12
|
+
- items (list of list of nodes): nested list of table contents
|
|
13
|
+
- colwidths (list of nums): relative column widths (seems to affect HTML
|
|
14
|
+
builder only)
|
|
15
|
+
- colspec (str): LaTeX column spec for overriding Sphinx defaults
|
|
16
|
+
|
|
17
|
+
Returns list of nodes, since there may be an associated TabularColumn node
|
|
18
|
+
that hints at sizing in PDF output.
|
|
19
|
+
'''
|
|
20
|
+
if colwidths is None:
|
|
21
|
+
colwidths = [1] * len(items[0]) # default to equal spacing
|
|
22
|
+
else:
|
|
23
|
+
assert len(colwidths) == len(items[0])
|
|
24
|
+
|
|
25
|
+
return_nodes = []
|
|
26
|
+
if colspec is not None:
|
|
27
|
+
colspec_node = sphinx.addnodes.tabular_col_spec()
|
|
28
|
+
colspec_node['spec'] = colspec
|
|
29
|
+
return_nodes.append(colspec_node)
|
|
30
|
+
|
|
31
|
+
table = nodes.table()
|
|
32
|
+
table['classes'] = ['longtable']
|
|
33
|
+
|
|
34
|
+
group = nodes.tgroup(cols=len(items[0]))
|
|
35
|
+
table += group
|
|
36
|
+
for colwidth in colwidths:
|
|
37
|
+
group += nodes.colspec(colwidth=colwidth)
|
|
38
|
+
|
|
39
|
+
body = nodes.tbody()
|
|
40
|
+
group += body
|
|
41
|
+
|
|
42
|
+
for row in items:
|
|
43
|
+
row_node = nodes.row()
|
|
44
|
+
body += row_node
|
|
45
|
+
for col in row:
|
|
46
|
+
entry = nodes.entry()
|
|
47
|
+
row_node += entry
|
|
48
|
+
entry += col
|
|
49
|
+
|
|
50
|
+
return_nodes.append(table)
|
|
51
|
+
|
|
52
|
+
return return_nodes
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
def build_section(text, key):
|
|
56
|
+
sec = nodes.section(ids=[get_ref_id(key)])
|
|
57
|
+
sec += nodes.title(text=text)
|
|
58
|
+
return sec
|
|
59
|
+
|
|
60
|
+
|
|
61
|
+
def build_section_with_target(text, key, ctx):
|
|
62
|
+
id = get_ref_id(key)
|
|
63
|
+
target = nodes.target('', '', ids=[id], names=[id])
|
|
64
|
+
sec = nodes.section(ids=[id])
|
|
65
|
+
sec += nodes.title(text=text)
|
|
66
|
+
|
|
67
|
+
# We don't need to add target node to hierarchy, just need to call this
|
|
68
|
+
# function.
|
|
69
|
+
ctx.note_explicit_target(target)
|
|
70
|
+
|
|
71
|
+
return sec
|
|
72
|
+
|
|
73
|
+
|
|
74
|
+
def get_ref_id(key):
|
|
75
|
+
return nodes.make_id(key + "-ref")
|
|
76
|
+
|
|
77
|
+
|
|
78
|
+
def para(text):
|
|
79
|
+
return nodes.paragraph(text=text)
|
|
80
|
+
|
|
81
|
+
|
|
82
|
+
def code(text):
|
|
83
|
+
return nodes.literal(text=text)
|
|
84
|
+
|
|
85
|
+
|
|
86
|
+
def literalblock(text):
|
|
87
|
+
block = nodes.literal_block(text=text)
|
|
88
|
+
block['language'] = 'none'
|
|
89
|
+
return block
|
|
90
|
+
|
|
91
|
+
|
|
92
|
+
def strong(text):
|
|
93
|
+
p = nodes.paragraph()
|
|
94
|
+
p += nodes.strong(text=text)
|
|
95
|
+
return p
|
|
96
|
+
|
|
97
|
+
|
|
98
|
+
def image(src, center=False):
|
|
99
|
+
i = nodes.image()
|
|
100
|
+
i['uri'] = '/' + src
|
|
101
|
+
if center:
|
|
102
|
+
i['align'] = 'center'
|
|
103
|
+
return i
|
|
104
|
+
|
|
105
|
+
|
|
106
|
+
def link(url, text=None):
|
|
107
|
+
if text is None:
|
|
108
|
+
text = url
|
|
109
|
+
return nodes.reference(internal=False, refuri=url, text=text)
|
|
110
|
+
|
|
111
|
+
|
|
112
|
+
def build_list(items, enumerated=False):
|
|
113
|
+
if enumerated:
|
|
114
|
+
list = nodes.enumerated_list()
|
|
115
|
+
else:
|
|
116
|
+
list = nodes.bullet_list()
|
|
117
|
+
|
|
118
|
+
for item in items:
|
|
119
|
+
docutils_item = nodes.list_item()
|
|
120
|
+
docutils_item += item
|
|
121
|
+
list += docutils_item
|
|
122
|
+
|
|
123
|
+
return list
|
|
124
|
+
|
|
125
|
+
|
|
126
|
+
def keypath(key_path, refdoc, key_text=None):
|
|
127
|
+
'''Helper function for displaying Schema keypaths.'''
|
|
128
|
+
text_parts = []
|
|
129
|
+
key_parts = []
|
|
130
|
+
cfg = Schema().cfg
|
|
131
|
+
for key in key_path:
|
|
132
|
+
if list(cfg.keys()) != ['default']:
|
|
133
|
+
text_parts.append(f"'{key}'")
|
|
134
|
+
key_parts.append(key)
|
|
135
|
+
try:
|
|
136
|
+
cfg = cfg[key]
|
|
137
|
+
except KeyError:
|
|
138
|
+
raise ValueError(f'Invalid keypath {key_path}')
|
|
139
|
+
else:
|
|
140
|
+
cfg = cfg['default']
|
|
141
|
+
if key.startswith('<') and key.endswith('>'):
|
|
142
|
+
# Placeholder
|
|
143
|
+
text_parts.append(key)
|
|
144
|
+
else:
|
|
145
|
+
# Fully-qualified
|
|
146
|
+
text_parts.append(f"'{key}'")
|
|
147
|
+
|
|
148
|
+
if 'help' not in cfg:
|
|
149
|
+
# Not leaf
|
|
150
|
+
text_parts.append('...')
|
|
151
|
+
|
|
152
|
+
if key_text:
|
|
153
|
+
text_parts = key_text
|
|
154
|
+
text = f"[{', '.join(text_parts)}]"
|
|
155
|
+
refid = get_ref_id('param-' + '-'.join(key_parts))
|
|
156
|
+
|
|
157
|
+
opt = {'refdoc': refdoc,
|
|
158
|
+
'refdomain': 'sc',
|
|
159
|
+
'reftype': 'ref',
|
|
160
|
+
'refexplicit': True,
|
|
161
|
+
'refwarn': True}
|
|
162
|
+
refnode = sphinx.addnodes.pending_xref('keypath', **opt)
|
|
163
|
+
refnode['reftarget'] = refid
|
|
164
|
+
refnode += code(text)
|
|
165
|
+
|
|
166
|
+
return refnode
|
|
File without changes
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
import siliconcompiler
|
|
2
|
+
from siliconcompiler.flows import asicflow, synflow
|
|
3
|
+
|
|
4
|
+
from lambdapdk import asap7
|
|
5
|
+
from lambdapdk.asap7.libs import asap7sc7p5t
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
####################################################
|
|
9
|
+
# Target Setup
|
|
10
|
+
####################################################
|
|
11
|
+
def setup(chip, syn_np=1, floorplan_np=1, physyn_np=1, place_np=1, cts_np=1, route_np=1,
|
|
12
|
+
timing_np=1):
|
|
13
|
+
'''
|
|
14
|
+
ASAP7 Demo Target
|
|
15
|
+
'''
|
|
16
|
+
|
|
17
|
+
asic_flow_args = {
|
|
18
|
+
"syn_np": syn_np,
|
|
19
|
+
"floorplan_np": floorplan_np,
|
|
20
|
+
"physyn_np": physyn_np,
|
|
21
|
+
"place_np": place_np,
|
|
22
|
+
"cts_np": cts_np,
|
|
23
|
+
"route_np": route_np
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
# 1. Load PDK, flow, libs combo
|
|
27
|
+
chip.use(asap7)
|
|
28
|
+
chip.use(asap7sc7p5t)
|
|
29
|
+
chip.use(asicflow, **asic_flow_args)
|
|
30
|
+
chip.use(synflow, syn_np=syn_np, timing_np=timing_np)
|
|
31
|
+
|
|
32
|
+
# 2. Select default flow/PDK
|
|
33
|
+
chip.set('option', 'flow', 'asicflow', clobber=False)
|
|
34
|
+
chip.set('option', 'pdk', 'asap7', clobber=False)
|
|
35
|
+
chip.set('option', 'stackup', '10M', clobber=False)
|
|
36
|
+
|
|
37
|
+
# 3. Select libraries
|
|
38
|
+
chip.set('asic', 'logiclib', 'asap7sc7p5t_rvt', clobber=False)
|
|
39
|
+
|
|
40
|
+
# 4. Project specific design choices
|
|
41
|
+
chip.set('asic', 'delaymodel', 'nldm', clobber=False)
|
|
42
|
+
chip.set('constraint', 'density', 40, clobber=False)
|
|
43
|
+
chip.set('constraint', 'coremargin', 1, clobber=False)
|
|
44
|
+
|
|
45
|
+
# 5. Timing corners
|
|
46
|
+
pex_corner = 'typical'
|
|
47
|
+
|
|
48
|
+
chip.set('constraint', 'timing', 'slow', 'libcorner', 'slow', clobber=False)
|
|
49
|
+
chip.set('constraint', 'timing', 'slow', 'pexcorner', pex_corner, clobber=False)
|
|
50
|
+
chip.set('constraint', 'timing', 'slow', 'mode', 'func', clobber=False)
|
|
51
|
+
chip.set('constraint', 'timing', 'slow', 'check', ['setup', 'hold'], clobber=False)
|
|
52
|
+
|
|
53
|
+
chip.set('constraint', 'timing', 'fast', 'libcorner', 'fast', clobber=False)
|
|
54
|
+
chip.set('constraint', 'timing', 'fast', 'pexcorner', pex_corner, clobber=False)
|
|
55
|
+
chip.set('constraint', 'timing', 'fast', 'mode', 'func', clobber=False)
|
|
56
|
+
chip.set('constraint', 'timing', 'fast', 'check', ['setup', 'hold'], clobber=False)
|
|
57
|
+
|
|
58
|
+
chip.set('constraint', 'timing', 'typical', 'libcorner', 'typical', clobber=False)
|
|
59
|
+
chip.set('constraint', 'timing', 'typical', 'pexcorner', pex_corner, clobber=False)
|
|
60
|
+
chip.set('constraint', 'timing', 'typical', 'mode', 'func', clobber=False)
|
|
61
|
+
chip.set('constraint', 'timing', 'typical', 'check', ['power'], clobber=False)
|
|
62
|
+
|
|
63
|
+
|
|
64
|
+
#########################
|
|
65
|
+
if __name__ == "__main__":
|
|
66
|
+
target = siliconcompiler.Chip('<target>')
|
|
67
|
+
setup(target)
|
|
68
|
+
target.write_manifest('asap7_demo.json')
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
import os
|
|
2
|
+
import siliconcompiler
|
|
3
|
+
from siliconcompiler.targets import skywater130_demo
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
def setup(chip):
|
|
7
|
+
'''
|
|
8
|
+
"Self-test" target which builds a small 8-bit counter design as an ASIC,
|
|
9
|
+
targeting the Skywater130 PDK.
|
|
10
|
+
|
|
11
|
+
This target is intended for testing purposes only,
|
|
12
|
+
to verify that SiliconCompiler is installed and configured correctly.
|
|
13
|
+
'''
|
|
14
|
+
|
|
15
|
+
# Set design name
|
|
16
|
+
design = 'heartbeat'
|
|
17
|
+
chip.set('design', design)
|
|
18
|
+
|
|
19
|
+
# Load the Sky130 PDK/standard cell library target.
|
|
20
|
+
chip.load_target(skywater130_demo)
|
|
21
|
+
|
|
22
|
+
# Set quiet flag
|
|
23
|
+
chip.set('option', 'quiet', True, clobber=False)
|
|
24
|
+
|
|
25
|
+
# Set die area and clock constraint.
|
|
26
|
+
chip.set('constraint', 'outline', [(0, 0), (50, 50)], clobber=False)
|
|
27
|
+
chip.set('constraint', 'corearea', [(5, 5), (45, 45)], clobber=False)
|
|
28
|
+
chip.clock('clk', period=10)
|
|
29
|
+
|
|
30
|
+
# Add source files.
|
|
31
|
+
chip.input(os.path.join('data', f'{design}.v'), package='siliconcompiler')
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
#########################
|
|
35
|
+
if __name__ == "__main__":
|
|
36
|
+
target = siliconcompiler.Chip('<target>')
|
|
37
|
+
setup(target)
|
|
38
|
+
target.write_manifest('asic_demo.json')
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
import siliconcompiler
|
|
2
|
+
from siliconcompiler import SiliconCompilerError
|
|
3
|
+
from siliconcompiler.fpgas import lattice_ice40
|
|
4
|
+
from siliconcompiler.fpgas import vpr_example
|
|
5
|
+
|
|
6
|
+
from siliconcompiler.flows import fpgaflow
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
############################################################################
|
|
10
|
+
# DOCS
|
|
11
|
+
############################################################################
|
|
12
|
+
def make_docs(chip):
|
|
13
|
+
chip.set('fpga', 'partname', 'ice40up5k-sg48')
|
|
14
|
+
|
|
15
|
+
|
|
16
|
+
####################################################
|
|
17
|
+
# Target Setup
|
|
18
|
+
####################################################
|
|
19
|
+
def setup(chip):
|
|
20
|
+
'''
|
|
21
|
+
Demonstration target for running the open-source fpgaflow.
|
|
22
|
+
'''
|
|
23
|
+
|
|
24
|
+
# 1. Configure fpga part
|
|
25
|
+
part_name = chip.get('fpga', 'partname')
|
|
26
|
+
if not part_name:
|
|
27
|
+
raise SiliconCompilerError('FPGA partname has not been set.', chip=chip)
|
|
28
|
+
|
|
29
|
+
# 2. Load all available FPGAs
|
|
30
|
+
chip.use(lattice_ice40)
|
|
31
|
+
chip.use(vpr_example)
|
|
32
|
+
|
|
33
|
+
if part_name not in chip.getkeys('fpga'):
|
|
34
|
+
raise SiliconCompilerError(f'{part_name} has not been loaded', chip=chip)
|
|
35
|
+
|
|
36
|
+
# 3. Load flow
|
|
37
|
+
chip.use(fpgaflow)
|
|
38
|
+
|
|
39
|
+
# 4. Select default flow
|
|
40
|
+
chip.set('option', 'flow', 'fpgaflow', clobber=False)
|
|
41
|
+
|
|
42
|
+
|
|
43
|
+
#########################
|
|
44
|
+
if __name__ == "__main__":
|
|
45
|
+
target = siliconcompiler.Chip('<target>')
|
|
46
|
+
setup(target)
|
|
47
|
+
target.write_manifest('fpgaflow_demo.json')
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import siliconcompiler
|
|
2
|
+
from siliconcompiler.flows import lintflow, asicflow, asictopflow, synflow
|
|
3
|
+
|
|
4
|
+
from lambdapdk import freepdk45
|
|
5
|
+
from lambdapdk.freepdk45.libs import nangate45
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
####################################################
|
|
9
|
+
# Target Setup
|
|
10
|
+
####################################################
|
|
11
|
+
def setup(chip, syn_np=1, floorplan_np=1, physyn_np=1, place_np=1, cts_np=1, route_np=1,
|
|
12
|
+
timing_np=1):
|
|
13
|
+
'''
|
|
14
|
+
FreePDK45 demo target
|
|
15
|
+
'''
|
|
16
|
+
|
|
17
|
+
asic_flow_args = {
|
|
18
|
+
"syn_np": syn_np,
|
|
19
|
+
"floorplan_np": floorplan_np,
|
|
20
|
+
"physyn_np": physyn_np,
|
|
21
|
+
"place_np": place_np,
|
|
22
|
+
"cts_np": cts_np,
|
|
23
|
+
"route_np": route_np
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
# 1. Load PDK, flow, libs combo
|
|
27
|
+
chip.use(freepdk45)
|
|
28
|
+
chip.use(nangate45)
|
|
29
|
+
chip.use(lintflow)
|
|
30
|
+
chip.use(asicflow, **asic_flow_args)
|
|
31
|
+
chip.use(synflow, syn_np=syn_np, timing_np=timing_np)
|
|
32
|
+
chip.use(asictopflow)
|
|
33
|
+
|
|
34
|
+
# 2. Set flow and pdk
|
|
35
|
+
chip.set('option', 'flow', 'asicflow', clobber=False)
|
|
36
|
+
chip.set('option', 'pdk', 'freepdk45', clobber=False)
|
|
37
|
+
chip.set('option', 'stackup', '10M', clobber=False)
|
|
38
|
+
|
|
39
|
+
# 3. Select libraries
|
|
40
|
+
chip.set('asic', 'logiclib', 'nangate45', clobber=False)
|
|
41
|
+
|
|
42
|
+
# 4. Set project specific design choices
|
|
43
|
+
chip.set('asic', 'delaymodel', 'nldm', clobber=False)
|
|
44
|
+
chip.set('constraint', 'density', 40, clobber=False)
|
|
45
|
+
chip.set('constraint', 'coremargin', 1, clobber=False)
|
|
46
|
+
|
|
47
|
+
# 5. Timing corners
|
|
48
|
+
corner = 'typical'
|
|
49
|
+
chip.set('constraint', 'timing', 'worst', 'libcorner', corner, clobber=False)
|
|
50
|
+
chip.set('constraint', 'timing', 'worst', 'pexcorner', corner, clobber=False)
|
|
51
|
+
chip.set('constraint', 'timing', 'worst', 'mode', 'func', clobber=False)
|
|
52
|
+
chip.set('constraint', 'timing', 'worst', 'check', ['setup', 'hold'], clobber=False)
|
|
53
|
+
|
|
54
|
+
|
|
55
|
+
#########################
|
|
56
|
+
if __name__ == "__main__":
|
|
57
|
+
target = siliconcompiler.Chip('<target>')
|
|
58
|
+
setup(target)
|
|
59
|
+
target.write_manifest('freepdk45_demo.json')
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
import siliconcompiler
|
|
2
|
+
from siliconcompiler.flows import asicflow, asictopflow, signoffflow, synflow
|
|
3
|
+
from siliconcompiler.checklists import oh_tapeout
|
|
4
|
+
from siliconcompiler.tools.openroad import openroad
|
|
5
|
+
from siliconcompiler.tools._common import get_tool_tasks
|
|
6
|
+
|
|
7
|
+
from lambdapdk import gf180
|
|
8
|
+
from lambdapdk.gf180.libs import gf180mcu
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
####################################################
|
|
12
|
+
# Target Setup
|
|
13
|
+
####################################################
|
|
14
|
+
def setup(chip, syn_np=1, floorplan_np=1, physyn_np=1, place_np=1, cts_np=1, route_np=1,
|
|
15
|
+
timing_np=1):
|
|
16
|
+
'''
|
|
17
|
+
Global foundries 180 Demo Target
|
|
18
|
+
'''
|
|
19
|
+
|
|
20
|
+
asic_flow_args = {
|
|
21
|
+
"syn_np": syn_np,
|
|
22
|
+
"floorplan_np": floorplan_np,
|
|
23
|
+
"physyn_np": physyn_np,
|
|
24
|
+
"place_np": place_np,
|
|
25
|
+
"cts_np": cts_np,
|
|
26
|
+
"route_np": route_np
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
# 1. Load PDK, flow, libs
|
|
30
|
+
chip.use(gf180)
|
|
31
|
+
chip.use(gf180mcu)
|
|
32
|
+
chip.use(asicflow, **asic_flow_args)
|
|
33
|
+
chip.use(synflow, syn_np=syn_np, timing_np=timing_np)
|
|
34
|
+
chip.use(asictopflow)
|
|
35
|
+
chip.use(signoffflow)
|
|
36
|
+
chip.use(oh_tapeout)
|
|
37
|
+
|
|
38
|
+
# 2. Set default targets
|
|
39
|
+
chip.set('option', 'flow', 'asicflow', clobber=False)
|
|
40
|
+
chip.set('option', 'pdk', 'gf180', clobber=False)
|
|
41
|
+
chip.set('option', 'stackup', '5LM_1TM_9K', clobber=False)
|
|
42
|
+
|
|
43
|
+
# 3. Set project specific design choices
|
|
44
|
+
chip.set('asic', 'logiclib', 'gf180mcu_fd_sc_mcu9t5v0', clobber=False)
|
|
45
|
+
|
|
46
|
+
# 4. get project specific design choices
|
|
47
|
+
chip.set('asic', 'delaymodel', 'nldm', clobber=False)
|
|
48
|
+
chip.set('constraint', 'density', 40, clobber=False)
|
|
49
|
+
chip.set('constraint', 'coremargin', 1, clobber=False)
|
|
50
|
+
|
|
51
|
+
# 5. Timing corners
|
|
52
|
+
chip.set('constraint', 'timing', 'slow', 'libcorner', 'slow', clobber=False)
|
|
53
|
+
chip.set('constraint', 'timing', 'slow', 'pexcorner', 'wst', clobber=False)
|
|
54
|
+
chip.set('constraint', 'timing', 'slow', 'mode', 'func', clobber=False)
|
|
55
|
+
chip.set('constraint', 'timing', 'slow', 'check', ['setup', 'hold'], clobber=False)
|
|
56
|
+
|
|
57
|
+
chip.set('constraint', 'timing', 'fast', 'libcorner', 'fast', clobber=False)
|
|
58
|
+
chip.set('constraint', 'timing', 'fast', 'pexcorner', 'bst', clobber=False)
|
|
59
|
+
chip.set('constraint', 'timing', 'fast', 'mode', 'func', clobber=False)
|
|
60
|
+
chip.set('constraint', 'timing', 'fast', 'check', ['setup', 'hold'], clobber=False)
|
|
61
|
+
|
|
62
|
+
chip.set('constraint', 'timing', 'typical', 'libcorner', 'typical', clobber=False)
|
|
63
|
+
chip.set('constraint', 'timing', 'typical', 'pexcorner', 'typ', clobber=False)
|
|
64
|
+
chip.set('constraint', 'timing', 'typical', 'mode', 'func', clobber=False)
|
|
65
|
+
chip.set('constraint', 'timing', 'typical', 'check', ['power'], clobber=False)
|
|
66
|
+
|
|
67
|
+
# PSM gets stuck in a loop, must be disabled for now on gf180
|
|
68
|
+
for task in get_tool_tasks(chip, openroad):
|
|
69
|
+
chip.set('tool', 'openroad', 'task', task, 'var', 'psm_enable', 'false')
|
|
70
|
+
chip.set('tool', 'openroad', 'task', 'route', 'var', 'ant_check', 'false')
|
|
71
|
+
|
|
72
|
+
|
|
73
|
+
#########################
|
|
74
|
+
if __name__ == "__main__":
|
|
75
|
+
target = siliconcompiler.Chip('<target>')
|
|
76
|
+
setup(target)
|
|
77
|
+
target.write_manifest('gf180_demo.json')
|