1
0
mirror of https://github.com/RPCS3/llvm-mirror.git synced 2024-10-20 03:23:01 +02:00
Commit Graph

39679 Commits

Author SHA1 Message Date
Dan Gohman
081848d881 Make SmallVector's grow use memcpy in common cases
instead of std::uninitialized_copy, which uses memmove.

llvm-svn: 52928
2008-06-30 21:45:13 +00:00
Dan Gohman
06ca992a01 Use plain operator new instead of new char[].
llvm-svn: 52927
2008-06-30 21:33:02 +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
Ted Kremenek
834afcfdcd Added some comments and some cleanups.
llvm-svn: 52922
2008-06-30 20:41:22 +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
Evan Cheng
a83d69e3b9 Remove unneeded include.
llvm-svn: 52920
2008-06-30 20:38:22 +00:00
Dan Gohman
a44757308c Reorder the fields in TargetLowering to require less padding.
llvm-svn: 52919
2008-06-30 20:36:26 +00:00
Dan Gohman
7c7639816b Change bools to 1-bit bitfields to shrink ArgListEntry slightly.
llvm-svn: 52918
2008-06-30 20:33:57 +00:00
Dan Gohman
295abfe228 Replace some std::vectors that showed up in heap profiling with
SmallVectors. Change the signature of TargetLowering::LowerArguments
to avoid returning a vector by value, and update the two targets
which still use this directly, Sparc and IA64, accordingly.

llvm-svn: 52917
2008-06-30 20:31:15 +00:00
Owen Anderson
8d6d17cd2c Add an isReachableFromEntry method.
llvm-svn: 52916
2008-06-30 20:28:02 +00:00
Dan Gohman
62c0b69aec Correct the allocation size for CCState's UsedRegs member, which
only needs one bit for each register. UsedRegs is a SmallVector
sized at 16, so this eliminates a heap allocation/free for every
call and return processed by Legalize on most targets.

llvm-svn: 52915
2008-06-30 20:25:31 +00:00
Devang Patel
41de5d3b17 Rename new lto2 tool as lto.
lto2->lto

llvm-svn: 52912
2008-06-30 18:15:01 +00:00
Ted Kremenek
70f042f0a1 Added ImmutableList, a companion ADT to ImmutableSet and ImmutableMap that is used to represent a purely functional list.
llvm-svn: 52911
2008-06-30 18:07:38 +00:00
Devang Patel
4a5fac1990 Remove old LTO interface.
llvm-svn: 52910
2008-06-30 18:05:29 +00:00
Devang Patel
e4fccc657e Remove old LTO interface.
llvm-svn: 52909
2008-06-30 18:04:55 +00:00
Chris Lattner
9adb1b56de add convenience 'constructors'
llvm-svn: 52908
2008-06-30 18:02:44 +00:00
Devang Patel
5b8e75e2fe Move dominator info printer into tool/opt/GraphPrinters.cpp
llvm-svn: 52907
2008-06-30 17:32:58 +00:00
Duncan Sands
93d7b1b4fa ExpungeNode is only needed for new nodes! This
fixes CodeGen/PowerPC/2008-06-19-LegalizerCrash.ll
when using the new LegalizeTypes infrastructure.

llvm-svn: 52903
2008-06-30 16:43:45 +00:00
Duncan Sands
c68385d4b5 Support for VAARG. As noted in a comment, this is
wrong for types like x86 long double and i1, but
no worse than what is done in LegalizeDAG.

llvm-svn: 52898
2008-06-30 13:55:15 +00:00
Duncan Sands
a706115957 Support for promoting select_cc operands.
llvm-svn: 52895
2008-06-30 11:50:11 +00:00
Cedric Venet
4036419ff8 Add loopVR files.
Users of VS need to manually force rebuild the X86 projet to use the last version of tablegen.

llvm-svn: 52894
2008-06-30 10:31:41 +00:00
Duncan Sands
c882a4eba9 Revert the SelectionDAG optimization that makes
it impossible to create a MERGE_VALUES node with
only one result: sometimes it is useful to be able
to create a node with only one result out of one of
the results of a node with more than one result, for
example because the new node will eventually be used
to replace a one-result node using ReplaceAllUsesWith,
cf X86TargetLowering::ExpandFP_TO_SINT.  On the other
hand, most users of MERGE_VALUES don't need this and
for them the optimization was valuable.  So add a new
utility method getMergeValues for creating MERGE_VALUES
nodes which by default performs the optimization.
Change almost everywhere to use getMergeValues (and
tidy some stuff up at the same time).

