1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-25 05:52:53 +02:00
Commit Graph

2324 Commits

Author SHA1 Message Date
David Greene
2fd6d03bc9 [AVX] Fix mask predicates for 256-bit UNPCKLPS/D and implement
missing patterns for them.

      Add a SIMD test subdirectory to hold tests for SIMD instruction
      selection correctness and quality.
'

llvm-svn: 126845
2011-03-02 17:23:43 +00:00
Cameron Zwarich
6a4612ba06 Eliminate the unused CodeGenPrepare option to split critical edges.
llvm-svn: 126825
2011-03-02 03:31:46 +00:00
Dan Gohman
0823ebc79b Don't re-use existing addrec expansions if they contain casts.
This fixes PR9259.

llvm-svn: 126812
2011-03-02 01:34:10 +00:00
Evan Cheng
5275ba7f98 Catch more cases where 2-address pass should 3-addressify instructions. rdar://9002648.
llvm-svn: 126811
2011-03-02 01:08:17 +00:00
Duncan Sands
0f78cf8a37 Windows codegen also dies on this, so restrict to the platform it was
actually tested on.

llvm-svn: 126652
2011-02-28 14:22:08 +00:00
Duncan Sands
195d2036d0 Make this test x86 specific because the ARM backend can't handle it.
llvm-svn: 126650
2011-02-28 12:30:47 +00:00
NAKAMURA Takumi
b35d45a714 Target/X86: Always emit "push/pop GPRs" in prologue/epilogue and emit "spill/reload frames" for XMMs.
It improves Win64's prologue/epilogue but it would not affect ia32 and amd64 (lack of nonvolatile XMMs).

llvm-svn: 126568
2011-02-27 08:47:19 +00:00
Cameron Zwarich
764320383d Fix PR9324 / <rdar://problem/9052489> by handling the case where a PHI has no uses.
llvm-svn: 126567
2011-02-27 08:06:01 +00:00
Cameron Zwarich
1409977fe2 Give a test file a more sensible name so that it can hold more test cases.
llvm-svn: 126566
2011-02-27 08:05:57 +00:00
Benjamin Kramer
412ffed4f0 Add some DAGCombines for (adde 0, 0, glue), which are useful to optimize legalized code for large integer arithmetic.
1. Inform users of ADDEs with two 0 operands that it never sets carry
2. Fold other ADDs or ADDCs into the ADDE if possible

It would be neat if we could do the same thing for SETCC+ADD eventually, but we can't do that in target independent code.

llvm-svn: 126557
2011-02-26 22:48:07 +00:00
Nadav Rotem
ab7cf630f4 Enable support for vector sext and trunc:
Limit the folding of any_ext and sext  into the load operation to scalars.
Limit the active-bits trunc optimization to scalars.
Document vector trunc and vector sext in LangRef.

Similar to commit 126080 (for enabling zext).

llvm-svn: 126424
2011-02-24 21:01:34 +00:00
Devang Patel
bac565c8a3 Move arch specific tests in arch specific directories.
llvm-svn: 126401
2011-02-24 19:06:27 +00:00
Cameron Zwarich
724eb8706a Merge information about the number of zero, one, and sign bits of live-out
registers at phis. This enables us to eliminate a lot of pointless zexts during
the DAGCombine phase. This fixes <rdar://problem/8760114>.

llvm-svn: 126380
2011-02-24 10:00:25 +00:00
Evan Cheng
9db7b1367d Fix bug in X86 folding / unfolding table. Int_CMPSDrm and Int_CMPSSrm memory
operands starts at index 2, not 1.
rdar://9045024
PR9305

llvm-svn: 126359
2011-02-24 02:36:52 +00:00
Devang Patel
e8ade74a52 Use DW_FORM_data2 for DW_AT_language and let users use DW_LANG_lo_user=0x8000 to DW_LANG_hi_user=0xffff range.
llvm-svn: 126339
2011-02-23 22:37:04 +00:00
Devang Patel
dc0160e163 Check only relevant strings in output to increase stability of the tests.
llvm-svn: 126338
2011-02-23 22:35:57 +00:00
NAKAMURA Takumi
c59b707d50 Revert r126195, "test/CodeGen/X86/vec_cast.ll: Mark as XFAIL: migw,win32 for workaround of PR8311."
It seems it affected configuration --target=i686-pc-mingw32, I don't know and will investigate why.

