[PATCH] D44868: [SLP] Distinguish "demanded and shrinkable" from "demanded and not shrinkable" values when determining the minimum bitwidth
Alexey Bataev via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Mar 26 09:22:38 PDT 2018
ABataev added inline comments.
================
Comment at: lib/Transforms/Vectorize/SLPVectorizer.cpp:4337
+ llvm::all_of(TreeRoot, [](Value *R) {
+ return isa<GetElementPtrInst>(*R->user_begin());
+ })) {
----------------
You can use just `R->user_back()`
================
Comment at: lib/Transforms/Vectorize/SLPVectorizer.cpp:4337
+ llvm::all_of(TreeRoot, [&](Value *R) {
+ return isa<GetElementPtrInst>(*R->user_begin());
+ })) {
----------------
haicheng wrote:
> ABataev wrote:
> > What if only begin use is GEP and others are not?
> I think we've checked earlier that there is only one use here.
Add the assert, please
================
Comment at: test/Transforms/SLPVectorizer/AArch64/ext-trunc.ll:1
+; RUN: opt -S -slp-vectorizer -instcombine < %s | FileCheck %s
+
----------------
haicheng wrote:
> lebedev.ri wrote:
> > haicheng wrote:
> > > ABataev wrote:
> > > > 1. Commit this test separately as NFC with checks for the current version of the compiler.
> > > > 2. Generate test checks using `utils/update_test_checks.py`
> > > I will commit the separately.
> > > > Commit this test separately as NFC with checks for the current version of the compiler.
> >
> > > I will commit the separately.
> >
> > What i think was meant is, commit the test now, and rebase the differential ontop of that commit,
> > so the diff actually shows what this differential changes in the testcase.
> Thank you for pointing this out. I am working on it now.
That's right
Repository:
rL LLVM
https://reviews.llvm.org/D44868
More information about the llvm-commits
mailing list