Skip to content
  1. Aug 13, 2013
    • Evgeniy Stepanov's avatar
      Fix compiler warnings. · 7dee697f
      Evgeniy Stepanov authored
      ../lib/Target/X86/X86ISelLowering.cpp:9715:7: error: unused variable 'OpVT' [-Werror,-Wunused-variable]
        EVT OpVT = Op0.getValueType();
            ^
      ../lib/Target/X86/X86ISelLowering.cpp:9763:14: error: unused variable 'NumElems' [-Werror,-Wunused-variable]
          unsigned NumElems = VT.getVectorNumElements();
      
      llvm-svn: 188269
      7dee697f
    • Elena Demikhovsky's avatar
      AVX-512: Added CMP and BLEND instructions. · 60b1f289
      Elena Demikhovsky authored
      Lowering for SETCC.
      
      llvm-svn: 188265
      60b1f289
  2. Aug 11, 2013
  3. Aug 07, 2013
  4. Aug 06, 2013
    • Tim Northover's avatar
      Refactor isInTailCallPosition handling · a4415854
      Tim Northover authored
      This change came about primarily because of two issues in the existing code.
      Niether of:
      
      define i64 @test1(i64 %val) {
        %in = trunc i64 %val to i32
        tail call i32 @ret32(i32 returned %in)
        ret i64 %val
      }
      
      define i64 @test2(i64 %val) {
        tail call i32 @ret32(i32 returned undef)
        ret i32 42
      }
      
      should be tail calls, and the function sameNoopInput is responsible. The main
      problem is that it is completely symmetric in the "tail call" and "ret" value,
      but in reality different things are allowed on each side.
      
      For these cases:
      1. Any truncation should lead to a larger value being generated by "tail call"
         than needed by "ret".
      2. Undef should only be allowed as a source for ret, not as a result of the
         call.
      
      Along the way I noticed that a mismatch between what this function treats as a
      valid truncation and what the backends see can lead to invalid calls as well
      (see x86-32 test case).
      
      This patch refactors the code so that instead of being based primarily on
      values which it recurses into when necessary, it starts by inspecting the type
      and considers each fundamental slot that the backend will see in turn. For
      example, given a pathological function that returned {{}, {{}, i32, {}}, i32}
      we would consider each "real" i32 in turn, and ask if it passes through
      unchanged. This is much closer to what the backend sees as a result of
      ComputeValueVTs.
      
      Aside from the bug fixes, this eliminates the recursion that's going on and, I
      believe, makes the bulk of the code significantly easier to understand. The
      trade-off is the nasty iterators needed to find the real types inside a
      returned value.
      
      llvm-svn: 187787
      a4415854
    • Craig Topper's avatar
      cf969ead
    • Craig Topper's avatar
      Simplify math a little bit. · 7418ff46
      Craig Topper authored
      llvm-svn: 187781
      7418ff46
    • Craig Topper's avatar
      9bc00b65
    • Craig Topper's avatar
      Simplify code slightly. No functional change. · 47d7c5c8
      Craig Topper authored
      llvm-svn: 187771
      47d7c5c8
  5. Aug 05, 2013
  6. Aug 04, 2013
    • Benjamin Kramer's avatar
      X86: Turn fp selects into mask operations. · 5bc180c1
      Benjamin Kramer authored
      double test(double a, double b, double c, double d) { return a<b ? c : d; }
      
      before:
      _test:
      	ucomisd	%xmm0, %xmm1
      	ja	LBB0_2
      	movaps	%xmm3, %xmm2
      LBB0_2:
      	movaps	%xmm2, %xmm0
      
      after:
      _test:
      	cmpltsd	%xmm1, %xmm0
      	andpd	%xmm0, %xmm2
      	andnpd	%xmm3, %xmm0
      	orpd	%xmm2, %xmm0
      
      Small speedup on Benchmarks/SmallPT
      
      llvm-svn: 187706
      5bc180c1
    • Tim Northover's avatar
      X86: correct tail return address calculation · ecc018c7
      Tim Northover authored
      Due to the weird and wondeful usual arithmetic conversions, some
      calculations involving negative values were getting performed in
      uint32_t and then promoted to int64_t, which is really not a good
      idea.
      
      Patch by Katsuhiro Ueno.
      
      llvm-svn: 187703
      ecc018c7
  7. Aug 01, 2013
  8. Jul 31, 2013
  9. Jul 29, 2013
  10. Jul 26, 2013
  11. Jul 24, 2013
  12. Jul 16, 2013
    • Juergen Ributzka's avatar
      [X86] Use min/max to optimze unsigend vector comparison on X86 · 3d527d80
      Juergen Ributzka authored
      Use PMIN/PMAX for UGE/ULE vector comparions to reduce the number of required
      instructions. This trick also works for UGT/ULT, but there is no advantage in
      doing so. It wouldn't reduce the number of instructions and it would actually
      reduce performance.
      
      Reviewer: Ben
      
      radar:5972691
      
      llvm-svn: 186432
      3d527d80
  13. Jul 15, 2013
  14. Jul 14, 2013
  15. Jul 12, 2013
  16. Jul 09, 2013
    • Stephen Lin's avatar
      AArch64/PowerPC/SystemZ/X86: This patch fixes the interface, usage, and all · 73de7bf5
      Stephen Lin authored
      in-tree implementations of TargetLoweringBase::isFMAFasterThanMulAndAdd in
      order to resolve the following issues with fmuladd (i.e. optional FMA)
      intrinsics:
      
      1. On X86(-64) targets, ISD::FMA nodes are formed when lowering fmuladd
      intrinsics even if the subtarget does not support FMA instructions, leading
      to laughably bad code generation in some situations.
      
      2. On AArch64 targets, ISD::FMA nodes are formed for operations on fp128,
      resulting in a call to a software fp128 FMA implementation.
      
      3. On PowerPC targets, FMAs are not generated from fmuladd intrinsics on types
      like v2f32, v8f32, v4f64, etc., even though they promote, split, scalarize,
      etc. to types that support hardware FMAs.
      
      The function has also been slightly renamed for consistency and to force a
      merge/build conflict for any out-of-tree target implementing it. To resolve,
      see comments and fixed in-tree examples.
      
      llvm-svn: 185956
      73de7bf5
  17. Jul 08, 2013
  18. Jul 07, 2013
  19. Jul 06, 2013
  20. Jul 04, 2013
  21. Jul 03, 2013
  22. Jun 26, 2013
  23. Jun 22, 2013
Loading