1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-20 19:42:54 +02:00
Commit Graph

54040 Commits

Author SHA1 Message Date
Chris Lattner
b976027c91 should not commit when distracted.
llvm-svn: 86929
2009-11-12 02:04:17 +00:00
Dan Gohman
b6f852353a Make the BranchFolderPass class local to BranchFolding.cpp.
llvm-svn: 86928
2009-11-12 01:59:26 +00:00
Chris Lattner
32bb09e867 We now thread some impossible condition information with LVI.
llvm-svn: 86927
2009-11-12 01:55:20 +00:00
Dan Gohman
8931850b74 Minor code cleanups.
llvm-svn: 86926
2009-11-12 01:51:28 +00:00
Chris Lattner
68f3b53ddc with the new code we can thread non-instruction values. This
allows us to handle the test10 testcase.

llvm-svn: 86924
2009-11-12 01:41:34 +00:00
Chris Lattner
ea8b237a74 this argument can be an arbitrary value, it doesn't need to be an instruction.
llvm-svn: 86923
2009-11-12 01:37:43 +00:00
Chris Lattner
b5bb115ece expose edge information and switch j-t to use it.
llvm-svn: 86920
2009-11-12 01:29:10 +00:00
Lang Hames
41dcc7ba71 Fixed an iteration condition in PreAllocSplitting. This should fix some miscompilations casued by PreAllocSplitting.
llvm-svn: 86919
2009-11-12 01:24:08 +00:00
Chris Lattner
46056d81aa move some stuff into DEBUG's and turn on lazy-value-info for
the basic.ll testcase.

llvm-svn: 86918
2009-11-12 01:22:16 +00:00
Eric Christopher
1764cc3934 Fix typo, cleanup whitespace.
llvm-svn: 86917
2009-11-12 01:06:08 +00:00
Devang Patel
c70b8eefb7 Do not use StringRef in DebugInfo interface.
This allows StringRef to skip controversial if(str) check in constructor.
Buildbots, wait for corresponding clang and llvm-gcc FE check-ins!

llvm-svn: 86914
2009-11-12 00:50:58 +00:00
Dan Gohman
f8ec4856e4 Tail merge at any size when there are two potentials blocks and one
can be made to fall through into the other.

llvm-svn: 86909
2009-11-12 00:39:10 +00:00
Bill Wendling
cfdaf6609a Don't mark a call as potentially throwing if the function it's calling has the
"nounwind" attribute.

llvm-svn: 86897
2009-11-11 23:17:02 +00:00
Bruno Cardoso Lopes
99e65b8707 A real solution for the first part of PR5445
llvm-svn: 86895
2009-11-11 23:09:33 +00:00
Chris Lattner
4c831006c7 make LazyValueInfo actually to some stuff. This isn't very tested but improves
strswitch.

llvm-svn: 86889
2009-11-11 22:48:44 +00:00
Chris Lattner
73b7ed2d9c pass TD into a SimplifyCmpInst call. Add another case that
uses LVI info when -enable-jump-threading-lvi is passed.

llvm-svn: 86886
2009-11-11 22:31:38 +00:00
Dan Gohman
93c57d5ff0 Promote MergePotentialsElt and SameTailElt to be regular classes
instead of typedefs for std::pair. This simplifies the type of
SameTails, which previously was std::vector<std::pair<std::vector<std::pair<unsigned, MachineBasicBlock *> >::iterator, MachineBasicBlock::iterator>

llvm-svn: 86885
2009-11-11 21:57:02 +00:00
Kenneth Uildriks
82bc831061 x86 users can now return arbitrary sized structs. Structs too large to fit in return registers will be returned through a hidden sret parameter introduced during SelectionDAG construction.
llvm-svn: 86876
2009-11-11 19:59:24 +00:00
Dan Gohman
9623ba83ce Revert this line of 86871.
llvm-svn: 86875
2009-11-11 19:56:05 +00:00
Devang Patel
e37dd6ef40 If doesSupportDebugInformation() is false then do not try to emit dwarf debug info.
llvm-svn: 86874
2009-11-11 19:55:08 +00:00
Dan Gohman
05a9a66c9e Check in the changes to this file too.
llvm-svn: 86873
2009-11-11 19:49:34 +00:00
Dan Gohman
9f47de10e3 Add support for tail duplication to BranchFolding, and extend
tail merging support to handle more cases.
 - Recognize several cases where tail merging is beneficial even when
   the tail size is smaller than the generic threshold.
 - Make use of MachineInstrDesc::isBarrier to help detect
   non-fallthrough blocks.
 - Check for and avoid disrupting fall-through edges in more cases.

llvm-svn: 86871
2009-11-11 19:48:59 +00:00
Jakob Stoklund Olesen
01582996dd Fix liveness calculation when splitting critical edges during PHI elimination.
- Edges are split before any phis are eliminated, so the code is SSA.

- Create a proper IR BasicBlock for the split edges.

- LiveVariables::addNewBlock now has same syntax as
  MachineDominatorTree::addNewBlock. Algorithm calculates predecessor live-out
  set rather than successor live-in set.

This feature still causes some miscompilations.

