Owen Anderson
0b0017e514
Avoid a redundant call.
...
llvm-svn: 53040
2008-07-02 18:15:31 +00:00
Owen Anderson
e20158affb
Add support to ADCE for pruning unreachable blocks. This addresses the final
...
part of PR2509.
llvm-svn: 53038
2008-07-02 18:05:19 +00:00
Duncan Sands
21e2a711e3
Add a new getMergeValues method that does not need
...
to be passed the list of value types, and use this
where appropriate. Inappropriate places are where
the value type list is already known and may be
long, in which case the existing method is more
efficient.
llvm-svn: 53035
2008-07-02 17:40:58 +00:00
Owen Anderson
764fe3df94
Use DenseSet rather than SmallPtrSet for the alive set. Using SmallPtrSet
...
with a huge "size" parameter is actually quite inefficient.
llvm-svn: 53034
2008-07-02 17:32:04 +00:00
Owen Anderson
5747d627e0
A better fix for PR2503 that doesn't pessimize GVN in the presence of unreachable blocks.
...
llvm-svn: 53032
2008-07-02 17:20:16 +00:00
Mon P Wang
55f4371807
Fixed problem in EmitStackConvert where the source and target type
...
have different alignment by creating a stack slot with the max
alignment of source and target type.
llvm-svn: 53031
2008-07-02 17:07:12 +00:00
Chris Lattner
8bcad39c9a
instead of aborting on shifts of i1, just implicitly fold them.
...
The dag combiner can produce a shift of i1 when folding icmp i1's.
llvm-svn: 53030
2008-07-02 17:01:57 +00:00
Duncan Sands
b7d8348f0d
Fix typo compounded by a cut-and-pasto.
...
llvm-svn: 53012
2008-07-02 10:03:53 +00:00
Duncan Sands
5d5f1e800d
Let AnalyzeNewNode take care of calling ExpungeNode.
...
This makes sure that all new nodes are expunged, not
just those the top node of a new subtree.
llvm-svn: 53011
2008-07-02 09:56:41 +00:00
Evan Cheng
3921085102
- Use a faster priority comparison function if -fast.
...
- Code clean up.
llvm-svn: 53010
2008-07-02 09:23:51 +00:00
Chris Lattner
06545d1c4a
Add a new (simple) StringMap::clear method, patch by Pratik
...
Solanki!
llvm-svn: 53008
2008-07-02 05:26:32 +00:00
Devang Patel
5d8e832471
reuse vectors.
...
llvm-svn: 53007
2008-07-02 01:44:29 +00:00
Devang Patel
9140e998b4
Fix comment.
...
llvm-svn: 53006
2008-07-02 01:31:19 +00:00
Devang Patel
68d9a25bcd
Preserve loop data so that it is not fetched everytime it is needed.
...
Keep track of currentLoop.
llvm-svn: 53005
2008-07-02 01:18:13 +00:00
Bill Wendling
83caf5a9d5
Use the canonical form for getting an empty structure.
...
llvm-svn: 53003
2008-07-02 00:50:02 +00:00
Bill Wendling
aa45e38a17
Sorry. I couldn't sleep at night knowing I put these ugly casts into the source tree.
...
llvm-svn: 53001
2008-07-02 00:35:47 +00:00
Owen Anderson
1530481dd3
Add a version of AddString that takes a const char* so we can avoid extraneous
...
conversions to std::string.
llvm-svn: 52995
2008-07-01 23:49:59 +00:00
Bill Wendling
27c38cee90
Darwin doesn't need exception handling information for the "move" info when
...
debug information is being output, because it's leet!
llvm-svn: 52994
2008-07-01 23:34:48 +00:00
Evan Cheng
5389352c98
Avoid creating expensive comment string if it's not going to be printed.
...
llvm-svn: 52992
2008-07-01 23:18:29 +00:00
Owen Anderson
b258a71a37
No need to use std::distance. We can just count the number of operands
...
much more cheaply.
llvm-svn: 52990
2008-07-01 22:34:11 +00:00
Evan Cheng
508e82fcfc
Simplify addRegisterKilled and addRegisterDead.
...
llvm-svn: 52988
2008-07-01 22:21:21 +00:00
Bill Wendling
c695823456
- Update comments.
...
- Don't use GlobalVariable::LinkageTypes when unsigned works.
llvm-svn: 52987
2008-07-01 22:08:01 +00:00
Dale Johannesen
d7ea0ac4fd
Fix longstanding thinko: don't exclude
...
predessors of exit blocks from tail merging
consideration.
llvm-svn: 52985
2008-07-01 21:50:14 +00:00
Devang Patel
a4a94290b8
Disable dom info verifier by default.
...
llvm-svn: 52983
2008-07-01 21:36:11 +00:00
Evan Cheng
8a30a09180
Eliminate a compile time warning.
...
llvm-svn: 52982
2008-07-01 21:35:46 +00:00
Owen Anderson
8564cd9dfe
Add a version of AsmPrinter::EOL that takes a const char* so that we don't have to do as many implicit std::string constructions.
...
Unfortunately, this doesn't appear to translate to a real speedup in practice.
llvm-svn: 52981
2008-07-01 21:16:27 +00:00
Bill Wendling
d7ccfdb867
Remove warning about initialization order.
...
llvm-svn: 52980
2008-07-01 21:00:31 +00:00
Devang Patel
0fc2badc38
Fix typos in comments.
...
Thanks for the feedback!
llvm-svn: 52978
2008-07-01 19:50:56 +00:00
Dan Gohman
83c1b4cede
Prune a few dependencies on MachineFunction.h.
...
llvm-svn: 52976
2008-07-01 18:15:35 +00:00
Evan Cheng
9a960dc2b2
Do run ComputeLiveOutVRegInfo with -fast.
...
llvm-svn: 52975
2008-07-01 18:15:04 +00:00
Evan Cheng
67ce381ffe
Do not use computationally expensive scheduling heuristics with -fast.
...
llvm-svn: 52971
2008-07-01 18:05:03 +00:00
Evan Cheng
b33d6b69ab
Apply Chris' suggestion.
...
llvm-svn: 52970
2008-07-01 17:59:20 +00:00
Devang Patel
1e1f4a0bdd
Add dom info verifier.
...
llvm-svn: 52967
2008-07-01 17:44:24 +00:00
Owen Anderson
fe73cb09c8
Make the subregister hashtable output more readable by wrapping the lines,
...
and mark it const along with the associated changes to TargetRegisterInfo.
llvm-svn: 52966
2008-07-01 17:34:38 +00:00
Duncan Sands
d8d11501c9
Highlight that getMergeValues optimization is
...
being suppressed here.
llvm-svn: 52952
2008-07-01 08:00:49 +00:00
Owen Anderson
99a71c6ac6
Properly handle cases where a predecessor of the block being queried on is unreachable.
...
This fixes PR2503, though we should also fix other passes not to emit this kind of code.
llvm-svn: 52946
2008-07-01 00:40:58 +00:00
Owen Anderson
059d64938b
Replace the dynamically computed std::set lookup method for subregisters with a hashtable-based
...
version that is computed by tblgen at the time LLVM is compiled.
llvm-svn: 52945
2008-07-01 00:18:52 +00:00
Dan Gohman
e3b796a81d
Minimize duplicated code in AsmPrinter::printLabel.
...
llvm-svn: 52944
2008-07-01 00:16:26 +00:00
Dan Gohman
c8097f8c8c
Split ISD::LABEL into ISD::DBG_LABEL and ISD::EH_LABEL, eliminating
...
the need for a flavor operand, and add a new SDNode subclass,
LabelSDNode, for use with them to eliminate the need for a label id
operand.
Change instruction selection to let these label nodes through
unmodified instead of creating copies of them. Teach the MachineInstr
emitter how to emit a MachineInstr directly from an ISD label node.
This avoids the need for allocating SDNodes for the label id and
flavor value, as well as SDNodes for each of the post-isel label,
label id, and label flavor.
llvm-svn: 52943
2008-07-01 00:05:16 +00:00
Evan Cheng
a40bb75480
Suppress compiler warning.
...
llvm-svn: 52934
2008-06-30 22:33:56 +00:00
Evan Cheng
488fdf516f
Don't run stack slot coloring if -fast.
...
llvm-svn: 52933
2008-06-30 22:33:16 +00:00
Dan Gohman
e9f33e576d
Don't use ISD namespace opcodes for MachineInstrs.
...
llvm-svn: 52932
2008-06-30 22:23:08 +00:00
Dan Gohman
082b08f33a
Use a simpler but equivalent form of RecordSource.
...
llvm-svn: 52931
2008-06-30 22:21:03 +00:00
Evan Cheng
3ec3837c38
Add timing report for various sub-passes under SelectionDAGISel.
...
llvm-svn: 52930
2008-06-30 22:10:09 +00:00
Dan Gohman
c8c04b1ff4
std::ostream and std::string microoptimizations for asm printing.
...
llvm-svn: 52929
2008-06-30 22:03:41 +00:00
Dan Gohman
9997cc353f
Use reserve.
...
SelectionDAG::allnodes_size is linear, but that doesn't appear to
outweigh the benefit of reducing heap traffic. If it does become a
problem, we should teach SelectionDAG to keep a count of how many
nodes are live, because there are several other places where that
information would be useful as well.
llvm-svn: 52926
2008-06-30 21:04:06 +00:00
Dan Gohman
e58f07e5d6
Update comments to new-style syntax.
...
llvm-svn: 52925
2008-06-30 21:00:56 +00:00
Dan Gohman
6cc648891b
Rename ISD::LOCATION to ISD::DBG_STOPPOINT to better reflect its
...
purpose, and give it a custom SDNode subclass so that it doesn't
need to have line number, column number, filename string, and
directory string, all existing as individual SDNodes to be the
operands.
This was the only user of ISD::STRING, StringSDNode, etc., so
remove those and some associated code.
This makes stop-points considerably easier to read in
-view-legalize-dags output, and reduces overhead (creating new
nodes and copying std::strings into them) on code containing
debugging information.
llvm-svn: 52924
2008-06-30 20:59:49 +00:00
Evan Cheng
3f664b6fd3
Split scheduling from instruction selection.
...
llvm-svn: 52923
2008-06-30 20:45:06 +00:00
Dale Johannesen
30d136e2c6
No need to align the stack if there are no stack
...
objects. Fixes a couple of tests on Linux.
llvm-svn: 52921
2008-06-30 20:40:16 +00:00