Victor Hernandez
e5f2af7594
Refactor common parts of MDNode::getFunction() and assertLocalFunction() into getFunctionForValue()
...
llvm-svn: 93977
2010-01-20 04:45:57 +00:00
Chandler Carruth
5b6d9265ba
Actually remove the include that r93974 made unnecessary.
...
llvm-svn: 93975
2010-01-20 04:09:11 +00:00
Chandler Carruth
b0af340592
Fix a layering issue between Basic and FE by moving a utility class into Basic.
...
This isn't entirely satisfactory, as it seems an implementation detail, and
with nothing to do with TargetInfo. Suggestions on where to put this are
welcome.
llvm-svn: 93974
2010-01-20 03:59:11 +00:00
Zhongxing Xu
00c6046a81
Add a missing case for DeclContext printer.
...
llvm-svn: 93973
2010-01-20 03:21:28 +00:00
Daniel Dunbar
3f3e2cd820
Driver: Lift clang resource directory computation to the Driver object.
...
llvm-svn: 93971
2010-01-20 02:35:16 +00:00
Daniel Dunbar
e2b661c26c
clang/Darwin: Update for rename of 10.4 static runtime library.
...
llvm-svn: 93970
2010-01-20 02:35:02 +00:00
Daniel Dunbar
857138f663
clang/Darwin: Rename x86_10.4 static lib config to just 10.4, and add 'eprintf'
...
which seems to be needed.
llvm-svn: 93969
2010-01-20 02:34:31 +00:00
Mike Stump
06c1d87d14
Also handle CXXConstructor, CXXDestructor and CXXConversion in CFG
...
printing.
llvm-svn: 93968
2010-01-20 02:28:05 +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
Mike Stump
281d6d7745
Use the llvm coding convention for indentation for switch.
...
llvm-svn: 93966
2010-01-20 02:03:14 +00:00
Fariborz Jahanian
98609b3a07
Patch to implement required warnings for unimplemented
...
properties imported frfom protocol. Fixes radar 7544809.
llvm-svn: 93965
2010-01-20 01:51:55 +00:00
John McCall
1bcb2631e6
Make UnresolvedSet.h standalone.
...
llvm-svn: 93964
2010-01-20 01:36:13 +00:00
Mike Stump
845384a938
Wire up the EH context for the catch clauses to the outer EH context. WIP.
...
llvm-svn: 93963
2010-01-20 01:30:58 +00:00
Mike Stump
0bdba6cdd8
Add an exceptional edge from the try terminated block to the outer EH
...
context (try or the Exit block) when there isn't a catch (...).
Improve CFG printing for catch (...).
llvm-svn: 93962
2010-01-20 01:15:34 +00:00
Douglas Gregor
52606ff2ca
Attempt to improve CIndex Doxygen organization, although I can't actually test this locally
...
llvm-svn: 93961
2010-01-20 01:10:47 +00:00
David Greene
3b2a68ceb8
Add some asserts to check SelectionDAG problems earlier.
...
llvm-svn: 93960
2010-01-20 00:59:23 +00:00
John McCall
ad371258aa
Give UnresolvedSet the ability to store access specifiers for each declaration.
...
Change LookupResult to use UnresolvedSet. Also extract UnresolvedSet into its
own header and make it templated over an inline capacity.
llvm-svn: 93959
2010-01-20 00:46:10 +00:00
Daniel Dunbar
e43fe7cbb7
For 'install-clang' target, also traverse tools/clang/lib/Runtime.
...
llvm-svn: 93958
2010-01-20 00:43:07 +00:00
Douglas Gregor
b693f65c4d
Remove some #if 0'd code that's never going to get used.
...
llvm-svn: 93957
2010-01-20 00:34:08 +00:00
Mike Stump
06b602e540
Improve CheckFallThrough analysis in the presense of the new C++ EH
...
support. WIP.
llvm-svn: 93956
2010-01-20 00:34:04 +00:00
Douglas Gregor
9074c3fe97
Kill off clang_getDeclColumn, clang_getDeclExtent, clang_getDeclLine,
...
clang_getDeclSource, and clang_getDeclSourceFile; the cursor
equivalents are the way of the future.
llvm-svn: 93955
2010-01-20 00:26:57 +00:00
Douglas Gregor
d2fc7277be
Introduce a special cursor kind for the translation unit, to serve as
...
the root of the conceptual cursor hierarchy (just like we do with
declarations). This will be used when we get to unify
clang_loadTranslationUnit() and clang_loadDeclaration() into something
more generally useful.
llvm-svn: 93954
2010-01-20 00:23:15 +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
Douglas Gregor
c0943d089f
CXCursor_UnexposedDecl to the first declaration kind
...
llvm-svn: 93952
2010-01-20 00:07:45 +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
Chris Lattner
e87668db26
add support for Fedora 10 x86_64, there really should be a better way to handle this.
...
patch by Dmitry
llvm-svn: 93948
2010-01-19 23:30:00 +00:00
Douglas Gregor
084236fafd
Kill CXCursor_ObjCSelectorRef, CXCursor_VarRef, CXCursor_FunctionRef,
...
and CXCursor_EnumConstantRef; they've been subsumed by expression
references, which do a much nicer job.
llvm-svn: 93947
2010-01-19 23:25:01 +00:00
Douglas Gregor
8f40bbee78
Extend the CIndex API with direct support for expressions and
...
statements, moving some of the more unnatural kinds of references
(VarRef, EnumConstantRef, etc.) over to the expressions. We can now
poke at arbitrary expressions and statements with, e.g.,
clang_getCursor() and get back useful information (e.g., source
ranges).
llvm-svn: 93946
2010-01-19 23:20:36 +00:00
Mike Stump
314825bc8a
Implement goto inside of blocks.
...
llvm-svn: 93945
2010-01-19 23:08:01 +00:00
Eric Christopher
99469702a3
Update and move around comments.
...
llvm-svn: 93942
2010-01-19 22:58:35 +00:00
Bob Wilson
6a4491b8c7
Wrap some comments to 80 columns.
...
llvm-svn: 93940
2010-01-19 22:56:26 +00:00
Dan Gohman
221708d826
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
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
John McCall
5d7aa7fa0a
The type of a compound literal expression is not necessarily the same as the
...
type which was syntactically written. Fixes PR 6080.
llvm-svn: 93933
2010-01-19 22:33:45 +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
Douglas Gregor
7d1efeb43d
Kill the unused and unnecessary CXCursor_MemberRef, twin to the
...
now-dead CXCursor_ObjCIvarRef.
llvm-svn: 93928
2010-01-19 22:15:34 +00:00
Douglas Gregor
015026e358
Kill CXCursor_ObjCIvarRef. Such cursors could never be created, and
...
have been marked for death for a while.
llvm-svn: 93927
2010-01-19 22:11:32 +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
Douglas Gregor
accb183371
Introduce the notion of an "unexposed" declaration into the CIndex
...
API. This is a catch-all for any declaration known to Clang but not
specifically part of the CIndex API. We'll use the same approach with
expressions, statements, references, etc., as needed.
llvm-svn: 93924
2010-01-19 22:07:56 +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
Mike Stump
92244b00c7
Add CFG support for the start and end of scopes and infrastructure for
...
implicit destructor calls. WIP.
llvm-svn: 93922
2010-01-19 22:00:14 +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
Dan Gohman
fb9bea7150
Add nounwinds.
...
llvm-svn: 93919
2010-01-19 21:51:51 +00:00
Chris Lattner
ecaf0dcbc6
eliminate AsmPrinter::EmitZeros: just use MCStreamer directly.
...
llvm-svn: 93918
2010-01-19 21:51:22 +00:00