Commit Graph

1722 Commits

Author SHA1 Message Date
Dan Gohman
890813243f Allow vector integer constants to be created with
SelectionDAG::getConstant, in the same way as vector floating-point
constants. This allows the legalize expansion code for @llvm.ctpop and
friends to be usable with vector types.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44954 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-12 22:21:26 +00:00
Evan Cheng
794405e6aa Use shuffles to implement insert_vector_elt for i32, i64, f32, and f64.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44929 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-12 07:55:34 +00:00
Evan Cheng
2044bccd1a Add a test case for -optimize-ext-uses.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44928 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-12 07:54:08 +00:00
Evan Cheng
db2d524d5f Lower a build_vector with all constants into a constpool load unless it can be done with a move to low part.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44921 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-12 06:45:40 +00:00
Evan Cheng
14b32e1941 - Improved v8i16 shuffle lowering. It now uses pshuflw and pshufhw as much as
possible before resorting to pextrw and pinsrw.
- Better codegen for v4i32 shuffles masquerading as v8i16 or v16i8 shuffles.
- Improves (i16 extract_vector_element 0) codegen by recognizing
  (i32 extract_vector_element 0) does not require a pextrw.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44836 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-11 01:46:18 +00:00
Christopher Lamb
11a4f64bd4 Improve branch folding by recgonizing that explict successor relationships impact the value of fall-through choices.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44785 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-10 07:24:06 +00:00
Gordon Henriksen
80a75bfae9 Adding a collector name attribute to Function in the IR. These
methods are new to Function:

  bool hasCollector() const;
  const std::string &getCollector() const;
  void setCollector(const std::string &);
  void clearCollector();

The assembly representation is as such:

  define void @f() gc "shadow-stack" { ...

The implementation uses an on-the-side table to map Functions to 
collector names, such that there is no overhead. A StringPool is 
further used to unique collector names, which are extremely
likely to be unique per process.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44769 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-10 03:18:06 +00:00
Gordon Henriksen
38200692fa Upgrading this test to 2.0 .ll syntax.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44738 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-09 15:03:01 +00:00
Chris Lattner
d96428597b Fix a significant code quality regression I introduced on PPC64 quite
a while ago.  We now produce:

_foo:
	mflr r0
	std r0, 16(r1)
	ld r2, 16(r1)
	std r2, 0(r3)
	ld r0, 16(r1)
	mtlr r0
	blr 

instead of:

_foo:
	mflr r0
	std r0, 16(r1)
	lis r0, 0
	ori r0, r0, 16
	ldx r2, r1, r0
	std r2, 0(r3)
	ld r0, 16(r1)
	mtlr r0
	blr 

for:

void foo(void **X) {
  *X = __builtin_return_address(0);
}

on ppc64.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44701 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-08 07:04:58 +00:00
Chris Lattner
3fc027df4f implement __builtin_return_addr(0) on ppc.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44700 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-08 06:59:59 +00:00
Evan Cheng
8a86c3f3ae Much improved v8i16 shuffles. (Step 1).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44676 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-07 08:07:39 +00:00
Evan Cheng
a97159336d New test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44672 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-07 01:48:46 +00:00
Evan Cheng
b0e370abdf Fix a bogus test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44668 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-06 22:12:45 +00:00
Evan Cheng
33faddc35d Turning simple splitting on. Start testing new coalescer heuristics as new llcbeta.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44660 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-06 08:54:31 +00:00
Chris Lattner
d3fd6d2b25 third time around: instead of disabling this completely,
only disable it if we don't know it will be obviously profitable.
Still fixme, but less so. :)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44658 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-06 07:47:55 +00:00
Chris Lattner
e00cbad78d Actually, disable this code for now. More analysis and improvements to
the X86 backend are needed before this should be enabled by default.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44657 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-06 07:44:31 +00:00
Chris Lattner
e70da20f9a implement a readme entry, compiling the code into:
_foo:
	movl	$12, %eax
	andl	4(%esp), %eax
	movl	_array(%eax), %eax
	ret

instead of:

_foo:
	movl	4(%esp), %eax
	shrl	$2, %eax
	andl	$3, %eax
	movl	_array(,%eax,4), %eax
	ret

As it turns out, this triggers all the time, in a wide variety of
situations, for example, I see diffs like this in various programs:

-       movl    8(%eax), %eax
-       shll    $2, %eax
-       andl    $1020, %eax
-       movl    (%esi,%eax), %eax
+       movzbl  8(%eax), %eax
+       movl    (%esi,%eax,4), %eax


-       shll    $2, %edx
-       andl    $1020, %edx
-       movl    (%edi,%edx), %edx
+       andl    $255, %edx
+       movl    (%edi,%edx,4), %edx

Unfortunately, I also see stuff like this, which can be fixed in the
X86 backend:

-       andl    $85, %ebx
-       addl    _bit_count(,%ebx,4), %ebp
+       shll    $2, %ebx
+       andl    $340, %ebx
+       addl    _bit_count(%ebx), %ebp



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44656 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-06 07:33:36 +00:00
Chris Lattner
7f3a75a529 fix this when run on non x86 hosts.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44645 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-06 01:05:52 +00:00
Evan Cheng
5ef3a04b54 Fix for PR1831: if all defs of an interval are re-materializable, then it's a preferred spill candiate.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44644 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-06 00:01:56 +00:00
Evan Cheng
e62f97c094 Allow some reloads to be folded in multi-use cases. Specifically testl r, r -> cmpl [mem], 0.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44479 91177308-0d34-0410-b5e6-96231b3b80d8
2007-12-01 02:07:52 +00:00
Evan Cheng
cddbb83ea8 Do not fold reload into an instruction with multiple uses. It issues one extra load.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44467 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-30 21:23:43 +00:00
Evan Cheng
213ee902cc Update tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44435 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-29 10:03:54 +00:00
Chris Lattner
4b341b4178 upgrade this test
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44405 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-28 18:22:12 +00:00
Chris Lattner
95d859332b xfail a test
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44395 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-28 05:37:13 +00:00
Chris Lattner
2adcf10a80 update this test after the fmrrd fix
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44393 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-28 05:27:07 +00:00
Tanya Lattner
727842e9d7 Fix bug in regression tests that ignored stderr output in RUN lines. Updated tests and fixed broken run lines.
XFAILed 3 arm regressions (will file bugs)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44389 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-28 04:57:00 +00:00
Chris Lattner
a5d4a4e33e commit testcase I forgot to svn add.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44383 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-27 22:43:37 +00:00
Chris Lattner
789db09cde Fix a crash on invalid code due to memcpy lowering.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44378 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-27 22:14:42 +00:00
Andrew Lenharth
19914ed97f something wrong with this opt
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44370 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-27 18:31:30 +00:00
Dan Gohman
b51947817d Remove unnecessary && from the RUN lines of this test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44342 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-27 00:03:38 +00:00
Dan Gohman
77003040b2 Don't lower srem/urem X%C to X-X/C*C unless the division is actually
optimized. This avoids creating illegal divisions when the combiner is
running after legalize; this fixes PR1815. Also, it produces better
code in the included testcase by avoiding the subtract and multiply
when the division isn't optimized.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44341 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-26 23:46:11 +00:00
Chris Lattner
8a594489bf Fix a long standing deficiency in the X86 backend: we would
sometimes emit "zero" and "all one" vectors multiple times,
for example:

_test2:
	pcmpeqd	%mm0, %mm0
	movq	%mm0, _M1
	pcmpeqd	%mm0, %mm0
	movq	%mm0, _M2
	ret

instead of:

_test2:
	pcmpeqd	%mm0, %mm0
	movq	%mm0, _M1
	movq	%mm0, _M2
	ret

This patch fixes this by always arranging for zero/one vectors
to be defined as v4i32 or v2i32 (SSE/MMX) instead of letting them be
any random type.  This ensures they get trivially CSE'd on the dag.
This fix is also important for LegalizeDAGTypes, as it gets unhappy
when the x86 backend wants BUILD_VECTOR(i64 0) to be legal even when
'i64' isn't legal.

This patch makes the following changes:

1) X86TargetLowering::LowerBUILD_VECTOR now lowers 0/1 vectors into
   their canonical types.
2) The now-dead patterns are removed from the SSE/MMX .td files.
3) All the patterns in the .td file that referred to immAllOnesV or
   immAllZerosV in the wrong form now use *_bc to match them with a
   bitcast wrapped around them.
4) X86DAGToDAGISel::SelectScalarSSELoad is generalized to handle 
   bitcast'd zero vectors, which simplifies the code actually.
5) getShuffleVectorZeroOrUndef is updated to generate a shuffle that
   is legal, instead of generating one that is illegal and expecting
   a later legalize pass to clean it up.
6) isZeroShuffle is generalized to handle bitcast of zeros.
7) several other minor tweaks.

This patch is definite goodness, but has the potential to cause random
code quality regressions.  Please be on the lookout for these and let 
me know if they happen.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44310 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-25 00:24:49 +00:00
Chris Lattner
9a5bdad0cc upgrade this test
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44298 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-24 05:39:29 +00:00
Duncan Sands
baccd5872e Fix a bug in which node A is replaced by node B, but later
node A gets back into the DAG again because it was hiding in
one of the node maps: make sure that node replacement happens
in those maps too.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44263 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-21 16:43:19 +00:00
Chris Lattner
cec5f3003f Testcase for PR1811
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44244 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-19 21:43:22 +00:00
Dan Gohman
089617d9e3 Add support in SplitVectorOp for remainder operators.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44233 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-19 15:15:03 +00:00
Chris Lattner
ef6c875dfa fix bogus test that the more strict lexer is finding.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44216 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-18 18:26:45 +00:00
Evan Cheng
6542481a6d Typo.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44196 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-16 23:55:08 +00:00
Dale Johannesen
d81ae56fa2 Testcase from PR 1508 (although its's somewhat
orthogonal to the main problem there)



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44194 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-16 23:16:35 +00:00
Evan Cheng
5d446265c7 Fix a thinko in post-allocation coalescer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44166 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-15 08:13:29 +00:00
Anton Korobeynikov
9de1934099 Fix PIC jump table codegen on x86-32/linux. In fact, such thing should be applied
to all targets uses GOT-relative offsets for PIC (Alpha?)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@44108 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-14 09:18:41 +00:00
Arnold Schwaighofer
38ada868f2 Update tailcall code to include inline attribute operand for memcpy.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43978 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-10 10:48:01 +00:00
Evan Cheng
9858c348d7 Fix tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43961 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-09 20:46:00 +00:00
Lauro Ramos Venancio
e0cb36b9fb [ARM] Implement __builtin_thread_pointer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43892 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-08 17:20:05 +00:00
Evan Cheng
4471194d69 If both parts of smul_lohi, etc. are used, don't simplify. If only one part is used, try simplify it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43888 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-08 09:25:29 +00:00
Evan Cheng
1fd15ba961 Add pseudo dependency to force two-address instruction to be scheduled after
other uses. There was a overly restricted check that prevented some obvious
cases.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43762 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-06 08:44:59 +00:00
Dan Gohman
80176319f3 Add support for vector remainder operations.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43744 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-05 23:35:22 +00:00
Dale Johannesen
eb57ea7ea2 Make labels work in asm blocks; allow labels as
parameters.  Rename ValueRefList to ParamList
in AsmParser, since its only use is for parameters.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43734 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-05 21:20:28 +00:00
Lauro Ramos Venancio
8699a97a2e [ARM] Fix code generation for:
static __thread struct {
    int a;
    int b;
} teste = {0, 0};



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43722 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-05 18:33:37 +00:00
Evan Cheng
5031fd2d32 Skip over deleted val#'s.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43700 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-05 06:46:45 +00:00
Evan Cheng
5942efb0e5 Handle cases where a register and one of its super-register are both marked as
defined on the same instruction. This fixes PR1767.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43699 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-05 03:11:55 +00:00
Evan Cheng
801e5a98bf Fix test case. Chris didn't do make check. :-)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43698 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-05 03:04:26 +00:00
Evan Cheng
8dec727c1f Doh. PR1187 -> PR1766.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43693 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-05 01:00:44 +00:00
Evan Cheng
5f5f3b6333 Fix PR1187.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43692 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-05 00:59:10 +00:00
Chris Lattner
fe6575c2bf Fix PR1761 by not printing (rip) suffix when in -static mode.
Evan, please review this.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43680 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-04 19:23:28 +00:00
Chris Lattner
03e6c7091e Fix PR1763 by allowing the 'q' constraint to work with 64-bit
regs on x86-64.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43669 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-04 06:51:12 +00:00
Evan Cheng
c92da3882e There are times when the coalescer would not coalesce away a copy but the copy
can be eliminated by the allocator is the destination and source targets the
same register. The most common case is when the source and destination registers
are in different class. For example, on x86 mov32to32_ targets GR32_ which
contains a subset of the registers in GR32.

The allocator can do 2 things:
1. Set the preferred allocation for the destination of a copy to that of its source.
2. After allocation is done, change the allocation of a copy destination (if
   legal) so the copy can be eliminated.

This eliminates 443 extra moves from 403.gcc.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43662 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-03 07:20:12 +00:00
Evan Cheng
deb36bd9d4 Add run line.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43645 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-02 17:36:58 +00:00
Evan Cheng
7277a7d031 One more extract_subreg coalescing bug.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43644 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-02 17:35:08 +00:00
Evan Cheng
9df7dc52e8 Missing a getNumOperands check.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43630 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-02 01:26:22 +00:00
Dale Johannesen
df17df864f Test that expand_vector_elt(v2i64) works in 32-bit mode.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43598 91177308-0d34-0410-b5e6-96231b3b80d8
2007-11-01 02:38:24 +00:00
Evan Cheng
8392772727 It's not safe to tell SplitCriticalEdge to merge identical edges. It may delete the phi instruction that's being processed.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43524 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-30 22:27:26 +00:00
Evan Cheng
af62c09437 - Bug fixes.
- Allow icmp rewrite using an iv / stride of a smaller integer type.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43480 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-29 22:07:18 +00:00
Dan Gohman
090b38a0da Fix a DAGCombiner abort on a bitcast from a scalar to a vector.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43470 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-29 20:44:42 +00:00
Evan Cheng
3c3ddb3a85 Enable more fold (sext (load x)) -> (sext (truncate (sextload x)))
transformation. Previously, it's restricted by ensuring the number of load uses
is one. Now the restriction is loosened up by allowing setcc uses to be
"extended" (e.g. setcc x, c, eq -> setcc sext(x), sext(c), eq).


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43465 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-29 19:58:20 +00:00
Chris Lattner
fb7f343615 Add support for the x86-64 'q' regigster modifier, and add support for the
b/h/w/k/q inline asm memory modifiers, which are just ignored.  This fixes
PR1748 and CodeGen/X86/2007-10-28-inlineasm-q-modifier.ll



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43430 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-29 03:09:07 +00:00
Bill Wendling
61297f960e On second thought. Remove this as it should never be generated in the first
place.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43400 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-26 20:34:37 +00:00
Bill Wendling
984e986929 - Remove the hacky code that forces a memcpy. Alignment is taken care of in the
FE.
- Explicitly pass in the alignment of the load & store.
- XFAIL 2007-10-23-UnalignedMemcpy.ll because llc has a bug that crashes on
  unaligned pointers.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43398 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-26 20:24:42 +00:00
Evan Cheng
2bd122c4d9 Loosen up iv reuse to allow reuse of the same stride but a larger type when truncating from the larger type to smaller type is free.
e.g.
Turns this loop:
LBB1_1: # entry.bb_crit_edge
        xorl    %ecx, %ecx
        xorw    %dx, %dx
        movw    %dx, %si
LBB1_2: # bb
        movl    L_X$non_lazy_ptr, %edi
        movw    %si, (%edi)
        movl    L_Y$non_lazy_ptr, %edi
        movw    %dx, (%edi)
		addw    $4, %dx
		incw    %si
		incl    %ecx
		cmpl    %eax, %ecx
		jne     LBB1_2  # bb
	
into

LBB1_1: # entry.bb_crit_edge
        xorl    %ecx, %ecx
        xorw    %dx, %dx
LBB1_2: # bb
        movl    L_X$non_lazy_ptr, %esi
        movw    %cx, (%esi)
        movl    L_Y$non_lazy_ptr, %esi
        movw    %dx, (%esi)
        addw    $4, %dx
		incl    %ecx
        cmpl    %eax, %ecx
        jne     LBB1_2  # bb


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43375 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-26 01:56:11 +00:00
Evan Cheng
cdf43b1fad If a loop termination compare instruction is the only use of its stride,
and the compaison is against a constant value, try eliminate the stride
by moving the compare instruction to another stride and change its
constant operand accordingly. e.g.

loop:
...
v1 = v1 + 3
v2 = v2 + 1
if (v2 < 10) goto loop
=>
loop:
...
v1 = v1 + 3
if (v1 < 30) goto loop


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43336 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-25 09:11:16 +00:00
Dale Johannesen
0bd5fcf49f This was failing on Darwin, which defaults to PIC;
no lea was generated.  I think this follows the intent.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43312 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-24 20:58:14 +00:00
Bill Wendling
8b1c68cee4 If there's an unaligned memcpy to/from the stack, don't lower it. Just call the
memcpy library function instead.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43270 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-23 23:32:40 +00:00
Evan Cheng
152b7e1874 Temporary solution: added a different set of BCTRL_Macho / BCTRL_ELF with right callee-saved defs set for ppc64.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43248 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-23 06:42:42 +00:00
Evan Cheng
4102eb57bb Fix memcpy lowering when addresses are 4-byte aligned but size is not multiple of 4.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43234 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-22 22:11:27 +00:00
Dan Gohman
02e4fa7d5f Strength reduction improvements.
- Avoid attempting stride-reuse in the case that there are users that
   aren't addresses. In that case, there will be places where the
   multiplications won't be folded away, so it's better to try to
   strength-reduce them.

 - Several SSE intrinsics have operands that strength-reduction can
   treat as addresses. The previous item makes this more visible, as
   any non-address use of an IV can inhibit stride-reuse.

 - Make ValidStride aware of whether there's likely to be a base
   register in the address computation. This prevents it from thinking
   that things like stride 9 are valid on x86 when the base register is
   already occupied.

Also, XFAIL the 2007-08-10-LEA16Use32.ll test; the new logic to avoid
stride-reuse elimintes the LEA in the loop, so the test is no longer
testing what it was intended to test.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43231 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-22 20:40:42 +00:00
Dan Gohman
8368805e25 Fix the folding of multiplication into addresses on x86, which was broken
by the recent {U,S}MUL_LOHI changes.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43230 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-22 20:22:24 +00:00
Evan Cheng
3311876c3c Use ptr type in the immediate field of a BxA instruction so we don't end up selecting 32-bit call instruction for ppc64.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43228 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-22 19:46:19 +00:00
Evan Cheng
40eaa99fa9 New test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43193 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-19 22:05:00 +00:00
Rafael Espindola
618b0d59e6 Test byval with a 8 bit aligned struct
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43173 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-19 11:29:21 +00:00
Rafael Espindola
5c0d6ed325 Add support for byval function whose argument is not 32 bit aligned.
To do this it is necessary to add a "always inline" argument to the
memcpy node. For completeness I have also added this node to memmove
and memset.  I have also added getMem* functions, because the extra
argument makes it cumbersome to use getNode and because I get confused
by it :-)




git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43172 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-19 10:41:11 +00:00
Bill Wendling
90bfc2d105 Pointer arithmetic should be done with the index the same size as the pointer.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43120 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-18 08:32:37 +00:00
Evan Cheng
4ae31a5d32 Really fix PR1734. Carefully track which register uses are sub-register uses by
traversing inverse register coalescing map.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43118 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-18 07:49:59 +00:00
Dan Gohman
c623096fe2 Add support for ISD::SELECT in SplitVectorOp.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43072 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-17 14:48:28 +00:00
Evan Cheng
234c6c6c25 Yet another test case for extract_subreg coalescing crash.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43063 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-17 02:15:06 +00:00
Evan Cheng
dcd8f78f8a Fix PR1734.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43035 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-16 19:29:47 +00:00
Dale Johannesen
cef254f8e1 New test for svn rev 43033, radar 5538745.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43034 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-16 18:10:14 +00:00
Chris Lattner
f602a25668 Fix a bug handling frame references in ppc inline asm when the frame offset
doesn't fit into 16 bits.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43032 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-16 18:00:18 +00:00
Evan Cheng
87c8935fd5 LowerFP_TO_SINT must not create a stack object if it's not needed.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43004 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-15 20:11:21 +00:00
Dan Gohman
f656b985ec Reapply the fix in 42908 for this file. This changes the function names
from "test" to "foo" so that they don't match the grep -i ST.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@43001 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-15 19:22:17 +00:00
Evan Cheng
f5c7359afa Fix PR1729: watch out for val# with no def.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42996 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-15 18:33:50 +00:00
Tanya Lattner
ba56fe801c Fix run line.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42990 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-15 16:35:13 +00:00
Evan Cheng
1074878fbf New test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42963 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-14 10:15:03 +00:00
Evan Cheng
347d39f1fd Revert 42908 for now.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42960 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-14 05:57:21 +00:00
Chris Lattner
f8f7cf3987 new testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42953 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-13 06:56:18 +00:00
Evan Cheng
e765f8ed1a Fix test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42949 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-13 03:14:06 +00:00
Evan Cheng
5a68b285c0 New tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42948 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-13 03:10:54 +00:00
Dan Gohman
dfb6f13a45 Fix this test to not depend on the assembly output containing something
that includes the string "st". This probably fixes the regression on
Darwin.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42932 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-12 20:42:14 +00:00
Dan Gohman
8ddde0a151 Change the names used for internal labels to use the current
function symbol name instead of a codegen-assigned function
number.

