rm disconnected pin from exceptions resolves #318
Signed-off-by: James Cherry <cherry@parallaxsw.com>
This commit is contained in:
parent
49dd390d29
commit
5b312ee084
|
|
@ -416,7 +416,7 @@ public:
|
|||
virtual void connectPinAfter(PinSet *,
|
||||
Network *) {}
|
||||
virtual void disconnectPinBefore(const Pin *,
|
||||
Network *) {}
|
||||
Network *);
|
||||
void deleteInstance(const Instance *inst,
|
||||
const Network *network);
|
||||
|
||||
|
|
|
|||
|
|
@ -1054,6 +1054,7 @@ protected:
|
|||
ExceptionPath *findMergeMatch(ExceptionPath *exception);
|
||||
void addException1(ExceptionPath *exception);
|
||||
void addException2(ExceptionPath *exception);
|
||||
void recordExceptionPins(ExceptionPath *exception);
|
||||
void recordPathDelayInternalFrom(ExceptionPath *exception);
|
||||
void unrecordPathDelayInternalFrom(ExceptionPath *exception);
|
||||
bool pathDelayFrom(const Pin *pin);
|
||||
|
|
@ -1369,6 +1370,7 @@ protected:
|
|||
PinExceptionsMap first_to_pin_exceptions_;
|
||||
ClockExceptionsMap first_to_clk_exceptions_;
|
||||
InstanceExceptionsMap first_to_inst_exceptions_;
|
||||
PinExceptionsMap pin_exceptions_;
|
||||
// Edges that traverse hierarchical exception pins.
|
||||
EdgeExceptionsMap first_thru_edge_exceptions_;
|
||||
// Exception hash with one missing from/thru/to point, used for merging.
|
||||
|
|
|
|||
|
|
@ -1155,6 +1155,13 @@ ExceptionFromTo::deleteInstance(const Instance *inst,
|
|||
}
|
||||
}
|
||||
|
||||
void
|
||||
ExceptionFromTo::disconnectPinBefore(const Pin *pin,
|
||||
Network *network)
|
||||
{
|
||||
deletePin(pin, network);
|
||||
}
|
||||
|
||||
const char *
|
||||
ExceptionFromTo::asString(const Network *network) const
|
||||
{
|
||||
|
|
@ -2057,6 +2064,7 @@ void
|
|||
ExceptionThru::disconnectPinBefore(const Pin *pin,
|
||||
Network *network)
|
||||
{
|
||||
deletePin(pin, network);
|
||||
// Remove edges from/to leaf pin and through hier pin.
|
||||
deletePinEdges(pin, network);
|
||||
}
|
||||
|
|
|
|||
38
sdc/Sdc.cc
38
sdc/Sdc.cc
|
|
@ -4601,6 +4601,7 @@ Sdc::recordException(ExceptionPath *exception)
|
|||
exception->setId(++exception_id_);
|
||||
recordMergeHashes(exception);
|
||||
recordExceptionFirstPts(exception);
|
||||
recordExceptionPins(exception);
|
||||
checkForThruHpins(exception);
|
||||
}
|
||||
|
||||
|
|
@ -4671,6 +4672,22 @@ Sdc::recordExceptionFirstFrom(ExceptionPath *exception)
|
|||
recordExceptionClks(exception, from->clks(), first_from_clk_exceptions_);
|
||||
}
|
||||
|
||||
void
|
||||
Sdc::recordExceptionPins(ExceptionPath *exception)
|
||||
{
|
||||
ExceptionFrom *from = exception->from();
|
||||
if (from)
|
||||
recordExceptionPins(exception, from->pins(), pin_exceptions_);
|
||||
ExceptionThruSeq *thrus = exception->thrus();
|
||||
if (thrus) {
|
||||
for (ExceptionThru *thru : *thrus)
|
||||
recordExceptionPins(exception, thru->pins(), pin_exceptions_);
|
||||
}
|
||||
ExceptionTo *to = exception->to();
|
||||
if (to)
|
||||
recordExceptionPins(exception, to->pins(), pin_exceptions_);
|
||||
}
|
||||
|
||||
void
|
||||
Sdc::recordExceptionFirstThru(ExceptionPath *exception)
|
||||
{
|
||||
|
|
@ -5089,7 +5106,8 @@ public:
|
|||
ExpandException(ExceptionPath *exception,
|
||||
ExceptionPathSet &expansions,
|
||||
Network *network);
|
||||
virtual void visit(ExceptionFrom *from, ExceptionThruSeq *thrus,
|
||||
virtual void visit(ExceptionFrom *from,
|
||||
ExceptionThruSeq *thrus,
|
||||
ExceptionTo *to);
|
||||
|
||||
private:
|
||||
|
|
@ -5606,13 +5624,19 @@ Sdc::connectPinAfter(const Pin *pin)
|
|||
void
|
||||
Sdc::disconnectPinBefore(const Pin *pin)
|
||||
{
|
||||
if (have_thru_hpin_exceptions_) {
|
||||
for (ExceptionPath *exception : exceptions_) {
|
||||
auto itr = pin_exceptions_.find(pin);
|
||||
if (itr != pin_exceptions_.end()) {
|
||||
for (ExceptionPath *exception : *itr->second) {
|
||||
ExceptionFrom *from = exception->from();
|
||||
if (from)
|
||||
from->disconnectPinBefore(pin, network_);
|
||||
ExceptionTo *to = exception->to();
|
||||
if (to)
|
||||
to->disconnectPinBefore(pin, network_);
|
||||
ExceptionPt *first_pt = exception->firstPt();
|
||||
ExceptionThruSeq *thrus = exception->thrus();
|
||||
if (thrus) {
|
||||
for (ExceptionThru *thru : *exception->thrus()) {
|
||||
if (thru->edges()) {
|
||||
thru->disconnectPinBefore(pin, network_);
|
||||
if (thru == first_pt)
|
||||
recordExceptionEdges(exception, thru->edges(),
|
||||
|
|
@ -5620,8 +5644,12 @@ Sdc::disconnectPinBefore(const Pin *pin)
|
|||
}
|
||||
}
|
||||
}
|
||||
first_from_pin_exceptions_.erase(pin);
|
||||
first_thru_pin_exceptions_.erase(pin);
|
||||
first_to_pin_exceptions_.erase(pin);
|
||||
pin_exceptions_.erase(pin);
|
||||
}
|
||||
}
|
||||
|
||||
for (int corner_index = 0; corner_index < corners_->count(); corner_index++)
|
||||
drvr_pin_wire_cap_maps_[corner_index].erase(pin);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue