Skip to content

Commit

Permalink
renumber error/warn messages
Browse files Browse the repository at this point in the history
Signed-off-by: James Cherry <[email protected]>
  • Loading branch information
jjcherry56 committed Jan 8, 2024
1 parent 099920f commit 3b721ba
Show file tree
Hide file tree
Showing 55 changed files with 1,035 additions and 1,038 deletions.
28 changes: 14 additions & 14 deletions dcalc/DelayCalc.tcl
Original file line number Diff line number Diff line change
Expand Up @@ -116,7 +116,7 @@ proc set_delay_calculator { alg } {
if { [is_delay_calc_name $alg] } {
set_delay_calculator_cmd $alg
} else {
sta_error 435 "delay calculator $alg not found."
sta_error 180 "delay calculator $alg not found."
}
}

Expand Down Expand Up @@ -145,38 +145,38 @@ proc set_assigned_delay_cmd { cmd cmd_args } {
if [info exists keys(-from)] {
set from_pins [get_port_pins_error "from_pins" $keys(-from)]
} else {
sta_error 442 "$cmd missing -from argument."
sta_error 181 "$cmd missing -from argument."
}
if [info exists keys(-to)] {
set to_pins [get_port_pins_error "to_pins" $keys(-to)]
} else {
sta_error 443 "$cmd missing -to argument."
sta_error 182 "$cmd missing -to argument."
}

set delay [lindex $cmd_args 0]
if {![string is double $delay]} {
sta_error 444 "$cmd delay is not a float."
sta_error 183 "$cmd delay is not a float."
}
set delay [time_ui_sta $delay]

if {[info exists flags(-cell)] && [info exists flags(-net)]} {
sta_error 445 "set_annotated_delay -cell and -net options are mutually excluive."
sta_error 184 "set_annotated_delay -cell and -net options are mutually excluive."
} elseif {[info exists flags(-cell)]} {
if { $from_pins != {} } {
set inst [[lindex $from_pins 0] instance]
foreach pin $from_pins {
if {[$pin instance] != $inst} {
sta_error 446 "$cmd pin [get_full_name $pin] is not attached to instance [get_full_name $inst]."
sta_error 185 "$cmd pin [get_full_name $pin] is not attached to instance [get_full_name $inst]."
}
}
foreach pin $to_pins {
if {[$pin instance] != $inst} {
sta_error 447 "$cmd pin [get_full_name $pin] is not attached to instance [get_full_name $inst]"
sta_error 186 "$cmd pin [get_full_name $pin] is not attached to instance [get_full_name $inst]"
}
}
}
} elseif {![info exists flags(-net)]} {
sta_error 448 "$cmd -cell or -net required."
sta_error 187 "$cmd -cell or -net required."
}
foreach from_pin $from_pins {
set from_vertices [$from_pin vertices]
Expand Down Expand Up @@ -240,7 +240,7 @@ proc set_assigned_check_cmd { cmd cmd_args } {
if { [info exists keys(-from)] } {
set from_pins [get_port_pins_error "from_pins" $keys(-from)]
} else {
sta_error 449 "$cmd missing -from argument."
sta_error 188 "$cmd missing -from argument."
}
set from_rf "rise_fall"
if { [info exists keys(-clock)] } {
Expand All @@ -249,14 +249,14 @@ proc set_assigned_check_cmd { cmd cmd_args } {
|| $clk_arg eq "fall" } {
set from_rf $clk_arg
} else {
sta_error 450 "$cmd -clock must be rise or fall."
sta_error 189 "$cmd -clock must be rise or fall."
}
}

if { [info exists keys(-to)] } {
set to_pins [get_port_pins_error "to_pins" $keys(-to)]
} else {
sta_error 451 "$cmd missing -to argument."
sta_error 190 "$cmd missing -to argument."
}
set to_rf [parse_rise_fall_flags flags]
set corner [parse_corner keys]
Expand All @@ -271,15 +271,15 @@ proc set_assigned_check_cmd { cmd cmd_args } {
} elseif { [info exists flags(-removal)] } {
set role "removal"
} else {
sta_error 452 "$cmd missing -setup|-hold|-recovery|-removal check type.."
sta_error 191 "$cmd missing -setup|-hold|-recovery|-removal check type.."
}
set cond ""
if { [info exists key(-cond)] } {
set cond $key(-cond)
}
set check_value [lindex $cmd_args 0]
if { ![string is double $check_value] } {
sta_error 453 "$cmd check_value is not a float."
sta_error 192 "$cmd check_value is not a float."
}
set check_value [time_ui_sta $check_value]

Expand Down Expand Up @@ -347,7 +347,7 @@ proc set_assigned_transition { args } {

set slew [lindex $args 0]
if {![string is double $slew]} {
sta_error 428 "set_assigned_transition transition is not a float."
sta_error 210 "set_assigned_transition transition is not a float."
}
set slew [time_ui_sta $slew]
set pins [get_port_pins_error "pins" [lindex $args 1]]
Expand Down
4 changes: 2 additions & 2 deletions dcalc/DmpCeff.cc
Original file line number Diff line number Diff line change
Expand Up @@ -1551,7 +1551,7 @@ DmpCeffDelayCalc::gateDelay(const Pin *drvr_pin,
float c2, rpi, c1;
parasitics_->piModel(parasitic, c2, rpi, c1);
if (isnan(c2) || isnan(c1) || isnan(rpi))
report_->error(618, "parasitic Pi model has NaNs.");
report_->error(1040, "parasitic Pi model has NaNs.");
setCeffAlgorithm(drvr_library, drvr_cell, pinPvt(drvr_pin, dcalc_ap),
table_model, rf, in_slew1, c2, rpi, c1);
double gate_delay, drvr_slew;
Expand Down Expand Up @@ -1579,7 +1579,7 @@ DmpCeffDelayCalc::gateDelay(const Pin *drvr_pin,
if (parasitic
&& !unsuppored_model_warned_) {
unsuppored_model_warned_ = true;
report_->warn(1, "cell %s delay model not supported on SPF parasitics by DMP delay calculator",
report_->warn(1041, "cell %s delay model not supported on SPF parasitics by DMP delay calculator",
drvr_cell->name());
}
return dcalc_result;
Expand Down
2 changes: 1 addition & 1 deletion dcalc/GraphDelayCalc.cc
Original file line number Diff line number Diff line change
Expand Up @@ -477,7 +477,7 @@ GraphDelayCalc::findPortIndex(const LibertyCell *cell,
return index;
index++;
}
report_->critical(207, "port not found in cell");
report_->critical(1100, "port not found in cell");
return 0;
}

Expand Down
2 changes: 1 addition & 1 deletion dcalc/LumpedCapDelayCalc.cc
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ LumpedCapDelayCalc::gateDelay(const Pin *drvr_pin,
float in_slew1 = delayAsFloat(in_slew);
// NaNs cause seg faults during table lookup.
if (isnan(load_cap) || isnan(delayAsFloat(in_slew)))
report_->error(710, "gate delay input variable is NaN");
report_->error(1350, "gate delay input variable is NaN");
model->gateDelay(pinPvt(drvr_pin, dcalc_ap), in_slew1, load_cap, pocv_enabled_,
gate_delay, drvr_slew);
return makeResult(drvr_library, rf, gate_delay, drvr_slew, load_pin_index_map);
Expand Down
2 changes: 1 addition & 1 deletion graph/DelayNormal1.cc
Original file line number Diff line number Diff line change
Expand Up @@ -200,7 +200,7 @@ delayAsFloat(const Delay &delay,
else if (early_late == EarlyLate::late())
return delay.mean() + delay.sigma() * sta->sigmaFactor();
else
sta->report()->critical(594, "unknown early/late value.");
sta->report()->critical(1020, "unknown early/late value.");
}
return delay.mean();
}
Expand Down
2 changes: 1 addition & 1 deletion graph/DelayNormal2.cc
Original file line number Diff line number Diff line change
Expand Up @@ -375,7 +375,7 @@ delayAsFloat(const Delay &delay,
else if (early_late == EarlyLate::late())
return delay.mean() + delay.sigma(early_late) * sta->sigmaFactor();
else
sta->report()->critical(595, "unknown early/late value.");
sta->report()->critical(1030, "unknown early/late value.");
}
return delay.mean();
}
Expand Down
8 changes: 4 additions & 4 deletions graph/Graph.cc
Original file line number Diff line number Diff line change
Expand Up @@ -790,7 +790,7 @@ Graph::arcDelayAnnotated(const Edge *edge,
if (arc_delay_annotated_.size()) {
size_t index = (edge->arcDelays() + arc->index()) * ap_count_ + ap_index;
if (index >= arc_delay_annotated_.size())
report_->critical(208, "arc_delay_annotated array bounds exceeded");
report_->critical(1080, "arc_delay_annotated array bounds exceeded");
return arc_delay_annotated_[index];
}
else
Expand All @@ -805,7 +805,7 @@ Graph::setArcDelayAnnotated(Edge *edge,
{
size_t index = (edge->arcDelays() + arc->index()) * ap_count_ + ap_index;
if (index >= arc_delay_annotated_.size())
report_->critical(209, "arc_delay_annotated array bounds exceeded");
report_->critical(1081, "arc_delay_annotated array bounds exceeded");
arc_delay_annotated_[index] = annotated;
}

Expand All @@ -817,7 +817,7 @@ Graph::wireDelayAnnotated(Edge *edge,
size_t index = (edge->arcDelays() + TimingArcSet::wireArcIndex(rf)) * ap_count_
+ ap_index;
if (index >= arc_delay_annotated_.size())
report_->critical(210, "arc_delay_annotated array bounds exceeded");
report_->critical(1082, "arc_delay_annotated array bounds exceeded");
return arc_delay_annotated_[index];
}

Expand All @@ -830,7 +830,7 @@ Graph::setWireDelayAnnotated(Edge *edge,
size_t index = (edge->arcDelays() + TimingArcSet::wireArcIndex(rf)) * ap_count_
+ ap_index;
if (index >= arc_delay_annotated_.size())
report_->critical(228, "arc_delay_annotated array bounds exceeded");
report_->critical(1083, "arc_delay_annotated array bounds exceeded");
arc_delay_annotated_[index] = annotated;
}

Expand Down
12 changes: 6 additions & 6 deletions liberty/Liberty.cc
Original file line number Diff line number Diff line change
Expand Up @@ -763,7 +763,7 @@ LibertyLibrary::makeCornerMap(LibertyCell *cell1,
port1->setCornerPort(port2, ap_index);
}
else
report->warn(2, "cell %s/%s port %s not found in cell %s/%s.",
report->warn(1110, "cell %s/%s port %s not found in cell %s/%s.",
cell1->library()->name(),
cell1->name(),
port_name,
Expand All @@ -789,7 +789,7 @@ LibertyLibrary::makeCornerMap(LibertyCell *cell1,
}
}
else
report->warn(3, "cell %s/%s %s -> %s timing group %s not found in cell %s/%s.",
report->warn(1111, "cell %s/%s %s -> %s timing group %s not found in cell %s/%s.",
cell1->library()->name(),
cell1->name(),
arc_set1->from()->name(),
Expand All @@ -808,7 +808,7 @@ LibertyLibrary::checkCorners(LibertyCell *cell,
for (const Corner *corner : *corners) {
for (auto min_max : MinMax::range()) {
if (!cell->checkCornerCell(corner, min_max))
report->error(705, "Liberty cell %s/%s for corner %s/%s not found.",
report->error(1112, "Liberty cell %s/%s for corner %s/%s not found.",
cell->libertyLibrary()->name(),
cell->name(),
corner->name(),
Expand Down Expand Up @@ -1745,7 +1745,7 @@ LibertyCell::makeLatchEnables(Report *report,
RiseFall *en_rf = latch_enable->enableEdge();
RiseFall *check_rf = check_arc->fromEdge()->asRiseFall();
if (check_rf == en_rf)
report->warn(4, "cell %s/%s %s -> %s latch enable %s_edge is inconsistent with %s -> %s setup_%s check.",
report->warn(1113, "cell %s/%s %s -> %s latch enable %s_edge is inconsistent with %s -> %s setup_%s check.",
library_->name(),
name_,
en->name(),
Expand All @@ -1759,15 +1759,15 @@ LibertyCell::makeLatchEnables(Report *report,
TimingSense en_sense = en_func->portTimingSense(en);
if (en_sense == TimingSense::positive_unate
&& en_rf != RiseFall::rise())
report->warn(5, "cell %s/%s %s -> %s latch enable %s_edge is inconsistent with latch group enable function positive sense.",
report->warn(1114, "cell %s/%s %s -> %s latch enable %s_edge is inconsistent with latch group enable function positive sense.",
library_->name(),
name_,
en->name(),
q->name(),
en_rf == RiseFall::rise()?"rising":"falling");
else if (en_sense == TimingSense::negative_unate
&& en_rf != RiseFall::fall())
report->warn(6, "cell %s/%s %s -> %s latch enable %s_edge is inconsistent with latch group enable function negative sense.",
report->warn(1115, "cell %s/%s %s -> %s latch enable %s_edge is inconsistent with latch group enable function negative sense.",
library_->name(),
name_,
en->name(),
Expand Down
4 changes: 2 additions & 2 deletions liberty/LibertyExpr.cc
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@ LibExprParser::makeFuncExprPort(const char *port_name)
if (port)
expr = FuncExpr::makePort(port);
else
report_->warn(7, "%s references unknown port %s.",
report_->warn(1130, "%s references unknown port %s.",
error_msg_, port_name);
stringDelete(port_name);
return expr;
Expand Down Expand Up @@ -172,7 +172,7 @@ LibExprParser::tokenAppend(char ch)
void
LibExprParser::parseError(const char *msg)
{
report_->error(206, "%s %s.", error_msg_, msg);
report_->error(1131, "%s %s.", error_msg_, msg);
}

} // namespace
Expand Down
Loading

0 comments on commit 3b721ba

Please sign in to comment.