Commit Graph

411 Commits

Author SHA1 Message Date
Evan Cheng
9c1e06e187 After reading memory that's already freed.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@49810 91177308-0d34-0410-b5e6-96231b3b80d8
2008-04-16 20:24:25 +00:00
Dale Johannesen
0a6ee6d131 Remove -unwind-tables-optional everywhere, since
this is now the default.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@49667 91177308-0d34-0410-b5e6-96231b3b80d8
2008-04-14 17:56:54 +00:00
Evan Cheng
172b70c62a A copy instruction may use a register multiple times on some targets. Change them all.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@49491 91177308-0d34-0410-b5e6-96231b3b80d8
2008-04-10 18:38:47 +00:00
Dale Johannesen
c8abfdec84 Rename -disable-required-unwind-tables to -unwind-tables-optional.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@49391 91177308-0d34-0410-b5e6-96231b3b80d8
2008-04-08 18:10:08 +00:00
Dale Johannesen
a25e5787bc Missed one.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@49365 91177308-0d34-0410-b5e6-96231b3b80d8
2008-04-08 00:14:59 +00:00
Dale Johannesen
235f7fb474 Add -disable-required-unwind-tables to tests
that need it (usually, grepping for some string
found in unwind info)



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@49364 91177308-0d34-0410-b5e6-96231b3b80d8
2008-04-08 00:14:17 +00:00
Dale Johannesen
1d3863fdbc Mark functions in some tests as 'nounwind'. Generating
EH info for these functions causes the tests to fail for
random reasons (e.g. looking for 'or' or counting lines
with asm-printer; labels count as lines.)



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@49003 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-31 23:20:09 +00:00
Evan Cheng
0c28432852 One more coalescer fix wrt deadness propagation.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48837 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-26 20:15:49 +00:00
Tanya Lattner
6f729d601c Byebye llvm-upgrade!
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48762 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-25 04:26:08 +00:00
Evan Cheng
a2fb634def lastRegisterUse() should ignore identity copies. Those will be erased.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48759 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-25 02:02:19 +00:00
Bill Wendling
3e98c30cf5 Use the bit size of the operand instead of the hard-coded 32 to generate the
mask.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48750 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-24 23:16:37 +00:00
Bill Wendling
d59c517a83 New testcase.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48697 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-22 22:27:01 +00:00
Dan Gohman
7925ed05d0 Add support for multiple return values for the PPC target by
converting call result lowering to use the CallingConvLowering
infastructure.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48552 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-19 21:39:28 +00:00
Evan Cheng
94202018c5 Fix live variables issues:
1. If part of a register is re-defined, an implicit kill and an implicit def are added to denote read / mod / write. However, this should only be necessary if the register is actually read later. This is a performance issue.
2. If a sub-register is being defined, and it doesn't have a previous use, do not add a implicit kill to the last use of a super-register:
   = EAX, AX<imp-use,kill>
...
AX =
In this case, EAX is live but AX is killed, this is wrong and will cause the coalescer to do bad things.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48521 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-19 00:52:20 +00:00
Dale Johannesen
cf49819877 Make conversions of i8/i16 to ppcf128 work.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48493 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-18 17:28:38 +00:00
Evan Cheng
3c88d742d4 Rewrite code that propagate isDead information after a dead copy is coalesced. This remove some ugly spaghetti code and fixed a number of subtle bugs.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48490 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-18 08:26:47 +00:00
Dan Gohman
002e5d0a17 More APInt-ification.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48344 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-13 22:13:53 +00:00
Dale Johannesen
01c18a7275 The feature this is testing did not work in the general case,
and has been removed.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48232 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-11 17:48:26 +00:00
Evan Cheng
9a8094159d Learn how to xfail a test.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48219 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-11 07:51:31 +00:00
Evan Cheng
de13acf862 XFAIL due to Dale's change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48216 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-11 07:15:44 +00:00
Dan Gohman
034f60ed24 Generalize ExpandIntToFP to handle the case where the operand is legal
and it's the result that requires expansion. This code is a little confusing
because the TargetLoweringInfo tables for [US]INT_TO_FP use the operand type
(the integer type) rather than the result type. 


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48206 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-11 01:59:03 +00:00
Dan Gohman
a2e9485e34 Implement more support for fp-to-i128 and i128-to-fp conversions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48189 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-10 23:03:31 +00:00
Bill Wendling
2b65c4e7cc Update llc flags for PPC register scavenger.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48187 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-10 22:59:08 +00:00
Chris Lattner
8aca4b13a8 upgrade this test
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48062 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-09 00:32:10 +00:00
Dan Gohman
a2fcff4d97 Add support for calls with i128 return values on ppc64.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48041 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-08 00:19:12 +00:00
Dan Gohman
9ed06db5c8 Add support for lowering 128-bit shifts on ppc64.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48029 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-07 20:36:53 +00:00
Bill Wendling
65bc122045 Add testcase.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@48005 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-06 23:34:22 +00:00
Evan Cheng
ecb2a8b9bc Fix a coalescer bug wrt how dead copy interval is shortened.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47966 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-05 22:09:42 +00:00
Bill Wendling
3fab77eb25 Use -enable-ppc-regscavenger flag for these checks
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47916 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-04 23:16:26 +00:00
Bill Wendling
7194aaf738 This is the initial check-in for adding register scavenging to PPC. (Currently,
PPC-64 doesn't work.) This also lowers the spilling of the CR registers so that
it uses a register other than the default R0 register (the scavenger scrounges
for one). A significant part of this patch fixes how kill information is
handled.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47863 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-03 22:19:16 +00:00
Chris Lattner
3be4893dce Evan implemented this.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47827 91177308-0d34-0410-b5e6-96231b3b80d8
2008-03-02 17:56:29 +00:00
Dale Johannesen
0154e47ed0 New test for misaligned Altivec laod/store.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47698 91177308-0d34-0410-b5e6-96231b3b80d8
2008-02-27 23:14:50 +00:00
Dan Gohman
ec59b95a19 Don't hard-code the mask size to be 32, which is incorrect on ppc64
and was causing aborts with the new APInt changes. This may also be
fixing an obscure ppc64 bug.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47692 91177308-0d34-0410-b5e6-96231b3b80d8
2008-02-27 21:12:32 +00:00
Bill Wendling
cc4831849e Upgrade testcase.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47644 91177308-0d34-0410-b5e6-96231b3b80d8
2008-02-26 23:22:40 +00:00
Gabor Greif
72c8f0d156 Really feed llvm-as with the testcase, do not let it read from stdin. This fixes the hangs seen on solaris10.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47604 91177308-0d34-0410-b5e6-96231b3b80d8
2008-02-26 13:37:13 +00:00
Tanya Lattner
cfab3da46e Remove llvm-upgrade and update tests.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47325 91177308-0d34-0410-b5e6-96231b3b80d8
2008-02-19 08:07:33 +00:00
Nate Begeman
5e1dd5597e Add testcase for recent legalizer change
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@47049 91177308-0d34-0410-b5e6-96231b3b80d8
2008-02-13 06:48:40 +00:00
Evan Cheng
431bfcbe37 Determine whether a spill kills the register it's spilling before insertion rather than trying to undo the kill marker afterwards.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46953 91177308-0d34-0410-b5e6-96231b3b80d8
2008-02-11 08:30:52 +00:00
Evan Cheng
bb4151bd1f If a vr is already marked alive in a bb, then it has PHI uses that are visited earlier, then it is not killed in the def block (i.e. not dead).
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46763 91177308-0d34-0410-b5e6-96231b3b80d8
2008-02-05 20:04:18 +00:00
Chris Lattner
7cf9abff23 Add target triples to these so they don't fail on linux.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46496 91177308-0d34-0410-b5e6-96231b3b80d8
2008-01-29 06:26:07 +00:00
Bill Wendling
c79348d8dc Need to convert to LLVM code and not C.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46397 91177308-0d34-0410-b5e6-96231b3b80d8
2008-01-26 06:56:08 +00:00
Bill Wendling
cd76af4a62 Rename the .c to .ll
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46396 91177308-0d34-0410-b5e6-96231b3b80d8
2008-01-26 06:53:40 +00:00
Bill Wendling
f7214bca74 Move testcase to the code gen directory.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46395 91177308-0d34-0410-b5e6-96231b3b80d8
2008-01-26 06:53:06 +00:00
Dale Johannesen
5c5eb80255 Implement flt_rounds for PowerPC.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46174 91177308-0d34-0410-b5e6-96231b3b80d8
2008-01-18 19:55:37 +00:00
Chris Lattner
a7a02fb828 Fix a latent bug exposed by my truncstore patch. We compiled stfiwx-2.ll to:
_test:
	fctiwz f0, f1
	stfiwx f0, 0, r4
	blr 

instead of:

_test:
	fctiwz f0, f1
	stfd f0, -8(r1)
	nop
	nop
	lwz r2, -4(r1)
	stb r2, 0(r4)
	blr 

The former is not correct (stores 4 bytes, not 1).



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46161 91177308-0d34-0410-b5e6-96231b3b80d8
2008-01-18 16:54:56 +00:00
Chris Lattner
b8b92216f1 add testcase for regression
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@46073 91177308-0d34-0410-b5e6-96231b3b80d8
2008-01-16 18:03:52 +00:00
Chris Lattner
a4040e9a9f remove darwin/i386 t-t
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@45743 91177308-0d34-0410-b5e6-96231b3b80d8
2008-01-08 06:52:51 +00:00
Chris Lattner
fe39edde27 Finally implement correct ordered comparisons for PPC, even though
the code generated is not wonderful.  This turns a miscompilation into
a code quality bug (noted in the ppc readme).  This fixes PR642, which
is over 2 years old (!).  Nate, please review this.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@45742 91177308-0d34-0410-b5e6-96231b3b80d8
2008-01-08 06:46:30 +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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
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
0f5aed5648 Make the llvm-runtest function much more amenable by eliminating all the
global variables that needed to be passed in. This makes it possible to
add new global variables with only a couple changes (Makefile and llvm-dg.exp)
instead of touching every single dg.exp file.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35918 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-11 19:56:59 +00:00
Chris Lattner
603572a771 new testcases for integer abs function
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35880 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-11 05:02:57 +00:00
Anton Korobeynikov
a6d3f1341d Fix test
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35673 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-04 21:28:36 +00:00
Chris Lattner
19e970542d Add a regtest for cases we now recognize as rotates, thanks to Scott Michel's
recent dagcombine patch


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35606 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-02 22:08:54 +00:00
Chris Lattner
465b7157d1 new testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35589 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-02 05:57:59 +00:00
Chris Lattner
028856dc39 my patch fixed the fixme.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35582 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-02 05:08:54 +00:00
Reid Spencer
2b35c15487 Let llvm-upgrade upgrade bswap intrinsic.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35568 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-02 01:08:02 +00:00
Reid Spencer
a3c533a716 For PR1297:
Update these test cases to use proper signatures for bswap which is now
and overloaded intrinsic. Its name must be of the form llvm.bswap.i32.i32
since both the parameter and the result or of type "iAny". Also, the
bit counting intrinsics changed to always return i32.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35548 91177308-0d34-0410-b5e6-96231b3b80d8
2007-04-01 07:36:28 +00:00
Evan Cheng
6eec2261e7 New test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35515 91177308-0d34-0410-b5e6-96231b3b80d8
2007-03-30 20:41:18 +00:00
Reid Spencer
5373b721c0 Remove use of implementation keyword.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35412 91177308-0d34-0410-b5e6-96231b3b80d8
2007-03-28 02:38:26 +00:00
Chris Lattner
eaa87ba1e7 test that the ppc backend can do 64-bit cntlz
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@35328 91177308-0d34-0410-b5e6-96231b3b80d8
2007-03-25 04:43:51 +00:00
Reid Spencer
87d266e593 This test passes on x86/Linux now.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34686 91177308-0d34-0410-b5e6-96231b3b80d8
2007-02-27 20:46:44 +00:00
Reid Spencer
79224c4407 XFAIL this on x86-Linux until its fixed.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34651 91177308-0d34-0410-b5e6-96231b3b80d8
2007-02-27 02:45:12 +00:00
Jim Laskey
da10e3350a New test - practically wrote itself.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34538 91177308-0d34-0410-b5e6-96231b3b80d8
2007-02-23 22:12:08 +00:00
Evan Cheng
d1b2c5b34d Fix test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34427 91177308-0d34-0410-b5e6-96231b3b80d8
2007-02-19 21:47:02 +00:00
Chris Lattner
0f74372ebf new test
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34372 91177308-0d34-0410-b5e6-96231b3b80d8
2007-02-17 06:57:11 +00:00
Chris Lattner
6e1472a928 Test that large absolute addresses are properly folded into addr modes on
both ppc32 and ppc64.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34370 91177308-0d34-0410-b5e6-96231b3b80d8
2007-02-17 06:41:57 +00:00
Chris Lattner
419116fb72 new testcase that crashes llc
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34367 91177308-0d34-0410-b5e6-96231b3b80d8
2007-02-17 05:59:01 +00:00
Dale Johannesen
6b896cec8b Fixes PR 1200
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34359 91177308-0d34-0410-b5e6-96231b3b80d8
2007-02-17 00:44:34 +00:00
Chris Lattner
6985dca2a0 testcase for recent targetdata regression
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34355 91177308-0d34-0410-b5e6-96231b3b80d8
2007-02-16 23:11:43 +00:00
Chris Lattner
511e1d1456 Add ppc-specific test for better i64 compare codegen.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@34082 91177308-0d34-0410-b5e6-96231b3b80d8
2007-02-09 04:49:46 +00:00
Reid Spencer
832254e1c2 Changes to support making the shift instructions be true BinaryOperators.
This feature is needed in order to support shifts of more than 255 bits
on large integer types.  This changes the syntax for llvm assembly to
make shl, ashr and lshr instructions look like a binary operator:
   shl i32 %X, 1
instead of
   shl i32 %X, i8 1
Additionally, this should help a few passes perform additional optimizations.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33776 91177308-0d34-0410-b5e6-96231b3b80d8
2007-02-02 02:16:23 +00:00
Chris Lattner
36a724341c new testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33731 91177308-0d34-0410-b5e6-96231b3b80d8
2007-02-01 00:38:56 +00:00
Reid Spencer
908504347b For PR411:
Update these tests to not use the same name even though the type of the
value differs. After PR411 hits, type planes will be gone and it will be
illegal for a name to be used twice, regardless of type.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33660 91177308-0d34-0410-b5e6-96231b3b80d8
2007-01-30 16:16:01 +00:00
Reid Spencer
c1f32a5f4e Make the input legal.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33655 91177308-0d34-0410-b5e6-96231b3b80d8
2007-01-30 06:32:25 +00:00
Chris Lattner
db4e6e77fc new testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33642 91177308-0d34-0410-b5e6-96231b3b80d8
2007-01-29 23:45:03 +00:00
Reid Spencer
e3ff5ada8a For PR761:
Remove "target endian/pointersize" or add "target datalayout" to make
the test parse properly or set the datalayout because defaults changes.

For PR645:
Make global names use the @ prefix.

For llvm-upgrade changes:
Fix test cases or completely remove use of llvm-upgrade for test cases
that cannot survive the new renaming or upgrade capabilities.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33533 91177308-0d34-0410-b5e6-96231b3b80d8
2007-01-26 08:25:06 +00:00
Evan Cheng
f4d6822348 Fix test case.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33507 91177308-0d34-0410-b5e6-96231b3b80d8
2007-01-25 22:28:32 +00:00
Bill Wendling
e47b029ac0 Added a -mtriple flag to force darwin backend.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33248 91177308-0d34-0410-b5e6-96231b3b80d8
2007-01-16 04:15:20 +00:00
Bill Wendling
eb9a42c90b Fix for PR1095:
LLVM would miscompile ASM dialects when compiling for PPC. Added dialects for
the X86 and PPC backends. It defaults to "0", the first variant of a compound
inline asm expression.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33246 91177308-0d34-0410-b5e6-96231b3b80d8
2007-01-16 03:42:04 +00:00
Reid Spencer
737ec5130e For PR1043:
Bye, Bye Booly. Remove the use of the bool type from non-upgraded test
cases and from grep expressions. The parser doesn't accept it and the
asm writer doesn't produce it any more.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33183 91177308-0d34-0410-b5e6-96231b3b80d8
2007-01-13 05:06:52 +00:00
Chris Lattner
cc78156a15 new testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@33023 91177308-0d34-0410-b5e6-96231b3b80d8
2007-01-08 23:03:19 +00:00
Reid Spencer
3b29264c11 This test case needs parameter attributes, manually upgrade and don't
run llvm-upgrade.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32926 91177308-0d34-0410-b5e6-96231b3b80d8
2007-01-05 18:38:33 +00:00
Reid Spencer
bf8955346a Update for change in parameter attributes syntax.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32923 91177308-0d34-0410-b5e6-96231b3b80d8
2007-01-05 18:34:20 +00:00
Reid Spencer
cfd09d9820 Wrap long RUN: line.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32922 91177308-0d34-0410-b5e6-96231b3b80d8
2007-01-05 18:33:43 +00:00
Reid Spencer
6b91775db6 Globals are not renamed any more.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32921 91177308-0d34-0410-b5e6-96231b3b80d8
2007-01-05 18:33:16 +00:00
Reid Spencer
c33a34ffba This test case needs zext and sext attributes so manually upgrade it and
don't run llvm-upgrade.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32920 91177308-0d34-0410-b5e6-96231b3b80d8
2007-01-05 18:31:56 +00:00
Chris Lattner
05a1416463 add missing flags
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32885 91177308-0d34-0410-b5e6-96231b3b80d8
2007-01-04 23:18:14 +00:00
Chris Lattner
e0170dfd2a new testcase
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32883 91177308-0d34-0410-b5e6-96231b3b80d8
2007-01-04 22:22:07 +00:00
Reid Spencer
7e6b4f7a6d For PR1070:
Tweak the RUN: lines of these tests to accommodate the renaming of
variables done by llvm-upgrade. The renaming occurs as a result of avoiding
name collisons for collapsed type planes. Conflicting names have a .u
(unsigned) or .s (signed) suffix added. This patch updates the grep
expression to accommodate the new names.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32815 91177308-0d34-0410-b5e6-96231b3b80d8
2007-01-02 05:55:05 +00:00
Reid Spencer
8aabc9eb23 For PR1070:
Revert previous patch now that llvm-upgrade can handle collapsed type
plane conversion properly.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32814 91177308-0d34-0410-b5e6-96231b3b80d8
2007-01-02 05:53:06 +00:00
Reid Spencer
eacb7020ec For PR950:
Update the test suite to accommodate the change from signed integer types
to signless integer types. The changes were of only a few kinds:

1. Make sure llvm-upgrade is run on the source which does the bulk of the
   changes automatically.

2. Change things like "grep 'int'" to "grep 'i32'"

3. In several tests bitcasting caused the same name to be reused in the
   same type plane. These had to be manually fixed. The fix was (generally)
   to leave the bitcast and provide the instruction with a new name. This
   should not affect the semantics of the test. In a few cases, the
   bitcasts were known to be superfluous and irrelevant to the test case
   so they were removed.

4. One test case uses a bytecode file which needed to be updated to the
   latest bytecode format.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32789 91177308-0d34-0410-b5e6-96231b3b80d8
2006-12-31 06:02:00 +00:00
Reid Spencer
73e70822ae Update tests that need to be run through llvm-upgrade. This is necessary
for upcoming changes to the llvm assembly grammar.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@32768 91177308-0d34-0410-b5e6-96231b3b80d8
2006-12-29 20:01:32 +00:00