Skip to content
  1. Aug 13, 2013
  2. Aug 11, 2013
  3. Aug 09, 2013
  4. Aug 08, 2013
  5. Aug 07, 2013
  6. 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
    • NAKAMURA Takumi's avatar
      Target/*/CMakeLists.txt: Add the dependency to CommonTableGen explicitly for... · aaf66c73
      NAKAMURA Takumi authored
      Target/*/CMakeLists.txt: Add the dependency to CommonTableGen explicitly for each corresponding CodeGen.
      
      Without explicit dependencies, both per-file action and in-CommonTableGen action could run in parallel.
      It races to emit *.inc files simultaneously.
      
      llvm-svn: 187780
      aaf66c73
    • Craig Topper's avatar
      9bc00b65
    • Craig Topper's avatar
      Simplify code slightly. No functional change. · 47d7c5c8
      Craig Topper authored
      llvm-svn: 187771
      47d7c5c8
  7. Aug 05, 2013
  8. 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
    • Elena Demikhovsky's avatar
      AVX-512 set: added VEXTRACTPS instruction · cd466917
      Elena Demikhovsky authored
      llvm-svn: 187705
      cd466917
    • 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
  9. Aug 01, 2013
  10. Jul 31, 2013
  11. Jul 29, 2013
  12. Jul 28, 2013
  13. Jul 26, 2013
  14. Jul 24, 2013
Loading