File tree Expand file tree Collapse file tree 1 file changed +6
-3
lines changed
Expand file tree Collapse file tree 1 file changed +6
-3
lines changed Original file line number Diff line number Diff line change @@ -884,8 +884,9 @@ int AntennaChecker::checkGates(odb::dbNet* db_net,
884884 excess_ratio = std::max (violation_info.excess_ratio_PAR ,
885885 violation_info.excess_ratio_PSR );
886886 }
887+ bool to_repair = (diode_mterm != nullptr );
887888 // while it has violation, increase iterm_diff_area
888- if (diode_mterm ) {
889+ if (to_repair ) {
889890 while (par_violation || psr_violation) {
890891 // increasing iterm_diff_area and count
891892 violation_info.iterm_diff_area += diode_diff_area * gates.size ();
@@ -934,8 +935,10 @@ int AntennaChecker::checkGates(odb::dbNet* db_net,
934935 diode_count_per_gate
935936 = std::max (0 , diode_count_per_gate - num_diodes_added[gate]);
936937 num_diodes_added[gate] += diode_count_per_gate;
937- // save antenna violation
938- if (violated && diode_count_per_gate > 0 ) {
938+ // save antenna violation when there is violation and
939+ // if number of diodes is greater than 0 or
940+ // the function is not called to repair antennas
941+ if (violated && (diode_count_per_gate > 0 || !to_repair)) {
939942 antenna_violations.push_back ({layer->getRoutingLevel (),
940943 gates_for_diode_insertion,
941944 diode_count_per_gate,
You can’t perform that action at this time.
0 commit comments