llvm-svn: 126217
2011-02-22 08:22:54 +00:00
NAKAMURA Takumi
5663670e56 Relax expressions and add explicit triplets -linux and -win32.
llvm-svn: 126216
2011-02-22 07:21:59 +00:00
NAKAMURA Takumi
d1a4c5b79b Relax expressions and add explicit triplets -linux and -win32.
llvm-svn: 126215
2011-02-22 07:21:51 +00:00
NAKAMURA Takumi
606d6d5dc3 Relax expressions and add explicit triplets -linux and -win32.
llvm-svn: 126214
2011-02-22 07:21:42 +00:00
NAKAMURA Takumi
7a721b6fb6 Relax expressions and add explicit triplets -linux and -win32.
llvm-svn: 126213
2011-02-22 07:21:33 +00:00
NAKAMURA Takumi
7ea92257f9 Relax expressions and add explicit triplets -linux and -win32.
llvm-svn: 126212
2011-02-22 07:21:25 +00:00
NAKAMURA Takumi
e601f83a06 Relax expressions and add explicit triplets -linux and -win32.
On @foobar(double %d, double* %x),
AMD64: (%xmm0, %rdi)
Win64: (%xmm0, %rdx) (not %rcx!)

llvm-svn: 126211
2011-02-22 07:21:17 +00:00
NAKAMURA Takumi
78e74f5921 Relax expressions and add explicit triplets -linux and -win32.
llvm-svn: 126210
2011-02-22 07:21:08 +00:00
NAKAMURA Takumi
e118fc3ea8 Relax expressions and add explicit triplets -linux and -win32.
llvm-svn: 126209
2011-02-22 07:21:01 +00:00
NAKAMURA Takumi
d2d57dd02d Relax expressions and add explicit triplets -linux and -win32.
llvm-svn: 126208
2011-02-22 07:20:52 +00:00
NAKAMURA Takumi
c5ed4733da Relax expressions and add explicit triplets -linux and -win32.
llvm-svn: 126207
2011-02-22 07:20:44 +00:00
NAKAMURA Takumi
2829a5083a Relax expressions and add explicit triplets -linux and -win32.
llvm-svn: 126206
2011-02-22 07:20:35 +00:00
NAKAMURA Takumi
558580b1a2 Relax expressions and add explicit triplets -linux and -win32.
llvm-svn: 126205
2011-02-22 07:20:26 +00:00
NAKAMURA Takumi
15eb3d67cb Relax expressions and add explicit triplets -linux and -win32.
llvm-svn: 126204
2011-02-22 07:20:18 +00:00
NAKAMURA Takumi
a9cb6da831 Relax expressions and add explicit triplets -linux and -win32.
llvm-svn: 126203
2011-02-22 07:20:10 +00:00
NAKAMURA Takumi
8e8c80a516 Relax expressions and add explicit triplets -linux and -win32.
llvm-svn: 126202
2011-02-22 07:20:02 +00:00
NAKAMURA Takumi
3223149a53 Relax expressions and add explicit triplets -linux and -win32.
llvm-svn: 126201
2011-02-22 07:19:54 +00:00
NAKAMURA Takumi
920ac67036 Relax expressions and add explicit triplets -linux and -win32.
llvm-svn: 126200
2011-02-22 07:19:46 +00:00
NAKAMURA Takumi
61577f03c4 Relax expressions and add explicit triplets -linux and -win32.
llvm-svn: 126199
2011-02-22 07:19:37 +00:00
NAKAMURA Takumi
101efee740 Relax expressions and add explicit triplets -linux and -win32.
llvm-svn: 126198
2011-02-22 07:19:28 +00:00
NAKAMURA Takumi
7f269a5123 Relax expressions and add explicit triplets -linux and -win32.
llvm-svn: 126197
2011-02-22 07:19:20 +00:00
NAKAMURA Takumi
68b4d6429e Relax expressions and add explicit triplets -linux and -win32.
llvm-svn: 126196
2011-02-22 07:19:12 +00:00
NAKAMURA Takumi
ec693007ce test/CodeGen/X86/vec_cast.ll: Mark as XFAIL: migw,win32 for workaround of PR8311.
llvm-svn: 126195
2011-02-22 07:19:03 +00:00
NAKAMURA Takumi
d44c74a8a6 test/CodeGen/X86/red-zone.ll: Add explicit -mtriple=x86_64-linux.
Redzone is not applicable on Win64.

