[PATCH] D67383: Add new optimization pass of Tree-Height-Reduction

Mandeep Singh Grang via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Sep 10 15:12:15 PDT 2019


mgrang added inline comments.


================
Comment at: lib/Transforms/Scalar/TreeHeightReduction.cpp:654
+  while (Leaves.size() > 1) {
+    std::sort(Leaves.begin(), Leaves.end(),
+              [] (Node *LHS, Node *RHS) -> bool {
----------------
Please use the range-based llvm::sort function here. See https://llvm.org/docs/CodingStandards.html#beware-of-non-deterministic-sorting-order-of-equal-elements.

```
llvm::sort(Leaves);
```


Repository:
  rL LLVM

CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D67383/new/

https://reviews.llvm.org/D67383





More information about the llvm-commits mailing list