Repository navigation
Conversation
There was a problem hiding this comment.
Code Review
This pull request introduces support for power calculation using SAIF or VCD files by adding three new configuration variables: POWER_FILE_SCOPE, SAIF_FILE, and VCD_FILE. These variables are documented and integrated into the reporting metrics script. The review feedback correctly identifies two issues in flow/scripts/report_metrics.tcl: a regex bug in get_power_file_scope_args where escaped parentheses prevent correct capturing, and a line of dead code appending to an unused additional_args variable.
| set scope_val [string trim $scope_val "\"'"] | ||
|
|
||
| # 2. Normalize: remove any backslashes immediately preceding [, ], or . | ||
| regsub -all {\\(\[|\]|\.)} $scope_val {\1} scope_val |
There was a problem hiding this comment.
The regular expression \\(\[|\]|\.) escapes the parentheses ( and ), which treats them as literal characters instead of a capturing group. This causes the pattern to match literal parentheses and incorrectly match any standalone ] character, replacing it with an empty string or causing unexpected behavior. It should be written without escaping the parentheses to correctly capture the character for the \1 replacement.
regsub -all {\\([\[\].])} $scope_val {\1} scope_val
🔍 QoR checkMetrics reflect the PR merge build — i.e. what will land on the target branch. Commit 62 design(s) checked — 0 with regression(s), 1 without a comparable baseline. |
|
Need yaml formatting |
adjusted RE per claude + yaml formatting tcl fmt Signed-off-by: Jeff Ng <jeffng@precisioninno.com>
Signed-off-by: Jeff Ng <jeffng@precisioninno.com>
4d93d5d to
f95b31b
Compare
Fixed |
piped through read_vcd/read_saif with three new flow variables: