Skip to content
  1. Apr 29, 2018
    • Craig Topper's avatar
      [X86] Use getX86SubSuperRegister in addGR32orGR64Operands in the AsmParser... · a3f52aaa
      Craig Topper authored
      [X86] Use getX86SubSuperRegister in addGR32orGR64Operands in the AsmParser instead of duplicating its functionality. NFC
      
      llvm-svn: 331128
      a3f52aaa
    • Nico Weber's avatar
      s/LLVM_ON_WIN32/_WIN32/, llvm · 712e8d29
      Nico Weber authored
      LLVM_ON_WIN32 is set exactly with MSVC and MinGW (but not Cygwin) in
      HandleLLVMOptions.cmake, which is where _WIN32 defined too.  Just use the
      default macro instead of a reinvented one.
      
      See thread "Replacing LLVM_ON_WIN32 with just _WIN32" on llvm-dev and cfe-dev.
      No intended behavior change.
      
      This moves over all uses of the macro, but doesn't remove the definition
      of it in (llvm-)config.h yet.
      
      llvm-svn: 331127
      712e8d29
    • Robert Widmann's avatar
      [LLVM-C] Add DIBuilder bindings to create import declarations · aec494f3
      Robert Widmann authored
      Summary: Add bindings to create import declarations for modules, functions, types, and other entities.  This wraps the conveniences available in the existing DIBuilder API, but these seem C++-specific.
      
      Reviewers: whitequark, harlanhaskins, deadalnix
      
      Reviewed By: whitequark
      
      Subscribers: llvm-commits
      
      Differential Revision: https://reviews.llvm.org/D46167
      
      llvm-svn: 331123
      aec494f3
  2. Apr 28, 2018
  3. Apr 27, 2018
    • Reid Kleckner's avatar
      [FastISel] Actually enable local value sinking by default · efc0f8cb
      Reid Kleckner authored
      llvm-svn: 331088
      efc0f8cb
    • Reid Kleckner's avatar
      [FastISel] Fix local value sinking algorithmic complexity · a28e767f
      Reid Kleckner authored
      Now local value sinking only scans and numbers instructions added
      between the current flush point and the last flush point. This ensures
      that ISel is overall linear in the size of the BB.
      
      Fixes PR37010 and re-enables local value sinking by default.
      
      llvm-svn: 331087
      a28e767f
    • Adrian Prantl's avatar
      Fix a bug in GlobalOpt's handling of DIExpressions. · 210a29de
      Adrian Prantl authored
      This patch adds support for fragment expressions
      TryToShrinkGlobalToBoolean() which were previously just dropped.
      
      Thanks to Reid Kleckner for providing me a reproducer!
      
      llvm-svn: 331086
      210a29de
    • Roman Lebedev's avatar
      [PatternMatch] Stabilize the matching order of commutative matchers · 6959b8e7
      Roman Lebedev authored
      Summary:
      Currently, we
      1. match `LHS` matcher to the `first` operand of binary operator,
      2. and then match `RHS` matcher to the `second` operand of binary operator.
      If that does not match, we swap the `LHS` and `RHS` matchers:
      1. match `RHS` matcher to the `first` operand of binary operator,
      2. and then match `LHS` matcher to the `second` operand of binary operator.
      
      This works ok.
      But it complicates writing of commutative matchers, where one would like to match
      (`m_Value()`) the value on one side, and use (`m_Specific()`) it on the other side.
      
      This is additionally complicated by the fact that `m_Specific()` stores the `Value *`,
      not `Value **`, so it won't work at all out of the box.
      
      The last problem is trivially solved by adding a new `m_c_Specific()` that stores the
      `Value **`, not `Value *`. I'm choosing to add a new matcher, not change the existing
      one because i guess all the current users are ok with existing behavior,
      and this additional pointer indirection may have performance drawbacks.
      Also, i'm storing pointer, not reference, because for some mysterious-to-me reason
      it did not work with the reference.
      
      The first one appears trivial, too.
      Currently, we
      1. match `LHS` matcher to the `first` operand of binary operator,
      2. and then match `RHS` matcher to the `second` operand of binary operator.
      If that does not match, we swap the ~~`LHS` and `RHS` matchers~~ **operands**:
      1. match ~~`RHS`~~ **`LHS`** matcher to the ~~`first`~~ **`second`** operand of binary operator,
      2. and then match ~~`LHS`~~ **`RHS`** matcher to the ~~`second`~ **`first`** operand of binary operator.
      
      Surprisingly, `$ ninja check-llvm` still passes with this.
      But i expect the bots will disagree..
      
      The motivational unittest is included.
      I'd like to use this in D45664.
      
      Reviewers: spatel, craig.topper, arsenm, RKSimon
      
      Reviewed By: craig.topper
      
      Subscribers: xbolva00, wdng, llvm-commits
      
      Differential Revision: https://reviews.llvm.org/D45828
      
      llvm-svn: 331085
      6959b8e7
    • Simon Pilgrim's avatar
      [X86] Merge some x87 instruction instregex single matches. NFCI. · 8ee7d01d
      Simon Pilgrim authored
      llvm-svn: 331084
      8ee7d01d
    • Sanjay Patel's avatar
      [Reassociate] add a test with debug info; NFC · 2677038c
      Sanjay Patel authored
      As suggested in D45842 
      (although still not sure if we're going to advance that),
      we must invalidate references to instructions that have
      been recycled (operands were changed, so result is different).
      
      llvm-svn: 331083
      2677038c
    • Daniel Sanders's avatar
      Attempt to fix remaining build failures after r331071 by changing the tuple to a struct · 4f246999
      Daniel Sanders authored
      Some of the bots were failing in a different way to the others. These were
      unable to compare tuples. Fix this by changing to a struct, thereby avoiding
      the quirks of tuples.
      
      llvm-svn: 331081
      4f246999
    • Philip Reames's avatar
      [LICM] Reduce nesting with an early return [NFC] · 5a648245
      Philip Reames authored
      llvm-svn: 331080
      5a648245
    • Philip Reames's avatar
      [MustExecute/LICM] Special case first instruction in throwing header · e4ec473b
      Philip Reames authored
      We currently have a hard to solve analysis problem around the order of instructions within a potentially throwing block.  We can't cheaply determine whether a given instruction is before the first potential throw in the block.  While we're working on that in the background, special case the first instruction within the header.
      
      why this particular special case?  Well, headers are guaranteed to execute if the loop does, and it turns out we tend to produce this form in practice.
      
      In a follow on patch, I tend to extend LICM with an alternate approach which works for any instruction in the header before the first throw, but this is the best I can come up with other users of the analysis (such as store promotion.)
      
      Note: I can't show the difference in the analysis result since we're ORing in the expensive instruction walk used by SCEV.  Using the full walk is not suitable for a general solution.
      llvm-svn: 331079
      e4ec473b
    • Vlad Tsyrklevich's avatar
      ELFObjectWriter: Allow one unique symver per symbol · 201a1086
      Vlad Tsyrklevich authored
      Summary:
      Only allow a single unique .symver alias per symbol. This matches the
      behavior of gas. I noticed that we ignored multiple mismatched symver
      directives looking at https://reviews.llvm.org/D45798
      
      Reviewers: pcc, tejohnson, espindola
      
      Reviewed By: pcc
      
      Subscribers: emaste, arichardson, llvm-commits, kcc
      
      Differential Revision: https://reviews.llvm.org/D45845
      
      llvm-svn: 331078
      201a1086
    • Daniel Neilson's avatar
      [LV] Common duplicate vector load/store address calculation (NFC) · a19ee7d7
      Daniel Neilson authored
      Summary:
      Commoning some obviously copy/paste code in
      InnerLoopVectorizer::vectorizeMemoryInstruction
      
      llvm-svn: 331076
      a19ee7d7
    • Daniel Sanders's avatar
      Attempt to fix build failure after r331071 using std::make_tuple · a05e8d3e
      Daniel Sanders authored
      llvm-svn: 331074
      a05e8d3e
    • Jun Bum Lim's avatar
      [PostRASink] extend the live-in check for all aliased registers · 9e3e14b5
      Jun Bum Lim authored
      Extend the live-in check for all aliased registers so that we can
      allow sinking Copy instructions when only implicit def is in successor's
      live-in.
      
      llvm-svn: 331072
      9e3e14b5
    • Daniel Sanders's avatar
      [globalisel][legalizerinfo] Add support for legalization based on the MachineMemOperand · 27fe8a50
      Daniel Sanders authored
      Summary:
      Currently only the memory size is supported but others can be added as
      needed.
      
      narrowScalar for G_LOAD and G_STORE now correctly update the
      MachineMemOperand and will refuse to legalize atomics since those need more
      careful expansions to maintain atomicity.
      
      Reviewers: ab, aditya_nandakumar, bogner, rtereshin, aemerson, javed.absar
      
      Reviewed By: aemerson
      
      Subscribers: aemerson, rovka, kristof.beyls, javed.absar, llvm-commits
      
      Differential Revision: https://reviews.llvm.org/D45466
      
      llvm-svn: 331071
      27fe8a50
Loading