Lines Matching full:clusters
57 std::vector<Cluster> clusters; member in __anon6ad36d800111::CallGraphSort
81 auto res = secToCluster.try_emplace(isec, clusters.size()); in CallGraphSort()
84 clusters.emplace_back(clusters.size(), isec->getSize()); in CallGraphSort()
96 // sections. This is done because otherwise we would end up with clusters in CallGraphSort()
107 clusters[to].weight += weight; in CallGraphSort()
113 Cluster &toC = clusters[to]; in CallGraphSort()
119 for (Cluster &c : clusters) in CallGraphSort()
123 // It's bad to merge clusters which would degrade the density too much.
153 // Group InputSections into clusters using the Call-Chain Clustering heuristic
154 // then sort the clusters by density.
156 std::vector<int> sorted(clusters.size()); in run()
157 std::vector<int> leaders(clusters.size()); in run()
162 return clusters[a].getDensity() > clusters[b].getDensity(); in run()
167 // clusters[L] has not been merged into another cluster yet. in run()
168 Cluster &c = clusters[l]; in run()
178 Cluster *predC = &clusters[predL]; in run()
186 mergeClusters(clusters, *predC, predL, c, l); in run()
189 // Sort remaining non-empty clusters by density. in run()
191 for (int i = 0, e = (int)clusters.size(); i != e; ++i) in run()
192 if (clusters[i].size > 0) in run()
195 return clusters[a].getDensity() > clusters[b].getDensity(); in run()
205 i = clusters[i].next; in run()
232 i = clusters[i].next; in run()
244 // according to the C³ heuristic. All clusters are then sorted by a density