llvm-svn: 52893
2008-06-30 10:19:09 +00:00
Evan Cheng
421919a049 Eliminate TargetRegisterDesc::ImmSubRegs. It's no longer in use.
llvm-svn: 52892
2008-06-30 07:32:56 +00:00
Evan Cheng
2005804de6 - Re-apply 52748 and friends with fix. GetConstantStringInfo() returns an empty string for ConstantAggregateZero case which surprises selectiondag.
- Correctly handle memcpy from constant string which is zero-initialized.

llvm-svn: 52891
2008-06-30 07:31:25 +00:00
Chris Lattner
6a22216d7a check in anton's patch to make inlining happen in a determinstic order
and fix the bug that it uncovers: inlining a pattern fragment could bring
in other pattern fragments if the inlinee hadn't already been inlined.

llvm-svn: 52888
2008-06-30 03:02:03 +00:00
Chris Lattner
95fecdd63a Implement split and scalarize for SELECT_CC, fixing PR2504
llvm-svn: 52887
2008-06-30 02:43:01 +00:00
Nick Lewycky
23476fb496 Because of the laziness, the required passes must exist even after
LoopVR::runOnFunction runs.

This should accomplish that, but it doesn't. I think that's a PassManager bug,
but without a consumer of LoopVR in the tree, I can't give steps to reproduce.

llvm-svn: 52886
2008-06-30 01:04:39 +00:00
Nick Lewycky
d63159dcd4 Add a value range analysis that lazily computes ranges using ScalarEvolutions.
llvm-svn: 52885
2008-06-30 00:04:21 +00:00
Anton Korobeynikov
6f260767ec Revert (52748 and friends):
Move GetConstantStringInfo to lib/Analysis. Remove
string output routine from Constant. Update all
callers. Change debug intrinsic api slightly to
accomodate move of routine, these now return values
instead of strings.

This unbreaks llvm-gcc bootstrap.

llvm-svn: 52884
2008-06-29 17:57:03 +00:00
Anton Korobeynikov
9e8c154272 Start refactoring of asmprinters: provide a TAI hook, which will select a 'section kind' for a global.
llvm-svn: 52868
2008-06-28 13:45:57 +00:00
Anton Korobeynikov
0b708e559e Unbreak
llvm-svn: 52866
2008-06-28 11:10:06 +00:00
Anton Korobeynikov
8562255056 Temporary rever invalid commit
llvm-svn: 52865
2008-06-28 11:09:48 +00:00
Anton Korobeynikov
ea88d91267 Move printing of module-level GVs into dedicated helper
llvm-svn: 52864
2008-06-28 11:09:32 +00:00
Anton Korobeynikov
77c3528f69 Use common naming convention
llvm-svn: 52863
2008-06-28 11:09:17 +00:00
Anton Korobeynikov
2331efee7e Factor out stuff into helper function
llvm-svn: 52862
2008-06-28 11:09:01 +00:00
Anton Korobeynikov
908c1fab55 Cleanup
llvm-svn: 52861
2008-06-28 11:08:44 +00:00
Anton Korobeynikov
adec555f96 Remove X86SharedAsmPrinter
llvm-svn: 52860
2008-06-28 11:08:27 +00:00
Anton Korobeynikov
dcc6a8314a whitespace cleanup
llvm-svn: 52859
2008-06-28 11:08:09 +00:00
Anton Korobeynikov
03a62267fe Make intel asmprinter child of generic asmprinter, not x86 shared asm printer. This leads to some code duplication, which will be resolved later.
llvm-svn: 52858
2008-06-28 11:07:54 +00:00
Anton Korobeynikov
b75aeb6b1a Cleanup
llvm-svn: 52857
2008-06-28 11:07:35 +00:00
Anton Korobeynikov
f4017f7d50 Whitespace cleanup
llvm-svn: 52856
2008-06-28 11:07:18 +00:00
Chris Lattner
2deb9ae6ad Really fix the bootstrap failure.
llvm-svn: 52854
2008-06-28 06:24:50 +00:00
Chris Lattner
090d81df5e Add back the capability to include nul characters in strings with
GetConstantStringInfo.  This will hopefully restore llvm-gcc to 
happy bootstrap land.

llvm-svn: 52851
2008-06-28 05:33:32 +00:00
Chris Lattner
98b286ff98 Tighten up checking.
llvm-svn: 52850
2008-06-28 04:37:04 +00:00
Dan Gohman
6b87f869e4 When folding a bitcast into a load or store, preserve the alignment
information of the original load or store, which is checked to be
at least as good, and possibly better.

llvm-svn: 52849
2008-06-28 00:45:22 +00:00
Seo Sanghyeon
12944690d5 Fix GetMainExecutable. Patch by Sam Bishop.
llvm-svn: 52847
2008-06-27 22:55:30 +00:00
Evan Cheng
36adcb1eea Looks like this condition is inverted.
llvm-svn: 52841
2008-06-27 22:11:49 +00:00