Anton Blanchard
07/26/2022, 8:00 AMset script_dir [file dirname [file normalize [info script]]]
...
set ::env(VERILOG_FILES) "\
$script_dir/src/multiply_add_64x64.v"
If I add this to the top:
puts [file dirname [file normalize [info script]]]
It seems to suggest we are sourcing the file twice (I see it output twice):
caravel_user_project/openlane/multiply_add_64x64
caravel_user_project/openlane/multiply_add_64x64/runs/22_07_26_17_55
Are we sourcing it twice for a reason?
if { $ext == ".tcl" } {
# for trusted end-users only
exec cp $config_file $config_in_path
source $config_file <----- here
} elseif { $ext == ".json" } {
set cmd "python3 $::env(SCRIPTS_DIR)/config/to_tcl.py from-json\
--pdk $::env(PDK) --scl $::env(STD_CELL_LIBRARY)\
--output $config_in_path\
--design-dir $::env(DESIGN_DIR)\
$config_file
"
if { [catch {exec {*}$cmd} errmsg] } {
puts_err $errmsg
exit -1
}
} else {
puts_err "$config_file error: unsupported extension '$ext'"
return -code error
}
source $config_in_path <----- again, but from the run dir
Vijayan Krishnan
07/26/2022, 8:06 AMscript_dir
deprecated with latest OpenLane. Refer this format https://github.com/The-OpenROAD-Project/OpenLane/blob/b50b4d03ab10ad0b3a49fd2df64448ad2c2d739e/designs/caravel_upw/config.tcl#L19Anton Blanchard
07/26/2022, 8:08 AMdonn
07/26/2022, 3:58 PM