oota-llvm.git
17 years agoSplit some code out into a new method. The generated code is exactly
Chris Lattner [Wed, 11 Oct 2006 03:35:34 +0000 (03:35 +0000)]
Split some code out into a new method.  The generated code is exactly
identical, this is just a refactoring.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30868 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoThis entry is done. switched to the gcc way of doing things.
Andrew Lenharth [Wed, 11 Oct 2006 01:48:03 +0000 (01:48 +0000)]
This entry is done.  switched to the gcc way of doing things.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30867 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFindModifiedNodeSlot needs to add LoadSDNode ivars to create proper SelectionDAGCSEMa...
Evan Cheng [Wed, 11 Oct 2006 01:47:58 +0000 (01:47 +0000)]
FindModifiedNodeSlot needs to add LoadSDNode ivars to create proper SelectionDAGCSEMap ID.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30866 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agonew testcase for zap generation, from the alpha readme
Chris Lattner [Wed, 11 Oct 2006 01:47:08 +0000 (01:47 +0000)]
new testcase for zap generation, from the alpha readme

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30865 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoThis has apparently been fixed
Chris Lattner [Wed, 11 Oct 2006 01:44:46 +0000 (01:44 +0000)]
This has apparently been fixed

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30864 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoMake the bugpoint reduction heuristics more effective. Patch submitted by
Chris Lattner [Tue, 10 Oct 2006 21:42:25 +0000 (21:42 +0000)]
Make the bugpoint reduction heuristics more effective.  Patch submitted by
Domagoj Babic, thanks!

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30863 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agouint <-> double conversion
Rafael Espindola [Tue, 10 Oct 2006 20:38:57 +0000 (20:38 +0000)]
uint <-> double conversion

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30862 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoAlso update getNodeLabel for LoadSDNode.
Evan Cheng [Tue, 10 Oct 2006 20:11:26 +0000 (20:11 +0000)]
Also update getNodeLabel for LoadSDNode.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30861 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoSDNode::dump should also print out extension type and VT.
Evan Cheng [Tue, 10 Oct 2006 20:05:10 +0000 (20:05 +0000)]
SDNode::dump should also print out extension type and VT.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30860 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoadd fp sub
Rafael Espindola [Tue, 10 Oct 2006 19:35:01 +0000 (19:35 +0000)]
add fp sub

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30859 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoadd double <-> int conversion
Rafael Espindola [Tue, 10 Oct 2006 18:55:14 +0000 (18:55 +0000)]
add double <-> int conversion

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30858 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFix another bug in extload promotion.
Chris Lattner [Tue, 10 Oct 2006 18:54:19 +0000 (18:54 +0000)]
Fix another bug in extload promotion.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30857 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agocompare doubles
Rafael Espindola [Tue, 10 Oct 2006 16:33:47 +0000 (16:33 +0000)]
compare doubles

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30856 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoadd some tests for floating point compare
Rafael Espindola [Tue, 10 Oct 2006 14:26:06 +0000 (14:26 +0000)]
add some tests for floating point compare

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30855 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoinitial support for fp compares. Unordered compares not implemented yet
Rafael Espindola [Tue, 10 Oct 2006 12:56:00 +0000 (12:56 +0000)]
initial support for fp compares. Unordered compares not implemented yet

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30854 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFix a bug introduced by my LOAD/LOADX changes.
Evan Cheng [Tue, 10 Oct 2006 07:51:21 +0000 (07:51 +0000)]
Fix a bug introduced by my LOAD/LOADX changes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30853 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoAdd test case from PR940.
Evan Cheng [Tue, 10 Oct 2006 04:33:46 +0000 (04:33 +0000)]
Add test case from PR940.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30852 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoMore isel time load folding checking for nodes that produce flag values.
Evan Cheng [Tue, 10 Oct 2006 01:46:56 +0000 (01:46 +0000)]
More isel time load folding checking for nodes that produce flag values.
See comment in CanBeFoldedBy() for detailed explanation.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30851 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoComments; getChain(), getBasePtr(), etc. should return a SDOperand by value.
Evan Cheng [Tue, 10 Oct 2006 01:44:58 +0000 (01:44 +0000)]
Comments; getChain(), getBasePtr(), etc. should return a SDOperand by value.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30850 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoshufps with load folding is better than movaps; movsd.
Evan Cheng [Mon, 9 Oct 2006 22:42:31 +0000 (22:42 +0000)]
shufps with load folding is better than movaps; movsd.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30849 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoDon't go too crazy with these AddComplexity. Try matching shufps with load
Evan Cheng [Mon, 9 Oct 2006 21:42:15 +0000 (21:42 +0000)]
Don't go too crazy with these AddComplexity. Try matching shufps with load
folding first.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30848 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoDon't convert to MOVLP if using shufps etc. may allow load folding.
Evan Cheng [Mon, 9 Oct 2006 21:39:25 +0000 (21:39 +0000)]
Don't convert to MOVLP if using shufps etc. may allow load folding.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30847 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoUse FindProgramByName instead of FindExecutable.
Devang Patel [Mon, 9 Oct 2006 21:16:05 +0000 (21:16 +0000)]
Use FindProgramByName instead of FindExecutable.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30846 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoPredicate function on the node should be matched before its childrean' matching
Evan Cheng [Mon, 9 Oct 2006 21:02:17 +0000 (21:02 +0000)]
Predicate function on the node should be matched before its childrean' matching
code. This is especially important now matching ISD::LOAD also requires a
Predicate_Load call.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30845 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoReflects ISD::LOAD / ISD::LOADX / LoadSDNode changes.
Evan Cheng [Mon, 9 Oct 2006 20:57:25 +0000 (20:57 +0000)]
Reflects ISD::LOAD / ISD::LOADX / LoadSDNode changes.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30844 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoMerging ISD::LOAD and ISD::LOADX. Added LoadSDNode to represent load nodes.
Evan Cheng [Mon, 9 Oct 2006 20:55:20 +0000 (20:55 +0000)]
Merging ISD::LOAD and ISD::LOADX. Added LoadSDNode to represent load nodes.
Chain and address ptr remains as operands. SrcValue, extending mode, extending
VT (or rather loaded VT before extension) are now instance variables of
LoadSDNode.

Introduce load / store addressing modes to represent pre- and post-indexed
load and store. Also added an additional operand offset that is only used in
post-indexed mode (i.e. base ptr += offset after load/store).

Added alignment info (not yet used) and isVolatile fields.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30843 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoDo error checking.
Devang Patel [Mon, 9 Oct 2006 20:20:13 +0000 (20:20 +0000)]
Do error checking.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30842 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoRemove a dead var noticed by Yorion
Chris Lattner [Mon, 9 Oct 2006 20:12:37 +0000 (20:12 +0000)]
Remove a dead var noticed by Yorion

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30841 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoadd some tests for floating point arithmetic
Rafael Espindola [Mon, 9 Oct 2006 19:15:17 +0000 (19:15 +0000)]
add some tests for floating point arithmetic

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30840 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFix build error in gcc 3.4 and make more this general
Andrew Lenharth [Mon, 9 Oct 2006 19:05:44 +0000 (19:05 +0000)]
Fix build error in gcc 3.4 and make more this general

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30839 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoUse GetTemporaryDirectory. Fix http://llvm.org/bugs/show_bug.cgi?id=894
Devang Patel [Mon, 9 Oct 2006 19:04:51 +0000 (19:04 +0000)]
Use GetTemporaryDirectory. Fix llvm.org/bugs/show_bug.cgi?id=894

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30838 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFix usage example.
Nick Lewycky [Mon, 9 Oct 2006 18:33:08 +0000 (18:33 +0000)]
Fix usage example.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30837 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoadd float -> double and double -> float conversion
Rafael Espindola [Mon, 9 Oct 2006 17:50:29 +0000 (17:50 +0000)]
add float -> double and double -> float conversion

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30835 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFix PR886:
Reid Spencer [Mon, 9 Oct 2006 17:36:59 +0000 (17:36 +0000)]
Fix PR886:
The result of yyparse() was not being checked. When YYERROR or YYABORT is
called it causes yyparse() to return 1 to indicate the error. The code was
silently ignoring this situation because it previously expected either an
exception or a null ParserResult to indicate an error. The patch corrects
this situation.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30834 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoxfail this until andrew has a chance to implement the alpha TM method.
Chris Lattner [Mon, 9 Oct 2006 17:34:40 +0000 (17:34 +0000)]
xfail this until andrew has a chance to implement the alpha TM method.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30833 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoadd a test for adds adcs
Rafael Espindola [Mon, 9 Oct 2006 17:30:15 +0000 (17:30 +0000)]
add a test for adds adcs

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30832 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFix a bug pointed out by Zhongxing Xu
Chris Lattner [Mon, 9 Oct 2006 17:28:13 +0000 (17:28 +0000)]
Fix a bug pointed out by Zhongxing Xu

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30831 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoadd ADDS and ADCS
Rafael Espindola [Mon, 9 Oct 2006 17:18:28 +0000 (17:18 +0000)]
add ADDS and ADCS

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30830 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoexpand ISD::SELECT
Rafael Espindola [Mon, 9 Oct 2006 16:28:33 +0000 (16:28 +0000)]
expand ISD::SELECT

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30829 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoadd a note
Rafael Espindola [Mon, 9 Oct 2006 14:18:33 +0000 (14:18 +0000)]
add a note

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30828 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoexpand ISD::EXTLOAD
Rafael Espindola [Mon, 9 Oct 2006 14:13:40 +0000 (14:13 +0000)]
expand ISD::EXTLOAD

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30827 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agomost ARM targets are little endian
Rafael Espindola [Mon, 9 Oct 2006 14:12:15 +0000 (14:12 +0000)]
most ARM targets are little endian

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30826 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoImplement SROA of unions with mixed pointers/integers in them. This implements
Chris Lattner [Sun, 8 Oct 2006 23:53:04 +0000 (23:53 +0000)]
Implement SROA of unions with mixed pointers/integers in them.  This implements
PR892 and Transforms/ScalarRepl/union-pointer.ll:test2

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30825 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agonew testcase for PR892
Chris Lattner [Sun, 8 Oct 2006 23:52:06 +0000 (23:52 +0000)]
new testcase for PR892

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30824 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoImplement Transforms/ScalarRepl/union-pointer.ll:test
Chris Lattner [Sun, 8 Oct 2006 23:28:04 +0000 (23:28 +0000)]
Implement Transforms/ScalarRepl/union-pointer.ll:test

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30823 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agonew testcase for SROA for stuff like "union { int*, float* }".
Chris Lattner [Sun, 8 Oct 2006 23:27:37 +0000 (23:27 +0000)]
new testcase for SROA for stuff like "union { int*, float* }".

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30822 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoEliminate more token factors by taking advantage of transitivity:
Chris Lattner [Sun, 8 Oct 2006 22:57:01 +0000 (22:57 +0000)]
Eliminate more token factors by taking advantage of transitivity:
if TF depends on A and B, and A depends on B, TF just needs to depend on
A.  With Jim's alias-analysis stuff enabled, this compiles the testcase in
PR892 into:

__Z4test3Val:
        subl $44, %esp
        call L__Z3foov$stub
        movl %edx, 28(%esp)
        movl %eax, 32(%esp)
        movl %eax, 24(%esp)
        movl %edx, 36(%esp)
        movl 52(%esp), %ecx
        movl %ecx, 4(%esp)
        movl %eax, 8(%esp)
        movl %edx, 12(%esp)
        movl 48(%esp), %eax
        movl %eax, (%esp)
        call L__Z3bar3ValS_$stub
        addl $44, %esp
        ret

instead of:

__Z4test3Val:
        subl $44, %esp
        call L__Z3foov$stub
        movl %eax, 24(%esp)
        movl %edx, 28(%esp)
        movl 24(%esp), %eax
        movl %eax, 32(%esp)
        movl 28(%esp), %eax
        movl %eax, 36(%esp)
        movl 32(%esp), %eax
        movl 36(%esp), %ecx
        movl 52(%esp), %edx
        movl %edx, 4(%esp)
        movl %eax, 8(%esp)
        movl %ecx, 12(%esp)
        movl 48(%esp), %eax
        movl %eax, (%esp)
        call L__Z3bar3ValS_$stub
        addl $44, %esp
        ret

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30821 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFix PR897
Chris Lattner [Sun, 8 Oct 2006 22:28:34 +0000 (22:28 +0000)]
Fix PR897

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30820 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoCombiner alias analysis passes Multisource (release-asserts.)
Jim Laskey [Sat, 7 Oct 2006 23:37:56 +0000 (23:37 +0000)]
Combiner alias analysis passes  Multisource (release-asserts.)

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30818 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agocompletely disable folding of loads into scalar sse instructions and provide
Chris Lattner [Sat, 7 Oct 2006 21:55:32 +0000 (21:55 +0000)]
completely disable folding of loads into scalar sse instructions and provide
a framework for doing it right.  This fixes
CodeGen/X86/2006-10-07-ScalarSSEMiscompile.ll.

Once X86DAGToDAGISel::SelectScalarSSELoad is implemented right, this task
will be done.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30817 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agonew testcase we miscompile
Chris Lattner [Sat, 7 Oct 2006 21:54:08 +0000 (21:54 +0000)]
new testcase we miscompile

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30816 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoconvert packed FP add/sub/mul/div to use a multiclass.
Chris Lattner [Sat, 7 Oct 2006 21:17:13 +0000 (21:17 +0000)]
convert packed FP add/sub/mul/div to use a multiclass.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30815 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoone multiclass now defines all 8 variants of binary-scalar-sse-fp operations.
Chris Lattner [Sat, 7 Oct 2006 20:55:57 +0000 (20:55 +0000)]
one multiclass now defines all 8 variants of binary-scalar-sse-fp operations.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30814 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoSwitch ADD/MUL/DIV/SUB scalarsse fp ops to a multiclass
Chris Lattner [Sat, 7 Oct 2006 20:35:44 +0000 (20:35 +0000)]
Switch ADD/MUL/DIV/SUB scalarsse fp ops to a multiclass

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30813 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoRandom acts of shrinkage
Chris Lattner [Sat, 7 Oct 2006 19:49:05 +0000 (19:49 +0000)]
Random acts of shrinkage

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30812 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoConvert pand/por/pxor to use multiclass
Chris Lattner [Sat, 7 Oct 2006 19:37:30 +0000 (19:37 +0000)]
Convert pand/por/pxor to use multiclass

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30811 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoConvert some more instructions over to use a new multiclass.
Chris Lattner [Sat, 7 Oct 2006 19:34:33 +0000 (19:34 +0000)]
Convert some more instructions over to use a new multiclass.

Fix a bug where the asmstring for PSUBQrm was wrong.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30810 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFix a bug where PADDQrm printed paddd instead of paddq.
Chris Lattner [Sat, 7 Oct 2006 19:15:46 +0000 (19:15 +0000)]
Fix a bug where PADDQrm printed paddd instead of paddq.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30809 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoAdd multiclass for SSE2 instructions that correspond to simple binops.
Chris Lattner [Sat, 7 Oct 2006 19:14:49 +0000 (19:14 +0000)]
Add multiclass for SSE2 instructions that correspond to simple binops.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30808 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agorename:
Chris Lattner [Sat, 7 Oct 2006 19:02:31 +0000 (19:02 +0000)]
rename:
  PDI_binop_rm -> PDI_binop_rm_int
  PDI_binop_rmi -> PDI_binop_rmi_int