Thanks Evan! :-)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42908 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-12 14:53:36 +00:00
Evan Cheng
37a073eab4 Doh.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42901 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-12 09:10:27 +00:00
Evan Cheng
dce05bc5ed EXTRACT_SUBREG test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42900 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-12 09:03:31 +00:00
Arnold Schwaighofer
a8e8864094 Added missing -march=x86 flag.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42893 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-12 07:49:48 +00:00
Dan Gohman
ac9385a555 Add intrinsics for sin, cos, and pow. These use llvm_anyfloat_ty, and so
may be overloaded with vector types. And add a testcase for codegen for
these.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42885 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-12 00:01:22 +00:00
Dan Gohman
68ac767e1e Add an explicit target triple to make this test behave as expected on
non-Apple hosts. And use the count script instead of wc + grep.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42878 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-11 23:04:36 +00:00
Arnold Schwaighofer
c85e1716f0 Added tail call optimization to the x86 back end. It can be
enabled by passing -tailcallopt to llc.  The optimization is
performed if the following conditions are satisfied:
* caller/callee are fastcc
* elf/pic is disabled OR
  elf/pic enabled + callee is in module + callee has
  visibility protected or hidden


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42870 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-11 19:40:01 +00:00
Dan Gohman
dde01ec409 These two tests now require only two multiply instructions,
instead of four.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42784 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-09 15:39:37 +00:00
Evan Cheng
f6be158e9e Update test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42775 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-08 22:20:32 +00:00
Dan Gohman
b5d12c4438 These two tests now require only three multiply instructions,
instead of four.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42765 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-08 20:48:12 +00:00
Dale Johannesen
b762c086c8 Make test work on non-x86 hosts.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42671 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-06 01:22:39 +00:00
Evan Cheng
bf287b63b3 Test case for 3-address conversion.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42664 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-05 23:33:09 +00:00
Evan Cheng
ecf80ac68a Enable convertToThreeAddress for X86 by default.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42655 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-05 22:31:10 +00:00
Dale Johannesen
161e897b0f First round of ppc long double. call/return and
basic arithmetic works.
Rename RTLIB long double functions to distinguish
different flavors of long double; the lib functions
have different names, alas.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42644 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-05 20:04:43 +00:00
Evan Cheng
eca18214bb New test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42628 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-05 01:44:22 +00:00
Evan Cheng
d18ba7c8de -pre-RA-sched=none, simple, simple-noitin are gone.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42505 91177308-0d34-0410-b5e6-96231b3b80d8
2007-10-01 22:17:20 +00:00
Dan Gohman
9fe4662d9a Teach SplitVectorOp how to split INSERT_VECTOR_ELT.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42457 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-28 23:53:40 +00:00
Rafael Espindola
068317bfa3 Refactor the memcpy lowering for the x86 target.
The only generated code difference is that now we call memcpy when
the size of the array is unknown. This matches GCC behavior and is
better since the run time value can be arbitrarily large.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42433 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-28 12:53:01 +00:00
Dale Johannesen
317096ab37 Add sqrt and powi intrinsics for long double.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42423 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-28 01:08:20 +00:00
Dale Johannesen
fe5293daa2 Modernize fabs.ll, add long double. Add tests
for direct codegen of fsin/fcos.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42369 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-26 21:12:10 +00:00
Dan Gohman
a37c9f7506 When both x/y and x%y are needed (x and y both scalar integer), compute
both results with a single div or idiv instruction. This uses new X86ISD
nodes for DIV and IDIV which are introduced during the legalize phase
so that the SelectionDAG's CSE can automatically eliminate redundant
computations.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42308 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-25 18:23:27 +00:00
Dale Johannesen
2246bb6011 Some tests for APFloat conversions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42303 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-25 17:50:55 +00:00
Evan Cheng
6ee23ad74b Forgot to check in the changes. Fix test case so it doesn't break with any scheduling changes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42302 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-25 17:47:38 +00:00
Dan Gohman
e40c7b0973 Use the correct result value type instead of using getValueType(0)
in ExpandEXTRACT_VECTOR_ELT and SplitVectorOp. This fixes an abort
in the included testcase.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42264 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-24 15:54:53 +00:00
Dan Gohman
ea81d095dc Fix a typo in a comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42263 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-24 15:50:11 +00:00
Dale Johannesen
c557a9c00a Implementation of +sse -sse2 has changed; add
-sse to preserve intent of this test.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42247 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-23 14:58:14 +00:00
Rafael Espindola
a37ac9ff53 Don't add a default STACK_ALIGN (use the generic ABI alignment)
Implement calls to functions with byval arguments on X86


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42192 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-21 15:50:22 +00:00
Evan Cheng
b7c8017208 Disable if-conversion for this test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42170 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-20 18:06:22 +00:00
Evan Cheng
4226689f44 -enable-arm-if-conversion is gone.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42169 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-20 18:03:23 +00:00
Dan Gohman
a4ddacf60b Fix several more entries in the x86 reload/remat folding tables.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42162 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-20 14:17:21 +00:00
Evan Cheng
921c85c487 Clean up.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42112 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-18 22:56:31 +00:00
Evan Cheng
e0480d2ec2 Fix a bogus splat xform:
shuffle <undef, undef, x, undef>, <undef, undef, undef, undef>, <2, 2, 2, 2>
!=
<undef, undef, x, undef>


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42111 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-18 21:54:37 +00:00
Bill Wendling
6e19896999 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.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42074 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-18 01:47:22 +00:00
Gordon Henriksen
8c33da5dc4 Fix for PR1633: Verifier doesn't fully verify GC intrinsics
LLVM now enforces the following prototypes for the write barriers:

<ty>* @llvm.gcread(<ty2>*, <ty>**)
void @llvm.gcwrite(<ty>*, <ty2>*, <ty>**)

And for @llvm.gcroot, the first stack slot is verified to be an alloca or a 
bitcast of an alloca.

