siliconcompiler 0.32.2__py3-none-any.whl → 0.32.3__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/_metadata.py +3 -2
- siliconcompiler/core.py +52 -56
- siliconcompiler/issue.py +3 -1
- siliconcompiler/remote/client.py +55 -16
- siliconcompiler/report/__init__.py +3 -2
- siliconcompiler/report/dashboard/__init__.py +61 -170
- siliconcompiler/report/dashboard/cli/__init__.py +788 -0
- siliconcompiler/report/dashboard/web/__init__.py +196 -0
- siliconcompiler/report/dashboard/{components → web/components}/__init__.py +4 -4
- siliconcompiler/report/dashboard/{components → web/components}/graph.py +1 -1
- siliconcompiler/report/dashboard/{layouts → web/layouts}/__init__.py +3 -3
- siliconcompiler/report/dashboard/{layouts → web/layouts}/_common.py +1 -1
- siliconcompiler/report/dashboard/{layouts → web/layouts}/vertical_flowgraph.py +5 -5
- siliconcompiler/report/dashboard/{layouts → web/layouts}/vertical_flowgraph_node_tab.py +6 -6
- siliconcompiler/report/dashboard/{layouts → web/layouts}/vertical_flowgraph_sac_tabs.py +6 -6
- siliconcompiler/report/dashboard/{viewer.py → web/viewer.py} +4 -4
- siliconcompiler/scheduler/__init__.py +8 -6
- siliconcompiler/templates/replay/replay.sh.j2 +2 -2
- siliconcompiler/tools/_common/__init__.py +2 -0
- siliconcompiler/tools/openroad/_apr.py +4 -0
- siliconcompiler/tools/openroad/fillmetal_insertion.py +14 -14
- siliconcompiler/tools/openroad/scripts/apr/sc_antenna_repair.tcl +1 -1
- siliconcompiler/tools/openroad/scripts/apr/sc_clock_tree_synthesis.tcl +1 -1
- siliconcompiler/tools/openroad/scripts/apr/sc_detailed_placement.tcl +1 -1
- siliconcompiler/tools/openroad/scripts/apr/sc_detailed_route.tcl +1 -1
- siliconcompiler/tools/openroad/scripts/apr/sc_endcap_tapcell_insertion.tcl +1 -1
- siliconcompiler/tools/openroad/scripts/apr/sc_fillercell_insertion.tcl +1 -1
- siliconcompiler/tools/openroad/scripts/apr/sc_fillmetal_insertion.tcl +2 -2
- siliconcompiler/tools/openroad/scripts/apr/sc_global_placement.tcl +1 -1
- siliconcompiler/tools/openroad/scripts/apr/sc_global_route.tcl +1 -1
- siliconcompiler/tools/openroad/scripts/apr/sc_init_floorplan.tcl +1 -1
- siliconcompiler/tools/openroad/scripts/apr/sc_macro_placement.tcl +1 -1
- siliconcompiler/tools/openroad/scripts/apr/sc_metrics.tcl +1 -1
- siliconcompiler/tools/openroad/scripts/apr/sc_pin_placement.tcl +1 -1
- siliconcompiler/tools/openroad/scripts/apr/sc_power_grid.tcl +1 -1
- siliconcompiler/tools/openroad/scripts/apr/sc_repair_design.tcl +1 -1
- siliconcompiler/tools/openroad/scripts/apr/sc_repair_timing.tcl +2 -2
- siliconcompiler/tools/openroad/scripts/apr/sc_write_data.tcl +1 -1
- siliconcompiler/tools/openroad/scripts/common/procs.tcl +1 -1
- siliconcompiler/tools/openroad/scripts/common/reports.tcl +2 -2
- siliconcompiler/tools/openroad/scripts/sc_rcx.tcl +1 -1
- siliconcompiler/tools/openroad/scripts/sc_rdlroute.tcl +1 -1
- siliconcompiler/tools/openroad/scripts/sc_show.tcl +1 -1
- siliconcompiler/tools/opensta/__init__.py +1 -1
- siliconcompiler/tools/opensta/scripts/sc_check_library.tcl +1 -1
- siliconcompiler/tools/opensta/scripts/sc_procs.tcl +16 -0
- siliconcompiler/tools/opensta/scripts/sc_report_libraries.tcl +1 -1
- siliconcompiler/tools/opensta/scripts/sc_timing.tcl +35 -7
- siliconcompiler/tools/opensta/timing.py +6 -2
- siliconcompiler/tools/yosys/sc_synth_asic.tcl +36 -28
- siliconcompiler/tools/yosys/syn_asic.py +11 -2
- siliconcompiler/toolscripts/_tools.json +9 -4
- siliconcompiler/toolscripts/rhel8/install-chisel.sh +2 -0
- siliconcompiler/toolscripts/rhel8/install-icarus.sh +1 -0
- siliconcompiler/toolscripts/rhel8/install-klayout.sh +2 -0
- siliconcompiler/toolscripts/rhel8/install-magic.sh +1 -2
- siliconcompiler/toolscripts/rhel8/install-netgen.sh +1 -1
- siliconcompiler/toolscripts/rhel8/install-slang.sh +2 -0
- siliconcompiler/toolscripts/rhel8/install-surelog.sh +3 -1
- siliconcompiler/toolscripts/rhel8/install-sv2v.sh +1 -0
- siliconcompiler/toolscripts/rhel8/install-verible.sh +2 -0
- siliconcompiler/toolscripts/rhel8/install-verilator.sh +1 -0
- siliconcompiler/toolscripts/rhel8/install-xyce.sh +2 -0
- siliconcompiler/toolscripts/rhel9/install-chisel.sh +2 -0
- siliconcompiler/toolscripts/rhel9/install-ghdl.sh +1 -0
- siliconcompiler/toolscripts/rhel9/install-gtkwave.sh +1 -0
- siliconcompiler/toolscripts/rhel9/install-icarus.sh +1 -0
- siliconcompiler/toolscripts/rhel9/install-klayout.sh +2 -0
- siliconcompiler/toolscripts/rhel9/install-magic.sh +1 -2
- siliconcompiler/toolscripts/rhel9/install-netgen.sh +1 -1
- siliconcompiler/toolscripts/rhel9/install-openroad.sh +2 -0
- siliconcompiler/toolscripts/rhel9/install-opensta.sh +76 -0
- siliconcompiler/toolscripts/rhel9/install-slang.sh +3 -1
- siliconcompiler/toolscripts/rhel9/install-surelog.sh +2 -1
- siliconcompiler/toolscripts/rhel9/install-sv2v.sh +1 -0
- siliconcompiler/toolscripts/rhel9/install-verible.sh +2 -0
- siliconcompiler/toolscripts/rhel9/install-verilator.sh +1 -0
- siliconcompiler/toolscripts/rhel9/install-vpr.sh +2 -0
- siliconcompiler/toolscripts/rhel9/install-xdm.sh +2 -0
- siliconcompiler/toolscripts/rhel9/install-xyce.sh +2 -0
- siliconcompiler/toolscripts/rhel9/install-yosys-moosic.sh +2 -0
- siliconcompiler/toolscripts/rhel9/install-yosys-parmys.sh +2 -0
- siliconcompiler/toolscripts/rhel9/install-yosys-slang.sh +3 -1
- siliconcompiler/toolscripts/rhel9/install-yosys.sh +2 -0
- siliconcompiler/toolscripts/ubuntu20/install-bambu.sh +2 -0
- siliconcompiler/toolscripts/ubuntu20/install-bluespec.sh +2 -0
- siliconcompiler/toolscripts/ubuntu20/install-chisel.sh +2 -0
- siliconcompiler/toolscripts/ubuntu20/install-ghdl.sh +2 -0
- siliconcompiler/toolscripts/ubuntu20/install-gtkwave.sh +2 -0
- siliconcompiler/toolscripts/ubuntu20/install-icarus.sh +2 -0
- siliconcompiler/toolscripts/ubuntu20/install-icepack.sh +2 -0
- siliconcompiler/toolscripts/ubuntu20/install-klayout.sh +2 -0
- siliconcompiler/toolscripts/ubuntu20/install-magic.sh +2 -0
- siliconcompiler/toolscripts/ubuntu20/install-netgen.sh +2 -0
- siliconcompiler/toolscripts/ubuntu20/install-nextpnr.sh +1 -3
- siliconcompiler/toolscripts/ubuntu20/install-openroad.sh +2 -0
- siliconcompiler/toolscripts/ubuntu20/install-opensta.sh +72 -0
- siliconcompiler/toolscripts/ubuntu20/install-slang.sh +3 -1
- siliconcompiler/toolscripts/ubuntu20/install-slurm.sh +2 -0
- siliconcompiler/toolscripts/ubuntu20/install-surelog.sh +3 -1
- siliconcompiler/toolscripts/ubuntu20/install-sv2v.sh +1 -1
- siliconcompiler/toolscripts/ubuntu20/install-verible.sh +2 -0
- siliconcompiler/toolscripts/ubuntu20/install-verilator.sh +2 -0
- siliconcompiler/toolscripts/ubuntu20/install-vpr.sh +2 -0
- siliconcompiler/toolscripts/ubuntu20/install-xdm.sh +2 -0
- siliconcompiler/toolscripts/ubuntu20/install-xyce.sh +2 -0
- siliconcompiler/toolscripts/ubuntu20/install-yosys-moosic.sh +2 -0
- siliconcompiler/toolscripts/ubuntu20/install-yosys-parmys.sh +2 -0
- siliconcompiler/toolscripts/ubuntu20/install-yosys.sh +2 -0
- siliconcompiler/toolscripts/ubuntu22/install-bambu.sh +2 -0
- siliconcompiler/toolscripts/ubuntu22/install-bluespec.sh +2 -0
- siliconcompiler/toolscripts/ubuntu22/install-chisel.sh +2 -0
- siliconcompiler/toolscripts/ubuntu22/install-ghdl.sh +2 -0
- siliconcompiler/toolscripts/ubuntu22/install-gtkwave.sh +2 -0
- siliconcompiler/toolscripts/ubuntu22/install-icarus.sh +2 -0
- siliconcompiler/toolscripts/ubuntu22/install-icepack.sh +2 -0
- siliconcompiler/toolscripts/ubuntu22/install-klayout.sh +2 -0
- siliconcompiler/toolscripts/ubuntu22/install-magic.sh +2 -0
- siliconcompiler/toolscripts/ubuntu22/install-netgen.sh +2 -0
- siliconcompiler/toolscripts/ubuntu22/install-nextpnr.sh +1 -2
- siliconcompiler/toolscripts/ubuntu22/install-openroad.sh +2 -0
- siliconcompiler/toolscripts/ubuntu22/install-opensta.sh +72 -0
- siliconcompiler/toolscripts/ubuntu22/install-slang.sh +3 -1
- siliconcompiler/toolscripts/ubuntu22/install-slurm.sh +2 -0
- siliconcompiler/toolscripts/ubuntu22/install-surelog.sh +3 -1
- siliconcompiler/toolscripts/ubuntu22/install-sv2v.sh +1 -1
- siliconcompiler/toolscripts/ubuntu22/install-verible.sh +2 -0
- siliconcompiler/toolscripts/ubuntu22/install-verilator.sh +2 -0
- siliconcompiler/toolscripts/ubuntu22/install-vpr.sh +2 -0
- siliconcompiler/toolscripts/ubuntu22/install-xdm.sh +2 -0
- siliconcompiler/toolscripts/ubuntu22/install-xyce.sh +2 -0
- siliconcompiler/toolscripts/ubuntu22/install-yosys-moosic.sh +2 -0
- siliconcompiler/toolscripts/ubuntu22/install-yosys-parmys.sh +2 -0
- siliconcompiler/toolscripts/ubuntu22/install-yosys-slang.sh +3 -1
- siliconcompiler/toolscripts/ubuntu22/install-yosys.sh +2 -0
- siliconcompiler/toolscripts/ubuntu24/install-bambu.sh +2 -0
- siliconcompiler/toolscripts/ubuntu24/install-bluespec.sh +2 -0
- siliconcompiler/toolscripts/ubuntu24/install-chisel.sh +2 -0
- siliconcompiler/toolscripts/ubuntu24/install-ghdl.sh +2 -0
- siliconcompiler/toolscripts/ubuntu24/install-gtkwave.sh +2 -0
- siliconcompiler/toolscripts/ubuntu24/install-icarus.sh +2 -0
- siliconcompiler/toolscripts/ubuntu24/install-icepack.sh +2 -0
- siliconcompiler/toolscripts/ubuntu24/install-klayout.sh +2 -0
- siliconcompiler/toolscripts/ubuntu24/install-magic.sh +2 -0
- siliconcompiler/toolscripts/ubuntu24/install-netgen.sh +2 -0
- siliconcompiler/toolscripts/ubuntu24/install-nextpnr.sh +1 -3
- siliconcompiler/toolscripts/ubuntu24/install-openroad.sh +2 -0
- siliconcompiler/toolscripts/ubuntu24/install-opensta.sh +72 -0
- siliconcompiler/toolscripts/ubuntu24/install-slang.sh +3 -1
- siliconcompiler/toolscripts/ubuntu24/install-slurm.sh +2 -0
- siliconcompiler/toolscripts/ubuntu24/install-surelog.sh +3 -1
- siliconcompiler/toolscripts/ubuntu24/install-sv2v.sh +1 -1
- siliconcompiler/toolscripts/ubuntu24/install-verible.sh +2 -0
- siliconcompiler/toolscripts/ubuntu24/install-verilator.sh +2 -0
- siliconcompiler/toolscripts/ubuntu24/install-vpr.sh +2 -0
- siliconcompiler/toolscripts/ubuntu24/install-xdm.sh +2 -0
- siliconcompiler/toolscripts/ubuntu24/install-xyce.sh +2 -0
- siliconcompiler/toolscripts/ubuntu24/install-yosys-moosic.sh +2 -0
- siliconcompiler/toolscripts/ubuntu24/install-yosys-parmys.sh +2 -0
- siliconcompiler/toolscripts/ubuntu24/install-yosys-slang.sh +3 -1
- siliconcompiler/toolscripts/ubuntu24/install-yosys.sh +2 -0
- siliconcompiler/utils/logging.py +87 -33
- {siliconcompiler-0.32.2.dist-info → siliconcompiler-0.32.3.dist-info}/METADATA +5 -4
- {siliconcompiler-0.32.2.dist-info → siliconcompiler-0.32.3.dist-info}/RECORD +172 -166
- /siliconcompiler/report/dashboard/{components → web/components}/flowgraph.py +0 -0
- /siliconcompiler/report/dashboard/{state.py → web/state.py} +0 -0
- /siliconcompiler/report/dashboard/{utils → web/utils}/__init__.py +0 -0
- /siliconcompiler/report/dashboard/{utils → web/utils}/file_utils.py +0 -0
- {siliconcompiler-0.32.2.dist-info → siliconcompiler-0.32.3.dist-info}/WHEEL +0 -0
- {siliconcompiler-0.32.2.dist-info → siliconcompiler-0.32.3.dist-info}/entry_points.txt +0 -0
- {siliconcompiler-0.32.2.dist-info → siliconcompiler-0.32.3.dist-info}/licenses/LICENSE +0 -0
- {siliconcompiler-0.32.2.dist-info → siliconcompiler-0.32.3.dist-info}/top_level.txt +0 -0
|
@@ -0,0 +1,196 @@
|
|
|
1
|
+
import os
|
|
2
|
+
import time
|
|
3
|
+
import tempfile
|
|
4
|
+
import json
|
|
5
|
+
|
|
6
|
+
import multiprocessing
|
|
7
|
+
import subprocess
|
|
8
|
+
import atexit
|
|
9
|
+
import shutil
|
|
10
|
+
import fasteners
|
|
11
|
+
import signal
|
|
12
|
+
import socketserver
|
|
13
|
+
|
|
14
|
+
from siliconcompiler.report.dashboard import AbstractDashboard
|
|
15
|
+
from siliconcompiler.report.dashboard.web import utils
|
|
16
|
+
|
|
17
|
+
try:
|
|
18
|
+
from streamlit.web import bootstrap
|
|
19
|
+
from streamlit import config as _config
|
|
20
|
+
except ModuleNotFoundError:
|
|
21
|
+
bootstrap = None
|
|
22
|
+
_config = None
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
class WebDashboard(AbstractDashboard):
|
|
26
|
+
__port = 8501
|
|
27
|
+
|
|
28
|
+
@staticmethod
|
|
29
|
+
def __signal_handler(signal, frame):
|
|
30
|
+
# used to avoid issues during shutdown
|
|
31
|
+
pass
|
|
32
|
+
|
|
33
|
+
def __init__(self, chip, port=None, graph_chips=None):
|
|
34
|
+
super().__init__(chip)
|
|
35
|
+
|
|
36
|
+
if not bootstrap:
|
|
37
|
+
raise NotImplementedError('streamlit is not available')
|
|
38
|
+
|
|
39
|
+
if not port:
|
|
40
|
+
port = WebDashboard.get_next_port()
|
|
41
|
+
if not port:
|
|
42
|
+
port = WebDashboard.__port
|
|
43
|
+
|
|
44
|
+
self.__dashboard = None
|
|
45
|
+
self.__chip = chip
|
|
46
|
+
self.__directory = tempfile.mkdtemp(prefix='sc_dashboard_',
|
|
47
|
+
suffix=f'_{self.__chip.design}')
|
|
48
|
+
self.__manifest = os.path.join(self.__directory, 'manifest.json')
|
|
49
|
+
self.__manifest_lock = os.path.join(self.__directory, 'manifest.lock')
|
|
50
|
+
self.__port = port
|
|
51
|
+
dirname = os.path.dirname(__file__)
|
|
52
|
+
self.__streamlit_file = os.path.join(dirname, 'viewer.py')
|
|
53
|
+
|
|
54
|
+
self.__streamlit_args = [
|
|
55
|
+
("browser.gatherUsageStats", False),
|
|
56
|
+
("browser.serverPort", self.__port),
|
|
57
|
+
("logger.level", 'error'),
|
|
58
|
+
("runner.fastReruns", True),
|
|
59
|
+
("server.port", self.__port),
|
|
60
|
+
("client.toolbarMode", "viewer")
|
|
61
|
+
]
|
|
62
|
+
|
|
63
|
+
# pass in a json object called __graph_chips
|
|
64
|
+
# the key is the chip_name and value is the filepath
|
|
65
|
+
# if another argument is passed
|
|
66
|
+
|
|
67
|
+
# use of list is to preserve order
|
|
68
|
+
self.__graph_chips = []
|
|
69
|
+
graph_chips_config = []
|
|
70
|
+
if graph_chips:
|
|
71
|
+
for chip_object_and_name in graph_chips:
|
|
72
|
+
chip_file_path = \
|
|
73
|
+
os.path.join(self.__directory,
|
|
74
|
+
f"{chip_object_and_name['name']}.json")
|
|
75
|
+
self.__graph_chips.append({
|
|
76
|
+
'chip': chip_object_and_name['chip'],
|
|
77
|
+
'name': chip_file_path
|
|
78
|
+
})
|
|
79
|
+
graph_chips_config.append({
|
|
80
|
+
"path": chip_file_path,
|
|
81
|
+
"cwd": utils.get_chip_cwd(
|
|
82
|
+
chip_object_and_name['chip'],
|
|
83
|
+
chip_object_and_name['cfg_path'])
|
|
84
|
+
})
|
|
85
|
+
|
|
86
|
+
self.__config = {
|
|
87
|
+
"manifest": self.__manifest,
|
|
88
|
+
"lock": self.__manifest_lock,
|
|
89
|
+
"graph_chips": graph_chips_config
|
|
90
|
+
}
|
|
91
|
+
|
|
92
|
+
self.__sleep_time = 0.5
|
|
93
|
+
self.__signal_handler = None
|
|
94
|
+
|
|
95
|
+
self.__lock = fasteners.InterProcessLock(self.__manifest_lock)
|
|
96
|
+
|
|
97
|
+
atexit.register(self.__cleanup)
|
|
98
|
+
|
|
99
|
+
def open_dashboard(self):
|
|
100
|
+
with open(self.__get_config_file(), 'w') as f:
|
|
101
|
+
json.dump(self.__config, f, indent=4)
|
|
102
|
+
|
|
103
|
+
self.update_manifest()
|
|
104
|
+
|
|
105
|
+
self.update_graph_manifests()
|
|
106
|
+
|
|
107
|
+
self.__dashboard = multiprocessing.Process(
|
|
108
|
+
target=self._run_streamlit_bootstrap)
|
|
109
|
+
|
|
110
|
+
self.__signal_handler = signal.signal(signal.SIGINT, WebDashboard.__signal_handler)
|
|
111
|
+
|
|
112
|
+
self.__dashboard.start()
|
|
113
|
+
|
|
114
|
+
def update_manifest(self, payload=None):
|
|
115
|
+
if not self.__manifest:
|
|
116
|
+
return
|
|
117
|
+
|
|
118
|
+
new_file = f"{self.__manifest}.new.json"
|
|
119
|
+
self.__chip.write_manifest(new_file)
|
|
120
|
+
|
|
121
|
+
with self.__lock:
|
|
122
|
+
shutil.move(new_file, self.__manifest)
|
|
123
|
+
|
|
124
|
+
def update_graph_manifests(self):
|
|
125
|
+
for chip_object_and_name in self.__graph_chips:
|
|
126
|
+
chip = chip_object_and_name['chip']
|
|
127
|
+
file_path = chip_object_and_name['name']
|
|
128
|
+
chip.write_manifest(file_path)
|
|
129
|
+
|
|
130
|
+
def __get_config_file(self):
|
|
131
|
+
return os.path.join(self.__directory, 'config.json')
|
|
132
|
+
|
|
133
|
+
def is_running(self):
|
|
134
|
+
if self.__dashboard is None:
|
|
135
|
+
return False
|
|
136
|
+
|
|
137
|
+
if self.__dashboard.is_alive():
|
|
138
|
+
return True
|
|
139
|
+
|
|
140
|
+
self.__dashboard = None
|
|
141
|
+
self.__manifest = None
|
|
142
|
+
return False
|
|
143
|
+
|
|
144
|
+
def end_of_run(self):
|
|
145
|
+
pass
|
|
146
|
+
|
|
147
|
+
def stop(self):
|
|
148
|
+
if not self.is_running():
|
|
149
|
+
return
|
|
150
|
+
|
|
151
|
+
while self.__dashboard.is_alive():
|
|
152
|
+
self.__dashboard.terminate()
|
|
153
|
+
self._sleep()
|
|
154
|
+
|
|
155
|
+
if self.__signal_handler:
|
|
156
|
+
signal.signal(signal.SIGINT, self.__signal_handler)
|
|
157
|
+
|
|
158
|
+
self.__dashboard = None
|
|
159
|
+
self.__manifest = None
|
|
160
|
+
self.__signal_handler = None
|
|
161
|
+
|
|
162
|
+
def wait(self):
|
|
163
|
+
self.__dashboard.join()
|
|
164
|
+
|
|
165
|
+
def _sleep(self):
|
|
166
|
+
time.sleep(self.__sleep_time)
|
|
167
|
+
|
|
168
|
+
def _run_streamlit_bootstrap(self):
|
|
169
|
+
for config, val in self.__streamlit_args:
|
|
170
|
+
_config.set_option(config, val)
|
|
171
|
+
|
|
172
|
+
bootstrap.run(self.__streamlit_file,
|
|
173
|
+
False,
|
|
174
|
+
[self.__get_config_file()],
|
|
175
|
+
flag_options={})
|
|
176
|
+
|
|
177
|
+
def __run_streamlit_subproc(self):
|
|
178
|
+
cmd = ['streamlit', 'run',
|
|
179
|
+
self.__streamlit_file, self.__get_config_file()]
|
|
180
|
+
for config, val in self.__streamlit_args:
|
|
181
|
+
cmd.append(f'--{config}')
|
|
182
|
+
cmd.append(val)
|
|
183
|
+
|
|
184
|
+
subprocess.Popen(cmd)
|
|
185
|
+
|
|
186
|
+
def __cleanup(self):
|
|
187
|
+
self.stop()
|
|
188
|
+
|
|
189
|
+
if os.path.exists(self.__directory):
|
|
190
|
+
shutil.rmtree(self.__directory)
|
|
191
|
+
|
|
192
|
+
@staticmethod
|
|
193
|
+
def get_next_port():
|
|
194
|
+
with socketserver.TCPServer(("localhost", 0), None) as s:
|
|
195
|
+
return s.server_address[1]
|
|
196
|
+
return None
|
|
@@ -14,10 +14,10 @@ from siliconcompiler import __version__ as sc_version
|
|
|
14
14
|
from siliconcompiler import utils
|
|
15
15
|
from siliconcompiler.report import report
|
|
16
16
|
|
|
17
|
-
from siliconcompiler.report.dashboard import state
|
|
18
|
-
from siliconcompiler.report.dashboard import layouts
|
|
19
|
-
from siliconcompiler.report.dashboard.utils import file_utils
|
|
20
|
-
from siliconcompiler.report.dashboard.components import flowgraph
|
|
17
|
+
from siliconcompiler.report.dashboard.web import state
|
|
18
|
+
from siliconcompiler.report.dashboard.web import layouts
|
|
19
|
+
from siliconcompiler.report.dashboard.web.utils import file_utils
|
|
20
|
+
from siliconcompiler.report.dashboard.web.components import flowgraph
|
|
21
21
|
|
|
22
22
|
|
|
23
23
|
SC_ABOUT = [
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
from siliconcompiler.report.dashboard.layouts import vertical_flowgraph
|
|
2
|
-
from siliconcompiler.report.dashboard.layouts import vertical_flowgraph_sac_tabs
|
|
3
|
-
from siliconcompiler.report.dashboard.layouts import vertical_flowgraph_node_tab
|
|
1
|
+
from siliconcompiler.report.dashboard.web.layouts import vertical_flowgraph
|
|
2
|
+
from siliconcompiler.report.dashboard.web.layouts import vertical_flowgraph_sac_tabs
|
|
3
|
+
from siliconcompiler.report.dashboard.web.layouts import vertical_flowgraph_node_tab
|
|
4
4
|
|
|
5
5
|
__LAYOUTS = {
|
|
6
6
|
"vertical_flowgraph": vertical_flowgraph.layout,
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import os
|
|
2
2
|
import streamlit
|
|
3
3
|
|
|
4
|
-
from siliconcompiler.report.dashboard import components
|
|
5
|
-
from siliconcompiler.report.dashboard.components import graph
|
|
6
|
-
from siliconcompiler.report.dashboard import state
|
|
7
|
-
from siliconcompiler.report.dashboard import utils
|
|
8
|
-
from siliconcompiler.report.dashboard.layouts import _common
|
|
4
|
+
from siliconcompiler.report.dashboard.web import components
|
|
5
|
+
from siliconcompiler.report.dashboard.web.components import graph
|
|
6
|
+
from siliconcompiler.report.dashboard.web import state
|
|
7
|
+
from siliconcompiler.report.dashboard.web import utils
|
|
8
|
+
from siliconcompiler.report.dashboard.web.layouts import _common
|
|
9
9
|
|
|
10
10
|
|
|
11
11
|
def layout():
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import os
|
|
2
2
|
import streamlit
|
|
3
3
|
|
|
4
|
-
from siliconcompiler.report.dashboard import components
|
|
5
|
-
from siliconcompiler.report.dashboard.components import graph
|
|
6
|
-
from siliconcompiler.report.dashboard import state
|
|
7
|
-
from siliconcompiler.report.dashboard import utils
|
|
8
|
-
from siliconcompiler.report.dashboard.utils import file_utils
|
|
9
|
-
from siliconcompiler.report.dashboard.layouts import _common
|
|
4
|
+
from siliconcompiler.report.dashboard.web import components
|
|
5
|
+
from siliconcompiler.report.dashboard.web.components import graph
|
|
6
|
+
from siliconcompiler.report.dashboard.web import state
|
|
7
|
+
from siliconcompiler.report.dashboard.web import utils
|
|
8
|
+
from siliconcompiler.report.dashboard.web.utils import file_utils
|
|
9
|
+
from siliconcompiler.report.dashboard.web.layouts import _common
|
|
10
10
|
import streamlit_antd_components as sac
|
|
11
11
|
|
|
12
12
|
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import os
|
|
2
2
|
import streamlit
|
|
3
3
|
|
|
4
|
-
from siliconcompiler.report.dashboard import components
|
|
5
|
-
from siliconcompiler.report.dashboard.components import graph
|
|
6
|
-
from siliconcompiler.report.dashboard import state
|
|
7
|
-
from siliconcompiler.report.dashboard import utils
|
|
8
|
-
from siliconcompiler.report.dashboard.utils import file_utils
|
|
9
|
-
from siliconcompiler.report.dashboard.layouts import _common
|
|
4
|
+
from siliconcompiler.report.dashboard.web import components
|
|
5
|
+
from siliconcompiler.report.dashboard.web.components import graph
|
|
6
|
+
from siliconcompiler.report.dashboard.web import state
|
|
7
|
+
from siliconcompiler.report.dashboard.web import utils
|
|
8
|
+
from siliconcompiler.report.dashboard.web.utils import file_utils
|
|
9
|
+
from siliconcompiler.report.dashboard.web.layouts import _common
|
|
10
10
|
import streamlit_antd_components as sac
|
|
11
11
|
|
|
12
12
|
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import streamlit
|
|
2
2
|
|
|
3
|
-
from siliconcompiler.report.dashboard import components
|
|
4
|
-
from siliconcompiler.report.dashboard import layouts
|
|
5
|
-
from siliconcompiler.report.dashboard import state
|
|
6
|
-
from siliconcompiler.report.dashboard import utils
|
|
3
|
+
from siliconcompiler.report.dashboard.web import components
|
|
4
|
+
from siliconcompiler.report.dashboard.web import layouts
|
|
5
|
+
from siliconcompiler.report.dashboard.web import state
|
|
6
|
+
from siliconcompiler.report.dashboard.web import utils
|
|
7
7
|
|
|
8
8
|
import streamlit_autorefresh
|
|
9
9
|
|
|
@@ -31,6 +31,7 @@ from siliconcompiler.flowgraph import _get_flowgraph_nodes, _get_flowgraph_execu
|
|
|
31
31
|
_get_pruned_node_inputs, _get_flowgraph_entry_nodes, \
|
|
32
32
|
_unreachable_steps_to_execute, _nodes_to_execute, \
|
|
33
33
|
get_nodes_from, nodes_to_execute, _check_flowgraph
|
|
34
|
+
from siliconcompiler.utils.logging import SCBlankLoggerFormatter
|
|
34
35
|
from siliconcompiler.tools._common import input_file_node_name
|
|
35
36
|
import lambdapdk
|
|
36
37
|
from siliconcompiler.tools._common import get_tool_task, record_metric
|
|
@@ -87,6 +88,8 @@ def run(chip):
|
|
|
87
88
|
|
|
88
89
|
# Re-init logger to include run info after setting up flowgraph.
|
|
89
90
|
chip._init_logger(in_run=True)
|
|
91
|
+
if chip._dash and not chip._dash.is_running():
|
|
92
|
+
chip._dash.open_dashboard()
|
|
90
93
|
|
|
91
94
|
# Check if flowgraph is complete and valid
|
|
92
95
|
flow = chip.get('option', 'flow')
|
|
@@ -130,10 +133,6 @@ def _finalize_run(chip):
|
|
|
130
133
|
filepath = os.path.join(chip.getworkdir(), f"{chip.design}.pkg.json")
|
|
131
134
|
chip.write_manifest(filepath)
|
|
132
135
|
|
|
133
|
-
# Update dashboard
|
|
134
|
-
if chip._dash:
|
|
135
|
-
chip._dash.update_manifest()
|
|
136
|
-
|
|
137
136
|
send_messages.send(chip, 'summary', None, None)
|
|
138
137
|
|
|
139
138
|
|
|
@@ -281,7 +280,7 @@ def _local_process(chip, flow):
|
|
|
281
280
|
|
|
282
281
|
# Handle logs across threads
|
|
283
282
|
log_listener = QueueListener(log_queue, chip.logger._console)
|
|
284
|
-
chip.logger._console.setFormatter(
|
|
283
|
+
chip.logger._console.setFormatter(SCBlankLoggerFormatter())
|
|
285
284
|
log_listener.start()
|
|
286
285
|
|
|
287
286
|
# Update dashboard before run begins
|
|
@@ -1629,6 +1628,8 @@ def _launch_nodes(chip, nodes_to_run, processes, local_processes):
|
|
|
1629
1628
|
if _get_callback('pre_run'):
|
|
1630
1629
|
_get_callback('pre_run')(chip)
|
|
1631
1630
|
|
|
1631
|
+
start_times = {None: time.time()}
|
|
1632
|
+
|
|
1632
1633
|
while len(nodes_to_run) > 0 or len(running_nodes) > 0:
|
|
1633
1634
|
changed = _process_completed_nodes(chip, processes, running_nodes)
|
|
1634
1635
|
|
|
@@ -1653,6 +1654,7 @@ def _launch_nodes(chip, nodes_to_run, processes, local_processes):
|
|
|
1653
1654
|
_get_callback('pre_node')(chip, *node)
|
|
1654
1655
|
|
|
1655
1656
|
chip.set('record', 'status', NodeStatus.RUNNING, step=node[0], index=node[1])
|
|
1657
|
+
start_times[node] = time.time()
|
|
1656
1658
|
changed = True
|
|
1657
1659
|
|
|
1658
1660
|
processes[node]["proc"].start()
|
|
@@ -1669,7 +1671,7 @@ def _launch_nodes(chip, nodes_to_run, processes, local_processes):
|
|
|
1669
1671
|
|
|
1670
1672
|
if chip._dash and changed:
|
|
1671
1673
|
# Update dashboard if the manifest changed
|
|
1672
|
-
chip._dash.update_manifest()
|
|
1674
|
+
chip._dash.update_manifest(payload={"starttimes": start_times})
|
|
1673
1675
|
|
|
1674
1676
|
if len(running_nodes) == 1:
|
|
1675
1677
|
# if there is only one node running, just join the thread
|
|
@@ -60,10 +60,10 @@ while [[ $# -gt 0 ]]; do
|
|
|
60
60
|
esac
|
|
61
61
|
done
|
|
62
62
|
|
|
63
|
-
if [ $SKIPEXPORT == 0 ]; then
|
|
63
|
+
{% if exports|length > 0 %}if [ $SKIPEXPORT == 0 ]; then
|
|
64
64
|
# Environmental variables{% for key, value in exports.items() %}
|
|
65
65
|
export {{ key }}="{{ value }}"{% endfor %}
|
|
66
|
-
fi
|
|
66
|
+
fi{% endif %}
|
|
67
67
|
|
|
68
68
|
# Switch to the working directory
|
|
69
69
|
cd "$CD_WORK"
|
|
@@ -500,6 +500,10 @@ def define_ppl_params(chip):
|
|
|
500
500
|
['pdk', pdkname, 'var', 'openroad', 'pin_layer_vertical', stackup]):
|
|
501
501
|
chip.add('tool', tool, 'task', task, 'require', ",".join(key),
|
|
502
502
|
step=step, index=index)
|
|
503
|
+
if chip.get('tool', tool, 'task', task, 'file', 'ppl_constraints', step=step, index=index):
|
|
504
|
+
chip.add('tool', tool, 'task', task, 'require',
|
|
505
|
+
",".join(['tool', tool, 'task', task, 'file', 'ppl_constraints']),
|
|
506
|
+
step=step, index=index)
|
|
503
507
|
|
|
504
508
|
|
|
505
509
|
def define_pdn_params(chip):
|
|
@@ -1,5 +1,3 @@
|
|
|
1
|
-
from siliconcompiler import NodeStatus
|
|
2
|
-
|
|
3
1
|
from siliconcompiler.tools._common import get_tool_task, has_pre_post_script
|
|
4
2
|
from siliconcompiler.tools._common.asic import get_mainlib
|
|
5
3
|
|
|
@@ -55,24 +53,26 @@ def setup(chip):
|
|
|
55
53
|
'clock_trees'
|
|
56
54
|
])
|
|
57
55
|
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
step = chip.get('arg', 'step')
|
|
61
|
-
index = chip.get('arg', 'index')
|
|
62
|
-
tool, task = get_tool_task(chip, step, index)
|
|
63
|
-
if not has_pre_post_script(chip) and \
|
|
64
|
-
chip.get('tool', tool, 'task', task, 'var', 'fin_add_fill',
|
|
65
|
-
step=step, index=index) == ["true"]:
|
|
56
|
+
if chip.get('tool', tool, 'task', task, 'var', 'fin_add_fill',
|
|
57
|
+
step=step, index=index) == ["true"]:
|
|
66
58
|
pdk = chip.get('option', 'pdk')
|
|
67
59
|
stackup = chip.get('option', 'stackup')
|
|
68
60
|
mainlib = get_mainlib(chip)
|
|
69
61
|
libtype = chip.get('library', mainlib, 'asic', 'libarch', step=step, index=index)
|
|
62
|
+
if chip.get('pdk', pdk, 'aprtech', tool, stackup, libtype, 'fill'):
|
|
63
|
+
chip.add('tool', tool, 'task', task, 'require',
|
|
64
|
+
",".join(['pdk', pdk, 'aprtech', tool, stackup, libtype, 'fill']),
|
|
65
|
+
step=step, index=index)
|
|
66
|
+
else:
|
|
67
|
+
if not has_pre_post_script(chip):
|
|
68
|
+
# nothing to do so we can skip
|
|
69
|
+
return "no fill script is available"
|
|
70
70
|
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
chip.logger.warning(f'{step}{index} will be skipped since there is nothing to do.')
|
|
74
|
-
return
|
|
71
|
+
chip.set('tool', tool, 'task', task, 'var', 'fin_add_fill', False,
|
|
72
|
+
step=step, index=index)
|
|
75
73
|
|
|
74
|
+
|
|
75
|
+
def pre_process(chip):
|
|
76
76
|
define_ord_files(chip)
|
|
77
77
|
build_pex_corners(chip)
|
|
78
78
|
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
# Reading SC Schema
|
|
3
3
|
###############################
|
|
4
4
|
|
|
5
|
-
source ./sc_manifest.tcl
|
|
5
|
+
source ./sc_manifest.tcl
|
|
6
6
|
|
|
7
7
|
###############################
|
|
8
8
|
# Task Preamble
|
|
@@ -18,7 +18,7 @@ source -echo "$sc_refdir/apr/preamble.tcl"
|
|
|
18
18
|
set sc_libtype [sc_cfg_get library $sc_mainlib asic libarch]
|
|
19
19
|
|
|
20
20
|
if {
|
|
21
|
-
|
|
21
|
+
[lindex [sc_cfg_tool_task_get var fin_add_fill] 0] == "true" &&
|
|
22
22
|
[sc_cfg_exists pdk $sc_pdk aprtech openroad $sc_stackup $sc_libtype fill]
|
|
23
23
|
} {
|
|
24
24
|
set sc_fillrules \
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
# Reading SC Schema
|
|
3
3
|
###############################
|
|
4
4
|
|
|
5
|
-
source ./sc_manifest.tcl
|
|
5
|
+
source ./sc_manifest.tcl
|
|
6
6
|
|
|
7
7
|
###############################
|
|
8
8
|
# Task Preamble
|
|
@@ -16,7 +16,7 @@ source -echo "$sc_refdir/apr/preamble.tcl"
|
|
|
16
16
|
###############################
|
|
17
17
|
|
|
18
18
|
set parasitics_stage -placement
|
|
19
|
-
if {
|
|
19
|
+
if { [sc_check_version 20073] && [grt::have_routes] } {
|
|
20
20
|
set parasitics_stage -global_routing
|
|
21
21
|
}
|
|
22
22
|
|
|
@@ -116,7 +116,7 @@ proc sc_detailed_placement { args } {
|
|
|
116
116
|
lappend dpl_args "-disallow_one_site_gaps"
|
|
117
117
|
}
|
|
118
118
|
|
|
119
|
-
set incremental_route
|
|
119
|
+
set incremental_route [expr { [sc_check_version 20073] && [grt::have_routes] }]
|
|
120
120
|
|
|
121
121
|
if { $incremental_route } {
|
|
122
122
|
global_route -start_incremental
|