crpr for clk paths
Signed-off-by: James Cherry <cherry@parallaxsw.com>
This commit is contained in:
parent
a976bbacab
commit
bbffa9b493
|
|
@ -238,25 +238,26 @@ public:
|
||||||
const RiseFall *to_rf,
|
const RiseFall *to_rf,
|
||||||
const MinMax *min_max,
|
const MinMax *min_max,
|
||||||
const PathAnalysisPt *path_ap);
|
const PathAnalysisPt *path_ap);
|
||||||
virtual Tag *thruTag(Tag *from_tag,
|
Tag *thruTag(Tag *from_tag,
|
||||||
Edge *edge,
|
Edge *edge,
|
||||||
const RiseFall *to_rf,
|
const RiseFall *to_rf,
|
||||||
const MinMax *min_max,
|
const MinMax *min_max,
|
||||||
const PathAnalysisPt *path_ap);
|
const PathAnalysisPt *path_ap);
|
||||||
virtual Tag *thruClkTag(PathVertex *from_path,
|
Tag *thruClkTag(PathVertex *from_path,
|
||||||
Tag *from_tag,
|
Tag *from_tag,
|
||||||
bool to_propagates_clk,
|
bool to_propagates_clk,
|
||||||
Edge *edge,
|
Edge *edge,
|
||||||
const RiseFall *to_rf,
|
const RiseFall *to_rf,
|
||||||
const MinMax *min_max,
|
const MinMax *min_max,
|
||||||
const PathAnalysisPt *path_ap);
|
const PathAnalysisPt *path_ap);
|
||||||
ClkInfo *thruClkInfo(PathVertex *from_path,
|
ClkInfo *thruClkInfo(PathVertex *from_path,
|
||||||
ClkInfo *from_tag_clk,
|
ClkInfo *from_clk_info,
|
||||||
Edge *edge,
|
bool from_is_clk,
|
||||||
Vertex *to_vertex,
|
Edge *edge,
|
||||||
const Pin *to_pin,
|
const Pin *to_pin,
|
||||||
const MinMax *min_max,
|
bool to_is_clk,
|
||||||
const PathAnalysisPt *path_ap);
|
const MinMax *min_max,
|
||||||
|
const PathAnalysisPt *path_ap);
|
||||||
ClkInfo *clkInfoWithCrprClkPath(ClkInfo *from_clk_info,
|
ClkInfo *clkInfoWithCrprClkPath(ClkInfo *from_clk_info,
|
||||||
PathVertex *from_path,
|
PathVertex *from_path,
|
||||||
const PathAnalysisPt *path_ap);
|
const PathAnalysisPt *path_ap);
|
||||||
|
|
|
||||||
|
|
@ -54,8 +54,8 @@ public:
|
||||||
const Arrival &insertion() const { return insertion_; }
|
const Arrival &insertion() const { return insertion_; }
|
||||||
ClockUncertainties *uncertainties() const { return uncertainties_; }
|
ClockUncertainties *uncertainties() const { return uncertainties_; }
|
||||||
PathAPIndex pathAPIndex() const { return path_ap_index_; }
|
PathAPIndex pathAPIndex() const { return path_ap_index_; }
|
||||||
// Clock path for the last driver in the clock network used for
|
// Clock path used for crpr resolution.
|
||||||
// crpr resolution.
|
// Null for clocks because the path cannot point to itself.
|
||||||
PathVertexRep &crprClkPath() { return crpr_clk_path_; }
|
PathVertexRep &crprClkPath() { return crpr_clk_path_; }
|
||||||
const PathVertexRep &crprClkPath() const { return crpr_clk_path_; }
|
const PathVertexRep &crprClkPath() const { return crpr_clk_path_; }
|
||||||
VertexId crprClkVertexId() const;
|
VertexId crprClkVertexId() const;
|
||||||
|
|
|
||||||
|
|
@ -152,13 +152,22 @@ CheckCrpr::checkCrpr1(const Path *src_path,
|
||||||
{
|
{
|
||||||
crpr = 0.0;
|
crpr = 0.0;
|
||||||
crpr_pin = nullptr;
|
crpr_pin = nullptr;
|
||||||
ClkInfo *src_clk_info = src_path->tag(this)->clkInfo();
|
const Tag *src_tag = src_path->tag(this);
|
||||||
|
ClkInfo *src_clk_info = src_tag->clkInfo();
|
||||||
ClkInfo *tgt_clk_info = tgt_clk_path->tag(this)->clkInfo();
|
ClkInfo *tgt_clk_info = tgt_clk_path->tag(this)->clkInfo();
|
||||||
const Clock *src_clk = src_clk_info->clock();
|
const Clock *src_clk = src_clk_info->clock();
|
||||||
const Clock *tgt_clk = tgt_clk_info->clock();
|
const Clock *tgt_clk = tgt_clk_info->clock();
|
||||||
const PathVertex src_clk_path1(src_clk_info->crprClkPath(), this);
|
PathVertex src_clk_path1;
|
||||||
const PathVertex *src_clk_path =
|
PathVertexRep &src_crpr_clk_path = src_clk_info->crprClkPath();
|
||||||
src_clk_path1.isNull() ? nullptr : &src_clk_path1;
|
const PathVertex *src_clk_path = nullptr;
|
||||||
|
if (src_tag->isClock()) {
|
||||||
|
src_clk_path1.init(src_path->vertex(this), src_path->tag(this), this);
|
||||||
|
src_clk_path = &src_clk_path1;
|
||||||
|
}
|
||||||
|
else if (!src_crpr_clk_path.isNull()) {
|
||||||
|
src_clk_path1.init(src_crpr_clk_path, this);
|
||||||
|
src_clk_path = &src_clk_path1;
|
||||||
|
}
|
||||||
const MinMax *src_clk_min_max =
|
const MinMax *src_clk_min_max =
|
||||||
src_clk_path ? src_clk_path->minMax(this) : src_path->minMax(this);
|
src_clk_path ? src_clk_path->minMax(this) : src_path->minMax(this);
|
||||||
if (src_clk && tgt_clk
|
if (src_clk && tgt_clk
|
||||||
|
|
|
||||||
|
|
@ -2417,8 +2417,9 @@ Search::thruClkTag(PathVertex *from_path,
|
||||||
&& to_propagates_clk
|
&& to_propagates_clk
|
||||||
&& (role->isWire()
|
&& (role->isWire()
|
||||||
|| role == TimingRole::combinational()));
|
|| role == TimingRole::combinational()));
|
||||||
ClkInfo *to_clk_info = thruClkInfo(from_path, from_clk_info,
|
ClkInfo *to_clk_info = thruClkInfo(from_path, from_clk_info, from_is_clk,
|
||||||
edge, to_vertex, to_pin, min_max, path_ap);
|
edge, to_pin, to_is_clk,
|
||||||
|
min_max, path_ap);
|
||||||
Tag *to_tag = mutateTag(from_tag,from_pin,from_rf,from_is_clk,from_clk_info,
|
Tag *to_tag = mutateTag(from_tag,from_pin,from_rf,from_is_clk,from_clk_info,
|
||||||
to_pin, to_rf, to_is_clk, to_is_reg_clk, false,
|
to_pin, to_rf, to_is_clk, to_is_reg_clk, false,
|
||||||
to_clk_info, nullptr, min_max, path_ap);
|
to_clk_info, nullptr, min_max, path_ap);
|
||||||
|
|
@ -2429,9 +2430,10 @@ Search::thruClkTag(PathVertex *from_path,
|
||||||
ClkInfo *
|
ClkInfo *
|
||||||
Search::thruClkInfo(PathVertex *from_path,
|
Search::thruClkInfo(PathVertex *from_path,
|
||||||
ClkInfo *from_clk_info,
|
ClkInfo *from_clk_info,
|
||||||
|
bool from_is_clk,
|
||||||
Edge *edge,
|
Edge *edge,
|
||||||
Vertex *to_vertex,
|
|
||||||
const Pin *to_pin,
|
const Pin *to_pin,
|
||||||
|
bool to_is_clk,
|
||||||
const MinMax *min_max,
|
const MinMax *min_max,
|
||||||
const PathAnalysisPt *path_ap)
|
const PathAnalysisPt *path_ap)
|
||||||
{
|
{
|
||||||
|
|
@ -2462,7 +2464,7 @@ Search::thruClkInfo(PathVertex *from_path,
|
||||||
|
|
||||||
PathVertex *to_crpr_clk_path = nullptr;
|
PathVertex *to_crpr_clk_path = nullptr;
|
||||||
if (sdc_->crprActive()
|
if (sdc_->crprActive()
|
||||||
&& to_vertex->isRegClk()) {
|
&& from_is_clk && !to_is_clk) {
|
||||||
to_crpr_clk_path = from_path;
|
to_crpr_clk_path = from_path;
|
||||||
changed = true;
|
changed = true;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue