Skip to content

Commit 9933fc6

Browse files
make a paragraph in the big picture comment of PlacerCriticalities more clear
1 parent ec00c1e commit 9933fc6

File tree

2 files changed

+14
-17
lines changed

2 files changed

+14
-17
lines changed

vpr/src/place/timing/PlacerCriticalities.cpp

Lines changed: 0 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -13,16 +13,6 @@ PlacerCriticalities::PlacerCriticalities(const ClusteredNetlist& clb_nlist,
1313
, timing_place_crit_(make_net_pins_matrix(clb_nlist_, std::numeric_limits<float>::quiet_NaN())) {
1414
}
1515

16-
/**
17-
* @brief Updated the criticalities in the timing_place_crit_ data structure.
18-
*
19-
* If the criticalities are not updated immediately after each time we call
20-
* timing_info->update(), then timing_info->pins_with_modified_setup_criticality()
21-
* cannot accurately account for all the pins that need to be updated. In this case,
22-
* `recompute_required` would be true, and we update all criticalities from scratch.
23-
*
24-
* If the criticality exponent has changed, we also need to update from scratch.
25-
*/
2616
void PlacerCriticalities::update_criticalities(const PlaceCritParams& crit_params) {
2717
// If update is not enabled, exit the routine.
2818
if (!update_enabled) {

vpr/src/place/timing/PlacerCriticalities.h

Lines changed: 14 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -33,14 +33,15 @@ struct PlaceCritParams {
3333
*
3434
* This process can be done incrementally, based on the modified connections/AtomPinIds
3535
* returned by SetupTimingInfo. However, the set returned only reflects the connections
36-
* changed by the last call to the timing info update.
36+
* changed by the last call to the timing info update (update_setup() method of SetupTimingInfo).
3737
*
38-
* Therefore, if SetupTimingInfo is updated twice in succession without criticalities
39-
* getting updated (update_enabled = false), the returned set cannot account for all
40-
* the connections that have been modified. In this case, we flag `recompute_required`
41-
* as false, and we recompute the criticalities for every connection to ensure that
42-
* they are all up to date. Hence, each time update_setup_slacks_and_criticalities()
43-
* is called, we assign `recompute_required` the opposite value of `update_enabled`.
38+
* Therefore, if SetupTimingInfo is updated twice in a row without criticalities
39+
* getting updated after the first update of SetupTimingInfo (PlacerCriticalities::update_enabled = false),
40+
* the returned set of modified connections/AtomPinIds by SetupTimingInfo after its second update does not
41+
* account for all the connections that have been modified.
42+
* To address this issue, whenever update_criticalities() is called with flag update_enabled = false,
43+
* we don't update criticalities and set flag recompute_required to true to remember that criticalities
44+
* need to be recomputed from scratch in the first call to update_criticalities() with update_enabled = true.
4445
*
4546
* This class also maps/transforms the modified atom connections/pins returned by the
4647
* timing info into modified clustered netlist connections/pins after calling
@@ -115,6 +116,12 @@ class PlacerCriticalities {
115116
* keep the criticalities stored in this class in sync with the timing analyzer.
116117
* If out of sync, then the criticalities cannot be incrementally updated on
117118
* during the next timing analysis iteration.
119+
*
120+
* If the criticalities are not updated immediately after each time we call
121+
* timing_info->update(), then timing_info->pins_with_modified_setup_criticality()
122+
* cannot accurately account for all the pins that need to be updated. In this case,
123+
* `recompute_required` would be true, and we update all criticalities from scratch.
124+
* If the criticality exponent has changed, we also need to update from scratch.
118125
*/
119126
void update_criticalities(const PlaceCritParams& crit_params);
120127

0 commit comments

Comments
 (0)