Fixes test/CodeGen/Generic/GC/lower_gcroot.ll, which violated these.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42051 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-17 20:30:04 +00:00
Dan Gohman
5f6913cecd Emit integer x<1 as x<=0, as comparisons with zero (now includeing
64-bit) can use test instead of cmp with an immediate.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42026 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-17 14:49:27 +00:00
Dan Gohman
11f7bfbb83 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.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@42024 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-17 14:35:24 +00:00
Dan Gohman
99da4e719c Add explicit triples to avoid default behavior that varies by host.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41959 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-14 20:37:18 +00:00
Rafael Espindola
7effac5475 Add support for functions with byval arguments on x86
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41953 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-14 15:48:13 +00:00
Evan Cheng
0d8d31674f Fixed a typo that's causing a missing kill marker.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41893 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-12 23:02:04 +00:00
Evan Cheng
6d6d352ed9 Sometimes a MI can define a register as well as defining a super-register at the
same time. Do not mark the "smaller" def as dead.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41871 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-11 22:34:47 +00:00
Chris Lattner
8de5f1cc7b this is not infinite recursion.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41806 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-10 21:16:23 +00:00
Dale Johannesen
907f28ce30 Implement misaligned FP loads and stores.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41786 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-08 19:29:23 +00:00
Bill Wendling
82d25148a7 Add missing index versions of instructions to the map.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41776 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-07 22:01:02 +00:00
Dan Gohman
1ab79897e2 Avoid storing and reloading zeros and other constants from stack slots
by flagging the associated instructions as being trivially rematerializable.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41775 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-07 21:32:51 +00:00
Rafael Espindola
588af2fb99 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.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41768 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-07 14:52:14 +00:00
Anton Korobeynikov
8806c7b1f5 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 :)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41763 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-07 11:39:35 +00:00
Anton Korobeynikov
325be7c608 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.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41746 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-06 17:21:48 +00:00
Evan Cheng
61d9c861fd Fix a bug in X86InstrInfo::convertToThreeAddress that caused it to codegen:
leal    (,%rcx,8), %rcx
It should be
leal    (,%rcx,8), %ecx


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41735 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-06 00:14:41 +00:00
Dale Johannesen
c2ec2baf3d Change all floating constants that are not exactly
representable to use hex format.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41722 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-05 17:50:36 +00:00
Duncan Sands
e9685143f4 Testcases for PR1628.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41719 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-05 11:53:04 +00:00
Bill Wendling
c3536b8ecb Add the 64-bit versions of the DS* Altivec instructions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41717 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-05 04:05:20 +00:00
Evan Cheng
a34d395358 Fix for PR1632. EHSELECTION always produces a i32 value.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41712 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-04 20:39:26 +00:00
Evan Cheng
67c906dce7 Fix for PR1613: added 64-bit rotate left PPC instructions and patterns.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41711 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-04 20:20:29 +00:00
Evan Cheng
4e9c473c4d Fix a gcroot lowering bug.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41668 91177308-0d34-0410-b5e6-96231b3b80d8
2007-09-01 02:00:51 +00:00
Rafael Espindola
1b5dcc34b7 Initial support for calling functions with byval arguments on x86-64
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41643 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-31 15:06:30 +00:00
Evan Cheng
144451fd99 Update test case to reflect Dale's change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41639 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-31 06:29:32 +00:00
Tanya Lattner
cad62802f4 Do not run on darwin.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41608 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-30 16:07:20 +00:00
Evan Cheng
f4c3a59dba Added support to fold X86 load / store instructions. This allow rematerialized loads to be folded into their uses.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41599 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-30 05:54:07 +00:00
Dan Gohman
9bd8a566eb Add explicit triples to avoid default behavior that varies by host.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41510 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-27 20:54:48 +00:00
Duncan Sands
56fe9b7396 Remove this test as it is too hard to fix after the
latest EH changes, and in any case it is hard to
imagine how the original bug could be reintroduced.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41497 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-27 17:08:14 +00:00
Duncan Sands
e22814b0a8 Now that we don't output cleanups by default, the action
offset needs to be adjusted in this test.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41490 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-27 16:30:05 +00:00
Dan Gohman
5f43f92c69 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.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41489 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-27 16:26:13 +00:00
Rafael Espindola
6b83b5d1ae 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)



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41479 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-27 10:18:20 +00:00
Chris Lattner
09ec1b0583 Allow target constants to be illegal types. The target should
know how to handle them.  This fixes 
test/CodeGen/Generic/asm-large-immediate.ll


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41388 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-25 01:00:22 +00:00
Andrew Lenharth
16adc23858 update test to check that codegen works with llvm.used in llvm.metadata section
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41289 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-22 19:36:31 +00:00
Evan Cheng
1594b98836 Test dag xform: Fold C ? 0 : 1 to ~C or zext(~C) or trunc(~C)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41164 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-18 06:11:57 +00:00
Evan Cheng
3da927b95d New test. Make sure dynamic_stackalloc size is rounded up.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41135 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-16 23:52:23 +00:00
Evan Cheng
cfc289d7b9 Update test: dynamic_stackalloc size *must* be rounded to ensure stack ptr be left in a valid state.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41134 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-16 23:51:28 +00:00
Rafael Espindola
24eb92e9ad add byval test
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41123 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-16 13:09:02 +00:00
Lauro Ramos Venancio
c90f08936d Implement FPOWI ExpandOp.
Fix PR1287.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41112 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-15 22:13:27 +00:00
Evan Cheng
77f8b72af2 Test case for PR1609.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41110 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-15 20:30:10 +00:00
Dan Gohman
64d8e1b9a7 This test used "wc | grep ..."; convert it to use the count script.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41101 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-15 13:55:47 +00:00
Dan Gohman
43c3db37f6 Convert tests using "grep -c ... | grep ..." to use the count script.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41100 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-15 13:49:33 +00:00
Dan Gohman
e5ab8c6765 Delete extraneous uses of wc -l.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41099 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-15 13:45:35 +00:00
Dan Gohman
52f11f7c88 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.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41098 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-15 13:42:36 +00:00
Dan Gohman
28beeeac4d Convert tests using "| wc -l | grep ..." to use the count script.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41097 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-15 13:36:28 +00:00
Evan Cheng
3b1d3068c3 New test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41087 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-14 23:34:50 +00:00
Evan Cheng
f65f11c384 Test case for PR1596.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41085 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-14 23:21:10 +00:00
Chris Lattner
b350b76a32 tcl seems to hate |& for some reason.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41073 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-14 16:19:35 +00:00
Chris Lattner
81e6fbe706 switch this to use fastcc to avoid fpstack traffic on x86-32. Switch to
using the count script instead of wc -l


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41072 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-14 16:14:10 +00:00
Evan Cheng
606b91de6c Update test case. A spill should now be deleted.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41070 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-14 09:16:00 +00:00
Evan Cheng
d24165aa71 Spiller reuse test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41068 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-14 05:51:03 +00:00
Evan Cheng
1f808011e0 Now capable of rematerializing coalesced live intervals.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41061 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-13 23:54:16 +00:00
Dan Gohman
badb2d23d1 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.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41049 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-13 20:03:06 +00:00
Chris Lattner
a45d9a15ba Fix PR1607
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41048 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-13 18:42:37 +00:00
Christopher Lamb
8441157f6e Fix test so it passes.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41012 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-10 22:20:57 +00:00
Christopher Lamb
c59e52108b Increase efficiency of sign_extend_inreg by using subregisters for truncation. As the README suggests sign_extend_subreg is selected to (sext(trunc)).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41010 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-10 21:48:46 +00:00
Christopher Lamb
b81337117c Add 2-addr to 3-addr promotion code that allows 32-bit LEA to be used via subregisters when 16-bit LEA is disabled.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@41007 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-10 21:18:25 +00:00
Dan Gohman
25ac7e8364 Fix EXTRACT_ELEMENT, EXTRACT_SUBVECTOR, and EXTRACT_VECTOR_ELT to
use an intptr ValueType instead of i32 for the index operand in
getCopyToParts.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40987 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-10 14:59:38 +00:00
Chris Lattner
3038778c1e allow this to pass on ppc hosts.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40846 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-05 18:48:18 +00:00
Chandler Carruth
6994040a95 This is the patch to provide clean intrinsic function overloading support in LLVM. It cleans up the intrinsic definitions and generally smooths the process for more complicated intrinsic writing. It will be used by the upcoming atomic intrinsics as well as vector and float intrinsics in the future.
This also changes the syntax for llvm.bswap, llvm.part.set, llvm.part.select, and llvm.ct* intrinsics. They are automatically upgraded by both the LLVM ASM reader and the bitcode reader. The test cases have been updated, with special tests added to ensure the automatic upgrading is supported.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40807 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-04 01:51:18 +00:00
Dan Gohman
7f55fcbc6b 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.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40756 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-02 21:17:01 +00:00
Dan Gohman
73a902b228 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.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40736 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-02 14:27:55 +00:00
Evan Cheng
0a2a515c5b Fix test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40721 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-02 05:04:16 +00:00
Evan Cheng
911935a068 New test. Bogus implicit-def prevented a copy from being coalesced.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40690 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-01 20:26:40 +00:00
Lauro Ramos Venancio
f3c13c82e3 Expand unaligned loads/stores when the target doesn't support them. (PR1548)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40682 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-01 19:34:21 +00:00
Chris Lattner
b59e985cdb we're now handling this right :)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40675 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-01 17:10:30 +00:00
Evan Cheng
ad076727f8 Requires SSE2.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40657 91177308-0d34-0410-b5e6-96231b3b80d8
2007-08-01 00:10:12 +00:00
Dan Gohman
b1576f56c8 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.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40648 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-31 20:11:57 +00:00
Chris Lattner
4330b3a3c2 new testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40636 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-31 16:18:25 +00:00
Evan Cheng
c64a1a921c Redo and generalize previously removed opt for pinsrw: (vextract (v4i32 bc (v4f32 s2v (f32 load ))), 0) -> (i32 load )
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40628 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-31 08:04:03 +00:00
Dan Gohman
be444ed6db Fix a bug in getCopyFromParts turned up in the testcase for PR1132.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40598 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-30 19:09:17 +00:00
Evan Cheng
a5e496ff07 New test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40587 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-30 07:52:03 +00:00
Dan Gohman
d300622eba 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.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40555 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-27 17:16:43 +00:00
Evan Cheng
3e22947d9a Reverting 40504 for now. It's breaking oggenc.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40547 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-27 01:37:47 +00:00
Evan Cheng
42000ef6c7 Test case for PR1573.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40539 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-26 17:45:57 +00:00
Evan Cheng
77baf8e80e Fix test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40536 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-26 17:07:03 +00:00
Dan Gohman
d3283832aa Remove X86ISD::LOAD_PACK and X86ISD::LOAD_UA and associated code from the
x86 target, replacing them with the new alignment attributes on memory
references.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40504 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-26 00:31:09 +00:00
Dan Gohman
a394117bc0 Use movaps to load a v4f32 build_vector of all-constant values into a
register instead of loading each element individually.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40478 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-24 22:55:08 +00:00
Duncan Sands
6c7ada4c58 The Ada f-e produces various auxiliary output files
that cannot be suppressed and cannot be redirected:
they are dumped in the current working directory.
When running the testsuite this means that these
files do not end up in the Output directory.  The
best solution I could find is to change directory
into Output before running tests.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40437 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-23 15:23:35 +00:00
Dan Gohman
9bc5dce98d Update these regression tests to accomodate X86InstrSSE.td now using movups/movaps
for everything.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40101 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-20 16:31:26 +00:00
Evan Cheng
7800479260 New test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40077 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-20 00:27:56 +00:00
Evan Cheng
66746741a7 New test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40073 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-19 23:53:50 +00:00
Evan Cheng
158622cca3 Try fixing it again.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40072 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-19 23:53:29 +00:00
Reid Spencer
9445e9aaa0 For PR1553:
Change the keywords for the zext and sext parameter attributes to be 
zeroext and signext so they don't conflict with the keywords for the
instructions of the same name. This gets around the ambiguity.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40069 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-19 23:13:04 +00:00
Bill Wendling
3b1c0994a0 Don't need the "&&" to glue lines together.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40063 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-19 18:06:26 +00:00
Bill Wendling
74430e7b0e Testcase for PR1549
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40041 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-19 06:31:11 +00:00
Evan Cheng
ccb21fdbb6 New test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40020 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-18 21:39:16 +00:00
Dan Gohman
4106f3714e Implement initial memory alignment awareness for SSE instructions. Vector loads
and stores that have a specified alignment of less than 16 bytes now use
instructions that support misaligned memory references.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40015 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-18 20:23:34 +00:00
Dan Gohman
48613b930a It's not necessary to do rounding for alloca operations when the requested
alignment is equal to the stack alignment.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@40004 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-18 16:29:46 +00:00
Evan Cheng
574470a561 Fix test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39976 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 18:16:09 +00:00
Tanya Lattner
c462d25776 Don't use * in XFAIL line unless you want it to XFAIL on everything. I don't believe you can use true regular expressions here. It will just look for those keywords. Please test this on sparc and see if they still are xfailed.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39975 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 18:08:32 +00:00
Gabor Greif
6bd7ada32d XFAIL these on sparc-solaris
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39969 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 10:25:31 +00:00
Evan Cheng
89d1659cf2 Use push / pop for prologues and epilogues.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39967 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 07:59:08 +00:00
Reid Spencer
cb5da4a8b6 For PR1558:
Move tests that have C/C++ sources into the appropriate directory. This
allows them to be selected for testing based on whether llvm-gcc is
present or not.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39963 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-17 06:20:38 +00:00
Reid Spencer
63d6d7385f Remove insignificant test no longer needed.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39931 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-16 22:03:36 +00:00
Dan Gohman
318f0dee83 Remove the trailing semicolon from function declarations in LLVM,
where it's interpreted as a comment, not part of the syntax.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39920 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-16 13:37:30 +00:00
Evan Cheng
7722ceb7de Added test case from PR1540.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39845 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-13 23:57:33 +00:00
Dale Johannesen
e7e7d0d7e3 Skeleton of post-RA scheduler; doesn't do anything yet.
Change name of -sched option and DEBUG_TYPE to
pre-RA-sched; adjust testcases.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39816 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-13 17:13:54 +00:00
Gabor Greif
7f6d4e8b6b these tests do not need a triple on Solaris. Thanks sabre!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39803 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-13 10:08:18 +00:00
Gabor Greif
fe20273427 fix the remaining 3 testcases that missed a target triple
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39773 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-12 13:21:08 +00:00
Lauro Ramos Venancio
a126bb71d5 Handle packed structs in the CBackend.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39752 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-11 19:56:53 +00:00
Evan Cheng
d04e8ecf5f Add test case for PR1545.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@39749 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-11 19:29:05 +00:00
Dan Gohman
743d3a7548 Change the peep for EXTRACT_VECTOR_ELT of BUILD_PAIR to look for
the new CONCAT_VECTORS node type instead, as that's what legalize
uses now. And add a peep for EXTRACT_VECTOR_ELT of INSERT_VECTOR_ELT.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@38503 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-10 18:20:44 +00:00
Dan Gohman
02e25b70aa Add a regression test for folding spill code into scalar min and max.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@38492 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-10 15:34:29 +00:00
Dan Gohman
532dc2e1f2 Change getCopyToParts and getCopyFromParts to always use target-endian
register ordering, for both physical and virtual registers. Update the PPC
target lowering for calls to expect registers for the call result to
already be in target order.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@38471 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-09 20:59:04 +00:00
Chris Lattner
ba7721633c force a cpu without SSE
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@38466 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-09 17:35:18 +00:00
Chris Lattner
349d4c8d66 allow this to work on ppc-darwin
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@38465 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-09 17:32:28 +00:00
Chris Lattner
4857b1b320 remove this bogus t-t
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@38464 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-09 17:31:07 +00:00
Chris Lattner
0f9d599dc9 add target triple to fix PR1546
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@38462 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-09 17:14:58 +00:00
Dan Gohman
2a69a04afa Add explicit triples to these tests so that llc behaves as expected on
non-Apple hosts.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@38455 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-09 13:42:32 +00:00
Dan Gohman
89a3066356 Add an explicit triple to the big-endian tests so that the assembly
output format is always consistent with what the greps are looking for.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37943 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-06 13:15:51 +00:00
Duncan Sands
d14526cf33 Test that byte offsets are used to index into the list
of filter ids, and not simply the id index.  Testing
this requires at least 128 type infos!


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37941 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-06 12:38:27 +00:00
Evan Cheng
9ad892ceec Fix test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37928 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-05 23:00:50 +00:00
Chris Lattner
02f7906b2f avoid ambiguity in target selection
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37927 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-05 22:16:19 +00:00
Dan Gohman
6183f78cf8 Add a parameter to getCopyToParts and getCopyFromParts to specify whether
endian swapping should be done, and update the code to use it. This fixes
some register ordering issues on big-endian systems, such as PowerPC,
introduced by the recent illegal by-val arguments changes.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37921 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-05 20:12:34 +00:00
Bill Wendling
93888428d4 Allow a GR64 to be moved into an MMX register via the "movd" instruction.
Still need to have JIT generate this code.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37863 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-04 00:19:54 +00:00
Dale Johannesen
9eed80cb12 New testcases for rev 37847 (PR's 1489 and 1505).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37848 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-03 00:58:37 +00:00
Dan Gohman
9212a8261f Add a basic test-case for passing and returning <4 x double> and
<8 x float> values on X86.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37845 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-02 16:23:47 +00:00
Dan Gohman
03de31acae New test case. DAGCombiner should be able to fold -sin(-x)
in -enable-unsafe-fp-math mode.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37841 91177308-0d34-0410-b5e6-96231b3b80d8
2007-07-02 15:43:20 +00:00
Evan Cheng
00e7fed30d New test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37823 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-29 23:17:15 +00:00
Evan Cheng
cdc85a58a0 New test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37815 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-29 21:40:30 +00:00
John Criswell
e644ef7b09 Convert .cvsignore files
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37801 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-29 16:35:07 +00:00
Evan Cheng
2c02c0ff30 New test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37791 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-29 01:36:33 +00:00
Evan Cheng
97f5ccf682 New tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37787 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-29 00:27:18 +00:00
Dan Gohman
10a7aa6dea Fix an assertion failure in legalizing bitcast operators on targets where
vectors are split down to single elements as part of legalization.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37785 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-29 00:09:08 +00:00
Evan Cheng
52974eb49a Fix tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37693 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-21 18:22:42 +00:00
Evan Cheng
53855ca95c New tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37686 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-21 07:40:00 +00:00
Evan Cheng
60c916bc72 Added some if-conversion tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37672 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-20 18:26:15 +00:00
Evan Cheng
ad0a4c0be9 New test case: identity operation of RHS / LHS of a VECTOR_SHUFFLE.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37637 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-19 00:06:08 +00:00
Chris Lattner
910b4b8479 ensure we don't regress on these tests. We generate aweful code in x86-32 for
these though.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37619 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-17 23:29:57 +00:00
Bill Wendling
521d5c72ac XFAILing until I can fix properly.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37618 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-16 23:57:51 +00:00
Bill Wendling
0c5c8d8f54 Testcase for MMX int to MMX register failure.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37612 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-16 06:31:47 +00:00
Chris Lattner
71683d3520 make this test harder, include a tied register.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37600 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-15 19:09:53 +00:00
Duncan Sands
f40708223e Workaround for PR1508.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37597 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-15 19:04:19 +00:00
Dale Johannesen
318093b6f8 Do not treat FP_REG_KILL as terminator in branch analysis (X86).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37578 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-14 22:03:45 +00:00
Duncan Sands
0bad514df1 "Simplified" testcase for PR1422.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37462 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-06 09:59:53 +00:00
Chris Lattner
de09d17231 new testcase for PR1495
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37452 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-06 01:21:46 +00:00
Evan Cheng
45beb482c4 New test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37431 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-05 01:45:08 +00:00
Dale Johannesen
fe7e397100 Tail merging wasn't working for predecessors of landing pads. PR 1496.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37427 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-04 23:52:54 +00:00
Dale Johannesen
a5a2117a46 Implement smarter algorithm for choosing which blocks to tail-merge.
See test/CodeGen/X86/test-pic-jtbl.ll for a case where it works well;
shaves another 10K off our favorite benchmark.  I was hesitant about
this because of compile speed, but seems to do OK on a bootstrap.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37392 91177308-0d34-0410-b5e6-96231b3b80d8
2007-06-01 23:02:45 +00:00
Lauro Ramos Venancio
4f3485c0da Add a test for PR1424.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37372 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-31 18:36:07 +00:00
Chris Lattner
548484d9a3 new testcase for PR1473
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37361 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-30 16:29:20 +00:00
Evan Cheng
51d2d0780f Add a new test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37317 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-24 02:31:15 +00:00
Dale Johannesen
4212a2320f tail merging shrinks this code a bit. Could do more in future.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37316 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-23 21:09:26 +00:00
Dale Johannesen
7e07b30e80 new testcases for -enable-tail-merge default handling
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37287 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-22 17:19:23 +00:00
Dale Johannesen
b68f3db93b Test assumes tail merging is off; this must now be explicit.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37286 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-22 17:18:05 +00:00
Evan Cheng
287b47f04b Add test for PR1259.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37273 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-21 23:30:33 +00:00
Chris Lattner
8a282967ef add source
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37253 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-19 01:22:52 +00:00
Chris Lattner
b0e07dd19a new testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37251 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-19 01:21:39 +00:00
Chris Lattner
35fbae2b6d new testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37245 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-19 00:41:40 +00:00
Evan Cheng
fd30eee2f0 New test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37174 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-17 18:49:50 +00:00
Chris Lattner
e1e9bc7e09 add testcase for 128-bit add/sub
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37170 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-17 18:22:37 +00:00
Chris Lattner
944a3f4d01 testcase for PR1427
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37140 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-17 03:29:17 +00:00
Chris Lattner
1651871342 testcase for maskmovq
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37101 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-16 06:14:10 +00:00
Lauro Ramos Venancio
b5bb7ffa9c Fix an infinite recursion in GetNegatedExpression.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37086 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-15 17:05:43 +00:00
Chris Lattner
14fc235e17 new testcase that crashes llc
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37068 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-15 01:33:12 +00:00
Chris Lattner
4b2e7acd6a testcase that crashes llc
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37059 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-15 01:13:42 +00:00
Chris Lattner
f2f4bb2594 new testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37053 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-14 22:04:16 +00:00
Evan Cheng
0dbea33fff Test for PR1406.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37051 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-14 21:12:43 +00:00
Evan Cheng
47927b3e5a New test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37048 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-14 20:47:21 +00:00
Evan Cheng
3cc94c08af Doh. .cpp -> .ll
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37047 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-14 20:43:28 +00:00
Lauro Ramos Venancio
69642f11ed Enable aliases on arm-linux.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37042 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-14 18:32:56 +00:00
Reid Spencer
b92cb1539f Reverse last patch .. premature. Depends on uncommitted CBE patch.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37039 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-14 17:58:52 +00:00
Reid Spencer
477e9746bb Update this test to match the (corrected) output from the CBE.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@37038 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-14 17:56:39 +00:00
Dale Johannesen
e163e696be Another test for tail mergeing
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36967 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-10 01:04:28 +00:00
Evan Cheng
7de291aa8c Can't fold bit_convert into truncating store.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36963 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-09 21:54:34 +00:00
Anton Korobeynikov
7294b58ecd Do not assert, when case range split metric is zero and JTs are not allowed: just emit binary tree in this case. This
fixes PR1403.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36959 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-09 20:07:08 +00:00
Evan Cheng
34ab6d68f5 PR1399 test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36957 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-09 19:20:37 +00:00
Dale Johannesen
fe252f38dd testcase for CodeGenPrepare bug fixed yesterday
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36940 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-08 17:44:36 +00:00
Chris Lattner
b64c2c8a2a move this out of Codegen/Generic, because it requires the ARM backend to be
linked into llc


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36919 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-08 02:19:56 +00:00
Chris Lattner
938ef6f0eb move to CodeGen/ARM/2007-05-07-tailmerge-1.ll
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36918 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-08 02:13:52 +00:00
Evan Cheng
fd4dbf78ae Fix tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36913 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-07 21:50:07 +00:00
Evan Cheng
070549eb9c Add some tests for (conv (load x)) -> (load (conv*)x) xform.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36912 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-07 21:49:35 +00:00
Evan Cheng
6b95e98e50 Fix test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36911 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-07 21:38:05 +00:00
Dale Johannesen
7d33b4c59b Handle some non-exit blocks in tail merging.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36907 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-07 20:57:21 +00:00
Duncan Sands
df8b1f0e8e Testcase for PR1398.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36905 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-07 20:45:20 +00:00
Lauro Ramos Venancio
8f57667a5d Fix PR1390.
Don't spill extra register to align the stack.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36814 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-05 23:44:41 +00:00
Chris Lattner
23f7f5898e the sparc v8 backend handles this correctly
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36801 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-05 22:12:57 +00:00
Chris Lattner
2947fd50cb remove this xfail'd test, move it to the X86 readme.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36800 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-05 22:10:53 +00:00
Chris Lattner
60ef91a3ce We need support for tail calls, this is moved to PR1392
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36798 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-05 22:03:12 +00:00
Chris Lattner
2d4a5abb75 remove xfailed testcase (attached to pr)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36797 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-05 21:57:34 +00:00
Chris Lattner
2db395600f unxfail this, llc doesn't support this feature yet, so don't run it.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36796 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-05 21:51:34 +00:00
Duncan Sands
9426caa8b2 Check that the right eh personality function is used.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36788 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-05 20:22:08 +00:00
Chris Lattner
09d933fdbd new testcase for PR1371
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36786 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-05 19:38:43 +00:00
Duncan Sands
f0799fe155 Test that the eh lowering code can handle constant folded bitcasts.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36746 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-04 17:14:42 +00:00
Evan Cheng
8535072e88 Test load global in static mode.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36719 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-04 00:29:34 +00:00
Evan Cheng
874ebada58 New test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36717 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-03 23:53:36 +00:00
Dale Johannesen
4ac075c859 Evan's patch to avoid FPreg->intreg copy for cvt; store to mem
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36693 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-03 20:54:42 +00:00
Evan Cheng
b2ef40c36f negatize -> negative
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36683 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-03 18:20:17 +00:00
Chris Lattner
b0d151540d new testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36671 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-03 16:54:08 +00:00
Chris Lattner
f972db0f4f match a reassociated form of fnmul
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36659 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-03 00:31:40 +00:00
Reid Spencer
9dd446c561 Split target dependent test portions to target-specific directories.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36612 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-01 02:56:15 +00:00
Evan Cheng
43d44f036c Test a dag combiner crasher.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36605 91177308-0d34-0410-b5e6-96231b3b80d8
2007-05-01 00:40:38 +00:00
Chris Lattner
045a9278b8 testcase for PR1228
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36601 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-30 23:34:46 +00:00
Chris Lattner
27679be2c0 testcase for PR1357
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36598 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-30 21:10:13 +00:00
Reid Spencer
4274e40514 For PR1370:
Rearrange some tests so that if PowerPC is not being built we don't try to
run PowerPC specific tests.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36587 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-30 05:11:58 +00:00
Anton Korobeynikov
21beed669e Updated aliases test
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36558 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-29 10:34:42 +00:00
Chris Lattner
c44f3ea172 new testcase for PR1356
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36535 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-28 06:41:13 +00:00
Chris Lattner
15c928640d ensure the operand prints.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36533 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-28 06:07:55 +00:00
Chris Lattner
5bee46d8e3 new testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36532 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-28 06:05:59 +00:00
Chris Lattner
93e3d8f308 update syntax
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36531 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-28 06:03:12 +00:00
Chris Lattner
827a1f45c5 update for new inline asm syntax
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36526 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-28 05:20:26 +00:00
Lauro Ramos Venancio
2a3779966f fix the test tls1.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36517 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-27 21:23:17 +00:00
Lauro Ramos Venancio
1bd151a851 add TLS tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36516 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-27 21:08:48 +00:00
Lauro Ramos Venancio
fdc9692f97 In Thumb mode, the frame register must be R7.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36512 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-27 17:58:03 +00:00
Chris Lattner
85f777946e make this testcase harder, to cover PR1326
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36509 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-27 17:12:23 +00:00
Duncan Sands
c88725fe21 Test that eh_selector lowering accepts global variables as well as bitcasts
of global variables.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36500 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-27 06:56:53 +00:00
Anton Korobeynikov
3d18d64089 Unxfail tests
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36497 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-26 21:20:04 +00:00
Dan Gohman
330ce44af6 testcase for PR1339: http://llvm.org/PR1339
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36492 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-26 21:04:39 +00:00
Anton Korobeynikov
566dfcbf98 Add test to proper place. Also, XFAIL until ppc bootstrap will be ok.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36491 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-26 20:49:05 +00:00
Anton Korobeynikov
ab8fd40403 Fixx off-by-one bug, which prevents llvm-gcc bootstrap on ppc32
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36490 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-26 20:44:04 +00:00
Evan Cheng
37a21457bf PR1348 test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36457 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-26 01:14:14 +00:00
Evan Cheng
0f8ad0d180 New test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36455 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-26 00:07:36 +00:00
Chris Lattner
0bc2f48d6f && no longer needed
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36453 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-25 22:32:55 +00:00
Bill Wendling
a03f1e3b0c Testcase for codegen bug.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36450 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-25 21:58:17 +00:00
Lauro Ramos Venancio
305b8a5f62 remember to emit weak reference in one more case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36438 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-25 14:50:40 +00:00
Anton Korobeynikov
8b0a8c84da Implement aliases. This fixes PR1017 and it's dependent bugs. CFE part
will follow.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36435 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-25 14:27:10 +00:00
Chris Lattner
3d4a548978 new testcase that crashes llc
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36412 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-25 00:00:12 +00:00
Chris Lattner
10161db780 testcase for PR1351
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36409 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-24 22:49:57 +00:00
Bill Wendling
b635d3faac Testcases for MMX.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36408 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-24 22:28:30 +00:00
Lauro Ramos Venancio
0a2cdb687b Add TLS tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36360 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-23 01:29:35 +00:00
Andrew Lenharth
007ce3b336 simplify this test until it can be dealt with
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36351 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-22 20:58:56 +00:00
Lauro Ramos Venancio
0ae4a3357a Implement PIC for arm-linux.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36324 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-22 00:04:12 +00:00
Reid Spencer
16154ef9f9 Use the llvm_supports_target function to prevent running of tests for
targets that LLVM is not configured to support.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36315 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-21 20:41:27 +00:00
Evan Cheng
ae1998f32c Fix test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36266 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-20 00:45:36 +00:00
Chris Lattner
1e6cf8630f new testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36243 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-18 03:04:37 +00:00
Evan Cheng
919184867c New crasher test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36241 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-18 02:35:10 +00:00
Chris Lattner
a00a5b95e7 new testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36230 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-17 23:43:31 +00:00
Chris Lattner
e54ec7ab0f new testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36220 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-17 21:12:26 +00:00
Chris Lattner
84e8315aaa new testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36211 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-17 19:03:02 +00:00
Anton Korobeynikov
57fc00d5cf Implemented correct stack probing on mingw/cygwin for dynamic alloca's.
Also, fixed static case in presence of eax livin. This fixes PR331

PS: Why don't we still have push/pop instructions? :)


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36195 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-17 09:20:00 +00:00
Andrew Lenharth
0644309e0d this is fixed
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36190 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-17 04:07:27 +00:00
Reid Spencer
b579650f01 Also validate that the code generation of IntrinsicLowering for LLI works.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36175 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 21:52:56 +00:00
Chris Lattner
8f9a0ff495 refix this
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36172 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 21:30:21 +00:00
Chris Lattner
3b317e5e7f use an x86 t-t for an x86 test. Thanks to Dan for noticing this!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36170 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 21:26:37 +00:00
Chris Lattner
4da9fd79f7 fix this test
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36160 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 21:05:37 +00:00
Evan Cheng
b71ccac03a Fixes tests and remove xfail.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36152 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 20:04:11 +00:00
Evan Cheng
4447934534 One more callee-saved register used.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36151 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 18:59:25 +00:00
Evan Cheng
8a5a75eb0f Fix test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36150 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 18:55:46 +00:00
Reid Spencer
892299ccf4 For PR1336:
Un-XFAIL because this passes now.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36145 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 17:51:25 +00:00
Reid Spencer
eb1d74e0c8 For PR1319:
Remove && from the end of the lines to prevent tests from throwing run
lines into the background. Also, clean up places where the same command
is run multiple times by using a temporary file.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36142 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 17:36:08 +00:00
Lauro Ramos Venancio
725aed3407 Fix hello.ll test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36141 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 17:08:00 +00:00
Lauro Ramos Venancio
3138b8995f Fix align test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36140 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 16:57:47 +00:00
Reid Spencer
43b40035ba For PR1319:
Fix syntax of tests to ensure grep pattern is properly quoted.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36134 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 15:31:49 +00:00
Reid Spencer
4cda190ef5 For PR1319:
Fix test syntax per new rules.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36133 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 15:15:52 +00:00
Reid Spencer
264225f982 For PR1336:
Rename test functions to not conflict with an instruction mnemonic.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36130 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 14:23:07 +00:00
Reid Spencer
bc243932a3 For PR1336:
Ignore case for instruction mnemonic comparison.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36129 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 14:20:28 +00:00
Reid Spencer
97d7a588a8 Wrap long line.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36128 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 14:17:04 +00:00
Reid Spencer
afc64e4da0 For PR1336:
Ignore case for register name compare.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36127 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 14:14:31 +00:00
Reid Spencer
57910836bd For PR1336:
Un-XFAIL as Alpha feature now specified in lower case.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36126 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 14:07:53 +00:00
Chris Lattner
6ab5d5d2b0 fix incorrectly upgraded test, add PR#
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36114 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 05:58:47 +00:00
Reid Spencer
18afa65788 Fix an intrinsic name.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36110 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 03:20:22 +00:00
Reid Spencer
a529f6f443 For PR1336:
Rename the intrinsic so this can be upgraded properly. It still fails with
an llc warning


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36109 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 03:18:25 +00:00
Reid Spencer
f9dd33268d For PR1336:
Upgrade the intrinsic to its new form.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36108 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 03:10:56 +00:00
Reid Spencer
296ba1bd9e For PR1336:
Un-XFAIL this test now that llvm-ugprade knows how to create functions with
empty names.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36107 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-16 03:06:39 +00:00
Reid Spencer
4575ab2186 For PR1336:
XFAIL tests covered by the PR. These will be un-XFAILed as they are fixed.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36093 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-15 23:00:46 +00:00
Reid Spencer
d3b1f6d3e0 For PR1319: Upgrade to new test harness.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36091 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-15 22:20:47 +00:00
Chris Lattner
9b63ceeada this test isn't testing what it thought it was
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36088 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-15 21:33:36 +00:00
Reid Spencer
c58ef0185b For PR1319: Upgrade to new test harness.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36087 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-15 21:17:45 +00:00
Reid Spencer
97e287ef8a For PR1319: Upgrade to new test harness.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36086 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-15 20:48:50 +00:00
Reid Spencer
2bd55af292 For PR1319: Upgrade to new test harness.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36080 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-15 19:35:51 +00:00
Reid Spencer
a99800c77f Make this test work.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36079 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-15 19:28:23 +00:00
Reid Spencer
a2c72b52e4 For PR1319: Upgrade to use new test harness
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36077 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-15 19:21:54 +00:00
Reid Spencer
1c0c94d6df For PR1319: Upgrade to use new test harness
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36076 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-15 19:11:47 +00:00
Reid Spencer
65f47a3a05 For PR1319: Upgrade to use new test harness
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36075 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-15 18:40:57 +00:00
Chris Lattner
01015d4a0e xfail for now
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36033 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-14 23:40:49 +00:00
Chris Lattner
a52bfcd3f0 fix test for linux hosts.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@36026 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-14 23:04:30 +00:00
Anton Korobeynikov
e01017bba4 Fix PR1325: Case range optimization was performed in the case it
shouldn't. Also fix some "latent" bug on 64-bit platforms


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35990 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-14 13:25:55 +00:00
Chris Lattner
4dcedf1e85 xfail this for now
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35973 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-13 22:20:27 +00:00
Chris Lattner
3bd767b91d new lsr testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35971 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-13 20:38:14 +00:00
Chris Lattner
d617d39f74 New testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35969 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-13 20:28:08 +00:00
Anton Korobeynikov
8085bcfdca Fix PR1323 : we haven't updated phi nodes in good manner :)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35963 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-13 06:53:51 +00:00