Skip to content
  1. Aug 04, 2015
  2. Aug 03, 2015
    • David Blaikie's avatar
      Fix with a bit more care. (but only a bit) · 871b4113
      David Blaikie authored
      llvm-svn: 243903
      871b4113
    • Chandler Carruth's avatar
      [Unroll] Improve the brute force loop unroll estimate by propagating · 87adb7a2
      Chandler Carruth authored
      through PHI nodes across iterations.
      
      This patch teaches the new advanced loop unrolling heuristics to propagate
      constants into the loop from the preheader and around the backedge after
      simulating each iteration. This lets us brute force solve simple recurrances
      that aren't modeled effectively by SCEV. It also makes it more clear why we
      need to process the loop in-order rather than bottom-up which might otherwise
      make much more sense (for example, for DCE).
      
      This came out of an attempt I'm making to develop a principled way to account
      for dead code in the unroll estimation. When I implemented
      a forward-propagating version of that it produced incorrect results due to
      failing to propagate *cost* between loop iterations through the PHI nodes, and
      it occured to me we really should at least propagate simplifications across
      those edges, and it is quite easy thanks to the loop being in canonical and
      LCSSA form.
      
      Differential Revision: http://reviews.llvm.org/D11706
      
      llvm-svn: 243900
      87adb7a2
    • David Blaikie's avatar
      69374412
    • David Blaikie's avatar
      -Wdeprecated-clean: Fix cases of violating the rule of 5 in ways that are deprecated in C++11 · e44a8a70
      David Blaikie authored
      Some functions return concrete ByteStreamers by value - explicitly
      support that in the base class. (dtor can be virtual, no one seems to be
      polymorphically owning/destroying them)
      
      llvm-svn: 243897
      e44a8a70
    • David Blaikie's avatar
      Recommit r243824: -Wdeprecated-clean: Fix cases of violating the rule of 5 in... · adbda4b9
      David Blaikie authored
      Recommit r243824: -Wdeprecated-clean: Fix cases of violating the rule of 5 in ways that are deprecated in C++11
      
      This reverts commit r243888, recommitting r243824.
      
      This broke the Windows build due to a difference in the C++ standard
      library implementation. Using emplace/forward_as_tuple should ensure
      there's no need to copy ValIDs.
      
      llvm-svn: 243896
      adbda4b9
    • Pete Cooper's avatar
      Convert some AArch64 code to foreach loops. NFC. · 7be8f8f0
      Pete Cooper authored
      Also converted a cast<> to dyn_cast while i was working on the same
      line of code.
      
      llvm-svn: 243894
      7be8f8f0
    • Reid Kleckner's avatar
      Revert "-Wdeprecated-clean: Fix cases of violating the rule of 5 in ways that... · e28b9cbd
      Reid Kleckner authored
      Revert "-Wdeprecated-clean: Fix cases of violating the rule of 5 in ways that are deprecated in C++11"
      
      This reverts commit r243824.
      
      It broke the build on Windows.
      
      llvm-svn: 243888
      e28b9cbd
    • Duncan P. N. Exon Smith's avatar
      DI: Disallow uniquable DICompileUnits · 55ca964e
      Duncan P. N. Exon Smith authored
      Since r241097, `DIBuilder` has only created distinct `DICompileUnit`s.
      The backend is liable to start relying on that (if it hasn't already),
      so make uniquable `DICompileUnit`s illegal and automatically upgrade old
      bitcode.  This is a nice cleanup, since we can remove an unnecessary
      `DenseSet` (and the associated uniquing info) from `LLVMContextImpl`.
      
      Almost all the testcases were updated with this script:
      
          git grep -e '= !DICompileUnit' -l -- test |
          grep -v test/Bitcode |
          xargs sed -i '' -e 's,= !DICompileUnit,= distinct !DICompileUnit,'
      
      I imagine something similar should work for out-of-tree testcases.
      
      llvm-svn: 243885
      55ca964e
    • Tim Northover's avatar
      ARM: prefer allocating VFP regs at stride 4 on Darwin. · 910dde7a
      Tim Northover authored
      This is necessary for WatchOS support, where the compact unwind format assumes
      this kind of layout. For now we only want this on Swift-like CPUs though, where
      it's been the Xcode behaviour for ages. Also, since it can expand the prologue
      we don't want it at -Oz.
      
      llvm-svn: 243884
      910dde7a
    • Duncan P. N. Exon Smith's avatar
      Linker: Move distinct MDNodes instead of cloning · 4fb46cb8
      Duncan P. N. Exon Smith authored
      Instead of cloning distinct `MDNode`s when linking in a module, just
      move them over.  The module linker destroys the source module, so the
      old node would otherwise just be leaked on the context.  Create the new
      node in place.  This also reduces the number of cloned uniqued nodes
      (since it's less likely their operands have changed).
      
      This mapping strategy is only correct when we're discarding the source,
      so the linker turns it on via a ValueMapper flag, `RF_MoveDistinctMDs`.
      
      There's nothing observable in terms of `llvm-link` output here: the
      linked module should be semantically identical.
      
      I'll be adding more 'distinct' nodes to the debug info metadata graph in
      order to break uniquing cycles, so the benefits of this will partly come
      in future commits.  However, we should get some gains immediately, since
      we have a fair number of 'distinct' `DILocation`s being linked in.
      
      llvm-svn: 243883
      4fb46cb8
    • JF Bastien's avatar
      Refactor AtomicExpand::expandAtomicRMWToCmpXchg into a standalone function. · e8aad299
      JF Bastien authored
      Summary:
      This is useful for PNaCl's `RewriteAtomics` pass. NaCl intrinsics don't exist for some of the more exotic RMW instructions, so by refactoring this function into its own, `RewriteAtomics` can share code rewriting those atomics with `AtomicExpand` while additionally saving a few cycles by generating the `cmpxchg` NaCl-specific intrinsic with the callback. Without this patch, `RewriteAtomics` would require two extra passes over functions, by first requiring use of the full `AtomicExpand` pass to just expand the leftover exotic RMWs and then running itself again to expand resulting `cmpxchg`s.
      
      NFC
      
      Reviewers: jfb
      
      Subscribers: jfb, llvm-commits
      
      Differential Revision: http://reviews.llvm.org/D11422
      
      llvm-svn: 243880
      e8aad299
    • Artur Pilipenko's avatar
      Currently string attributes on function arguments/return values can be... · 17376c4e
      Artur Pilipenko authored
      Currently string attributes on function arguments/return values can be generated using LLVM API. However they are not supported in parser. So, the following scenario will fail:
      * generate function with string attribute using API,
      * dump it in LL format,
      * try to parse.
      Add parser support for string attributes to fix the issue.
      
      Reviewed By: reames, hfinkel
      
      Differential Revision: http://reviews.llvm.org/D11058
      
      llvm-svn: 243877
      17376c4e
    • John Brawn's avatar
      [ARM] Make GlobalMerge merge extern globals by default · f3324cf1
      John Brawn authored
      Enabling merging of extern globals appears to be generally either beneficial or
      harmless. On some benchmarks suites (on Cortex-M4F, Cortex-A9, and Cortex-A57)
      it gives improvements in the 1-5% range, but in the rest the overall effect is
      zero.
      
      Differential Revision: http://reviews.llvm.org/D10966
      
      llvm-svn: 243874
      f3324cf1
    • John Brawn's avatar
      [GlobalMerge] Allow targets to enable merging of extern variables, NFC. · 8b954241
      John Brawn authored
      Adjust the GlobalMergeOnExternal option so that the default behaviour is to
      do whatever the Target thinks is best. Explicitly enabled or disabling the
      option will override this default.
      
      Differential Revision: http://reviews.llvm.org/D10965
      
      llvm-svn: 243873
      8b954241
    • James Molloy's avatar
      Be less conservative about forming IT blocks. · 6967e5e4
      James Molloy authored
      In http://reviews.llvm.org/rL215382, IT forming was made more conservative under
      the belief that a flag-setting instruction was unpredictable inside an IT block on ARMv6M.
      
      But actually, ARMv6M doesn't even support IT blocks so that's impossible. In the ARMARM for
      v7M, v7AR and v8AR it states that the semantics of such an instruction changes inside an
      IT block - it doesn't set the flags. So actually it is fine to use one inside an IT block
      as long as the flags register is dead afterwards.
      
      This gives significant performance improvements in a variety of MPEG based workloads.
      
      Differential revision: http://reviews.llvm.org/D11680
      
      llvm-svn: 243869
      6967e5e4
    • Duncan P. N. Exon Smith's avatar
      ValueMapper: Only check for cycles if operands change · 50f8969e
      Duncan P. N. Exon Smith authored
      This is a minor optimization to only check for unresolved operands
      inside `mapDistinctNode()` if the operands have actually changed.  This
      shouldn't really cause any change in behaviour.  I didn't actually see a
      slowdown in a profile, I was just poking around nearby and saw the
      opportunity.
      
      llvm-svn: 243866
      50f8969e
Loading