projects
/
oota-llvm.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
4b8e1fd
)
LSR fix: "Special" users are just like "Basic" users but allow -1 scale.
author
Andrew Trick
<atrick@apple.com>
Fri, 15 Jun 2012 20:07:26 +0000
(20:07 +0000)
committer
Andrew Trick
<atrick@apple.com>
Fri, 15 Jun 2012 20:07:26 +0000
(20:07 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@158536
91177308
-0d34-0410-b5e6-
96231b3b80d8
lib/Transforms/Scalar/LoopStrengthReduce.cpp
patch
|
blob
|
history
diff --git
a/lib/Transforms/Scalar/LoopStrengthReduce.cpp
b/lib/Transforms/Scalar/LoopStrengthReduce.cpp
index 94c229a8e2440da07c098ec18102cd6a1bd81b9e..963811ee2798a9cc0f7575752546b3f890c4ad84 100644
(file)
--- a/
lib/Transforms/Scalar/LoopStrengthReduce.cpp
+++ b/
lib/Transforms/Scalar/LoopStrengthReduce.cpp
@@
-1308,8
+1308,8
@@
static bool isLegalUse(const TargetLowering::AddrMode &AM,
return !AM.BaseGV && AM.Scale == 0 && AM.BaseOffs == 0;
case LSRUse::Special:
- //
Only handle -1 scales, or no scale
.
- return
AM.Scale == 0 || AM.Scale == -1
;
+ //
Special case Basic to handle -1 scales
.
+ return
!AM.BaseGV && (AM.Scale == 0 || AM.Scale == -1) && AM.BaseOffs == 0
;
}
llvm_unreachable("Invalid LSRUse Kind!");