llvm-svn: 86867
2009-11-11 19:31:31 +00:00
Devang Patel
630136fb86 Reenable StackTracke.cpp test.
llvm-svn: 86861
2009-11-11 19:08:42 +00:00
Devang Patel
304b516363 Add SetDebugLocation() variant to
add debug info location to an instruction.

llvm-svn: 86859
2009-11-11 19:06:06 +00:00
Evan Cheng
a11308742c Add TargetLowering::isLegalICmpImmediate. It tells LSR what immediate can be folded into target icmp instructions.
llvm-svn: 86858
2009-11-11 19:05:52 +00:00
Jim Grosbach
9ecdde2be4 Do jump table adjustment before constant island allocation
llvm-svn: 86857
2009-11-11 19:04:24 +00:00
Dan Gohman
b0f32c095c Fix indentation level.
llvm-svn: 86856
2009-11-11 18:42:28 +00:00
Dan Gohman
b72c986b78 Whitespace cleanups.
llvm-svn: 86855
2009-11-11 18:38:14 +00:00
Dan Gohman
60b5c20890 Prefix MBB numbers with "BB#" in debug output to make it clear what
the numbers mean.

llvm-svn: 86854
2009-11-11 18:23:17 +00:00
Dan Gohman
281338a3d2 Minor code simplification.
llvm-svn: 86853
2009-11-11 18:18:34 +00:00
Dan Gohman
574137b4c0 Fix a copy+pasto in a comment.
llvm-svn: 86852
2009-11-11 18:14:02 +00:00
Dan Gohman
4631d78a3b Set isBarrier = 1 on return instructions, as they are control barriers.
llvm-svn: 86851
2009-11-11 18:11:07 +00:00
Dan Gohman
3045fc7514 Use a tab in INT3's asm string, for consistency.
llvm-svn: 86850
2009-11-11 18:07:16 +00:00
Chris Lattner
0dd2fe1e1e another const prop failure.
llvm-svn: 86848
2009-11-11 17:54:02 +00:00
Chris Lattner
20da198cb6 add a note
llvm-svn: 86847
2009-11-11 17:51:27 +00:00
Chris Lattner
a3457e6bae Reject duplicate case values in a switch, PR5450.
llvm-svn: 86846
2009-11-11 17:37:02 +00:00
Duncan Sands
f0d9823d0b Don't trivially delete unused calls to llvm.invariant.start. This allows
llvm.invariant.start to be used without necessarily being paired with a call
to llvm.invariant.end.  If you run the entire optimization pipeline then such
calls are in fact deleted (adce does it), but that's actually a good thing since
we probably do want them to be zapped late in the game.  There should really be
an integration test that checks that the llvm.invariant.start call lasts long
enough that all passes that do interesting things with it get to do their stuff
before it is deleted.  But since no passes do anything interesting with it yet
this will have to wait for later.

llvm-svn: 86840
2009-11-11 15:34:13 +00:00
Evan Cheng
913687616e Add nounwind.
llvm-svn: 86814
2009-11-11 07:11:02 +00:00
Chris Lattner
36009e416c remove the now dead condprop pass, PR3906.
llvm-svn: 86810
2009-11-11 05:56:35 +00:00
Jeffrey Yasskin
92dc6cb703 Fix JITTest.ModuleDeletion in -Asserts mode (which turns off JITEmitDebugInfo
by default).

llvm-svn: 86807
2009-11-11 05:30:02 +00:00
Chris Lattner
746b4b7f2a remove condprop testcases.
llvm-svn: 86804
2009-11-11 05:25:16 +00:00
Daniel Dunbar
da387a1c25 Add StringRef::split(StringRef), to complement StringRef::split(char).
llvm-svn: 86803
2009-11-11 05:19:11 +00:00
Rafael Espindola
cea17df39c Remove dead code.
llvm-svn: 86802
2009-11-11 04:10:24 +00:00
Sandeep Patel
a167903217 Show command-line args and features passed into backend in debug output. Approved by Evan Cheng.
llvm-svn: 86797
2009-11-11 03:23:46 +00:00
Daniel Dunbar
def4580a85 Add missing run line. Devang, please check.
llvm-svn: 86795
2009-11-11 03:10:03 +00:00
Daniel Dunbar
d29c05945a Fix -Asserts warning.
llvm-svn: 86794
2009-11-11 03:09:50 +00:00
Jim Grosbach
d7aab5323b The TBB and TBH instructions for Thumb2 are really handy for jump tables, but
can only branch forward. To best take advantage of them, we'd like to adjust
the basic blocks around a bit when reasonable. This patch puts basics in place
to do that, with a super-simple algorithm for backwards jump table targets that
creates a new branch after the jump table which branches backwards. Real
heuristics for reordering blocks or other modifications rather than inserting
branches will follow.

llvm-svn: 86791
2009-11-11 02:47:19 +00:00
Chris Lattner
b45381c3f0 stub out some LazyValueInfo interfaces, and have JumpThreading
start using them in a trivial way when -enable-jump-threading-lvi
is passed.  enable-jump-threading-lvi will be my playground for 
awhile.

llvm-svn: 86789
2009-11-11 02:08:33 +00:00
Bill Wendling
a6d7a411d3 Fix test to work on every platform.
llvm-svn: 86786
2009-11-11 01:44:22 +00:00