From 178aca633f93fb3be9b2bffd987881427a97cee1 Mon Sep 17 00:00:00 2001 From: "Amir.A" Date: Tue, 10 Dec 2024 13:39:57 -0400 Subject: [PATCH] tcl update - error handling --- vtr_flow/misc/yosys/synthesis.tcl | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/vtr_flow/misc/yosys/synthesis.tcl b/vtr_flow/misc/yosys/synthesis.tcl index 48bdfc8382..6dad1978f9 100644 --- a/vtr_flow/misc/yosys/synthesis.tcl +++ b/vtr_flow/misc/yosys/synthesis.tcl @@ -7,8 +7,14 @@ read_verilog -nomem2reg +/parmys/vtr_primitives.v setattr -mod -set keep_hierarchy 1 single_port_ram setattr -mod -set keep_hierarchy 1 dual_port_ram -set synlig $::env(synlig_exe_path) -puts "Using parmys as partial mapper" +# synlig path error handling +if {[catch {set synlig $::env(synlig_exe_path)} err]} { + puts "Error: $err" + puts "synlig_exe_path is not set" +} else { + set synlig $::env(synlig_exe_path) + puts "Using parmys as partial mapper" +} # arch file: QQQ # input files: [XXX]