siliconcompiler 0.34.2__py3-none-any.whl → 0.34.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/__init__.py +12 -5
- siliconcompiler/__main__.py +1 -7
- siliconcompiler/_metadata.py +1 -1
- siliconcompiler/apps/_common.py +104 -23
- siliconcompiler/apps/sc.py +4 -8
- siliconcompiler/apps/sc_dashboard.py +6 -4
- siliconcompiler/apps/sc_install.py +10 -6
- siliconcompiler/apps/sc_issue.py +7 -5
- siliconcompiler/apps/sc_remote.py +1 -1
- siliconcompiler/apps/sc_server.py +9 -14
- siliconcompiler/apps/sc_show.py +6 -5
- siliconcompiler/apps/smake.py +130 -94
- siliconcompiler/apps/utils/replay.py +4 -7
- siliconcompiler/apps/utils/summarize.py +3 -5
- siliconcompiler/asic.py +420 -0
- siliconcompiler/checklist.py +25 -2
- siliconcompiler/cmdlineschema.py +534 -0
- siliconcompiler/constraints/asic_component.py +2 -2
- siliconcompiler/constraints/asic_pins.py +2 -2
- siliconcompiler/constraints/asic_timing.py +3 -3
- siliconcompiler/core.py +7 -32
- siliconcompiler/data/templates/tcl/manifest.tcl.j2 +8 -0
- siliconcompiler/dependencyschema.py +89 -31
- siliconcompiler/design.py +176 -207
- siliconcompiler/filesetschema.py +250 -0
- siliconcompiler/flowgraph.py +274 -95
- siliconcompiler/fpga.py +124 -1
- siliconcompiler/library.py +218 -20
- siliconcompiler/metric.py +233 -20
- siliconcompiler/package/__init__.py +271 -50
- siliconcompiler/package/git.py +92 -16
- siliconcompiler/package/github.py +108 -12
- siliconcompiler/package/https.py +79 -16
- siliconcompiler/packageschema.py +88 -7
- siliconcompiler/pathschema.py +31 -2
- siliconcompiler/pdk.py +566 -1
- siliconcompiler/project.py +1095 -94
- siliconcompiler/record.py +38 -1
- siliconcompiler/remote/__init__.py +5 -2
- siliconcompiler/remote/client.py +11 -6
- siliconcompiler/remote/schema.py +5 -23
- siliconcompiler/remote/server.py +41 -54
- siliconcompiler/report/__init__.py +3 -3
- siliconcompiler/report/dashboard/__init__.py +48 -14
- siliconcompiler/report/dashboard/cli/__init__.py +99 -21
- siliconcompiler/report/dashboard/cli/board.py +364 -179
- siliconcompiler/report/dashboard/web/__init__.py +90 -12
- siliconcompiler/report/dashboard/web/components/__init__.py +219 -240
- siliconcompiler/report/dashboard/web/components/flowgraph.py +49 -26
- siliconcompiler/report/dashboard/web/components/graph.py +139 -100
- siliconcompiler/report/dashboard/web/layouts/__init__.py +29 -1
- siliconcompiler/report/dashboard/web/layouts/_common.py +38 -2
- siliconcompiler/report/dashboard/web/layouts/vertical_flowgraph.py +39 -26
- siliconcompiler/report/dashboard/web/layouts/vertical_flowgraph_node_tab.py +50 -50
- siliconcompiler/report/dashboard/web/layouts/vertical_flowgraph_sac_tabs.py +49 -46
- siliconcompiler/report/dashboard/web/state.py +141 -14
- siliconcompiler/report/dashboard/web/utils/__init__.py +79 -16
- siliconcompiler/report/dashboard/web/utils/file_utils.py +74 -11
- siliconcompiler/report/dashboard/web/viewer.py +25 -1
- siliconcompiler/report/report.py +5 -2
- siliconcompiler/report/summary_image.py +29 -11
- siliconcompiler/scheduler/__init__.py +9 -1
- siliconcompiler/scheduler/docker.py +79 -1
- siliconcompiler/scheduler/run_node.py +35 -19
- siliconcompiler/scheduler/scheduler.py +208 -24
- siliconcompiler/scheduler/schedulernode.py +372 -46
- siliconcompiler/scheduler/send_messages.py +77 -29
- siliconcompiler/scheduler/slurm.py +76 -12
- siliconcompiler/scheduler/taskscheduler.py +140 -20
- siliconcompiler/schema/__init__.py +0 -2
- siliconcompiler/schema/baseschema.py +194 -38
- siliconcompiler/schema/journal.py +7 -4
- siliconcompiler/schema/namedschema.py +16 -10
- siliconcompiler/schema/parameter.py +55 -9
- siliconcompiler/schema/parametervalue.py +60 -0
- siliconcompiler/schema/safeschema.py +25 -2
- siliconcompiler/schema/schema_cfg.py +5 -5
- siliconcompiler/schema/utils.py +2 -2
- siliconcompiler/schema_obj.py +20 -3
- siliconcompiler/tool.py +979 -302
- siliconcompiler/tools/bambu/__init__.py +41 -0
- siliconcompiler/tools/builtin/concatenate.py +2 -2
- siliconcompiler/tools/builtin/minimum.py +2 -1
- siliconcompiler/tools/builtin/mux.py +2 -1
- siliconcompiler/tools/builtin/nop.py +2 -1
- siliconcompiler/tools/builtin/verify.py +2 -1
- siliconcompiler/tools/klayout/__init__.py +95 -0
- siliconcompiler/tools/openroad/__init__.py +289 -0
- siliconcompiler/tools/openroad/scripts/apr/preamble.tcl +3 -0
- siliconcompiler/tools/openroad/scripts/apr/sc_detailed_route.tcl +7 -2
- siliconcompiler/tools/openroad/scripts/apr/sc_global_route.tcl +8 -4
- siliconcompiler/tools/openroad/scripts/apr/sc_init_floorplan.tcl +9 -5
- siliconcompiler/tools/openroad/scripts/common/write_images.tcl +5 -1
- siliconcompiler/tools/slang/__init__.py +1 -1
- siliconcompiler/tools/slang/elaborate.py +2 -1
- siliconcompiler/tools/vivado/scripts/sc_run.tcl +1 -1
- siliconcompiler/tools/vivado/scripts/sc_syn_fpga.tcl +8 -1
- siliconcompiler/tools/vivado/syn_fpga.py +6 -0
- siliconcompiler/tools/vivado/vivado.py +35 -2
- siliconcompiler/tools/vpr/__init__.py +150 -0
- siliconcompiler/tools/yosys/__init__.py +369 -1
- siliconcompiler/tools/yosys/scripts/procs.tcl +0 -1
- siliconcompiler/toolscripts/_tools.json +5 -10
- siliconcompiler/utils/__init__.py +66 -0
- siliconcompiler/utils/flowgraph.py +2 -2
- siliconcompiler/utils/issue.py +2 -1
- siliconcompiler/utils/logging.py +14 -0
- siliconcompiler/utils/multiprocessing.py +256 -0
- siliconcompiler/utils/showtools.py +10 -0
- {siliconcompiler-0.34.2.dist-info → siliconcompiler-0.34.3.dist-info}/METADATA +5 -5
- {siliconcompiler-0.34.2.dist-info → siliconcompiler-0.34.3.dist-info}/RECORD +115 -118
- {siliconcompiler-0.34.2.dist-info → siliconcompiler-0.34.3.dist-info}/entry_points.txt +3 -0
- siliconcompiler/schema/cmdlineschema.py +0 -250
- siliconcompiler/toolscripts/rhel8/install-slang.sh +0 -40
- siliconcompiler/toolscripts/rhel9/install-slang.sh +0 -40
- siliconcompiler/toolscripts/ubuntu20/install-slang.sh +0 -47
- siliconcompiler/toolscripts/ubuntu22/install-slang.sh +0 -37
- siliconcompiler/toolscripts/ubuntu24/install-slang.sh +0 -37
- {siliconcompiler-0.34.2.dist-info → siliconcompiler-0.34.3.dist-info}/WHEEL +0 -0
- {siliconcompiler-0.34.2.dist-info → siliconcompiler-0.34.3.dist-info}/licenses/LICENSE +0 -0
- {siliconcompiler-0.34.2.dist-info → siliconcompiler-0.34.3.dist-info}/top_level.txt +0 -0
siliconcompiler/__init__.py
CHANGED
|
@@ -5,18 +5,20 @@ from siliconcompiler.schema_obj import SchemaTmp as Schema
|
|
|
5
5
|
|
|
6
6
|
from siliconcompiler.packageschema import PackageSchema
|
|
7
7
|
|
|
8
|
+
from siliconcompiler.library import LibrarySchema, ToolLibrarySchema, StdCellLibrarySchema
|
|
9
|
+
from siliconcompiler.fpga import FPGASchema
|
|
10
|
+
|
|
8
11
|
from siliconcompiler.design import DesignSchema
|
|
9
12
|
from siliconcompiler.record import RecordSchema
|
|
10
13
|
from siliconcompiler.metric import MetricSchema
|
|
11
14
|
from siliconcompiler.pdk import PDKSchema
|
|
12
15
|
from siliconcompiler.flowgraph import FlowgraphSchema
|
|
13
|
-
from siliconcompiler.tool import ToolSchema, TaskSchema
|
|
16
|
+
from siliconcompiler.tool import ToolSchema, TaskSchema, ASICTaskSchema
|
|
17
|
+
from siliconcompiler.tool import ShowTaskSchema, ScreenshotTaskSchema
|
|
14
18
|
from siliconcompiler.checklist import ChecklistSchema
|
|
15
|
-
from siliconcompiler.asic import ASICSchema
|
|
16
|
-
from siliconcompiler.fpga import FPGASchema
|
|
17
19
|
|
|
18
20
|
from siliconcompiler.project import Project
|
|
19
|
-
from siliconcompiler.
|
|
21
|
+
from siliconcompiler.asic import ASICSchema, ASICProject
|
|
20
22
|
|
|
21
23
|
from siliconcompiler.core import Chip
|
|
22
24
|
|
|
@@ -51,5 +53,10 @@ __all__ = [
|
|
|
51
53
|
"PackageSchema",
|
|
52
54
|
|
|
53
55
|
"Project",
|
|
54
|
-
"
|
|
56
|
+
"ASICProject",
|
|
57
|
+
"StdCellLibrarySchema",
|
|
58
|
+
"ToolLibrarySchema",
|
|
59
|
+
"ASICTaskSchema",
|
|
60
|
+
"ShowTaskSchema",
|
|
61
|
+
"ScreenshotTaskSchema"
|
|
55
62
|
]
|
siliconcompiler/__main__.py
CHANGED
siliconcompiler/_metadata.py
CHANGED
siliconcompiler/apps/_common.py
CHANGED
|
@@ -1,16 +1,30 @@
|
|
|
1
|
+
"""
|
|
2
|
+
A collection of utility functions for discovering and selecting the correct
|
|
3
|
+
SiliconCompiler manifest file (`.pkg.json`) within a project directory.
|
|
4
|
+
|
|
5
|
+
This module provides logic to automatically find manifests based on a standard
|
|
6
|
+
build directory structure, and then select the most appropriate one based on
|
|
7
|
+
the chip's configuration (design, jobname, step, index) or other clues.
|
|
8
|
+
"""
|
|
1
9
|
import os
|
|
10
|
+
import os.path
|
|
2
11
|
|
|
3
12
|
|
|
4
|
-
#
|
|
5
|
-
# design names
|
|
13
|
+
# A placeholder to detect if the design name has not been set by the user.
|
|
14
|
+
# Legal design names are unlikely to contain spaces.
|
|
6
15
|
UNSET_DESIGN = ' unset '
|
|
7
16
|
|
|
8
17
|
|
|
9
18
|
def manifest_switches():
|
|
10
|
-
|
|
11
|
-
Returns a list of
|
|
12
|
-
|
|
13
|
-
|
|
19
|
+
"""
|
|
20
|
+
Returns a list of command-line switches used to identify a manifest.
|
|
21
|
+
|
|
22
|
+
These switches correspond to chip parameters that can specify a unique
|
|
23
|
+
run or node within a project.
|
|
24
|
+
|
|
25
|
+
Returns:
|
|
26
|
+
list[str]: A list of command-line switch names.
|
|
27
|
+
"""
|
|
14
28
|
return ['-design',
|
|
15
29
|
'-cfg',
|
|
16
30
|
'-arg_step',
|
|
@@ -19,24 +33,47 @@ def manifest_switches():
|
|
|
19
33
|
|
|
20
34
|
|
|
21
35
|
def _get_manifests(cwd):
|
|
36
|
+
"""
|
|
37
|
+
Scans a directory tree to find all SiliconCompiler manifest files.
|
|
38
|
+
|
|
39
|
+
This function walks through a standard SC build structure
|
|
40
|
+
(`<builddir>/<design>/<jobname>/<step>/<index>`) to locate all
|
|
41
|
+
`.pkg.json` files. It organizes them into a nested dictionary for
|
|
42
|
+
easy lookup.
|
|
43
|
+
|
|
44
|
+
Args:
|
|
45
|
+
cwd (str): The current working directory to start the scan from.
|
|
46
|
+
|
|
47
|
+
Returns:
|
|
48
|
+
dict: A nested dictionary mapping:
|
|
49
|
+
`{design: {jobname: {(step, index): /path/to/manifest.pkg.json}}}`.
|
|
50
|
+
Top-level manifests are stored with a (None, None) key for the node.
|
|
51
|
+
"""
|
|
22
52
|
manifests = {}
|
|
23
53
|
|
|
24
|
-
def get_dirs(
|
|
54
|
+
def get_dirs(path):
|
|
55
|
+
"""Helper to get all subdirectories of a given path."""
|
|
25
56
|
dirs = []
|
|
26
|
-
|
|
27
|
-
|
|
57
|
+
if not os.path.isdir(path):
|
|
58
|
+
return dirs
|
|
59
|
+
for dirname in os.listdir(path):
|
|
60
|
+
fullpath = os.path.join(path, dirname)
|
|
28
61
|
if os.path.isdir(fullpath):
|
|
29
62
|
dirs.append((dirname, fullpath))
|
|
30
63
|
return dirs
|
|
31
64
|
|
|
65
|
+
# Expected structure: <cwd>/<builddir>/<design>/<jobname>/<step>/<index>
|
|
32
66
|
for _, buildpath in get_dirs(cwd):
|
|
33
67
|
for design, designdir in get_dirs(buildpath):
|
|
34
68
|
for jobname, jobdir in get_dirs(designdir):
|
|
69
|
+
# Check for top-level manifest
|
|
35
70
|
manifest = os.path.join(jobdir, f'{design}.pkg.json')
|
|
36
71
|
if os.path.isfile(manifest):
|
|
37
72
|
manifests[(design, jobname, None, None)] = manifest
|
|
73
|
+
# Check for node-level manifests
|
|
38
74
|
for step, stepdir in get_dirs(jobdir):
|
|
39
75
|
for index, indexdir in get_dirs(stepdir):
|
|
76
|
+
# Check outputs first, then inputs
|
|
40
77
|
manifest = os.path.join(indexdir, 'outputs', f'{design}.pkg.json')
|
|
41
78
|
if os.path.isfile(manifest):
|
|
42
79
|
manifests[(design, jobname, step, index)] = manifest
|
|
@@ -45,6 +82,7 @@ def _get_manifests(cwd):
|
|
|
45
82
|
if os.path.isfile(manifest):
|
|
46
83
|
manifests[(design, jobname, step, index)] = manifest
|
|
47
84
|
|
|
85
|
+
# Reorganize the flat list into a nested dictionary for easier access.
|
|
48
86
|
organized_manifest = {}
|
|
49
87
|
for (design, job, step, index), manifest in manifests.items():
|
|
50
88
|
jobs = organized_manifest.setdefault(design, {})
|
|
@@ -54,6 +92,22 @@ def _get_manifests(cwd):
|
|
|
54
92
|
|
|
55
93
|
|
|
56
94
|
def pick_manifest_from_file(chip, src_file, all_manifests):
|
|
95
|
+
"""
|
|
96
|
+
Tries to find a manifest located in the same directory as a given source file.
|
|
97
|
+
|
|
98
|
+
This is useful for applications like a GUI where a user might open a single
|
|
99
|
+
file from a larger project, and we need to infer the associated manifest.
|
|
100
|
+
|
|
101
|
+
Args:
|
|
102
|
+
chip (Chip): The chip object, used for logging.
|
|
103
|
+
src_file (str): The path to the source file provided by the user.
|
|
104
|
+
all_manifests (dict): The dictionary of all discovered manifests from
|
|
105
|
+
`_get_manifests`.
|
|
106
|
+
|
|
107
|
+
Returns:
|
|
108
|
+
str or None: The path to the found manifest, or None if no manifest
|
|
109
|
+
is found in the same directory.
|
|
110
|
+
"""
|
|
57
111
|
if src_file is None:
|
|
58
112
|
return None
|
|
59
113
|
|
|
@@ -72,54 +126,81 @@ def pick_manifest_from_file(chip, src_file, all_manifests):
|
|
|
72
126
|
|
|
73
127
|
|
|
74
128
|
def pick_manifest(chip, src_file=None):
|
|
129
|
+
"""
|
|
130
|
+
Selects the most appropriate manifest based on the chip's configuration.
|
|
131
|
+
|
|
132
|
+
This function implements the selection logic in the following order of priority:
|
|
133
|
+
1. Find a manifest in the same directory as `src_file`, if provided.
|
|
134
|
+
2. If the design is not set, try to infer it (only works if there is exactly one design).
|
|
135
|
+
3. If the jobname is not set, try to infer it (only works if there is one job for the design).
|
|
136
|
+
4. If step/index are specified, return the manifest for that specific node.
|
|
137
|
+
5. If no node is specified, return the top-level manifest for the job.
|
|
138
|
+
6. As a last resort, return the most recently modified manifest for the job.
|
|
139
|
+
|
|
140
|
+
Args:
|
|
141
|
+
chip (Chip): The chip object containing the configuration.
|
|
142
|
+
src_file (str, optional): A path to a source file to help locate the
|
|
143
|
+
manifest. Defaults to None.
|
|
144
|
+
|
|
145
|
+
Returns:
|
|
146
|
+
str or None: The absolute path to the selected manifest, or None if a
|
|
147
|
+
suitable manifest cannot be determined.
|
|
148
|
+
"""
|
|
75
149
|
all_manifests = _get_manifests(os.getcwd())
|
|
76
150
|
|
|
151
|
+
# 1. Try to find based on source file location.
|
|
77
152
|
manifest = pick_manifest_from_file(chip, src_file, all_manifests)
|
|
78
153
|
if manifest:
|
|
79
154
|
return manifest
|
|
80
155
|
|
|
156
|
+
# 2. Infer design if unset and only one option exists.
|
|
81
157
|
if chip.design == UNSET_DESIGN:
|
|
82
158
|
if len(all_manifests) == 1:
|
|
83
159
|
chip.set('design', list(all_manifests.keys())[0])
|
|
84
160
|
else:
|
|
85
|
-
chip.logger.error('Design name is not set')
|
|
161
|
+
chip.logger.error('Design name is not set and could not be inferred.')
|
|
86
162
|
return None
|
|
87
163
|
|
|
88
164
|
if chip.design not in all_manifests:
|
|
89
|
-
chip.logger.error(f'Could not find
|
|
90
|
-
return None
|
|
91
|
-
|
|
92
|
-
if chip.get('option', 'jobname') not in all_manifests[chip.design] and \
|
|
93
|
-
len(all_manifests[chip.design]) != 1:
|
|
94
|
-
chip.logger.error(f'Could not determine jobname for {chip.design}')
|
|
165
|
+
chip.logger.error(f'Could not find any manifests for design "{chip.design}".')
|
|
95
166
|
return None
|
|
96
167
|
|
|
168
|
+
# 3. Infer jobname if unset and only one option exists.
|
|
97
169
|
jobname = chip.get('option', 'jobname')
|
|
98
|
-
if
|
|
99
|
-
|
|
170
|
+
if jobname not in all_manifests[chip.design]:
|
|
171
|
+
if len(all_manifests[chip.design]) == 1:
|
|
172
|
+
jobname = list(all_manifests[chip.design].keys())[0]
|
|
173
|
+
else:
|
|
174
|
+
chip.logger.error(f'Could not determine jobname for design "{chip.design}".')
|
|
175
|
+
return None
|
|
100
176
|
|
|
177
|
+
# 4. Find specific node manifest if step/index are provided.
|
|
101
178
|
step, index = chip.get('arg', 'step'), chip.get('arg', 'index')
|
|
179
|
+
# Auto-complete index if only step is provided
|
|
102
180
|
if step and not index:
|
|
103
181
|
all_nodes = list(all_manifests[chip.design][jobname].keys())
|
|
104
182
|
try:
|
|
105
|
-
all_nodes.remove((None, None))
|
|
183
|
+
all_nodes.remove((None, None)) # Exclude top-level
|
|
106
184
|
except ValueError:
|
|
107
185
|
pass
|
|
108
186
|
for found_step, found_index in sorted(all_nodes):
|
|
109
187
|
if found_step == step:
|
|
110
188
|
index = found_index
|
|
189
|
+
break # Take the first matching index
|
|
111
190
|
if index is None:
|
|
112
|
-
index = '0'
|
|
191
|
+
index = '0' # Default to '0' if no match found
|
|
192
|
+
|
|
113
193
|
if step and index:
|
|
114
194
|
if (step, index) in all_manifests[chip.design][jobname]:
|
|
115
195
|
return all_manifests[chip.design][jobname][(step, index)]
|
|
116
196
|
else:
|
|
117
|
-
chip.logger.error(f'{step}/{index} is not a valid node.')
|
|
197
|
+
chip.logger.error(f'Node "{step}/{index}" is not a valid node.')
|
|
118
198
|
return None
|
|
119
199
|
|
|
200
|
+
# 5. Return top-level job manifest if it exists.
|
|
120
201
|
if (None, None) in all_manifests[chip.design][jobname]:
|
|
121
|
-
return all_manifests[chip.design][jobname][None, None]
|
|
202
|
+
return all_manifests[chip.design][jobname][(None, None)]
|
|
122
203
|
|
|
123
|
-
#
|
|
204
|
+
# 6. Fallback: return the most recently modified manifest in the job.
|
|
124
205
|
return list(sorted(all_manifests[chip.design][jobname].values(),
|
|
125
206
|
key=lambda file: os.stat(file).st_ctime))[-1]
|
siliconcompiler/apps/sc.py
CHANGED
|
@@ -1,13 +1,12 @@
|
|
|
1
1
|
# Copyright 2020 Silicon Compiler Authors. All Rights Reserved.
|
|
2
|
-
|
|
3
|
-
# Standard Modules
|
|
4
2
|
import os
|
|
5
3
|
import sys
|
|
6
4
|
|
|
7
|
-
import
|
|
5
|
+
from siliconcompiler import Chip
|
|
6
|
+
from siliconcompiler import SiliconCompilerError
|
|
8
7
|
from siliconcompiler.utils import get_default_iomap
|
|
9
8
|
from siliconcompiler.targets import skywater130_demo
|
|
10
|
-
from siliconcompiler import
|
|
9
|
+
from siliconcompiler.apps._common import UNSET_DESIGN
|
|
11
10
|
|
|
12
11
|
|
|
13
12
|
def _infer_designname(chip):
|
|
@@ -61,12 +60,9 @@ def main():
|
|
|
61
60
|
Sources: https://github.com/siliconcompiler/siliconcompiler
|
|
62
61
|
------------------------------------------------------------
|
|
63
62
|
"""
|
|
64
|
-
# TODO: this is a hack to get around design name requirement: since legal
|
|
65
|
-
# design names probably can't contain spaces, we can detect if it is unset.
|
|
66
|
-
UNSET_DESIGN = ' unset '
|
|
67
63
|
|
|
68
64
|
# Create a base chip class.
|
|
69
|
-
chip =
|
|
65
|
+
chip = Chip(UNSET_DESIGN)
|
|
70
66
|
|
|
71
67
|
# Read command-line inputs and generate Chip objects to run the flow on.
|
|
72
68
|
try:
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
# Copyright 2023 Silicon Compiler Authors. All Rights Reserved.
|
|
2
2
|
import sys
|
|
3
|
-
|
|
4
|
-
import os
|
|
3
|
+
|
|
4
|
+
import os.path
|
|
5
|
+
|
|
6
|
+
from siliconcompiler import Chip
|
|
5
7
|
from siliconcompiler.apps._common import pick_manifest, manifest_switches, UNSET_DESIGN
|
|
6
8
|
|
|
7
9
|
|
|
@@ -31,7 +33,7 @@ To include another chip object to compare to:
|
|
|
31
33
|
"""
|
|
32
34
|
|
|
33
35
|
# Create a base chip class.
|
|
34
|
-
chip =
|
|
36
|
+
chip = Chip(UNSET_DESIGN)
|
|
35
37
|
|
|
36
38
|
dashboard_arguments = {
|
|
37
39
|
"-port": {'type': int,
|
|
@@ -93,7 +95,7 @@ To include another chip object to compare to:
|
|
|
93
95
|
f' {args} in "-graph_cfg {name_and_file_path}"'))
|
|
94
96
|
if not os.path.isfile(file_path):
|
|
95
97
|
raise ValueError(f'not a valid file path: {file_path}')
|
|
96
|
-
graph_chip =
|
|
98
|
+
graph_chip = Chip(design='')
|
|
97
99
|
graph_chip.read_manifest(file_path)
|
|
98
100
|
graph_chips.append({
|
|
99
101
|
'chip': graph_chip,
|
|
@@ -1,15 +1,18 @@
|
|
|
1
1
|
# Copyright 2024 Silicon Compiler Authors. All Rights Reserved.
|
|
2
|
-
|
|
3
2
|
import argparse
|
|
4
3
|
import glob
|
|
4
|
+
import re
|
|
5
|
+
import shutil
|
|
5
6
|
import subprocess
|
|
6
7
|
import sys
|
|
7
|
-
|
|
8
|
-
import re
|
|
8
|
+
|
|
9
9
|
import os.path
|
|
10
|
+
|
|
10
11
|
from collections.abc import Container
|
|
11
12
|
from pathlib import Path
|
|
13
|
+
|
|
12
14
|
import siliconcompiler
|
|
15
|
+
|
|
13
16
|
from siliconcompiler import RecordSchema
|
|
14
17
|
|
|
15
18
|
|
|
@@ -146,9 +149,10 @@ def _get_tools_list():
|
|
|
146
149
|
|
|
147
150
|
def _recommended_tool_groups(tools):
|
|
148
151
|
groups = {
|
|
149
|
-
"asic": {"sv2v", "yosys", "openroad", "klayout"},
|
|
150
|
-
"
|
|
151
|
-
"
|
|
152
|
+
"asic": {"sv2v", "yosys", "yosys-slang", "openroad", "klayout"},
|
|
153
|
+
"asic-hls": {"bambu", "yosys", "yosys-slang", "openroad", "klayout"},
|
|
154
|
+
"fpga": {"sv2v", "yosys", "yosys-slang", "vpr"},
|
|
155
|
+
"digital-simulation": {"verilator", "icarus", "surfer"},
|
|
152
156
|
"analog-simulation": {"xyce"}
|
|
153
157
|
}
|
|
154
158
|
|
siliconcompiler/apps/sc_issue.py
CHANGED
|
@@ -1,17 +1,19 @@
|
|
|
1
1
|
# Copyright 2023 Silicon Compiler Authors. All Rights Reserved.
|
|
2
|
+
import json
|
|
2
3
|
import sys
|
|
3
|
-
import os
|
|
4
|
-
import siliconcompiler
|
|
5
4
|
import tarfile
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
|
|
6
|
+
import os.path
|
|
7
|
+
|
|
8
|
+
from siliconcompiler import Chip
|
|
9
|
+
from siliconcompiler.scheduler import SchedulerNode
|
|
8
10
|
from siliconcompiler.utils.issue import generate_testcase
|
|
9
11
|
from siliconcompiler.tools._common import get_tool_task
|
|
10
12
|
|
|
11
13
|
|
|
12
14
|
def main():
|
|
13
15
|
progname = "sc-issue"
|
|
14
|
-
chip =
|
|
16
|
+
chip = Chip(progname)
|
|
15
17
|
switchlist = ['-cfg',
|
|
16
18
|
'-arg_step',
|
|
17
19
|
'-arg_index',
|
|
@@ -1,8 +1,7 @@
|
|
|
1
1
|
# Copyright 2020 Silicon Compiler Authors. All Rights Reserved.
|
|
2
|
-
|
|
3
2
|
import sys
|
|
4
3
|
|
|
5
|
-
from siliconcompiler.remote
|
|
4
|
+
from siliconcompiler.remote import Server
|
|
6
5
|
|
|
7
6
|
|
|
8
7
|
###############################################
|
|
@@ -11,25 +10,21 @@ from siliconcompiler.remote.server import Server
|
|
|
11
10
|
def main():
|
|
12
11
|
progname = "sc-server"
|
|
13
12
|
description = """
|
|
14
|
-
|
|
13
|
+
---------------------------------------------------------
|
|
15
14
|
Silicon Compiler Collection Remote Job Server (sc-server)
|
|
16
|
-
|
|
15
|
+
---------------------------------------------------------
|
|
17
16
|
"""
|
|
18
17
|
|
|
19
|
-
server = Server(
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
description=description)
|
|
25
|
-
except ValueError as e:
|
|
26
|
-
server.logger.error(f'{e}')
|
|
27
|
-
return 1
|
|
18
|
+
server = Server.create_cmdline(
|
|
19
|
+
progname,
|
|
20
|
+
description=description,
|
|
21
|
+
use_cfg=True,
|
|
22
|
+
use_sources=False)
|
|
28
23
|
|
|
29
24
|
try:
|
|
30
25
|
server.run()
|
|
31
26
|
except Exception as e:
|
|
32
|
-
server.logger.
|
|
27
|
+
server.logger.exception(e)
|
|
33
28
|
return 1
|
|
34
29
|
|
|
35
30
|
return 0
|
siliconcompiler/apps/sc_show.py
CHANGED
|
@@ -1,10 +1,11 @@
|
|
|
1
1
|
# Copyright 2020 Silicon Compiler Authors. All Rights Reserved.
|
|
2
2
|
import sys
|
|
3
|
-
|
|
4
|
-
import
|
|
5
|
-
|
|
3
|
+
|
|
4
|
+
import os.path
|
|
5
|
+
|
|
6
|
+
from siliconcompiler import Chip
|
|
7
|
+
from siliconcompiler.utils import get_default_iomap, get_file_ext
|
|
6
8
|
from siliconcompiler.apps._common import manifest_switches, pick_manifest, UNSET_DESIGN
|
|
7
|
-
from siliconcompiler.utils import get_file_ext
|
|
8
9
|
|
|
9
10
|
|
|
10
11
|
def main():
|
|
@@ -44,7 +45,7 @@ def main():
|
|
|
44
45
|
"""
|
|
45
46
|
|
|
46
47
|
# Create a base chip class.
|
|
47
|
-
chip =
|
|
48
|
+
chip = Chip(UNSET_DESIGN)
|
|
48
49
|
|
|
49
50
|
# Fill input map with default mapping only for showable files
|
|
50
51
|
input_map = {}
|