Skip to content

Commit e919264

Browse files
committed
upf: changing use_interface_cell according to upf 2.1
Signed-off-by: Lucas Yuki Imamura <lucasyuki@yahoo.com.br>
1 parent f974085 commit e919264

File tree

1 file changed

+14
-4
lines changed

1 file changed

+14
-4
lines changed

src/upf/src/upf.tcl

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -251,38 +251,48 @@ proc set_isolation { args } {
251251
# - domain: power domain
252252
# - strategy: isolation strategy name
253253
# - lib_cells: list of lib cells that could be used
254+
# - interface_implementation_name: for compatibility only. OpenRoad doesn't use it.
254255

255256
sta::define_cmd_args "use_interface_cell" { \
256257
[-domain domain] \
257258
[-strategy strategy] \
258-
[-lib_cells lib_cells]
259+
[-lib_cells lib_cells] \
260+
interface_implementation_name
259261
}
260262
proc use_interface_cell { args } {
261263
upf::check_block_exists
262264

263265
sta::parse_key_args "use_interface_cell" args \
264266
keys {-domain -strategy -lib_cells} flags {}
265267

266-
sta::check_argc_eq0 "use_interface_cell" $args
268+
sta::check_argc_eq0or1 "use_interface_cell" $args
267269

268270
set domain ""
269271
set strategy ""
270272
set lib_cells {}
271273

272274
if { [info exists keys(-domain)] } {
273275
set domain $keys(-domain)
276+
} else {
277+
utl::error UPF 75 "-domain is required for use_interface_cell"
274278
}
275279

276280
if { [info exists keys(-strategy)] } {
277281
set strategy $keys(-strategy)
282+
} else {
283+
utl::error UPF 76 "-strategy is required for use_interface_cell"
278284
}
279285

280286
if { [info exists keys(-lib_cells)] } {
281287
set lib_cells $keys(-lib_cells)
288+
} else {
289+
utl::error UPF 77 "-lib_cells is required for use_interface_cell"
282290
}
283291

284-
foreach {cell} $lib_cells {
285-
upf::use_interface_cell_cmd $domain $strategy $cell
292+
foreach {strat} $strategy {
293+
foreach {cell} $lib_cells {
294+
upf::use_interface_cell_cmd $domain $strat $cell
295+
}
286296
}
287297
}
288298

0 commit comments

Comments
 (0)