summaryrefslogtreecommitdiffstats
path: root/llvm/lib/Transforms
diff options
context:
space:
mode:
authorEvan Cheng <evan.cheng@apple.com>2009-03-06 00:56:43 +0000
committerEvan Cheng <evan.cheng@apple.com>2009-03-06 00:56:43 +0000
commit5fd4fc76bf6f38c330113349da1999c23233221a (patch)
tree078e5a93550f484df93144e9f30f621994e2c217 /llvm/lib/Transforms
parent62d9de7cae3390ec92aab662f3ae0ce793a431f2 (diff)
downloadbcm5719-llvm-5fd4fc76bf6f38c330113349da1999c23233221a.tar.gz
bcm5719-llvm-5fd4fc76bf6f38c330113349da1999c23233221a.zip
SRThreshold is meant to be inclusive.
llvm-svn: 66227
Diffstat (limited to 'llvm/lib/Transforms')
-rw-r--r--llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp b/llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp
index 441b448c010..710bdfb6f7e 100644
--- a/llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp
+++ b/llvm/lib/Transforms/Scalar/ScalarReplAggregates.cpp
@@ -260,7 +260,7 @@ bool SROA::performScalarRepl(Function &F) {
if ((isa<StructType>(AI->getAllocatedType()) ||
isa<ArrayType>(AI->getAllocatedType())) &&
// Do not promote any struct into more than "32" separate vars.
- getNumSAElements(AI->getAllocatedType()) < SRThreshold/4) {
+ getNumSAElements(AI->getAllocatedType()) <= SRThreshold/4) {
// Check that all of the users of the allocation are capable of being
// transformed.
switch (isSafeAllocaToScalarRepl(AI)) {
OpenPOWER on IntegriCloud