1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-22 12:33:33 +02:00
Commit Graph

195 Commits

Author SHA1 Message Date
Evan Cheng
2716b97b13 Fix a bogus splat xform:
shuffle <undef, undef, x, undef>, <undef, undef, undef, undef>, <2, 2, 2, 2>
!=
<undef, undef, x, undef>

llvm-svn: 42111
2007-09-18 21:54:37 +00:00
Bill Wendling
803e0d9970 Objective-C was generating EH frame info like this:
"_-[NSString(local) isNullOrNil]".eh = 0
        .no_dead_strip  "_-[NSString(local) isNullOrNil]".eh

The ".eh" should be inside the quotes.

llvm-svn: 42074
2007-09-18 01:47:22 +00:00
Dan Gohman
1aeaeec570 Emit integer x<1 as x<=0, as comparisons with zero (now includeing
64-bit) can use test instead of cmp with an immediate.

llvm-svn: 42026
2007-09-17 14:49:27 +00:00
Dan Gohman
b9449c9118 Use "test reg,reg" in place of "cmp reg,0" for 64-bit operands. This was
previously only done for 32-bit and smaller operands.

llvm-svn: 42024
2007-09-17 14:35:24 +00:00
Rafael Espindola
5d8b225881 Add support for functions with byval arguments on x86
llvm-svn: 41953
2007-09-14 15:48:13 +00:00
Dan Gohman
3bc1bc2590 Avoid storing and reloading zeros and other constants from stack slots
by flagging the associated instructions as being trivially rematerializable.

llvm-svn: 41775
2007-09-07 21:32:51 +00:00
Rafael Espindola
8c57e70f93 Add support for having different alignment for objects on call frames.
The x86-64 ABI states that objects passed on the stack have
8 byte alignment. Implement that.

llvm-svn: 41768
2007-09-07 14:52:14 +00:00
Anton Korobeynikov
899c0c9c8d Split eh.select / eh.typeid.for intrinsics into i32/i64 versions. This is needed, because they just "mark" register
liveins and we let frontend solve type issue, not lowering code :)

llvm-svn: 41763
2007-09-07 11:39:35 +00:00
Anton Korobeynikov
0e3789f07a Proper handle case, when aliasee is external weak symbol referenced only by alias itself.
Also, fix a case, when target doesn't have weak symbols supported.

llvm-svn: 41746
2007-09-06 17:21:48 +00:00
Evan Cheng
896c1ed385 Fix a bug in X86InstrInfo::convertToThreeAddress that caused it to codegen:
leal    (,%rcx,8), %rcx
It should be
leal    (,%rcx,8), %ecx

llvm-svn: 41735
2007-09-06 00:14:41 +00:00
Dale Johannesen
f9ca7b6094 Change all floating constants that are not exactly
representable to use hex format.

llvm-svn: 41722
2007-09-05 17:50:36 +00:00
Evan Cheng
bb21883dd3 Fix for PR1632. EHSELECTION always produces a i32 value.
llvm-svn: 41712
2007-09-04 20:39:26 +00:00
Rafael Espindola
4ddaad4de0 Initial support for calling functions with byval arguments on x86-64
llvm-svn: 41643
2007-08-31 15:06:30 +00:00
Evan Cheng
064691b876 Update test case to reflect Dale's change.
llvm-svn: 41639
2007-08-31 06:29:32 +00:00
Tanya Lattner
0b279ff814 Do not run on darwin.
llvm-svn: 41608
2007-08-30 16:07:20 +00:00
Evan Cheng
cb317912b2 Added support to fold X86 load / store instructions. This allow rematerialized loads to be folded into their uses.
llvm-svn: 41599
2007-08-30 05:54:07 +00:00
Dan Gohman
c6e88b9bc2 Add explicit triples to avoid default behavior that varies by host.
llvm-svn: 41510
2007-08-27 20:54:48 +00:00
Dan Gohman
2e7e251f24 If the source and destination pointers in an llvm.memmove are known
to not alias each other, it can be translated as an llvm.memcpy.

llvm-svn: 41489
2007-08-27 16:26:13 +00:00
Rafael Espindola
3d52fe3ef3 call libc memcpy/memset if array size is bigger then threshold.
Coping 100MB array (after a warmup) shows that glibc 2.6.1 implementation on
x86-64 (core 2) is 30% faster (from 0.270917s to 0.188079s)

llvm-svn: 41479
2007-08-27 10:18:20 +00:00
Evan Cheng
703bafa177 Test dag xform: Fold C ? 0 : 1 to ~C or zext(~C) or trunc(~C)
llvm-svn: 41164
2007-08-18 06:11:57 +00:00
Evan Cheng
97e0a167ec New test. Make sure dynamic_stackalloc size is rounded up.
llvm-svn: 41135
2007-08-16 23:52:23 +00:00
Evan Cheng
625e712911 Update test: dynamic_stackalloc size *must* be rounded to ensure stack ptr be left in a valid state.
llvm-svn: 41134
2007-08-16 23:51:28 +00:00
Rafael Espindola
817adb6532 add byval test
llvm-svn: 41123
2007-08-16 13:09:02 +00:00
Dan Gohman
34263074cb Convert tests using "grep -c ... | grep ..." to use the count script.
llvm-svn: 41100
2007-08-15 13:49:33 +00:00
Dan Gohman
10c3892fde Delete extraneous uses of wc -l.
llvm-svn: 41099
2007-08-15 13:45:35 +00:00
Dan Gohman
f259c770df Convert another test to use the count script. This one didn't fit the
regex used to convert all the others because the first '|' was on a
separate line.

