[llvm-commits] [llvm] r66228 - /llvm/branches/Apple/Dib/lib/Transforms/Scalar/ScalarReplAggregates.cpp

Bill Wendling isanbard at gmail.com
Thu Mar 5 17:06:21 PST 2009


Author: void
Date: Thu Mar  5 19:06:20 2009
New Revision: 66228

URL: http://llvm.org/viewvc/llvm-project?rev=66228&view=rev
Log:
--- Merging (from foreign repository) r66227 into '.':
U    lib/Transforms/Scalar/ScalarReplAggregates.cpp

SRThreshold is meant to be inclusive.

Modified:
    llvm/branches/Apple/Dib/lib/Transforms/Scalar/ScalarReplAggregates.cpp

Modified: llvm/branches/Apple/Dib/lib/Transforms/Scalar/ScalarReplAggregates.cpp
URL: http://llvm.org/viewvc/llvm-project/llvm/branches/Apple/Dib/lib/Transforms/Scalar/ScalarReplAggregates.cpp?rev=66228&r1=66227&r2=66228&view=diff

==============================================================================
--- llvm/branches/Apple/Dib/lib/Transforms/Scalar/ScalarReplAggregates.cpp (original)
+++ llvm/branches/Apple/Dib/lib/Transforms/Scalar/ScalarReplAggregates.cpp Thu Mar  5 19:06:20 2009
@@ -260,7 +260,7 @@
     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)) {





More information about the llvm-commits mailing list