to make it clear that these are for use with intrinsics.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30807 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoConvert saturating PADD/PSUB's to use a multiclass
Chris Lattner [Sat, 7 Oct 2006 18:48:46 +0000 (18:48 +0000)]
Convert saturating PADD/PSUB's to use a multiclass

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30806 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoConvert PAVG*, PMADDWD, and PMUL* to use multiclasses.
Chris Lattner [Sat, 7 Oct 2006 18:39:00 +0000 (18:39 +0000)]
Convert PAVG*, PMADDWD, and PMUL* to use multiclasses.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30805 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFix typo in packsswb instr definition, where the load had the wrong type.
Chris Lattner [Sat, 7 Oct 2006 18:23:58 +0000 (18:23 +0000)]
Fix typo in packsswb instr definition, where the load had the wrong type.
This allows us to use the multiclass for other packs.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30804 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoimplement FUITOS and FUITOD
Rafael Espindola [Sat, 7 Oct 2006 14:24:52 +0000 (14:24 +0000)]
implement FUITOS and FUITOD

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30803 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoimplement FLDD
Rafael Espindola [Sat, 7 Oct 2006 14:03:39 +0000 (14:03 +0000)]
implement FLDD

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30802 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoimplement fadds, faddd, fmuls and fmuld
Rafael Espindola [Sat, 7 Oct 2006 13:46:42 +0000 (13:46 +0000)]
implement fadds, faddd, fmuls and fmuld

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30801 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agohandle pmin/pmax with multiclasses
Chris Lattner [Sat, 7 Oct 2006 07:49:33 +0000 (07:49 +0000)]
handle pmin/pmax with multiclasses

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30800 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoregenerate
Chris Lattner [Sat, 7 Oct 2006 07:15:19 +0000 (07:15 +0000)]
regenerate

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30799 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoBugfix: this allows multiclasses to have default arguments.
Chris Lattner [Sat, 7 Oct 2006 07:14:48 +0000 (07:14 +0000)]
Bugfix: this allows multiclasses to have default arguments.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30798 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agosimplify pack and shift intrinsics with multiclasses
Chris Lattner [Sat, 7 Oct 2006 07:06:17 +0000 (07:06 +0000)]
simplify pack and shift intrinsics with multiclasses

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30797 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoUse a multiclass to simplify 'SSE2 Integer comparison'
Chris Lattner [Sat, 7 Oct 2006 06:47:08 +0000 (06:47 +0000)]
Use a multiclass to simplify 'SSE2 Integer comparison'

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30796 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agomove class defns close to uses to make it easier to read
Chris Lattner [Sat, 7 Oct 2006 06:33:36 +0000 (06:33 +0000)]
move class defns close to uses to make it easier to read

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30795 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agosimplify horizontal op definitions
Chris Lattner [Sat, 7 Oct 2006 06:31:41 +0000 (06:31 +0000)]
simplify horizontal op definitions

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30794 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoremove more unneeded type info
Chris Lattner [Sat, 7 Oct 2006 06:27:03 +0000 (06:27 +0000)]
remove more unneeded type info

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30793 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoremove unneeded definitions and type info
Chris Lattner [Sat, 7 Oct 2006 06:19:41 +0000 (06:19 +0000)]
remove unneeded definitions and type info

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30792 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoremove some unneeded type info
Chris Lattner [Sat, 7 Oct 2006 06:17:43 +0000 (06:17 +0000)]
remove some unneeded type info

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30791 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agosimplify patterns by merging in operand info
Chris Lattner [Sat, 7 Oct 2006 05:50:25 +0000 (05:50 +0000)]
simplify patterns by merging in operand info

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30790 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFactor operands into packed unary classes
Chris Lattner [Sat, 7 Oct 2006 05:47:20 +0000 (05:47 +0000)]
Factor operands into packed unary classes

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30789 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoremove dead/duplicate instructions
Chris Lattner [Sat, 7 Oct 2006 05:41:52 +0000 (05:41 +0000)]
remove dead/duplicate instructions

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30788 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoPull operand info up into parent class for scalar sse intrinsics.
Chris Lattner [Sat, 7 Oct 2006 05:26:13 +0000 (05:26 +0000)]
Pull operand info up into parent class for scalar sse intrinsics.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30787 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoconvert the sole sd unary intrinsic to a multiclass for consistency
Chris Lattner [Sat, 7 Oct 2006 05:19:31 +0000 (05:19 +0000)]
convert the sole sd unary intrinsic to a multiclass for consistency

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30786 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agopull operand string into the multiclass
Chris Lattner [Sat, 7 Oct 2006 05:13:26 +0000 (05:13 +0000)]
pull operand string into the multiclass

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30785 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoRemove RSQRTSS[rm] RCPSS[rm], which are dead.
Chris Lattner [Sat, 7 Oct 2006 05:09:48 +0000 (05:09 +0000)]
Remove RSQRTSS[rm] RCPSS[rm], which are dead.