llvm-svn: 41098
2007-08-15 13:42:36 +00:00
Dan Gohman
794fa1f8f7 Convert tests using "| wc -l | grep ..." to use the count script.
llvm-svn: 41097
2007-08-15 13:36:28 +00:00
Chris Lattner
603e77e54e tcl seems to hate |& for some reason.
llvm-svn: 41073
2007-08-14 16:19:35 +00:00
Chris Lattner
a76ba56608 switch this to use fastcc to avoid fpstack traffic on x86-32. Switch to
using the count script instead of wc -l

llvm-svn: 41072
2007-08-14 16:14:10 +00:00
Evan Cheng
5c28086ce6 Update test case. A spill should now be deleted.
llvm-svn: 41070
2007-08-14 09:16:00 +00:00
Evan Cheng
fb29461720 Spiller reuse test case.
llvm-svn: 41068
2007-08-14 05:51:03 +00:00
Evan Cheng
e79599dc2d Now capable of rematerializing coalesced live intervals.
llvm-svn: 41061
2007-08-13 23:54:16 +00:00
Dan Gohman
2390ff5060 When x86 addresses matching exceeds its recursion limit, check to
see if the base register is already occupied before assuming it can be
used. This fixes bogus code generation in the accompanying testcase.

llvm-svn: 41049
2007-08-13 20:03:06 +00:00
Chris Lattner
7dfec1ee54 Fix PR1607
llvm-svn: 41048
2007-08-13 18:42:37 +00:00
Christopher Lamb
6c79abee5d Fix test so it passes.
llvm-svn: 41012
2007-08-10 22:20:57 +00:00
Christopher Lamb
450f6815b9 Increase efficiency of sign_extend_inreg by using subregisters for truncation. As the README suggests sign_extend_subreg is selected to (sext(trunc)).
llvm-svn: 41010
2007-08-10 21:48:46 +00:00
Christopher Lamb
7196f0d724 Add 2-addr to 3-addr promotion code that allows 32-bit LEA to be used via subregisters when 16-bit LEA is disabled.
llvm-svn: 41007
2007-08-10 21:18:25 +00:00
Dan Gohman
f18e94535f Fix EXTRACT_ELEMENT, EXTRACT_SUBVECTOR, and EXTRACT_VECTOR_ELT to
use an intptr ValueType instead of i32 for the index operand in
getCopyToParts.

llvm-svn: 40987
2007-08-10 14:59:38 +00:00
Chris Lattner
f2a88ac82d allow this to pass on ppc hosts.
llvm-svn: 40846
2007-08-05 18:48:18 +00:00
Dan Gohman
1afde4166e Fix the alignment requirements of several unpck and shuf instructions.
Generalize isPSHUFDMask and add a unary SHUFPD pattern so that SHUFPD's
memory operand alignment can be tested as well, with a fix to avoid
breaking MMX's use of isPSHUFDMask.

llvm-svn: 40756
2007-08-02 21:17:01 +00:00
Dan Gohman
a599a813d5 Mark the SSE and MMX load instructions that
X86InstrInfo::isReallyTriviallyReMaterializable knows how to handle
with the isReMaterializable flag so that it is given a chance to handle
them. Without hoisting constant-pool loads from loops this isn't very
visible, though it does keep CodeGen/X86/constant-pool-remat-0.ll from
making a copy of the constant pool on the stack.

llvm-svn: 40736
2007-08-02 14:27:55 +00:00
Evan Cheng
5a30bb6d47 Fix test.
llvm-svn: 40721
2007-08-02 05:04:16 +00:00
Evan Cheng
8183a284fd New test. Bogus implicit-def prevented a copy from being coalesced.
llvm-svn: 40690
2007-08-01 20:26:40 +00:00
Chris Lattner
5d3a429915 we're now handling this right :)
llvm-svn: 40675
2007-08-01 17:10:30 +00:00
Evan Cheng
7a025bad7a Requires SSE2.
llvm-svn: 40657
2007-08-01 00:10:12 +00:00
Dan Gohman
e3464e6bec Change the x86 assembly output to use tab characters to separate the
mnemonics from their operands instead of single spaces. This makes the
assembly output a little more consistent with various other compilers
(f.e. GCC), and slightly easier to read. Also, update the regression
tests accordingly.

llvm-svn: 40648
2007-07-31 20:11:57 +00:00
Evan Cheng
3493ec0ce1 Redo and generalize previously removed opt for pinsrw: (vextract (v4i32 bc (v4f32 s2v (f32 load ))), 0) -> (i32 load )
llvm-svn: 40628
2007-07-31 08:04:03 +00:00
Dan Gohman
0252aa07ee Re-apply 40504, but with a fix for the segfault it caused in oggenc:
Make the alignedload and alignedstore patterns always require 16-byte
alignment. This way when they are used in the "Fs" instructions, in which
a vector instruction is used for a scalar purpose, they can still require
the full vector alignment. And add a regression test for this.

llvm-svn: 40555
2007-07-27 17:16:43 +00:00
Evan Cheng
cb8f08ebca Reverting 40504 for now. It's breaking oggenc.
llvm-svn: 40547
2007-07-27 01:37:47 +00:00
Evan Cheng
7b20c11ccf Test case for PR1573.
llvm-svn: 40539
2007-07-26 17:45:57 +00:00