Skip to content
  1. Nov 01, 2012
    • Chandler Carruth's avatar
      Revert the series of commits starting with r166578 which introduced the · 7ec5085e
      Chandler Carruth authored
      getIntPtrType support for multiple address spaces via a pointer type,
      and also introduced a crasher bug in the constant folder reported in
      PR14233.
      
      These commits also contained several problems that should really be
      addressed before they are re-committed. I have avoided reverting various
      cleanups to the DataLayout APIs that are reasonable to have moving
      forward in order to reduce the amount of churn, and minimize the number
      of commits that were reverted. I've also manually updated merge
      conflicts and manually arranged for the getIntPtrType function to stay
      in DataLayout and to be defined in a plausible way after this revert.
      
      Thanks to Duncan for working through this exact strategy with me, and
      Nick Lewycky for tracking down the really annoying crasher this
      triggered. (Test case to follow in its own commit.)
      
      After discussing with Duncan extensively, and based on a note from
      Micah, I'm going to continue to back out some more of the more
      problematic patches in this series in order to ensure we go into the
      LLVM 3.2 branch with a reasonable story here. I'll send a note to
      llvmdev explaining what's going on and why.
      
      Summary of reverted revisions:
      
      r166634: Fix a compiler warning with an unused variable.
      r166607: Add some cleanup to the DataLayout changes requested by
               Chandler.
      r166596: Revert "Back out r166591, not sure why this made it through
               since I cancelled the command. Bleh, sorry about this!
      r166591: Delete a directory that wasn't supposed to be checked in yet.
      r166578: Add in support for getIntPtrType to get the pointer type based
               on the address space.
      llvm-svn: 167221
      7ec5085e
    • Jakub Staszak's avatar
      4e45abf0
  2. Oct 31, 2012
  3. Oct 30, 2012
  4. Oct 29, 2012
  5. Oct 27, 2012
  6. Oct 25, 2012
    • Chandler Carruth's avatar
      Teach SROA how to split whole-alloca integer loads and stores into · 58d05567
      Chandler Carruth authored
      smaller integer loads and stores.
      
      The high-level motivation is that the frontend sometimes generates
      a single whole-alloca integer load or store during ABI lowering of
      splittable allocas. We need to be able to break this apart in order to
      see the underlying elements and properly promote them to SSA values. The
      hope is that this fixes some performance regressions on x86-32 with the
      new SROA pass.
      
      Unfortunately, this causes quite a bit of churn in the test cases, and
      bloats some IR that comes out. When we see an alloca that consists soley
      of bits and bytes being extracted and re-inserted, we now do some
      splitting first, before building widened integer "bucket of bits"
      representations. These are always well folded by instcombine however, so
      this shouldn't actually result in missed opportunities.
      
      If this splitting of all-integer allocas does cause problems (perhaps
      due to smaller SSA values going into the RA), we could potentially go to
      some extreme measures to only do this integer splitting trick when there
      are non-integer component accesses of an alloca, but discovering this is
      quite expensive: it adds yet another complete walk of the recursive use
      tree of the alloca.
      
      Either way, I will be watching build bots and LNT bots to see what
      fallout there is here. If anyone gets x86-32 numbers before & after this
      change, I would be very interested.
      
      llvm-svn: 166662
      58d05567
  7. Oct 24, 2012
  8. Oct 23, 2012
  9. Oct 22, 2012
  10. Oct 21, 2012
    • Benjamin Kramer's avatar
      Revert r166390 "LoopIdiom: Replace custom dependence analysis with LoopDependenceAnalysis." · f77f224d
      Benjamin Kramer authored
      It passes all tests, produces better results than the old code but uses the
      wrong pass, LoopDependenceAnalysis, which is old and unmaintained. "Why is it
      still in tree?", you might ask. The answer is obviously: "To confuse developers."
      
      Just swapping in the new dependency pass sends the pass manager into an infinte
      loop, I'll try to figure out why tomorrow.
      
      llvm-svn: 166399
      f77f224d
    • Benjamin Kramer's avatar
      LoopIdiom: Replace custom dependence analysis with LoopDependenceAnalysis. · 3ae8bc68
      Benjamin Kramer authored
      Requires a lot less code and complexity on loop-idiom's side and the more
      precise analysis can catch more cases, like the one I included as a test case.
      This also fixes the edge-case miscompilation from PR9481. I'm not entirely
      sure that all cases are handled that the old checks handled but LDA will
      certainly become smarter in the future.
      
      llvm-svn: 166390
      3ae8bc68
  11. Oct 20, 2012
  12. Oct 19, 2012
  13. Oct 18, 2012
    • Meador Inge's avatar
      instcombine: Migrate strcpy optimizations · 000dbccf
      Meador Inge authored
      This patch migrates the strcpy optimizations from the simplify-libcalls pass
      into the instcombine library call simplifier.  Note also that StrCpyChkOpt
      has been updated with a few simplifications that were being done in the
      simplify-libcalls version of StrCpyOpt, but not in the migrated implementation
      of StrCpyOpt.  There is no reason to overload StrCpyOpt with fortified and
      regular simplifications in the new model since there is already a dedicated
      simplifier for __strcpy_chk.
      
      llvm-svn: 166198
      000dbccf
    • Chandler Carruth's avatar
      Refactor insert and extract of sub-integers into static helpers that · 59ff93af
      Chandler Carruth authored
      operate purely on values. Sink the alloca loading and storing logic into
      the rewrite routines that are specific to alloca-integer-rewrite
      driving. This is just a refactoring here, but the subsequent step will
      be to reuse the insertion and extraction logic when rewriting integer
      loads and stores that have been split and decomposed into narrower loads
      and stores.
      
      No functionality changed other than different names for instructions.
      
      llvm-svn: 166176
      59ff93af
    • Chandler Carruth's avatar
      This FIXME was fixed some time ago. =] · e793a50f
      Chandler Carruth authored
      llvm-svn: 166175
      e793a50f
    • Bob Wilson's avatar
      Temporarily revert the TargetTransform changes. · d6d9ccca
      Bob Wilson authored
      The TargetTransform changes are breaking LTO bootstraps of clang.  I am
      working with Nadav to figure out the problem, but I am reverting it for now
      to get our buildbots working.
      
      This reverts svn commits: 165665 165669 165670 165786 165787 165997
      and I have also reverted clang svn 165741
      
      llvm-svn: 166168
      d6d9ccca
  14. Oct 17, 2012
    • Chandler Carruth's avatar
      This just in, it is a *bad idea* to use 'udiv' on an offset of · 6fab42aa
      Chandler Carruth authored
      a pointer. A very bad idea. Let's not do that. Fixes PR14105.
      
      Note that this wasn't *that* glaring of an oversight. Originally, these
      routines were only called on offsets within an alloca, which are
      intrinsically positive. But over the evolution of the pass, they ended
      up being called for arbitrary offsets, and things went downhill...
      
      llvm-svn: 166095
      6fab42aa
    • Chandler Carruth's avatar
      Fix a really annoying "bug" introduced in r165941. The change from that · 40617f59
      Chandler Carruth authored
      revision makes no sense. We cannot use the address space of the *post
      indexed* type to conclude anything about a *pre indexed* pointer type's
      size. More importantly, this index can never be over a pointer. We are
      indexing over arrays and vectors here.
      
      Of course, I have no test case here. Neither did the original patch. =/
      
      llvm-svn: 166091
      40617f59
  15. Oct 16, 2012
Loading