llvm-svn: 126194
2011-02-22 07:18:55 +00:00
Andrew Trick
ec08eae0aa VirtRegRewriter assertion fix.
Apparently it's ok for multiple operands to "kill" the same register.
Fixes PR9237.

llvm-svn: 126190
2011-02-22 06:52:56 +00:00
Cameron Zwarich
c942ffcae4 Roll out r126169 and r126170 in an attempt to fix the selfhost bot.
llvm-svn: 126185
2011-02-22 03:24:52 +00:00
Cameron Zwarich
63ed1f4c67 Merge information about the number of zero, one, and sign bits of live-out registers
at phis. This enables us to eliminate a lot of pointless zexts during the DAGCombine
phase. This fixes <rdar://problem/8760114>.

llvm-svn: 126170
2011-02-22 00:46:27 +00:00
Eric Christopher
de9e3eaf5f Revert r125960, it's breaking darwin10 bootstrap.
llvm-svn: 126163
2011-02-21 23:52:19 +00:00
Devang Patel
d5c4589795 Revert r124611 - "Keep track of incoming argument's location while emitting LiveIns."
In other words, do not keep track of argument's location.  The debugger (gdb) is not prepared to see line table entries for arguments. For the debugger, "second" line table entry marks beginning of function body.
This requires some coordination with debugger to get this working. 
 - The debugger needs to be aware of prolog_end attribute attached with line table entries.
 - The compiler needs to accurately mark prolog_end in line table entries (at -O0 and at -O1+)

llvm-svn: 126155
2011-02-21 23:21:26 +00:00
NAKAMURA Takumi
a03e9f0267 Target/X86/X86FastISel: [PR6275] Fix Win32's dllimport function with fastisel.
"dllimport" function must not be GlobalVariable, but Function. It is enough to check with GlobalValue.
test/CodeGen/X86/dll-linkage.ll is updated to check llc -O0.

llvm-svn: 126110
2011-02-21 04:50:06 +00:00
Cameron Zwarich
b7e676db6c The signed version of our "magic number" computation for the integer approximation
of a constant had a minor typo introduced when copying it from the book, which
caused it to favor negative approximations over positive approximations in many
cases. Positive approximations require fewer operations beyond the multiplication.

In the case of division by 3, we still generate code that is a single instruction
larger than GCC's code.

llvm-svn: 126097
2011-02-21 00:22:02 +00:00
Nick Lewycky
ecae3aec02 Make RecursivelyDeleteDeadPHINode delete a phi node that has no users and add a
test for that. With this change, test/CodeGen/X86/codegen-dce.ll no longer finds
any instructions to DCE, so delete the test.

Also renamed J and JP to I and IP in RecursivelyDeleteDeadPHINode.

llvm-svn: 126088
2011-02-20 18:05:56 +00:00
Nadav Rotem
1660c0bc25 Fix 9267; Add vector zext support.
The DAGCombiner folds the zext into complex load instructions. This patch
prevents this optimization on vectors since none of the supported targets
knows how to perform load+vector_zext in one instruction.

llvm-svn: 126080
2011-02-20 12:37:50 +00:00
Devang Patel
03430d117f DIE numbers do not add any value in this test.
llvm-svn: 126008
2011-02-19 01:28:37 +00:00