Commit Graph

43529 Commits

Author SHA1 Message Date
Chris Lattner
1c39d4cfaa translateX86CC can never fail. Simplify it based on this.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61423 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-24 23:53:05 +00:00
Bill Wendling
722f5f1cfb Darwin likes for the EH frame to be non-local.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61420 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-24 08:05:17 +00:00
Bill Wendling
d4121bef3c GCC doesn't emit DW_EH_PE_sdata4 for the FDE encoding on Darwin. I'm not sure
about other platforms.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61415 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-24 05:25:49 +00:00
Bill Wendling
e5b7e0ec08 Revert the changes in this testcase until Anton can fix them.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61414 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-24 05:23:34 +00:00
Dan Gohman
82779704ff Fix a compiler-abort on a testcase where the stack-pointer is added to
a symbolic constant. This is unlikely to be intentional, but it
shouldn't crash the compiler.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61408 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-24 00:27:51 +00:00
Chris Lattner
4328708bad indentation
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61407 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-24 00:11:37 +00:00
Dale Johannesen
7c7bc722ec Change comments so everybody can understand them, hopefully.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61405 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 23:47:22 +00:00
Chris Lattner
4c78e0286a simplify some control flow and reduce indentation, no functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61404 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 23:42:27 +00:00
Dale Johannesen
f6727b01a5 Revert 61362 and 61402 until SPEC breakage is fixed.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61403 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 23:21:35 +00:00
Dale Johannesen
2fa2517324 This fixes the bug in 175.vpr. It doesn't fix the
other SPEC breakage.  I'll be reverting all recent
changes shortly, this checking is mostly so this
change doesn't get lost.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61402 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 23:05:26 +00:00
Dale Johannesen
f9cbc1f9ac Add another permutation where we should get rid of a-a.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61401 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 23:01:27 +00:00
Dan Gohman
c7a37d4ff2 Add instruction patterns and encodings for the x86 bt instructions.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61400 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 22:45:23 +00:00
Anton Korobeynikov
42a8bbce2c Update test
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61399 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 22:26:37 +00:00
Anton Korobeynikov
56d245ba8b Restore debug printing
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61398 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 22:26:18 +00:00
Anton Korobeynikov
e2f95e9b61 Sometimes APInt syntax is really ugly... :(
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61397 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 22:26:01 +00:00
Anton Korobeynikov
1bfe237d69 Indent stuff properly
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61396 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 22:25:45 +00:00
Anton Korobeynikov
2321858c8c Initial checkin of APInt'ififcation of switch lowering
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61395 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 22:25:27 +00:00
Devang Patel
fd1c6c3123 Silence unused variable warnings.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61392 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 21:56:28 +00:00
Devang Patel
d0935c3f43 Fix typo.
Silence unused variable warning.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61391 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 21:55:38 +00:00
Devang Patel
2755896fd0 Silience unused warnings.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61390 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 21:55:04 +00:00
Dan Gohman
0b1d4a798d Clean up the atomic opcodes in SelectionDAG.
This removes all the _8, _16, _32, and _64 opcodes and replaces each
group with an unsuffixed opcode. The MemoryVT field of the AtomicSDNode
is now used to carry the size information. In tablegen, the size-specific
opcodes are replaced by size-independent opcodes that utilize the
ability to compose them with predicates.

This shrinks the per-opcode tables and makes the code that handles
atomics much more concise.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61389 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 21:37:04 +00:00
Chris Lattner
9cf8ef63c6 add some notes for simplifylibcalls optimizations
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61385 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 20:52:52 +00:00
Chris Lattner
2e24342570 Testcase to show we can tie together integers and pointers of
the same size.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61380 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 18:52:26 +00:00
Steve Naroff
1f33f8e4cc Tweak --version to include the date and time.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61378 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 18:41:47 +00:00
Dan Gohman
c9a5b9e38b Rename BuildSchedUnits to BuildSchedGraph, and refactor the
code in ScheduleDAGSDNodes' BuildSchedGraph into separate functions.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61376 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 18:36:58 +00:00
Dan Gohman
1bda0541f0 Comment MO_FPImmediate and doxygenate surrounding comments.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61374 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 18:20:16 +00:00
Dan Gohman
237dee1259 Use isTerminator() instead of isBranch()||isReturn() in
several places. isTerminator() returns true for a superset
of cases, and includes things like FP_REG_KILL, which are
nither return or branch but aren't safe to move/remat/etc.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61373 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 17:28:50 +00:00
Dan Gohman
e1dfc7da89 Avoid an unnecessary call to allnodes_size(), which is linear.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61372 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 17:24:50 +00:00
Dan Gohman
1578f8486d Minor code simplifications.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61371 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 17:22:32 +00:00
Zhongxing Xu
f900f7b5a2 revert r61368.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61369 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 05:43:56 +00:00
Zhongxing Xu
fe5c8d08ff Remove dead code.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61368 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 05:30:44 +00:00
Mon P Wang
2fe269def2 Added shuffle and splat test cases for r61365.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61366 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 04:05:08 +00:00
Mon P Wang
62c75ea397 Fixed code generation for v8i16 and v16i8 splats on X86.
Fixed lowering of v8i16 shuffles for v8i16 when we fall back to extract/insert.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61365 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 04:03:27 +00:00
Dale Johannesen
e6ec25543f Fix the time regression I introduced in 464.h264ref with
my last patch to this file.

The issue there was that all uses of an IV inside a loop
are actually references to Base[IV*2], and there was one
use outside that was the same but LSR didn't see the base
or the scaling because it didn't recurse into uses outside
the loop; thus, it used base+IV*scale mode inside the loop
instead of pulling base out of the loop.  This was extra bad
because register pressure later forced both base and IV into
memory.  Doing that recursion, at least enough
to figure out addressing modes, is a good idea in general;
the change in AddUsersIfInteresting does this.  However,
there were side effects....

It is also possible for recursing outside the loop to
introduce another IV where there was only 1 before (if
the refs inside are not scaled and the ref outside is).
I don't think this is a common case, but it's in the testsuite.
It is right to be very aggressive about getting rid of
such introduced IVs (CheckForIVReuse and the handling of
nonzero RewriteFactor in StrengthReduceStridedIVUsers).
In the testcase in question the new IV produced this way
has both a nonconstant stride and a nonzero base, neither
of which was handled before.  And when inserting 
new code that feeds into a PHI, it's right to put such 
code at the original location rather than in the PHI's 
immediate predecessor(s) when the original location is outside 
the loop (a case that couldn't happen before)
(RewriteInstructionToUseNewBase); better to avoid making
multiple copies of it in this case.

Also, the mechanism for keeping SCEV's corresponding to GEP's
no longer works, as the GEP might change after its SCEV
is remembered, invalidating the SCEV, and we might get a bad
SCEV value when looking up the GEP again for a later loop.  
This also couldn't happen before, as we weren't recursing
into GEP's outside the loop.

I owe some testcases for this, want to get it in for nightly runs.



git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61362 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 02:12:52 +00:00
Dale Johannesen
58e39b0200 One more permutation of subtracting off a base value.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61361 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 01:59:54 +00:00
Owen Anderson
ae53c932b9 Don't forget to remove phi nodes from the value numbering table after we collapse them.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61358 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 00:49:51 +00:00
Dan Gohman
15a3a49e19 Make the fuse-failed debug output human-readable.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61356 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-23 00:19:20 +00:00
Bill Wendling
30788b828a Comment clean-ups. No functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61354 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-22 22:32:22 +00:00
Bill Wendling
6d463f2efc Check that the instruction isn't in the value numbering scope.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61353 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-22 22:28:56 +00:00
Bill Wendling
75f02ee771 Simplification: Negate the operator== method instead of implementing a full operator!= method.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61352 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-22 22:16:31 +00:00
Bill Wendling
70ded19b3f Add verification that deleted instruction isn't hiding in the PHI map.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61350 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-22 22:14:07 +00:00
Bill Wendling
ec40d50aa4 Verify removed in a few more places.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61349 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-22 21:57:30 +00:00
Bill Wendling
246dbbb8be Add verification functions to GVN which check to see that an instruction was
truely deleted. These will be expanded with further checks of all of the data
structures.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61347 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-22 21:36:08 +00:00
Dan Gohman
00d448a341 Refactor a bunch of code out of AsmPrinter::EmitGlobalConstant into separate
functions.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61345 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-22 21:14:27 +00:00
Dan Gohman
8044e9b3af Optimize setDepthDirty and setHeightDirty a little, as they showed
up on a profile.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61344 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-22 21:11:33 +00:00
Dan Gohman
361c31da5e Add an assertion to the ScheduleDAGInstrs class to catch SUnits
reallocations. We don't do cloning on MachineInstr schedule DAGs,
but this is a worthwhile sanity check regardless.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61343 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-22 21:08:08 +00:00
Dan Gohman
fb8a1356b2 Add an accesor for the isNormalMemory field in the SDep class.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61342 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-22 21:06:56 +00:00
Dan Gohman
983bbbaf36 Add an assertion to catch SUnits reallocations. And add a doxygen
comment for the ScheduleDAGSDNodes class.


git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61341 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-22 21:06:20 +00:00
Dan Gohman
b5544940c1 Clarify a comment.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61338 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-22 19:44:39 +00:00
Mikhail Glushenkov
a01ce0091a Use ignore & grep instead of XFAIL.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@61307 91177308-0d34-0410-b5e6-96231b3b80d8
2008-12-21 07:47:49 +00:00