siliconcompiler 0.33.2__py3-none-any.whl → 0.34.0__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 +2 -0
- siliconcompiler/_metadata.py +1 -1
- siliconcompiler/apps/sc_issue.py +5 -3
- siliconcompiler/apps/sc_remote.py +0 -17
- siliconcompiler/checklist.py +1 -1
- siliconcompiler/core.py +34 -47
- siliconcompiler/dependencyschema.py +392 -0
- siliconcompiler/design.py +664 -0
- siliconcompiler/flowgraph.py +32 -1
- siliconcompiler/package/__init__.py +383 -223
- siliconcompiler/package/git.py +75 -77
- siliconcompiler/package/github.py +70 -97
- siliconcompiler/package/https.py +77 -93
- siliconcompiler/packageschema.py +260 -0
- siliconcompiler/pdk.py +2 -2
- siliconcompiler/remote/client.py +15 -3
- siliconcompiler/report/dashboard/cli/board.py +1 -1
- siliconcompiler/scheduler/__init__.py +3 -1382
- siliconcompiler/scheduler/docker.py +268 -0
- siliconcompiler/scheduler/run_node.py +10 -16
- siliconcompiler/scheduler/scheduler.py +308 -0
- siliconcompiler/scheduler/schedulernode.py +934 -0
- siliconcompiler/scheduler/slurm.py +147 -163
- siliconcompiler/scheduler/taskscheduler.py +39 -52
- siliconcompiler/schema/__init__.py +3 -3
- siliconcompiler/schema/baseschema.py +234 -10
- siliconcompiler/schema/editableschema.py +4 -0
- siliconcompiler/schema/journal.py +210 -0
- siliconcompiler/schema/namedschema.py +31 -2
- siliconcompiler/schema/parameter.py +14 -1
- siliconcompiler/schema/parametervalue.py +1 -34
- siliconcompiler/schema/schema_cfg.py +210 -349
- siliconcompiler/tool.py +61 -20
- siliconcompiler/tools/builtin/concatenate.py +2 -2
- siliconcompiler/tools/builtin/verify.py +1 -2
- siliconcompiler/tools/openroad/scripts/common/procs.tcl +27 -25
- siliconcompiler/tools/vpr/route.py +69 -0
- siliconcompiler/toolscripts/_tools.json +4 -4
- siliconcompiler/utils/__init__.py +2 -23
- siliconcompiler/utils/flowgraph.py +5 -5
- siliconcompiler/utils/logging.py +2 -1
- {siliconcompiler-0.33.2.dist-info → siliconcompiler-0.34.0.dist-info}/METADATA +4 -3
- {siliconcompiler-0.33.2.dist-info → siliconcompiler-0.34.0.dist-info}/RECORD +47 -42
- siliconcompiler/scheduler/docker_runner.py +0 -254
- siliconcompiler/schema/journalingschema.py +0 -242
- {siliconcompiler-0.33.2.dist-info → siliconcompiler-0.34.0.dist-info}/WHEEL +0 -0
- {siliconcompiler-0.33.2.dist-info → siliconcompiler-0.34.0.dist-info}/entry_points.txt +0 -0
- {siliconcompiler-0.33.2.dist-info → siliconcompiler-0.34.0.dist-info}/licenses/LICENSE +0 -0
- {siliconcompiler-0.33.2.dist-info → siliconcompiler-0.34.0.dist-info}/top_level.txt +0 -0
siliconcompiler/tool.py
CHANGED
|
@@ -61,11 +61,35 @@ class TaskExecutableNotFound(TaskError):
|
|
|
61
61
|
|
|
62
62
|
|
|
63
63
|
class TaskSchema(NamedSchema):
|
|
64
|
-
def __init__(self, name
|
|
65
|
-
super().__init__(name
|
|
64
|
+
def __init__(self, name):
|
|
65
|
+
super().__init__(name)
|
|
66
66
|
|
|
67
67
|
schema_task(self)
|
|
68
68
|
|
|
69
|
+
def add_parameter(self, name, type, help, defvalue=None):
|
|
70
|
+
'''
|
|
71
|
+
Adds a parameter to the task definition.
|
|
72
|
+
|
|
73
|
+
Args:
|
|
74
|
+
name (str): name of parameter
|
|
75
|
+
type (str): schema type of the parameter
|
|
76
|
+
help (str): help string for this parameter
|
|
77
|
+
defvalue (any): default value for the parameter
|
|
78
|
+
'''
|
|
79
|
+
help = trim(help)
|
|
80
|
+
param = Parameter(
|
|
81
|
+
type,
|
|
82
|
+
defvalue=defvalue,
|
|
83
|
+
scope=Scope.JOB,
|
|
84
|
+
pernode=PerNode.OPTIONAL,
|
|
85
|
+
shorthelp=help,
|
|
86
|
+
help=help
|
|
87
|
+
)
|
|
88
|
+
|
|
89
|
+
EditableSchema(self).insert("var", name, param)
|
|
90
|
+
|
|
91
|
+
return param
|
|
92
|
+
|
|
69
93
|
|
|
70
94
|
class ToolSchema(NamedSchema):
|
|
71
95
|
__parse_version_check_str = r"""
|
|
@@ -83,13 +107,13 @@ class ToolSchema(NamedSchema):
|
|
|
83
107
|
r"^\s*" + __parse_version_check_str + r"\s*$",
|
|
84
108
|
re.VERBOSE | re.IGNORECASE)
|
|
85
109
|
|
|
86
|
-
def __init__(self, name
|
|
87
|
-
super().__init__(name
|
|
110
|
+
def __init__(self, name):
|
|
111
|
+
super().__init__(name)
|
|
88
112
|
|
|
89
113
|
schema_tool(self)
|
|
90
114
|
|
|
91
115
|
schema = EditableSchema(self)
|
|
92
|
-
schema.insert("task", "default", TaskSchema())
|
|
116
|
+
schema.insert("task", "default", TaskSchema(None))
|
|
93
117
|
|
|
94
118
|
self.set_runtime(None)
|
|
95
119
|
|
|
@@ -359,13 +383,14 @@ class ToolSchema(NamedSchema):
|
|
|
359
383
|
envvars[lic_env] = ':'.join(license_file)
|
|
360
384
|
|
|
361
385
|
if include_path:
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
386
|
+
path = self.find_files(
|
|
387
|
+
"path", step=self.__step, index=self.__index,
|
|
388
|
+
packages=self.__chip.get("package", field="schema").get_resolvers(),
|
|
389
|
+
cwd=self.__chip.cwd,
|
|
390
|
+
missing_ok=True)
|
|
365
391
|
|
|
366
392
|
envvars["PATH"] = os.getenv("PATH", os.defpath)
|
|
367
393
|
|
|
368
|
-
path = path_param.get(field=None).resolve_path() # TODO: needs package search
|
|
369
394
|
if path:
|
|
370
395
|
envvars["PATH"] = path + os.pathsep + envvars["PATH"]
|
|
371
396
|
|
|
@@ -391,15 +416,6 @@ class ToolSchema(NamedSchema):
|
|
|
391
416
|
'''
|
|
392
417
|
|
|
393
418
|
cmdargs = []
|
|
394
|
-
cmdargs.extend(self.get('task', self.__task, 'option',
|
|
395
|
-
step=self.__step, index=self.__index))
|
|
396
|
-
|
|
397
|
-
# Add scripts files / TODO:
|
|
398
|
-
scripts = self.__chip.find_files('tool', self.__tool, 'task', self.__task, 'script',
|
|
399
|
-
step=self.__step, index=self.__index)
|
|
400
|
-
|
|
401
|
-
cmdargs.extend(scripts)
|
|
402
|
-
|
|
403
419
|
try:
|
|
404
420
|
cmdargs.extend(self.runtime_options())
|
|
405
421
|
except Exception as e:
|
|
@@ -826,7 +842,17 @@ class ToolSchema(NamedSchema):
|
|
|
826
842
|
pass
|
|
827
843
|
|
|
828
844
|
def runtime_options(self):
|
|
829
|
-
|
|
845
|
+
cmdargs = []
|
|
846
|
+
cmdargs.extend(self.get('task', self.__task, 'option',
|
|
847
|
+
step=self.__step, index=self.__index))
|
|
848
|
+
|
|
849
|
+
# Add scripts files / TODO:
|
|
850
|
+
scripts = self.__chip.find_files('tool', self.__tool, 'task', self.__task, 'script',
|
|
851
|
+
step=self.__step, index=self.__index)
|
|
852
|
+
|
|
853
|
+
cmdargs.extend(scripts)
|
|
854
|
+
|
|
855
|
+
return cmdargs
|
|
830
856
|
|
|
831
857
|
def run(self):
|
|
832
858
|
raise NotImplementedError("must be implemented by the implementation class")
|
|
@@ -839,6 +865,9 @@ class ToolSchema(NamedSchema):
|
|
|
839
865
|
# Migration helper
|
|
840
866
|
###########################################################################
|
|
841
867
|
class ToolSchemaTmp(ToolSchema):
|
|
868
|
+
def __init__(self):
|
|
869
|
+
super().__init__(None)
|
|
870
|
+
|
|
842
871
|
def __module_func(self, name, modules):
|
|
843
872
|
for module in modules:
|
|
844
873
|
method = getattr(module, name, None)
|
|
@@ -874,6 +903,17 @@ class ToolSchemaTmp(ToolSchema):
|
|
|
874
903
|
return method(version)
|
|
875
904
|
return ToolSchema.normalize_version(self, version)
|
|
876
905
|
|
|
906
|
+
def generate_replay_script(self, filepath, workdir, include_path=True):
|
|
907
|
+
prev_step, prev_index = self._ToolSchema__chip.get('arg', 'step'), \
|
|
908
|
+
self._ToolSchema__chip.get('arg', 'index')
|
|
909
|
+
step, index = self.node()
|
|
910
|
+
self._ToolSchema__chip.set('arg', 'step', step)
|
|
911
|
+
self._ToolSchema__chip.set('arg', 'index', index)
|
|
912
|
+
ret = ToolSchema.generate_replay_script(self, filepath, workdir, include_path=include_path)
|
|
913
|
+
self._ToolSchema__chip.set('arg', 'step', prev_step)
|
|
914
|
+
self._ToolSchema__chip.set('arg', 'index', prev_index)
|
|
915
|
+
return ret
|
|
916
|
+
|
|
877
917
|
def setup(self):
|
|
878
918
|
_, task = self.__tool_task_modules()
|
|
879
919
|
method = self.__module_func("setup", [task])
|
|
@@ -928,7 +968,8 @@ class ToolSchemaTmp(ToolSchema):
|
|
|
928
968
|
step, index = self.node()
|
|
929
969
|
self._ToolSchema__chip.set('arg', 'step', step)
|
|
930
970
|
self._ToolSchema__chip.set('arg', 'index', index)
|
|
931
|
-
ret =
|
|
971
|
+
ret = ToolSchema.runtime_options(self)
|
|
972
|
+
ret.extend(method(self._ToolSchema__chip))
|
|
932
973
|
self._ToolSchema__chip.set('arg', 'step', prev_step)
|
|
933
974
|
self._ToolSchema__chip.set('arg', 'index', prev_index)
|
|
934
975
|
return ret
|
|
@@ -3,7 +3,7 @@ import os
|
|
|
3
3
|
from siliconcompiler import sc_open, SiliconCompilerError
|
|
4
4
|
from siliconcompiler import utils
|
|
5
5
|
from siliconcompiler.tools._common import input_provides, input_file_node_name, get_tool_task
|
|
6
|
-
from siliconcompiler import
|
|
6
|
+
from siliconcompiler.scheduler.schedulernode import SchedulerNode
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
def make_docs(chip):
|
|
@@ -12,7 +12,7 @@ def make_docs(chip):
|
|
|
12
12
|
chip.set('option', 'flow', 'asicflow')
|
|
13
13
|
|
|
14
14
|
for step, index in chip.schema.get("flowgraph", "asicflow", field="schema").get_entry_nodes():
|
|
15
|
-
|
|
15
|
+
SchedulerNode(chip, step, index).setup()
|
|
16
16
|
|
|
17
17
|
chip.set('arg', 'step', 'import.combine')
|
|
18
18
|
chip.set('arg', 'index', '0')
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
from siliconcompiler.tools.builtin import _common
|
|
2
2
|
from siliconcompiler.schema.parametertype import NodeType
|
|
3
|
-
from siliconcompiler.scheduler import _haltstep
|
|
4
3
|
from siliconcompiler.tools.builtin.builtin import set_io_files
|
|
5
4
|
from siliconcompiler import utils, SiliconCompilerError
|
|
6
5
|
from siliconcompiler.tools._common import get_tool_task
|
|
@@ -59,7 +58,7 @@ def _select_inputs(chip, step, index):
|
|
|
59
58
|
chip.error(f"{step}{index} fails '{metric}' metric: {value}{op}{goal}")
|
|
60
59
|
|
|
61
60
|
if not passes:
|
|
62
|
-
|
|
61
|
+
return []
|
|
63
62
|
|
|
64
63
|
return inputs
|
|
65
64
|
|
|
@@ -634,36 +634,38 @@ proc sc_setup_sta { } {
|
|
|
634
634
|
set_timing_derate -late $sta_late_timing_derate
|
|
635
635
|
}
|
|
636
636
|
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
[lindex [sc_cfg_tool_task_get var sta_define_path_groups] 0] == "true" &&
|
|
640
|
-
[llength [sta::path_group_names]] == 0
|
|
641
|
-
} {
|
|
642
|
-
sc_path_group -name in2out -from [all_inputs -no_clocks] -to [all_outputs]
|
|
643
|
-
|
|
637
|
+
if { [sc_check_version 19370] } {
|
|
638
|
+
# Create path groups
|
|
644
639
|
if {
|
|
645
|
-
[
|
|
646
|
-
[
|
|
640
|
+
[lindex [sc_cfg_tool_task_get var sta_define_path_groups] 0] == "true" &&
|
|
641
|
+
[llength [sta::path_group_names]] == 0
|
|
647
642
|
} {
|
|
648
|
-
sc_path_group -name
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
sc_path_group -name in2reg
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
643
|
+
sc_path_group -name in2out -from [all_inputs -no_clocks] -to [all_outputs]
|
|
644
|
+
|
|
645
|
+
if {
|
|
646
|
+
[llength [all_clocks]] == 1 ||
|
|
647
|
+
[lindex [sc_cfg_tool_task_get var sta_unique_path_groups_per_clock] 0] == "false"
|
|
648
|
+
} {
|
|
649
|
+
sc_path_group -name in2reg -from [all_inputs -no_clocks] -to [all_registers]
|
|
650
|
+
sc_path_group -name reg2reg -from [all_registers] -to [all_registers]
|
|
651
|
+
sc_path_group -name reg2out -from [all_registers] -to [all_outputs]
|
|
652
|
+
} else {
|
|
653
|
+
foreach clock [all_clocks] {
|
|
654
|
+
set clk_name [get_property $clock name]
|
|
655
|
+
sc_path_group -name in2reg.${clk_name} \
|
|
656
|
+
-from [all_inputs -no_clocks] \
|
|
657
|
+
-to [all_registers -clock $clock]
|
|
658
|
+
sc_path_group -name reg2reg.${clk_name} \
|
|
659
|
+
-from [all_registers -clock $clock] \
|
|
660
|
+
-to [all_registers -clock $clock]
|
|
661
|
+
sc_path_group -name reg2out.${clk_name} \
|
|
662
|
+
-from [all_registers -clock $clock] \
|
|
663
|
+
-to [all_outputs]
|
|
664
|
+
}
|
|
663
665
|
}
|
|
664
666
|
}
|
|
667
|
+
utl::info FLW 1 "Timing path groups: [sta::path_group_names]"
|
|
665
668
|
}
|
|
666
|
-
utl::info FLW 1 "Timing path groups: [sta::path_group_names]"
|
|
667
669
|
|
|
668
670
|
# Check timing setup
|
|
669
671
|
if { [sc_cfg_tool_task_check_in_list check_setup var reports] } {
|
|
@@ -44,6 +44,45 @@ def setup(chip, clobber=True):
|
|
|
44
44
|
chip.add('tool', tool, 'task', task, 'output', design + '.net', step=step, index=index)
|
|
45
45
|
chip.add('tool', tool, 'task', task, 'output', design + '.place', step=step, index=index)
|
|
46
46
|
|
|
47
|
+
# Add a parameter for generating a post-implementation netlist for external
|
|
48
|
+
# static timing analysis.
|
|
49
|
+
chip.set('tool', tool, 'task', task, 'var', 'gen_post_implementation_netlist',
|
|
50
|
+
False, step=step, index=index, clobber=False)
|
|
51
|
+
|
|
52
|
+
chip.set('tool', tool, 'task', task, 'var', 'gen_post_implementation_netlist',
|
|
53
|
+
'set to true to have VPR generate a post-implementation netlist',
|
|
54
|
+
field='help')
|
|
55
|
+
|
|
56
|
+
chip.set('tool', tool, 'task', task, 'require',
|
|
57
|
+
",".join(['tool', tool, 'task', task, 'var', 'gen_post_implementation_netlist']),
|
|
58
|
+
step=step, index=index)
|
|
59
|
+
|
|
60
|
+
# Add a parameter to control the timing corner used when generating SDF files.
|
|
61
|
+
chip.set('tool', tool, 'task', task, 'var', 'timing_corner', 'typical',
|
|
62
|
+
step=step, index=index, clobber=False)
|
|
63
|
+
|
|
64
|
+
chip.set('tool', tool, 'task', task, 'var', 'timing_corner',
|
|
65
|
+
'set the timing corner for files generated by the post-implementation netlist',
|
|
66
|
+
field='help')
|
|
67
|
+
|
|
68
|
+
chip.set('tool', tool, 'task', task, 'require',
|
|
69
|
+
",".join(['tool', tool, 'task', task, 'var', 'timing_corner']),
|
|
70
|
+
step=step, index=index)
|
|
71
|
+
|
|
72
|
+
# Add the post-implementation timing netlist outputs if requested.
|
|
73
|
+
gen_post_implementation_netlist = chip.get('tool', tool, 'task', task, 'var',
|
|
74
|
+
'gen_post_implementation_netlist',
|
|
75
|
+
step=step, index=index)[0]
|
|
76
|
+
timing_corner = chip.get('tool', tool, 'task', task, 'var', 'timing_corner',
|
|
77
|
+
step=step, index=index)[0]
|
|
78
|
+
if gen_post_implementation_netlist == 'true':
|
|
79
|
+
chip.add('tool', tool, 'task', task, 'output', f'{design}.vg',
|
|
80
|
+
step=step, index=index)
|
|
81
|
+
chip.add('tool', tool, 'task', task, 'output', f'{design}.sdc',
|
|
82
|
+
step=step, index=index)
|
|
83
|
+
chip.add('tool', tool, 'task', task, 'output', f'{design}.{timing_corner}.sdf',
|
|
84
|
+
step=step, index=index)
|
|
85
|
+
|
|
47
86
|
|
|
48
87
|
def runtime_options(chip):
|
|
49
88
|
'''Command line options to vpr for the route step
|
|
@@ -104,6 +143,21 @@ def runtime_options(chip):
|
|
|
104
143
|
options.append("--graphics_commands")
|
|
105
144
|
options.append(graphics_command_str)
|
|
106
145
|
|
|
146
|
+
# Generate a post-implementation netlist for use in external timing analysis
|
|
147
|
+
# if requested.
|
|
148
|
+
gen_post_implementation_netlist = chip.get('tool', tool, 'task', task, 'var',
|
|
149
|
+
'gen_post_implementation_netlist',
|
|
150
|
+
step=step, index=index)[0]
|
|
151
|
+
if gen_post_implementation_netlist == 'true':
|
|
152
|
+
# Generate the netlist.
|
|
153
|
+
options.extend(["--gen_post_synthesis_netlist", "on"])
|
|
154
|
+
# Generate the SDC file.
|
|
155
|
+
options.extend(["--gen_post_implementation_sdc", "on"])
|
|
156
|
+
# Create undriven nets for unconnected inputs.
|
|
157
|
+
options.extend(["--post_synth_netlist_unconn_inputs", "nets"])
|
|
158
|
+
# Turn off module parameters.
|
|
159
|
+
options.extend(["--post_synth_netlist_module_parameters", "off"])
|
|
160
|
+
|
|
107
161
|
return options
|
|
108
162
|
|
|
109
163
|
|
|
@@ -122,3 +176,18 @@ def post_process(chip):
|
|
|
122
176
|
shutil.copy2(f'inputs/{design}.blif', 'outputs')
|
|
123
177
|
shutil.copy2(f'inputs/{design}.net', 'outputs')
|
|
124
178
|
shutil.copy2(f'inputs/{design}.place', 'outputs')
|
|
179
|
+
|
|
180
|
+
# Copy and rename the post-implementation netlist results into the output
|
|
181
|
+
# directory to be used in external timing analysis.
|
|
182
|
+
step = chip.get('arg', 'step')
|
|
183
|
+
index = chip.get('arg', 'index')
|
|
184
|
+
tool, task = get_tool_task(chip, step, index)
|
|
185
|
+
gen_post_implementation_netlist = chip.get('tool', tool, 'task', task, 'var',
|
|
186
|
+
'gen_post_implementation_netlist',
|
|
187
|
+
step=step, index=index)[0]
|
|
188
|
+
timing_corner = chip.get('tool', tool, 'task', task, 'var', 'timing_corner',
|
|
189
|
+
step=step, index=index)[0]
|
|
190
|
+
if gen_post_implementation_netlist == 'true':
|
|
191
|
+
shutil.move(f'{design}_post_synthesis.v', f'outputs/{design}.vg')
|
|
192
|
+
shutil.move(f'{design}_post_synthesis.sdc', f'outputs/{design}.sdc')
|
|
193
|
+
shutil.move(f'{design}_post_synthesis.sdf', f'outputs/{design}.{timing_corner}.sdf')
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"openroad": {
|
|
3
3
|
"git-url": "https://github.com/The-OpenROAD-Project/OpenROAD.git",
|
|
4
|
-
"git-commit": "
|
|
4
|
+
"git-commit": "4b729ea474e9bd0a3513579b41a8c96fe20dc75e",
|
|
5
5
|
"docker-cmds": [
|
|
6
6
|
"# Remove OR-Tools files",
|
|
7
7
|
"RUN rm -f $SC_PREFIX/Makefile $SC_PREFIX/README.md",
|
|
@@ -17,7 +17,7 @@
|
|
|
17
17
|
},
|
|
18
18
|
"opensta": {
|
|
19
19
|
"git-url": "https://github.com/parallaxsw/OpenSTA.git",
|
|
20
|
-
"git-commit": "
|
|
20
|
+
"git-commit": "343b93b6336962b2dbcc5b7c7500c01df0367696",
|
|
21
21
|
"auto-update": true
|
|
22
22
|
},
|
|
23
23
|
"netgen": {
|
|
@@ -101,7 +101,7 @@
|
|
|
101
101
|
},
|
|
102
102
|
"yosys": {
|
|
103
103
|
"git-url": "https://github.com/YosysHQ/yosys.git",
|
|
104
|
-
"git-commit": "v0.
|
|
104
|
+
"git-commit": "v0.54",
|
|
105
105
|
"version-prefix": "",
|
|
106
106
|
"auto-update": true
|
|
107
107
|
},
|
|
@@ -151,7 +151,7 @@
|
|
|
151
151
|
},
|
|
152
152
|
"yosys-slang": {
|
|
153
153
|
"git-url": "https://github.com/povik/yosys-slang.git",
|
|
154
|
-
"git-commit": "
|
|
154
|
+
"git-commit": "e863336db656b1f0ec82f7af65249b6a4ee3e56c",
|
|
155
155
|
"docker-depends": "yosys",
|
|
156
156
|
"auto-update": true
|
|
157
157
|
},
|
|
@@ -329,29 +329,6 @@ def grep(chip, args, line):
|
|
|
329
329
|
return line
|
|
330
330
|
|
|
331
331
|
|
|
332
|
-
#######################################
|
|
333
|
-
def get_env_vars(chip, step, index):
|
|
334
|
-
'''
|
|
335
|
-
Returns a dictionary of environmental variables from the manifest
|
|
336
|
-
'''
|
|
337
|
-
|
|
338
|
-
schema_env = {}
|
|
339
|
-
for env in chip.getkeys('option', 'env'):
|
|
340
|
-
schema_env[env] = chip.get('option', 'env', env)
|
|
341
|
-
|
|
342
|
-
flow = chip.get('option', 'flow')
|
|
343
|
-
if step is not None and index is not None and flow:
|
|
344
|
-
tool = chip.get('flowgraph', flow, step, str(index), 'tool')
|
|
345
|
-
task = chip.get('flowgraph', flow, step, str(index), 'task')
|
|
346
|
-
|
|
347
|
-
if chip.valid('tool', tool, 'task', task, 'env'):
|
|
348
|
-
for env in chip.getkeys('tool', tool, 'task', task, 'env'):
|
|
349
|
-
schema_env[env] = chip.get('tool', tool, 'task', task, 'env', env,
|
|
350
|
-
step=step, index=index)
|
|
351
|
-
|
|
352
|
-
return schema_env
|
|
353
|
-
|
|
354
|
-
|
|
355
332
|
def get_plugins(system, name=None):
|
|
356
333
|
'''
|
|
357
334
|
Search for python modules with a specific function
|
|
@@ -370,6 +347,8 @@ def get_plugins(system, name=None):
|
|
|
370
347
|
|
|
371
348
|
|
|
372
349
|
def truncate_text(text, width):
|
|
350
|
+
width = max(width, 5)
|
|
351
|
+
|
|
373
352
|
if len(text) <= width:
|
|
374
353
|
return text
|
|
375
354
|
|
|
@@ -4,6 +4,7 @@ from siliconcompiler import NodeStatus
|
|
|
4
4
|
from siliconcompiler.tools._common import input_file_node_name, get_tool_task
|
|
5
5
|
|
|
6
6
|
from siliconcompiler.flowgraph import RuntimeFlowgraph
|
|
7
|
+
from siliconcompiler.scheduler.schedulernode import SchedulerNode
|
|
7
8
|
|
|
8
9
|
|
|
9
10
|
###########################################################################
|
|
@@ -87,7 +88,6 @@ def _check_flowgraph_io(chip, nodes=None):
|
|
|
87
88
|
|
|
88
89
|
|
|
89
90
|
def _get_flowgraph_information(chip, flow, io=True):
|
|
90
|
-
from siliconcompiler.scheduler import _setup_node
|
|
91
91
|
from siliconcompiler.tools._common import input_provides, input_file_node_name
|
|
92
92
|
|
|
93
93
|
# Save schema to avoid making permanent changes
|
|
@@ -97,12 +97,12 @@ def _get_flowgraph_information(chip, flow, io=True):
|
|
|
97
97
|
# Setup nodes
|
|
98
98
|
node_exec_order = chip.schema.get("flowgraph", flow, field="schema").get_execution_order()
|
|
99
99
|
if io:
|
|
100
|
-
|
|
100
|
+
prev_flow = chip.get("option", "flow")
|
|
101
|
+
chip.set("option", "flow", flow)
|
|
101
102
|
for layer_nodes in node_exec_order:
|
|
102
103
|
for step, index in layer_nodes:
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
# io = False
|
|
104
|
+
SchedulerNode(chip, step, index).setup()
|
|
105
|
+
chip.set("option", "flow", prev_flow)
|
|
106
106
|
|
|
107
107
|
node_rank = {}
|
|
108
108
|
for rank, rank_nodes in enumerate(node_exec_order):
|
siliconcompiler/utils/logging.py
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import logging
|
|
2
2
|
import sys
|
|
3
|
-
from siliconcompiler.remote import client
|
|
4
3
|
from siliconcompiler import utils
|
|
5
4
|
|
|
6
5
|
|
|
@@ -38,6 +37,8 @@ class SCInRunLoggerFormatter(logging.Formatter):
|
|
|
38
37
|
|
|
39
38
|
@staticmethod
|
|
40
39
|
def configure_format(fmt, chip, step, index):
|
|
40
|
+
from siliconcompiler.remote import client
|
|
41
|
+
|
|
41
42
|
max_width = 20
|
|
42
43
|
|
|
43
44
|
flow = chip.get('option', 'flow')
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: siliconcompiler
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.34.0
|
|
4
4
|
Summary: A compiler framework that automates translation from source code to silicon.
|
|
5
5
|
Author-email: Andreas Olofsson <andreas.d.olofsson@gmail.com>
|
|
6
6
|
License: Apache License 2.0
|
|
@@ -27,7 +27,7 @@ Description-Content-Type: text/markdown
|
|
|
27
27
|
License-File: LICENSE
|
|
28
28
|
Requires-Dist: aiohttp==3.10.11; python_version <= "3.8"
|
|
29
29
|
Requires-Dist: aiohttp<3.13.0,>=3.10.11; python_version >= "3.9"
|
|
30
|
-
Requires-Dist: requests==2.32.
|
|
30
|
+
Requires-Dist: requests==2.32.4
|
|
31
31
|
Requires-Dist: PyYAML==6.0.2
|
|
32
32
|
Requires-Dist: pandas>=1.1.5
|
|
33
33
|
Requires-Dist: Jinja2>=2.11.3
|
|
@@ -57,7 +57,8 @@ Requires-Dist: streamlit-autorefresh==1.0.1; python_full_version != "3.9.7"
|
|
|
57
57
|
Requires-Dist: rich==13.9.4; python_version <= "3.8"
|
|
58
58
|
Requires-Dist: rich<15.0.0,>=14.0.0; python_version >= "3.9"
|
|
59
59
|
Provides-Extra: test
|
|
60
|
-
Requires-Dist: pytest==8.3.5; extra == "test"
|
|
60
|
+
Requires-Dist: pytest==8.3.5; python_version <= "3.8" and extra == "test"
|
|
61
|
+
Requires-Dist: pytest==8.4.0; python_version >= "3.9" and extra == "test"
|
|
61
62
|
Requires-Dist: pytest-xdist==3.6.1; python_version <= "3.8" and extra == "test"
|
|
62
63
|
Requires-Dist: pytest-xdist==3.7.0; python_version >= "3.9" and extra == "test"
|
|
63
64
|
Requires-Dist: pytest-timeout==2.4.0; extra == "test"
|