Fariborz Jahanian
18bc195473
Add code gen for pointer-to-member function in
...
ctor's initializer. Fixes pr5178.
llvm-svn: 86040
2009-11-04 19:13:37 +00:00
Chris Lattner
762b56fa8c
Fix an iterator invalidation bug that happens when a hashtable
...
resizes in IPSCCP. This fixes PR5394.
llvm-svn: 86036
2009-11-04 18:57:42 +00:00
Douglas Gregor
3552259059
Properly replace (cxxscope, template-id) annotation tokens with a
...
single typename annotation token when backtracing. Fixes PR5350.
llvm-svn: 86034
2009-11-04 18:18:19 +00:00
Fariborz Jahanian
09cc10f9f8
This patch extends CleanupScope to support destruction
...
of array objects on block exit. Patch is by Anders Calrsson.
llvm-svn: 86032
2009-11-04 17:57:40 +00:00
Douglas Gregor
2de8f4149e
Don't try to check the initialization of fields with dependent
...
types. Fixes PR5352.
Fariborz, please review.
llvm-svn: 86031
2009-11-04 17:16:11 +00:00
Douglas Gregor
615ac67fb8
Store the unresolved class type in MemberPointerType's Class field,
...
from Peter Collingbourne!
llvm-svn: 86030
2009-11-04 16:49:01 +00:00
Chris Lattner
b73beb36f5
this test has started failing due to an optimizer change. Clang tests
...
should only look at -O0 IR output not -O3 assembly output. XFAIL it for
now.
llvm-svn: 86029
2009-11-04 16:37:13 +00:00
Douglas Gregor
e7b5f81ba5
Eliminate the "old" ways of parsing operator-function-ids and
...
conversion-function-ids; all clients have moved on to
ParseUnqualifiedId.
llvm-svn: 86028
2009-11-04 16:32:12 +00:00
Douglas Gregor
220f4277bd
Switch parsing of using declarations over to ParseUnqualifiedId.
...
llvm-svn: 86027
2009-11-04 16:30:06 +00:00
Evan Cheng
531045d554
Look for llvm-gcc under /Developer/usr/bin first.
...
llvm-svn: 86023
2009-11-04 08:36:50 +00:00
Evan Cheng
95bdc5d899
RangeIsDefinedByCopyFromReg() should check for subreg_to_reg, insert_subreg,
...
and extract_subreg as a "copy" that defines a valno.
Also fixes a typo. These two issues prevent a simple subreg coalescing from
happening before.
llvm-svn: 86022
2009-11-04 08:33:14 +00:00
Chris Lattner
cb3c64ee3c
move two functions up higher in the file. Delete a useless argument
...
to EmitGEPOffset.
Implement some new transforms for optimizing
subtracts of two pointer to ints into the same vector. This happens
for C++ iterator idioms for example, stringmap takes a const char*
that points to the start and end of a string. Once inlined, we want
the pointer difference to turn back into a length.
This is rdar://7362831.
llvm-svn: 86021
2009-11-04 08:05:20 +00:00
Chris Lattner
e3cdf2ed3b
filecheckize this test.
...
llvm-svn: 86020
2009-11-04 07:57:05 +00:00
Evan Cheng
c63943018f
The .n suffix must go after the predicate.
...
llvm-svn: 86019
2009-11-04 07:38:48 +00:00
John McCall
4c98fd8953
Preserve type source information in sizeof/alignof expressions, and pass it
...
through to indexing.
llvm-svn: 86018
2009-11-04 07:28:41 +00:00
Douglas Gregor
c95a1fa7f6
When performing template instantiation (transformation) of
...
expressions, keep track of whether we are immediately taking the
address of the expression. Pass this flag when building a declaration
name expression so that we handle pointer-to-member constants
properly.
llvm-svn: 86017
2009-11-04 07:01:15 +00:00
Daniel Dunbar
a9be734c24
Fix commento.
...
llvm-svn: 86016
2009-11-04 06:57:08 +00:00
Daniel Dunbar
0300bbcf80
Update CMake.
...
llvm-svn: 86015
2009-11-04 06:39:40 +00:00
Daniel Dunbar
5ec950218a
Move -fcolor-diagnostics logic to driver.
...
llvm-svn: 86014
2009-11-04 06:24:57 +00:00
Daniel Dunbar
2c9784769a
Move logic for selection -fmessage-length= to driver.
...
llvm-svn: 86013
2009-11-04 06:24:47 +00:00
Daniel Dunbar
1c7577c9bd
Fix indentation.
...
llvm-svn: 86011
2009-11-04 06:24:38 +00:00
Daniel Dunbar
c2e6a4709e
Factor out a diagnostic options class.
...
llvm-svn: 86010
2009-11-04 06:24:30 +00:00
Nick Lewycky
b8c923b1a6
The magic for our current brand of .bc files is BC. For older ones it was llvc.
...
When was it ever "llvm"?
llvm-svn: 86009
2009-11-04 06:15:28 +00:00
Chris Lattner
0fc4311f0e
make IRBuilder zap "X|0" and "X&-1" when building IR, this happens
...
during bitfield codegen and slows down -O0 compile times by making
useless IR. rdar://7362516
llvm-svn: 86006
2009-11-04 05:00:12 +00:00
Daniel Dunbar
b4a289c88e
configure: Add --with-optimize-option, for setting the default value of
...
OPTIMIZE_OPTION.
llvm-svn: 86005
2009-11-04 04:32:50 +00:00
Ted Kremenek
9346a56793
Add FIXME.
...
llvm-svn: 86004
2009-11-04 04:24:44 +00:00
Ted Kremenek
ef910047b2
Catch uses of undefined values when they are used in assignment, thus catching such bugs closer to the source.
...
llvm-svn: 86003
2009-11-04 04:24:16 +00:00
Ted Kremenek
9db38f6f83
Add mising #ifdef guards.
...
llvm-svn: 86002
2009-11-04 04:03:43 +00:00
John McCall
4976fd4ea9
Diagnose the use of 'fastcall' on functions without prototypes or with
...
varargs prototypes.
llvm-svn: 86001
2009-11-04 03:36:09 +00:00
Evan Cheng
2969877eea
Silence implicit conversion warnings.
...
llvm-svn: 86000
2009-11-04 03:08:57 +00:00
John McCall
9eff4e60ae
Diagnose __builtin_offsetof on incomplete types. Fixes
...
rdar://problem/7222956
llvm-svn: 85999
2009-11-04 03:03:43 +00:00
John McCall
28a6aeab7e
Change our basic strategy for avoiding deprecation warnings when the decl use
...
appears in a deprecated context. In the new strategy, we emit the warnings
as usual unless we're currently parsing a declaration, where "declaration" is
restricted to mean a decl group or a few special cases in Objective C. If
we *are* parsing a declaration, we queue up the deprecation warnings until
the declaration has been completely parsed, and then emit them only if the
decl is not deprecated.
We also standardize the bookkeeping for deprecation so as to avoid special cases.
llvm-svn: 85998
2009-11-04 02:18:39 +00:00
Lang Hames
88fa1e6c01
Another spurious friend declaration removed.
...
llvm-svn: 85997
2009-11-04 01:52:40 +00:00
Zhongxing Xu
259d46407a
Merge ZeroSizedVLAChecker and UndefSizedVLAChecker.
...
llvm-svn: 85996
2009-11-04 01:43:07 +00:00
Lang Hames
cd72c7b2b6
Removed an unnecessary friend declaration and some crufty comments from IndexListEntry.
...
llvm-svn: 85995
2009-11-04 01:34:22 +00:00
Douglas Gregor
90790c7781
Fix CMake makefiles
...
llvm-svn: 85994
2009-11-04 01:32:06 +00:00
Tanya Lattner
f9d41df093
Merge constant array and structures. This will create a global variables for arrays and structs that are constant and their initializer is constant. It is on by default but can be disable with the flag -fno-merge-all-constants.
...
llvm-svn: 85991
2009-11-04 01:18:09 +00:00
Mike Stump
b9c9b351e9
Fix 80-col violations.
...
llvm-svn: 85990
2009-11-04 01:11:15 +00:00
Douglas Gregor
71395fa1d5
Implement support for parsing dependent template-ids that refer to
...
overloaded operators, e.g.,
p->template operator+<T>()
llvm-svn: 85989
2009-11-04 00:56:37 +00:00
Mike Stump
71609a2874
Split out return adjustments in thunks from this adjustment in thunks
...
so the optimizer can tailcall into the return value adjustment thunk.
This improves codesize for complex hierarchies.
llvm-svn: 85988
2009-11-04 00:53:51 +00:00
Evan Cheng
8f4e3d99c9
Fix test.
...
llvm-svn: 85986
2009-11-04 00:42:33 +00:00
Daniel Dunbar
caa00adafd
Use unsigned char instead of unsigned : 8 to make the optimizer happier.
...
llvm-svn: 85985
2009-11-04 00:34:40 +00:00
Ted Kremenek
b006b82daf
Refactor StoreManager::BindDecl() to take a VarRegion* instead of a VarDecl*, and modify GRExprEngine::EvalBind() to handle decl initialization as well. This paves the way for adding "checker" visitation in EvalBind().
...
llvm-svn: 85983
2009-11-04 00:09:15 +00:00
Evan Cheng
3f1a92468a
Use ldr.n to workaround a darwin assembler bug.
...
llvm-svn: 85980
2009-11-04 00:00:39 +00:00
Lang Hames
05fb9637f6
The Indexes Patch.
...
This introduces a new pass, SlotIndexes, which is responsible for numbering
instructions for register allocation (and other clients). SlotIndexes numbering
is designed to match the existing scheme, so this patch should not cause any
changes in the generated code.
For consistency, and to avoid naming confusion, LiveIndex has been renamed
SlotIndex.
The processImplicitDefs method of the LiveIntervals analysis has been moved
into its own pass so that it can be run prior to SlotIndexes. This was
necessary to match the existing numbering scheme.
llvm-svn: 85979
2009-11-03 23:52:08 +00:00
Mike Stump
8117848174
Misc cleanups.
...
llvm-svn: 85978
2009-11-03 23:50:34 +00:00
Bob Wilson
53a31ad3c1
Fix branch folding bug for indirect branches: for a block containing only
...
an unconditional branch (possibly from tail merging), this code is
trying to redirect all of its predecessors to go directly to the branch
target, but that isn't feasible for indirect branches. The other
predecessors (that don't end with indirect branches) could theoretically
still be handled, but that is not easily done right now.
The AnalyzeBranch interface doesn't currently let us distinguish jump table
branches from indirect branches, and this code is currently handling
jump tables. To avoid punting on address-taken blocks, we would have to give
up handling jump tables. That seems like a bad tradeoff.
llvm-svn: 85975
2009-11-03 23:44:31 +00:00
Chris Lattner
156b8c7109
reimplement multiple return value handling in IPSCCP, making it
...
more aggressive an correct. This survives building llvm in 64-bit
mode with optimizations and the built llvm passes make check.
llvm-svn: 85973
2009-11-03 23:40:48 +00:00
Mike Stump
6de15a8881
Test case for recent checkin.
...
llvm-svn: 85972
2009-11-03 23:32:42 +00:00
Ted Kremenek
0fbbb0877d
Change GRTransferFuncs::RegisterChecks() to take a GRExprEngine& instead of a BugReporter&. This paves the way for pulling some of the retain/release checker into a "Checker" class.
...
llvm-svn: 85971
2009-11-03 23:30:34 +00:00