Introduce SS_IntUnary, a multiclass to replace SS_Int[rm].

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30784 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoeliminate redundancy
Chris Lattner [Sat, 7 Oct 2006 04:52:09 +0000 (04:52 +0000)]
eliminate redundancy

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30783 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFix a bug legalizing zero-extending i64 loads into 32-bit loads. The bottom
Chris Lattner [Sat, 7 Oct 2006 00:58:36 +0000 (00:58 +0000)]
Fix a bug legalizing zero-extending i64 loads into 32-bit loads.  The bottom
part was always forced to be sextload, even when we needed an zextload.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30782 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoSet the jt section
Chris Lattner [Fri, 6 Oct 2006 22:52:33 +0000 (22:52 +0000)]
Set the jt section

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30781 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoinitialize ivar
Chris Lattner [Fri, 6 Oct 2006 22:52:08 +0000 (22:52 +0000)]
initialize ivar

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30780 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoIf a target uses a GOT, put it in the jt data section, not the text
Chris Lattner [Fri, 6 Oct 2006 22:50:56 +0000 (22:50 +0000)]
If a target uses a GOT, put it in the jt data section, not the text
section.  This will fix alpha when Andrew implements
AlphaTargetMachine::getTargetLowering().

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30779 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoAlpha uses a got
Chris Lattner [Fri, 6 Oct 2006 22:46:51 +0000 (22:46 +0000)]
Alpha uses a got

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30778 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoAdd support for targets to declare that they use a GOT
Chris Lattner [Fri, 6 Oct 2006 22:46:34 +0000 (22:46 +0000)]
Add support for targets to declare that they use a GOT

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30777 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agojump tables handle pic
Chris Lattner [Fri, 6 Oct 2006 22:32:29 +0000 (22:32 +0000)]
jump tables handle pic

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30776 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoprint labels even if a MBB doesn't have a corresponding LLVM BB, just don't
Chris Lattner [Fri, 6 Oct 2006 21:28:17 +0000 (21:28 +0000)]
print labels even if a MBB doesn't have a corresponding LLVM BB, just don't
print the LLVM BB label.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30775 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoadd optional input flag to FMRRD
Rafael Espindola [Fri, 6 Oct 2006 20:33:26 +0000 (20:33 +0000)]
add optional input flag to FMRRD

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30774 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoadd support for calling functions that return double
Rafael Espindola [Fri, 6 Oct 2006 19:10:05 +0000 (19:10 +0000)]
add support for calling functions that return double

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30771 91177308-0d34-0410-b5e6-96231b3b80d8

17 years ago80 col violation.
Evan Cheng [Fri, 6 Oct 2006 18:57:51 +0000 (18:57 +0000)]
80 col violation.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30770 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agougly codegen
Chris Lattner [Fri, 6 Oct 2006 17:39:34 +0000 (17:39 +0000)]
ugly codegen

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30769 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoFix a miscompilation of:
Chris Lattner [Fri, 6 Oct 2006 17:34:12 +0000 (17:34 +0000)]
Fix a miscompilation of:

long long foo(long long X) {
  return (long long)(signed char)(int)X;
}

Instead of:

_foo:
        extsb r2, r4
        srawi r3, r4, 31
        mr r4, r2
        blr

we now produce:

_foo:
        extsb r4, r4
        srawi r3, r4, 31
        blr

This fixes a miscompilation in ConstantFolding.cpp.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30768 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agofix some bugs affecting functions with no arguments
Rafael Espindola [Fri, 6 Oct 2006 17:26:30 +0000 (17:26 +0000)]
fix some bugs affecting functions with no arguments

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30767 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agofix the stack alignment
Rafael Espindola [Fri, 6 Oct 2006 14:29:47 +0000 (14:29 +0000)]
fix the stack alignment

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30766 91177308-0d34-0410-b5e6-96231b3b80d8

17 years agoadd support for calling functions that have double arguments
Rafael Espindola [Fri, 6 Oct 2006 12:50:22 +0000 (12:50 +0000)]
add support for calling functions that have double arguments

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@30765 91177308-0d34-0410-b5e6-96231b3b80d8