Skip to content

Commit

Permalink
[llvm-exegesis] InstructionBenchmarkClustering::dbScan(): replace std…
Browse files Browse the repository at this point in the history
…::vector<> with std::deque<> in llvm::SetVector<>

Summary:
Old: (D54388)
```
 Performance counter stats for './bin/llvm-exegesis -mode=analysis -analysis-epsilon=100000 -benchmarks-file=/tmp/benchmarks.yaml -analysis-inconsistencies-output-file=/tmp/clusters.html' (10 runs):

       8606.323981      task-clock (msec)         #    1.000 CPUs utilized            ( +-  0.11% )
...
           8.60773 +- 0.00978 seconds time elapsed  ( +-  0.11% )
```
New:
```
 Performance counter stats for './bin/llvm-exegesis -mode=analysis -analysis-epsilon=100000 -benchmarks-file=/tmp/benchmarks.yaml -analysis-inconsistencies-output-file=/tmp/clusters.html' (10 runs):

       7971.403653      task-clock (msec)         #    1.000 CPUs utilized            ( +-  0.14% )
...
            7.9728 +- 0.0113 seconds time elapsed  ( +-  0.14% )
```
Another -~7%.

Reviewers: courbet, MaskRay, RKSimon, gchatelet, john.brawn

Reviewed By: courbet, RKSimon

Subscribers: tschuett, llvm-commits

Differential Revision: https://reviews.llvm.org/D54389

llvm-svn: 347201
  • Loading branch information
LebedevRI committed Nov 19, 2018
1 parent 8aecb0c commit 5c5b1ea
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion llvm/tools/llvm-exegesis/lib/Clustering.cpp
Expand Up @@ -121,7 +121,7 @@ void InstructionBenchmarkClustering::dbScan(const size_t MinPts) {
CurrentCluster.PointIndices.push_back(P);

// Process P's neighbors.
llvm::SetVector<size_t> ToProcess;
llvm::SetVector<size_t, std::deque<size_t>> ToProcess;
ToProcess.insert(Neighbors.begin(), Neighbors.end());
while (!ToProcess.empty()) {
// Retrieve a point from the set.
Expand Down

0 comments on commit 5c5b1ea

Please sign in to comment.