Commit Graph

74903 Commits

Author SHA1 Message Date
Benjamin Kramer 8adc1e2263 Add missing include (for inline PATypeHolder::get).
llvm-svn: 92222
2009-12-28 12:27:56 +00:00
Chris Lattner 95c445d280 avoid a completely unneeded linear walk.
llvm-svn: 92221
2009-12-28 09:32:10 +00:00
Chris Lattner c6d17e29df Eliminate two bits of ugliness in MDNode::replaceElement:
eliminate the temporary smallvector, and only do FindNodeOrInsertPos
twice if the first one succeeds and we delete a node.

llvm-svn: 92220
2009-12-28 09:24:53 +00:00
Chris Lattner f543eff71c rearrange some methods, no functionality change.
llvm-svn: 92219
2009-12-28 09:12:35 +00:00
Chris Lattner d944cf76de avoid temporary CallbackVH's.
llvm-svn: 92218
2009-12-28 09:10:16 +00:00
Chris Lattner 588096e51d Rewrite the function-local validation logic for MDNodes (most of r91708).
Among other benefits, this doesn't leak the SmallPtrSet, has the verifier
code in the verifier pass, actually does the verification at the end,
and is considerably simpler.

llvm-svn: 92217
2009-12-28 09:07:21 +00:00
Chris Lattner 66a4c3d084 rename MDNode instance variables to something meaningful.
llvm-svn: 92216
2009-12-28 08:48:12 +00:00
Chris Lattner 5a409bd17a snip one more #include from Metadata.h
llvm-svn: 92214
2009-12-28 08:30:43 +00:00
Chris Lattner f91d3c34ff prune #includes more.
llvm-svn: 92213
2009-12-28 08:26:43 +00:00
Chris Lattner 1300f45ba9 prune some #includes
llvm-svn: 92212
2009-12-28 08:24:16 +00:00
Chris Lattner f8d22fc77d Metadata.h doesn't need to include ValueHandle.h anymore.
llvm-svn: 92211
2009-12-28 08:20:46 +00:00
Chris Lattner 53bb5e4ae0 change the strange MetadataContext::getMDs function to expose less
irrelevant internal implementation details to clients.

llvm-svn: 92210
2009-12-28 08:14:54 +00:00
Chris Lattner 1bc810bb89 change NamedMDNode to use a pimpl for its operand list instead
of making it a declared part of the value.

llvm-svn: 92209
2009-12-28 08:07:14 +00:00
Chris Lattner f1ef03ad4d eliminate the elem_* iterator stuff from NamedMDNode.
llvm-svn: 92208
2009-12-28 07:57:01 +00:00
Chris Lattner 74a6ad6f29 move ElementVH out of the MDNode class into the MDNode.cpp file. Among
other things, this avoids vtable and rtti data for it being splatted in 
every translation unit that uses it.

llvm-svn: 92207
2009-12-28 07:41:54 +00:00
Chris Lattner f81add3fdf move these out of their own timer groups into the 'uncategorized' groups.
llvm-svn: 92206
2009-12-28 07:41:18 +00:00
Zhongxing Xu 6de8201a63 Adjust indentation.
llvm-svn: 92205
2009-12-28 06:52:51 +00:00
Zhongxing Xu 947420d6ad Fix 80-col violation.
llvm-svn: 92204
2009-12-28 06:49:22 +00:00
Chris Lattner 9e0005f445 use best-fit instead of first-fit when reusing a MacroArgs object,
this speeds up Eonly on the testcase in PR5888 from 30.5s to 0.85s

llvm-svn: 92203
2009-12-28 06:36:46 +00:00
Chris Lattner 394f589e73 The PreExpArgTokens array is indexed with an argument #,
not a token number.  Fix the reserve logic to get the right
amount of space.

