[PATCH] D67510: [LV] Support gaps, overlaps, and inexact sizes in speculation logic
Ayal Zaks via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Sun Sep 15 02:04:56 PDT 2019
Ayal added inline comments.
================
Comment at: lib/Analysis/Loads.cpp:225
+ APInt StepC = Step->getAPInt();
+ // Stide of zero is a degenerate cases, avoid
+ // TODO: Negative strides require computing the base to query from
----------------
St[r]ide of zero should be covered by the loop-invariant case above.
================
Comment at: lib/Analysis/Loads.cpp:226
+ // Stide of zero is a degenerate cases, avoid
+ // TODO: Negative strides require computing the base to query from
+ if (!StepC.isStrictlyPositive())
----------------
Worth adding test with negative step?
================
Comment at: lib/Analysis/Loads.cpp:254
- // For the moment, restrict ourselves to the case where the access size is a
- // multiple of the requested alignment and the base is aligned.
- // TODO: generalize if a case found which warrants
- if (EltSize.urem(Align) != 0)
+ // If the base is aligned, and the step is multiple of the alignment, then
+ // the address at each iteration is aligned. (Note: Alignment may be less
----------------
This "if" condition is both necessary and sufficient ("iff"); i.e., nothing TODO/generalize, right?
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D67510/new/
https://reviews.llvm.org/D67510
More information about the llvm-commits
mailing list