Daniel Dunbar
39f85e6a96
For 'install-clang' target, also traverse tools/clang/lib/Runtime.
...
llvm-svn: 93958
2010-01-20 00:43:07 +00:00
Dale Johannesen
ac7865b75b
Move findDebugLoc somewhere more central. Fix
...
more cases where debug declarations affect
debug line info.
llvm-svn: 93953
2010-01-20 00:19:24 +00:00
Dan Gohman
34b548b94a
Fold (add x, shl(0 - y, n)) -> sub(x, shl(y, n)), to simplify some code
...
that SCEVExpander can produce when running on behalf of LSR.
llvm-svn: 93949
2010-01-19 23:30:49 +00:00
Bob Wilson
5daaa4b21c
Wrap some comments to 80 columns.
...
llvm-svn: 93940
2010-01-19 22:56:26 +00:00
Dan Gohman
94c0e08951
Make SCEVAddRecExpr's getType return a pointer type when the add
...
has a pointer member. This helps reduce unnecessary bitcasting
and uglygeps.
llvm-svn: 93939
2010-01-19 22:53:50 +00:00
Dale Johannesen
8d25276141
Fix a case where debug_value was perturbing the
...
line number info.
llvm-svn: 93937
2010-01-19 22:50:05 +00:00
Dan Gohman
4ca37472ec
When doing address-mode sinking, expand the base register first, rather
...
than the scaled register. This makes it more likely that subsequent
AddrModeMatcher queries will match the new address the same way as the
old, instead of accidentally matching what had been the base register
as the new scaled register, and then failing to match the scaled register.
This fixes some problems with address-mode sinking multiple muls into a
block, which will be a lot more common with some upcoming
LoopStrengthReduction changes.
llvm-svn: 93935
2010-01-19 22:45:06 +00:00
Chris Lattner
8e3badb9a7
give MCAsmInfo a 'has little endian' bit. This is unfortunate, but
...
I really want clients of the streamer to be able to say "emit this
64-bit integer" and have it get broken down right by the streamer.
I may change this in the future, we'll see how it works out.
llvm-svn: 93934
2010-01-19 22:42:28 +00:00
Dan Gohman
2c72837459
Add a comment and tidy up some whitespace.
...
llvm-svn: 93932
2010-01-19 22:27:22 +00:00
Dan Gohman
ddb23efce9
Fix a typo and an 80-column violation in comments.
...
llvm-svn: 93931
2010-01-19 22:26:02 +00:00
Dan Gohman
273322a12b
Give ScalarEvolution access to the DominatorTree. It'll need this
...
to make more intellegent AddRec folding decisions.
llvm-svn: 93930
2010-01-19 22:21:27 +00:00
Chris Lattner
1b0d0247b2
simplify the rest of fp constant printing.
...
llvm-svn: 93929
2010-01-19 22:16:33 +00:00
Chris Lattner
53a988c8f1
simplify the code for printing x86 long double, don't do work
...
for -fverbose-asm unless it's on.
llvm-svn: 93926
2010-01-19 22:11:05 +00:00
Jakob Stoklund Olesen
b93c3b9624
Identify predicate and optional-def operands when printing machine
...
instructions.
llvm-svn: 93925
2010-01-19 22:08:34 +00:00
Chris Lattner
20c1857075
add a new EmitIntValue method that MCStreamer impls can optionally define
...
and that clients can use.
llvm-svn: 93923
2010-01-19 22:03:38 +00:00
Dan Gohman
71b2d12a48
Add a new helper function to IVUsers for returning the "canonical"
...
form of an expression. This is the expression without the
post-increment adjustment made, which is useful in determining
which registers will be used by the expansion.
llvm-svn: 93921
2010-01-19 21:55:32 +00:00
Dan Gohman
190fee462e
Add nounwinds.
...
llvm-svn: 93919
2010-01-19 21:51:51 +00:00
Chris Lattner
2842ccd76f
eliminate AsmPrinter::EmitZeros: just use MCStreamer directly.
...
llvm-svn: 93918
2010-01-19 21:51:22 +00:00
Sean Callanan
4bb95fd7d6
Promoted the getTok() method to MCAsmParser so that
...
the two token accessor functions are declared consistently.
Modified the clients of MCAsmParser to reflect this change.
llvm-svn: 93916
2010-01-19 21:44:56 +00:00
Xerxes Ranby
c3fa089148
Stubs for getHostCPUFeatures API. This implements part of PR5389.
...
llvm-svn: 93913
2010-01-19 21:26:05 +00:00
Jakob Stoklund Olesen
e7d4286d73
Remove predicates when changing an add into an unpredicable mov.
...
Since the mov is executed unconditionally, make sure that the add didn't have
any predicate.
llvm-svn: 93909
2010-01-19 21:08:28 +00:00
Benjamin Kramer
5ad576dacf
Update CMake list.
...
llvm-svn: 93905
2010-01-19 20:59:04 +00:00
David Greene
fde2825063
Add some new debugging APIs to print out "raw" SelectionDAGs to make
...
understanding CannotYTetSelect and other errors easier.
llvm-svn: 93901
2010-01-19 20:37:34 +00:00
Sean Callanan
7fa5ebbed0
Propagated the parser-side Lex function's declaration to
...
MCAsmParser, and changed the target-specific AsmParsers
to use it.
llvm-svn: 93900
2010-01-19 20:27:46 +00:00
Sean Callanan
985ff03e7d
Added a Lex function to the AsmParser, to allow handling
...
of include directives to occur within the parser itself.
This will break the lexer's dependency on a SourceMgr as
input.
llvm-svn: 93899
2010-01-19 20:22:31 +00:00
Bruno Cardoso Lopes
36445b07f0
Fix a bug introduced on r92564 where the name "Node" was already
...
in use by Mips.
llvm-svn: 93897
2010-01-19 19:57:07 +00:00
Chris Lattner
336c2b0d47
Generalize mcasmstreamer data emission APIs to take an address space
...
identifier. There is no way to work around it.
llvm-svn: 93896
2010-01-19 19:46:13 +00:00
Evan Cheng
4b916556a5
Do not extend extension results beyond the use of a PHI instruction at the start of a use block. A PHI use is expected to kill its source values.
...
llvm-svn: 93895
2010-01-19 19:45:51 +00:00
Chris Lattner
a5895e4127
refactor code to be static functions instead of methods on AsmPrinter.
...
This fixes some bugs handling address spaces.
llvm-svn: 93891
2010-01-19 19:10:44 +00:00
Chris Lattner
b98efb6e76
mcstreamerize AsmPrinter::EmitZeros, at least when emitting to the
...
default address space.
llvm-svn: 93890
2010-01-19 18:58:52 +00:00
Chris Lattner
7c3ff46d45
add an MCAsmStreamer::EmitFill specialization of EmitFill that
...
emits one directive instead of N. Not doing this would be a
significant regression on the # bytes generated by .fill.
llvm-svn: 93889
2010-01-19 18:52:28 +00:00
Chris Lattner
f26d29e436
add a "MCStreamer::EmitFill" method, and move the default implementation
...
(which just iteratively emits bytes) to MCStreamer.
llvm-svn: 93888
2010-01-19 18:45:47 +00:00
Chris Lattner
50636e0db8
remove MAI::ZeroDirectiveSuffix, which is only used by MASM,
...
which we don't support anymore.
llvm-svn: 93886
2010-01-19 18:37:01 +00:00
Jim Grosbach
034f69e0aa
For aligned load/store instructions, it's only required to know whether a
...
function can support dynamic stack realignment. That's a much easier question
to answer at instruction selection stage than whether the function actually
will have dynamic alignment prologue. This allows the removal of the
stack alignment heuristic pass, and improves code quality for cases where
the heuristic would result in dynamic alignment code being generated when
it was not strictly necessary.
llvm-svn: 93885
2010-01-19 18:31:11 +00:00
Chris Lattner
e0124f19f9
optimize ~(~X >>s Y) --> (X >>s Y), patch by Edmund Grimley
...
Evans!
llvm-svn: 93884
2010-01-19 18:16:19 +00:00
Bruno Cardoso Lopes
6d3b12a256
On pic function calls some arguments were marked dead and
...
the instruction to load those args removed. This fix PR6071
llvm-svn: 93880
2010-01-19 17:00:43 +00:00
Bob Wilson
c82f536a5c
The change in r90189 adds a link in a directory outside the iPhone platform
...
directory when building the llvmCore_Embedded project. Fix this by putting
the iPhone platform directory into DEST_DIR instead of DEST_ROOT. I also
noticed what appears to be an unintentional use of DEVELOPER_BIN instead of
DEVELOPER_DIR, so I fixed that and changed to use DEVELOPER_DIR in some places
that were hardcoded to "Developer". Finally, the other changes here allowed
some refactoring and simplification, which I have done.
llvm-svn: 93878
2010-01-19 16:42:10 +00:00
Bruno Cardoso Lopes
a3fff69e88
load f64 +0.0 in a cleaner way. This fix part of PR5445
...
llvm-svn: 93876
2010-01-19 12:53:04 +00:00
Bruno Cardoso Lopes
46c69e2a0a
Fix return registers for mips eabi
...
llvm-svn: 93875
2010-01-19 12:37:35 +00:00
Chris Lattner
405ac51ba0
mcstreamer'ize the rest of EmitGlobalVariable that is used on
...
darwin. The next big piece to get global variables streamerized
is EmitGlobalConstant.
llvm-svn: 93870
2010-01-19 06:41:24 +00:00
Chris Lattner
ff16ee18d9
don't let asm-verbose break the check-next lines in these tests.
...
llvm-svn: 93869
2010-01-19 06:39:54 +00:00
Chris Lattner
15e2a64ec2
stop using the .lcomm pseudoop on darwin, instead, directly use the
...
.zerofill directive. Streamerize its generation.
llvm-svn: 93868
2010-01-19 06:25:51 +00:00
Chris Lattner
dcd325e360
fix parsing .comm directives on systems which do not represent alignments
...
as a power of 2. This fixes MC/AsmParser/directive_comm.s
llvm-svn: 93867
2010-01-19 06:22:22 +00:00
Chris Lattner
79166b498e
only darwin has zerofill
...
llvm-svn: 93866
2010-01-19 06:21:23 +00:00
Devang Patel
a230047a58
MDNodes are not expected to disappear or replaced by another MDNode, so there is no need to pay the cost of WeakVH and ValueMaps.
...
llvm-svn: 93865
2010-01-19 06:19:05 +00:00
Devang Patel
bb63f9dd91
Avoid including DebugInfo.h in AsmPrinter.h
...
llvm-svn: 93864
2010-01-19 06:09:04 +00:00
Chris Lattner
8aa691460a
zap the ARM version of PrintGlobalVariable, which I missed.
...
llvm-svn: 93863
2010-01-19 06:08:15 +00:00
Chris Lattner
e339d60351
mc'ize some stuff, don't comment out .lcomm directive in -fverbose-asm mode.
...
llvm-svn: 93860
2010-01-19 06:01:04 +00:00
Chris Lattner
ebe63b403e
factor this code better.
...
llvm-svn: 93859
2010-01-19 05:51:42 +00:00
Chris Lattner
377bd87849
Now that we have everything nicely factored (e.g. asmprinter is not
...
doing global variable classification anymore) and hookized, sink almost
all target targets global variable emission code into AsmPrinter and out
of each target.
Some notes:
1. PIC16 does completely custom and crazy stuff, so it is not changed.
2. XCore has some custom handling for extra directives. I'll look at it next.
3. This switches linux/ppc to use .globl instead of .global. If .globl is
actually wrong, let me know and I'll fix it.
4. This makes linux/ppc get a lot of random cases right which were obviously
wrong before, it is probably now a bit healthier.
5. Blackfin will probably start getting .comm and other things that it didn't
before. If this is undesirable, it should explicitly opt out of these
things by clearing the relevant fields of MCAsmInfo.
This leads to a nice diffstat:
14 files changed, 127 insertions(+), 830 deletions(-)
llvm-svn: 93858
2010-01-19 05:38:33 +00:00