[PATCH] D38586: SLPVectorizer.cpp: Ensure SLPVectorizer can visit each block by dominated order
Davide Italiano via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Oct 6 22:53:35 PDT 2017
davide added inline comments.
================
Comment at: llvm/trunk/lib/Transforms/Vectorize/SLPVectorizer.cpp:3347
// dominating it are visited.
- std::stable_sort(CSEWorkList.begin(), CSEWorkList.end(),
- [this](const DomTreeNode *A, const DomTreeNode *B) {
- return DT->properlyDominates(A, B);
- });
+ // std::sort is unavailable since the comparator is asymmetric.
+ for (auto A = CSEWorkList.begin(), E = CSEWorkList.end(); A != E; ++A)
----------------
this is going to be stale once you have a value numbering to fix this in linear time.
================
Comment at: llvm/trunk/test/Transforms/SLPVectorizer/X86/visit-dominated.ll:2
+; RUN: opt -slp-vectorizer < %s -S | FileCheck %s
+; Ensure the vectorizer can visit each block by dominated order.
+; VEC_VALUE_QUALTYPE should dominate others.
----------------
I'm not sure I understand this comment?
================
Comment at: llvm/trunk/test/Transforms/SLPVectorizer/X86/visit-dominated.ll:4
+; VEC_VALUE_QUALTYPE should dominate others.
+; QUAL1_*(s) may be inducted by VEC_VALUE_QUALTYPE, since their pred is "entry".
+
----------------
what do you mean by `may be inducted` ?
Repository:
rL LLVM
https://reviews.llvm.org/D38586
More information about the llvm-commits
mailing list