Search::pathClkPathArrival1 return PathRef
This commit is contained in:
parent
b9824b62b2
commit
bf3d254fe9
|
|
@ -521,9 +521,7 @@ protected:
|
||||||
bool clk_gating_hold);
|
bool clk_gating_hold);
|
||||||
bool matchesFilterTo(Path *path,
|
bool matchesFilterTo(Path *path,
|
||||||
const ClockEdge *to_clk_edge) const;
|
const ClockEdge *to_clk_edge) const;
|
||||||
void pathClkPathArrival1(const Path *path,
|
PathRef pathClkPathArrival1(const Path *path) const;
|
||||||
// Return value.
|
|
||||||
PathRef &clk_path) const;
|
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -2258,24 +2258,22 @@ Search::clkPathArrival(const Path *clk_path,
|
||||||
Arrival
|
Arrival
|
||||||
Search::pathClkPathArrival(const Path *path) const
|
Search::pathClkPathArrival(const Path *path) const
|
||||||
{
|
{
|
||||||
PathRef src_clk_path;
|
ClkInfo *clk_info = path->clkInfo(this);
|
||||||
pathClkPathArrival1(path, src_clk_path);
|
if (clk_info->isPropagated()) {
|
||||||
if (!src_clk_path.isNull())
|
PathRef src_clk_path = pathClkPathArrival1(path);
|
||||||
return clkPathArrival(&src_clk_path);
|
if (!src_clk_path.isNull())
|
||||||
else {
|
return clkPathArrival(&src_clk_path);
|
||||||
// Check for input arrival clock.
|
|
||||||
ClockEdge *clk_edge = path->clkEdge(this);
|
|
||||||
if (clk_edge)
|
|
||||||
return clk_edge->time();
|
|
||||||
}
|
}
|
||||||
|
// Check for input arrival clock.
|
||||||
|
ClockEdge *clk_edge = path->clkEdge(this);
|
||||||
|
if (clk_edge)
|
||||||
|
return clk_edge->time();
|
||||||
return 0.0;
|
return 0.0;
|
||||||
}
|
}
|
||||||
|
|
||||||
// PathExpanded::expand() and PathExpanded::clkPath().
|
// PathExpanded::expand() and PathExpanded::clkPath().
|
||||||
void
|
PathRef
|
||||||
Search::pathClkPathArrival1(const Path *path,
|
Search::pathClkPathArrival1(const Path *path) const
|
||||||
// Return value.
|
|
||||||
PathRef &clk_path) const
|
|
||||||
{
|
{
|
||||||
PathRef p(path);
|
PathRef p(path);
|
||||||
while (!p.isNull()) {
|
while (!p.isNull()) {
|
||||||
|
|
@ -2283,28 +2281,25 @@ Search::pathClkPathArrival1(const Path *path,
|
||||||
TimingArc *prev_arc;
|
TimingArc *prev_arc;
|
||||||
p.prevPath(this, prev_path, prev_arc);
|
p.prevPath(this, prev_path, prev_arc);
|
||||||
|
|
||||||
if (p.isClock(this)) {
|
if (p.isClock(this))
|
||||||
clk_path.init(p);
|
return p;
|
||||||
return;
|
|
||||||
}
|
|
||||||
if (prev_arc) {
|
if (prev_arc) {
|
||||||
TimingRole *prev_role = prev_arc->role();
|
TimingRole *prev_role = prev_arc->role();
|
||||||
if (prev_role == TimingRole::regClkToQ()
|
if (prev_role == TimingRole::regClkToQ()
|
||||||
|| prev_role == TimingRole::latchEnToQ()) {
|
|| prev_role == TimingRole::latchEnToQ()) {
|
||||||
p.prevPath(this, prev_path, prev_arc);
|
p.prevPath(this, prev_path, prev_arc);
|
||||||
clk_path.init(prev_path);
|
return prev_path;
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
else if (prev_role == TimingRole::latchDtoQ()) {
|
else if (prev_role == TimingRole::latchDtoQ()) {
|
||||||
Edge *prev_edge = p.prevEdge(prev_arc, this);
|
Edge *prev_edge = p.prevEdge(prev_arc, this);
|
||||||
PathVertex enable_path;
|
PathVertex enable_path;
|
||||||
latches_->latchEnablePath(&p, prev_edge, enable_path);
|
latches_->latchEnablePath(&p, prev_edge, enable_path);
|
||||||
clk_path.init(enable_path);
|
return enable_path;
|
||||||
return;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
p.init(prev_path);
|
p.init(prev_path);
|
||||||
}
|
}
|
||||||
|
return PathRef();
|
||||||
}
|
}
|
||||||
|
|
||||||
////////////////////////////////////////////////////////////////
|
////////////////////////////////////////////////////////////////
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue