From f0e5147122dac8bdba48b506c0f25ba8b952fc0c Mon Sep 17 00:00:00 2001 From: James Cherry Date: Mon, 18 Feb 2019 16:24:41 -0800 Subject: [PATCH] report_power -instances table format --- tcl/Power.tcl | 26 +++++++++++--------------- 1 file changed, 11 insertions(+), 15 deletions(-) diff --git a/tcl/Power.tcl b/tcl/Power.tcl index 73bff6c3..afa58473 100644 --- a/tcl/Power.tcl +++ b/tcl/Power.tcl @@ -114,11 +114,15 @@ proc report_power_insts { insts corner digits } { lappend inst_pwrs [list $inst $power_result] } set inst_pwrs [lsort -command inst_pwr_cmp $inst_pwrs] + + puts " Internal Switching Leakage Total Instance" + puts " Power Power Power Power (mW)" + puts "-------------------------------------------------------------------" + foreach inst_pwr $inst_pwrs { set inst [lindex $inst_pwr 0] set power [lindex $inst_pwr 1] report_power_inst $inst $power $digits - puts "" } } @@ -137,20 +141,12 @@ proc inst_pwr_cmp { inst_pwr1 inst_pwr2 } { } proc report_power_inst { inst power_result digits } { - puts "Instance: [get_full_name $inst]" - set cell [get_property $inst "liberty_cell"] - if { $cell != "NULL" } { - puts "Cell: [get_name $cell]" - set library [get_property $cell "library"] - puts "Library file: [get_property $library filename]" - lassign $power_result internal switching leakage total - report_power_line "Internal power" $internal $digits - report_power_line "Switching power" $switching $digits - report_power_line "Leakage power" $leakage $digits - report_power_line "Total power" $total $digits - } else { - sta_error "[get_full_name $inst] is not a liberty cell instance." - } + lassign $power_result internal switching leakage total + report_power_col $internal $digits + report_power_col $switching $digits + report_power_col $leakage $digits + report_power_col $total $digits + puts " [get_full_name $inst]" } ################################################################