From db3a1dd6e6c345cb9d8f39027dc482921df3af70 Mon Sep 17 00:00:00 2001 From: James Cherry Date: Thu, 13 Nov 2025 10:31:43 -0700 Subject: [PATCH] disconnect_pin do not delete pin from exceptions Signed-off-by: James Cherry --- include/sta/ExceptionPath.hh | 12 ++++++------ include/sta/Sdc.hh | 2 +- sdc/ExceptionPath.cc | 8 ++++---- sdc/Sdc.cc | 8 ++++---- search/Sta.cc | 1 - test/disconnect_mcp_pin.ok | 16 ++++++++-------- 6 files changed, 23 insertions(+), 24 deletions(-) diff --git a/include/sta/ExceptionPath.hh b/include/sta/ExceptionPath.hh index 267b5653..c1c09978 100644 --- a/include/sta/ExceptionPath.hh +++ b/include/sta/ExceptionPath.hh @@ -355,8 +355,8 @@ public: const Network *network) = 0; virtual void connectPinAfter(PinSet *, Network *network) = 0; - virtual void disconnectPinBefore(const Pin *pin, - Network *network) = 0; + virtual void deletePinBefore(const Pin *pin, + Network *network) = 0; protected: const RiseFallBoth *rf_; @@ -415,8 +415,8 @@ public: const Network *) {} virtual void connectPinAfter(PinSet *, Network *) {} - virtual void disconnectPinBefore(const Pin *, - Network *); + virtual void deletePinBefore(const Pin *, + Network *); void deleteInstance(const Instance *inst, const Network *network); @@ -537,8 +537,8 @@ public: virtual size_t objectCount() const; virtual void connectPinAfter(PinSet *drvrs, Network *network); - virtual void disconnectPinBefore(const Pin *pin, - Network *network); + virtual void deletePinBefore(const Pin *pin, + Network *network); void deleteInstance(const Instance *inst, const Network *network); diff --git a/include/sta/Sdc.hh b/include/sta/Sdc.hh index 580303dc..b14e10cc 100644 --- a/include/sta/Sdc.hh +++ b/include/sta/Sdc.hh @@ -1027,7 +1027,7 @@ public: void removeGraphAnnotations(); // Network edit before/after methods. - void disconnectPinBefore(const Pin *pin); + void deletePinBefore(const Pin *pin); void connectPinAfter(const Pin *pin); void clkHpinDisablesChanged(const Pin *pin); void makeClkHpinDisable(const Clock *clk, diff --git a/sdc/ExceptionPath.cc b/sdc/ExceptionPath.cc index 2d4ccbf3..163dcf65 100644 --- a/sdc/ExceptionPath.cc +++ b/sdc/ExceptionPath.cc @@ -1166,8 +1166,8 @@ ExceptionFromTo::deleteInstance(const Instance *inst, } void -ExceptionFromTo::disconnectPinBefore(const Pin *pin, - Network *network) +ExceptionFromTo::deletePinBefore(const Pin *pin, + Network *network) { deletePin(pin, network); } @@ -2080,8 +2080,8 @@ ExceptionThru::makePinEdges(const Pin *pin, } void -ExceptionThru::disconnectPinBefore(const Pin *pin, - Network *network) +ExceptionThru::deletePinBefore(const Pin *pin, + Network *network) { deletePin(pin, network); // Remove edges from/to leaf pin and through hier pin. diff --git a/sdc/Sdc.cc b/sdc/Sdc.cc index 1522bbcf..daca9186 100644 --- a/sdc/Sdc.cc +++ b/sdc/Sdc.cc @@ -5685,22 +5685,22 @@ Sdc::connectPinAfter(const Pin *pin) } void -Sdc::disconnectPinBefore(const Pin *pin) +Sdc::deletePinBefore(const Pin *pin) { 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_); + from->deletePinBefore(pin, network_); ExceptionTo *to = exception->to(); if (to) - to->disconnectPinBefore(pin, network_); + to->deletePinBefore(pin, network_); ExceptionPt *first_pt = exception->firstPt(); ExceptionThruSeq *thrus = exception->thrus(); if (thrus) { for (ExceptionThru *thru : *exception->thrus()) { - thru->disconnectPinBefore(pin, network_); + thru->deletePinBefore(pin, network_); if (thru == first_pt) recordExceptionEdges(exception, thru->edges(), first_thru_edge_exceptions_); diff --git a/search/Sta.cc b/search/Sta.cc index d51ecae9..ae9c220b 100644 --- a/search/Sta.cc +++ b/search/Sta.cc @@ -4477,7 +4477,6 @@ Sta::disconnectPinBefore(const Pin *pin) sdc_network_->pathName(pin), sdc_network_->pathName(network_->net(pin))); parasitics_->disconnectPinBefore(pin, network_); - sdc_->disconnectPinBefore(pin); sim_->disconnectPinBefore(pin); if (graph_) { if (network_->isDriver(pin)) { diff --git a/test/disconnect_mcp_pin.ok b/test/disconnect_mcp_pin.ok index 19c4fede..a0645c2b 100644 --- a/test/disconnect_mcp_pin.ok +++ b/test/disconnect_mcp_pin.ok @@ -44,16 +44,16 @@ Path Type: max 0.00 510.00 ^ u1/A (BUFx2_ASAP7_75t_R) 510.00 data arrival time - 250.00 250.00 clock clk (fall edge) - 0.00 250.00 clock network delay (propagated) - 0.00 250.00 clock reconvergence pessimism - 250.00 v clk (in) - -10.00 240.00 data check setup time - 240.00 data required time + 750.00 750.00 clock clk (fall edge) + 0.00 750.00 clock network delay (propagated) + 0.00 750.00 clock reconvergence pessimism + 750.00 v clk (in) + -10.00 740.00 data check setup time + 740.00 data required time --------------------------------------------------------- - 240.00 data required time + 740.00 data required time -510.00 data arrival time --------------------------------------------------------- - -270.00 slack (VIOLATED) + 230.00 slack (MET)