Commit Graph

4865 Commits

Author SHA1 Message Date
Lauro Ramos Venancio bb979f4b1c Update testcase.
llvm-svn: 47735
2008-02-28 23:13:15 +00:00
Gabor Greif f77e6977a0 Fix http://llvm.org/bugs/show_bug.cgi?id=2104 by ordering lexicographically what gets printed. Be const-correct in PrintResults and uninline it too
llvm-svn: 47712
2008-02-28 08:38:45 +00:00
Evan Cheng 507713de08 Set to default: x86 no longer fold and into test if it has more than one use.
llvm-svn: 47711
2008-02-28 07:46:38 +00:00
Dale Johannesen 820de906b1 New test for misaligned Altivec laod/store.
llvm-svn: 47698
2008-02-27 23:14:50 +00:00
Dan Gohman 26854f242e 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.

llvm-svn: 47692
2008-02-27 21:12:32 +00:00
Evan Cheng fdc732ab9a Fix a bug in dead spill slot elimination.
llvm-svn: 47687
2008-02-27 19:57:11 +00:00
Chris Lattner 3df31ba41b actually run llc, thanks Dan :)
llvm-svn: 47677
2008-02-27 17:46:54 +00:00
Evan Cheng 8ae8e2d50b Don't track max alignment during stack object allocations since they can be deleted later. Let PEI compute it.
llvm-svn: 47668
2008-02-27 10:04:56 +00:00
Chris Lattner 83263b8cfb Make X86TargetLowering::LowerSINT_TO_FP return without creating a dead
stack slot and store if the  SINT_TO_FP is actually legal.  This allows
us to compile:

double a(double b) {return (unsigned)b;}

to:

_a:
	cvttsd2siq	%xmm0, %rax
	movl	%eax, %eax
	cvtsi2sdq	%rax, %xmm0
	ret

instead of:

_a:
	subq	$8, %rsp
	cvttsd2siq	%xmm0, %rax
	movl	%eax, %eax
	cvtsi2sdq	%rax, %xmm0
	addq	$8, %rsp
	ret

crazy.

llvm-svn: 47660
2008-02-27 05:57:41 +00:00
Chris Lattner 3c7d3d5700 Compile x86-64-and-mask.ll into:
_test:
	movl	%edi, %eax
	ret

instead of:

_test:
        movl    $4294967295, %ecx
        movq    %rdi, %rax
        andq    %rcx, %rax
        ret

It would be great to write this as a Pat pattern that used subregs 
instead of a 'pseudo' instruction, but I don't know how to do that
in td files.

llvm-svn: 47658
2008-02-27 05:47:54 +00:00
Evan Cheng 6d56368caf Spiller now remove unused spill slots.
llvm-svn: 47657
2008-02-27 03:04:06 +00:00
Bill Wendling 30075852ef Upgrade testcase.
llvm-svn: 47644
2008-02-26 23:22:40 +00:00
Owen Anderson e41c19c987 Add PR number to testcase.
llvm-svn: 47640
2008-02-26 23:16:11 +00:00
Owen Anderson d29ed0b122 Fix an issue where GVN had the sizes of the two memcpy's reverse, resulting
in an invalid transformation.

llvm-svn: 47639
2008-02-26 23:06:17 +00:00
Evan Cheng fa6b366892 Enable -coalescer-commute-instrs by default.
llvm-svn: 47623
2008-02-26 20:40:22 +00:00
Dan Gohman 9db0aa86d9 Avoid aborting on invalid shift counts.
llvm-svn: 47612
2008-02-26 18:50:50 +00:00
Eli Friedman 666bbe34f4 Fix for pr2093: direct operands aren't necessarily addresses, so don't
try to simplify them.

llvm-svn: 47610
2008-02-26 18:37:49 +00:00
Chris Lattner a39cff3aaa fix this test so that the fn name doesn't match the regex
llvm-svn: 47608
2008-02-26 18:13:51 +00:00
Chris Lattner 07c83cc86e Fix PR2096, a regression introduced with my patch last night. This
also fixes cfrac, flops, and 175.vpr

llvm-svn: 47605
2008-02-26 17:09:59 +00:00
Gabor Greif 3d9755f6ca Really feed llvm-as with the testcase, do not let it read from stdin. This fixes the hangs seen on solaris10.
llvm-svn: 47604
2008-02-26 13:37:13 +00:00
Gabor Greif 0a43601153 unbreak check-one
by supplying a dummy
"verbose" procedure

llvm-svn: 47603
2008-02-26 13:27:49 +00:00
Gabor Greif d5691031f5 While hunting for two hanging tests,
(on solaris10, which are:
  CodeGen/PowerPC/frounds.ll
  Transforms/InstCombine/2008-02-23-MulSub.ll)

I needed a tool to figure out which one is the guilty.

To this end I have added a verbosity
option to the test/Makefile.

It can be invoked thus:

gmake check TESTSUITE=CodeGen/PowerPC VERBOSE="-v -v"

(The number of "-v"s specifies the verbosity level.
 Instead of "-v" other aliases can be specified,
 please consult the dejagnu docs for info.)

At level >= 2 following line is logged for each
test, before running it:

ABOUT TO RUN: <test>.ll

llvm-svn: 47602
2008-02-26 12:08:55 +00:00
Evan Cheng 2ff0b0e681 This is possible:
vr1 = extract_subreg vr2, 3
...
vr3 = extract_subreg vr1, 2
The end result is vr3 is equal to vr2 with subidx 2.

llvm-svn: 47592
2008-02-26 08:03:41 +00:00
Chris Lattner e7c14013f5 Fix isNegatibleForFree to not return true for ConstantFP nodes
after legalize.  Just because a constant is legal (e.g. 0.0 in SSE) 
doesn't mean that its negated value is legal (-0.0).  We could make
this stronger by checking to see if the negated constant is actually
legal post negation, but it doesn't seem like a big deal.

llvm-svn: 47591
2008-02-26 07:04:54 +00:00
Evan Cheng 1da250097b Fix PR2076. CodeGenPrepare now sinks address computation for inline asm memory
operands into inline asm block.

llvm-svn: 47589
2008-02-26 02:42:37 +00:00
Devang Patel bbfd874cb4 Update bitcode reader and writer to handle multiple return values.
Take 2.

llvm-svn: 47583
2008-02-26 01:29:32 +00:00
Owen Anderson df1d2b02f9 Fix an issue where GVN was performing the return slot optimization when it was
not safe.  This is fixed by more aggressively checking that the return slot is
not used elsewhere in the function.

llvm-svn: 47544
2008-02-25 04:08:09 +00:00
Evan Cheng 01d6257e81 Temporarily reverting 46959.
llvm-svn: 47542
2008-02-25 03:57:32 +00:00
Owen Anderson 40dca46ddb Fix an issue where GVN would try to use an instruction before its definition when performing return slot optimization.
llvm-svn: 47541
2008-02-25 00:40:41 +00:00
Evan Cheng 2f18c39720 Backing out r47521 for now. This has broken a number of tests.
llvm-svn: 47533
2008-02-23 19:32:32 +00:00
Scott Michel 7d5eaec6dd Merge current work back to tree to minimize diffs and drift. Major highlights
for CellSPU modifications:

- SPUInstrInfo.td refactoring: "multiclass" really is _your_ friend.
- Other improvements based on refactoring effort in SPUISelLowering.cpp,
  esp. in SPUISelLowering::PerformDAGCombine(), where zero amount shifts and
  rotates are now eliminiated, other scalar-to-vector-to-scalar silliness
  is also eliminated.
- 64-bit operations are being implemented, _muldi3.c gcc runtime now
  compiles and generates the right code. More work still needs to be done.

llvm-svn: 47532
2008-02-23 18:41:37 +00:00
Zhou Sheng aae582ba99 Testcase for Revision 47478.
llvm-svn: 47531
2008-02-23 10:59:51 +00:00
Evan Cheng 504c645b3e Rematerialization logic was overly conservative when it comes to loads from fixed stack slots.
llvm-svn: 47529
2008-02-23 03:38:34 +00:00
Evan Cheng 405827dc26 Update test.
llvm-svn: 47527
2008-02-23 02:57:25 +00:00
Evan Cheng 174ef9a0bb Remat of pic loads are now on by default.
llvm-svn: 47525
2008-02-23 02:08:30 +00:00
Dan Gohman 63d2d1f554 Fix a bug that caused opt and other tools to silently ignore
invalid command-line options.

llvm-svn: 47523
2008-02-23 01:55:25 +00:00
Devang Patel 6a49782d33 Properly read and write bitcodes for multiple return values.
llvm-svn: 47521
2008-02-23 01:44:55 +00:00
Evan Cheng 26e5d01ca1 Really. Why doesn't every arch support MMX?
llvm-svn: 47513
2008-02-23 00:56:14 +00:00
Evan Cheng cee351c410 Test case for PR2082.
llvm-svn: 47501
2008-02-22 20:38:49 +00:00
Evan Cheng 94ba37f8e3 Allow re-materialization of pic load (controlled by -remat-pic-load for now).
llvm-svn: 47476
2008-02-22 09:25:47 +00:00
Chris Lattner ab8bfc28c8 copy mmx values from/to memory with GPRs on x86-32
instead of with mmx registers.  This horribleness is apparently
done by gcc to avoid having to insert emms in places that really 
should have it.  This is the second half of rdar://5741668.

llvm-svn: 47474
2008-02-22 05:18:04 +00:00
Chris Lattner 997b3a65ca Start using GPR's to copy around mmx value instead of mmx regs.
GCC apparently does this, and code depends on not having to do
emms when this happens.  This is x86-64 only so far, second half
should handle x86-32.

rdar://5741668

llvm-svn: 47470
2008-02-22 02:09:43 +00:00
Chris Lattner bdd4c8b04d Treat clobber operands like early clobbers: if we have
any, we force sdisel to do all regalloc for an asm.  This
leads to gross but correct codegen.

This fixes the rest of PR2078.

llvm-svn: 47454
2008-02-21 19:43:13 +00:00
Tanya Lattner 3cdf542f5a Remove llvm-upgrade and update tests.
llvm-svn: 47432
2008-02-21 07:42:26 +00:00
Chris Lattner 59f18b4de6 testcase for PR1133
llvm-svn: 47427
2008-02-21 05:27:08 +00:00
Chris Lattner 83c93d5afd Fix a (harmless) but where vregs were added to the used reg lists for
inline asms.

Fix PR2078 by marking aliases of registers used when a register is 
marked used.  This prevents EAX from being allocated when AX is listed
in the clobber set for the asm.

llvm-svn: 47426
2008-02-21 04:55:52 +00:00
Devang Patel ad582fc34b Let invoke return aggregate value.
llvm-svn: 47425
2008-02-21 02:14:01 +00:00
Devang Patel 1f00b535e1 Let function call return aggregate.
Now, we have very first multiple return value testcase!

llvm-svn: 47424
2008-02-21 01:54:02 +00:00
Devang Patel fe988eba4b XFAIL for now.
llvm-svn: 47411
2008-02-20 23:10:42 +00:00
Devang Patel b2aa6fe905 Now functions can return aggregate values.
llvm-svn: 47409
2008-02-20 22:51:28 +00:00