Chris Lattner
397af34e6f
adopt getAdjustedAnalysisPointer in BasicCallGraph.
...
llvm-svn: 94015
2010-01-20 19:51:46 +00:00
Chris Lattner
af362f014d
add some new methods to adjust this pointers. Not used yet.
...
llvm-svn: 94013
2010-01-20 19:26:14 +00:00
Chris Lattner
c47ece59a8
don't send null pointers through the constantexpr codepath unneededly.
...
llvm-svn: 94010
2010-01-20 17:57:50 +00:00
Chris Lattner
6a7939243f
reduce redundant are's.
...
llvm-svn: 94008
2010-01-20 17:53:51 +00:00
Jakob Stoklund Olesen
8a19d3c96c
Move per-function inline threshold calculation to a method.
...
No functional change except the forgotten test for
InlineLimit.getNumOccurrences() == 0 in the CurrentThreshold2 calculation.
llvm-svn: 94007
2010-01-20 17:51:28 +00:00
Chris Lattner
9fc980403e
use getGlobalDirective(), don't hardcode .globl. PR6093
...
llvm-svn: 94006
2010-01-20 17:50:30 +00:00
David Greene
35dca86659
Fix an infinite recursion problem. dbgs() should return errs() in
...
release mode.
llvm-svn: 94001
2010-01-20 15:27:19 +00:00
Chris Lattner
71601e8b3b
eliminate some uses of AsmPrinter::EmitIntXXX
...
llvm-svn: 93996
2010-01-20 07:41:15 +00:00
Victor Hernandez
ab62196c9d
Backout r93990
...
llvm-svn: 93995
2010-01-20 07:37:49 +00:00
Chris Lattner
db42c8d23d
inline and radically simplify printDataDirective. It will eventually
...
go completely away.
llvm-svn: 93994
2010-01-20 07:33:29 +00:00
Chris Lattner
f8dcf784a7
emit basic block labels with mcstreamer.
...
llvm-svn: 93993
2010-01-20 07:24:05 +00:00
Chris Lattner
4c8b1824f0
emit integer and fp zeros as (e.g.) .byte 0 instead of .space 1,
...
for tidiness.
llvm-svn: 93992
2010-01-20 07:19:19 +00:00
Chris Lattner
03cb2a3035
signficant cleanups to EmitGlobalConstant (including streamerization
...
of int initializers), change some methods to be static functions,
use raw_ostream::write_hex instead of a smallstring dance with
APValue::toStringUnsigned(S, 16).
llvm-svn: 93991
2010-01-20 07:11:32 +00:00
Victor Hernandez
6c50c06e70
Fix/strengthen verification of llvm.dbg.declare
...
llvm-svn: 93990
2010-01-20 06:57:02 +00:00
Victor Hernandez
f2462407ee
Switch Elts from vector to SmallVector
...
llvm-svn: 93989
2010-01-20 06:56:16 +00:00
Chris Lattner
37020ccf48
switch ConstantFP emission to use MCStreamer, significantly
...
simplifying the code.
llvm-svn: 93988
2010-01-20 06:53:37 +00:00
Chris Lattner
45eeffcc2a
make mcasmstreamer handle expanding 8 byte integer constants to
...
4-byte constants if .quad isn't supported. Switch a bunch of
methods used by the dwarf writer to use OutStreamer.EmitIntValue.
llvm-svn: 93987
2010-01-20 06:45:39 +00:00
Chris Lattner
38caaf14c1
give createAsmStreamer an 'isLittleEndian' argument.
...
llvm-svn: 93986
2010-01-20 06:39:07 +00:00
Chris Lattner
2b4364fe03
revert 93934, removing the MCAsmInfo endianness bit. I can't
...
stomache MCAsmInfo having this, and I found a better solution to
this layering issue.
llvm-svn: 93985
2010-01-20 06:34:14 +00:00
Victor Hernandez
d0b2ff9b7a
Fix if/else brackets; getFunctionForValue() is to be called for non-metadata values
...
llvm-svn: 93984
2010-01-20 06:22:33 +00:00
Chandler Carruth
d6514b1e13
Fix the conditions to unambiguously show the logic they represent. This is the
...
logic enforced in the test case as well, so hopefully it is correct. Please
review Victor.
llvm-svn: 93980
2010-01-20 06:01:02 +00:00
Victor Hernandez
5fa88d4e30
Map operands of all function-local metadata, not just metadata passed to llvm.dbg.declare intrinsics
...
llvm-svn: 93979
2010-01-20 05:49:59 +00:00
Victor Hernandez
20425abea4
Avoid unnecessary Elts array
...
llvm-svn: 93978
2010-01-20 05:44:11 +00:00
Victor Hernandez
e5f2af7594
Refactor common parts of MDNode::getFunction() and assertLocalFunction() into getFunctionForValue()
...
llvm-svn: 93977
2010-01-20 04:45:57 +00:00
Devang Patel
7771b7c621
If a instruction belongs to another function (and not current function) as per debug info attached with the instruction then ignore the dangling lexical scope of this instruction. Such scopes are unreachable.
...
llvm-svn: 93967
2010-01-20 02:05:23 +00:00
David Greene
3b2a68ceb8
Add some asserts to check SelectionDAG problems earlier.
...
llvm-svn: 93960
2010-01-20 00:59:23 +00:00
Dale Johannesen
91970b4ea2
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
954f49014d
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
6a4491b8c7
Wrap some comments to 80 columns.
...
llvm-svn: 93940
2010-01-19 22:56:26 +00:00
Dale Johannesen
aa6655557b
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
ca19445d08
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
003b5c8472
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
8d67d2f5f8
Add a comment and tidy up some whitespace.
...
llvm-svn: 93932
2010-01-19 22:27:22 +00:00
Dan Gohman
510bffca45
Fix a typo and an 80-column violation in comments.
...
llvm-svn: 93931
2010-01-19 22:26:02 +00:00
Dan Gohman
f86d904b7d
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
eaef5e111d
simplify the rest of fp constant printing.
...
llvm-svn: 93929
2010-01-19 22:16:33 +00:00
Chris Lattner
c70daf316e
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
e8800b8d7c
Identify predicate and optional-def operands when printing machine
...
instructions.
llvm-svn: 93925
2010-01-19 22:08:34 +00:00
Chris Lattner
dc50e5d128
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
d693472821
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
Chris Lattner
ecaf0dcbc6
eliminate AsmPrinter::EmitZeros: just use MCStreamer directly.
...
llvm-svn: 93918
2010-01-19 21:51:22 +00:00
Sean Callanan
936b0d3144
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
17dc3a0a94
Stubs for getHostCPUFeatures API. This implements part of PR5389.
...
llvm-svn: 93913
2010-01-19 21:26:05 +00:00
Jakob Stoklund Olesen
bdc17f6840
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
f007697c56
Update CMake list.
...
llvm-svn: 93905
2010-01-19 20:59:04 +00:00
David Greene
f1c7388b29
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
a83fd7d52c
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
Bruno Cardoso Lopes
e1afaf5c22
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
c35681b298
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
bf43525a29
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