llvm-svn: 92202
2009-12-28 06:17:16 +00:00
Sanjiv Gupta 1ecffe13b2 Fixed llc crash for zext (i1 -> i8) loads.
llvm-svn: 92201
2009-12-28 04:53:24 +00:00
Sam Weinig b999f68ed9 Fix for PR5871. Make __PRETTY_FUNCTION__ work for member functions defined in a class local to a function.
llvm-svn: 92200
2009-12-28 03:19:38 +00:00
Sanjiv Gupta 0b00a1b54e Allow targets to specify the return type of libcalls that are generated for floating point comparisons, rather than hard-coding them as i32.
llvm-svn: 92199
2009-12-28 02:40:33 +00:00
Bill Wendling 5dda76ef11 Mark variable used by 'assert' as 'unused'.
llvm-svn: 92198
2009-12-28 02:07:00 +00:00
Bill Wendling 220f4dad9e Remove dead variable.
llvm-svn: 92197
2009-12-28 02:05:36 +00:00
Bill Wendling 82e5904cbd Remove dead variable.
llvm-svn: 92196
2009-12-28 02:04:53 +00:00
Bill Wendling 18f28cb9c0 Remove dead variable.
llvm-svn: 92195
2009-12-28 02:01:06 +00:00
Bill Wendling 44a47d61df Remove dead variable.
llvm-svn: 92194
2009-12-28 02:00:30 +00:00
Bill Wendling a91b8207cc Remove dead variable.
llvm-svn: 92193
2009-12-28 01:57:39 +00:00
Bill Wendling d8dcdefb0e Remove dead store.
llvm-svn: 92192
2009-12-28 01:54:15 +00:00
Bill Wendling 9bea533c8e Remove dead store and simplify code.
llvm-svn: 92191
2009-12-28 01:53:00 +00:00
Bill Wendling 42bc7ad2b1 Remove dead store.
llvm-svn: 92190
2009-12-28 01:51:30 +00:00
Bill Wendling 5b8d89d0a2 Remove dead variable.
llvm-svn: 92189
2009-12-28 01:48:56 +00:00
Bill Wendling 9a62b467a8 Remove dead variable.
llvm-svn: 92188
2009-12-28 01:47:48 +00:00
Bill Wendling 798e1e6f71 Remove dead store.
llvm-svn: 92187
2009-12-28 01:44:39 +00:00
Bill Wendling 56631085ea Remove dead variable.
llvm-svn: 92186
2009-12-28 01:42:12 +00:00
Bill Wendling acde434d1a Remove dead variable.
llvm-svn: 92185
2009-12-28 01:41:12 +00:00
Bill Wendling 3179a89067 Remove dead variable.
llvm-svn: 92184
2009-12-28 01:36:02 +00:00
Bill Wendling ae606a1d1d Mark some debug variables as 'unused' to quiet compiler and analyzer.
llvm-svn: 92183
2009-12-28 01:34:57 +00:00
Bill Wendling 6ff71a1953 Remove dead store. The initial value was never used, but always overridden.
llvm-svn: 92182
2009-12-28 01:31:11 +00:00
Bill Wendling b8d960d615 Add an "ATTRIBUTE_UNUSED" macro (and use it). It's for variables which are
mainly used in debugging and/or assert situations. It should make the compiler
and the static analyzer stop nagging us about them.

llvm-svn: 92181
2009-12-28 01:20:29 +00:00
Bill Wendling 846ca9b38b Remove dead variable.
llvm-svn: 92180
2009-12-28 01:02:21 +00:00
Bill Wendling ee5ca6e962 Remove dead variable.
llvm-svn: 92179
2009-12-28 01:01:14 +00:00
Bill Wendling 7da8f90d41 Remove dead variable.
llvm-svn: 92178
2009-12-28 01:00:12 +00:00
Eli Friedman affd5fdf37 Make sure to give an error for template argument lists followed by junk.
llvm-svn: 92177
2009-12-27 22:31:18 +00:00
Anton Korobeynikov 73d50b9141 Promote arguments of frameaddr / returnaddr builtins to i32 type, when needed.
This is needed for the platforms, where bitwidth of "int" is not 32 bits
(e.g. 16 on msp430).

llvm-svn: 92176
2009-12-27 14:27:22 +00:00
Eli Friedman 1e26278b3b Add a sanity assertion so that we don't silently generate bad code; I'll file
a bug with a testcase hitting this assertion in a moment.

llvm-svn: 92175
2009-12-27 07:02:50 +00:00
Eli Friedman e513c6af97 Fix runline.
llvm-svn: 92174
2009-12-27 05:59:41 +00:00
Eli Friedman 847a2bce04 Fix PointerExprEvaluator::VisitCastExpr so it doesn't misfold C++ casts which
it doesn't know how to fold, like derived-to-base casts.

llvm-svn: 92173
2009-12-27 05:43:15 +00:00
Eli Friedman af76ad73ed Fix obvious mistake.
llvm-svn: 92172
2009-12-27 03:44:17 +00:00