Commit Graph

82429 Commits

Author SHA1 Message Date
Ted Kremenek 9e0cf0978c Add optional timing logging for code completion results. This causes a UDP packet
containing the time taken for the code completion to be sent to a designated server
(which is specified using a compile-time -D flag).

llvm-svn: 101326
2010-04-15 01:02:28 +00:00
Evan Cheng 8442ef6f89 80 col violations.
llvm-svn: 101325
2010-04-15 01:01:55 +00:00
Devang Patel 3d6c40c616 Add comment.
llvm-svn: 101317
2010-04-15 00:02:49 +00:00
Douglas Gregor 454a5b65d4 Warn about non-aggregate classes with no user-declared constructors
that have reference or const scalar members, since those members can
never be initializer or modified. Fixes <rdar://problem/7804350>.

llvm-svn: 101316
2010-04-15 00:00:53 +00:00
Devang Patel 97bdf94da3 There is no need to track compile unit offsets if there is only one compile unit.
llvm-svn: 101315
2010-04-14 23:56:24 +00:00
Devang Patel b08ccb62d5 Remove dead code.
llvm-svn: 101314
2010-04-14 23:54:13 +00:00
Tobias Grosser de1a37b872 IPO needs ScalarOpts and InstCombine in its libs
The commit "Adding IPSCCP and Internalize passes to the C-bindings" introduced
new dependencies for IPO. Add these to the CMAKE build as otherwise the
BUILD_SHARED_LIBS=1 build fails.

llvm-svn: 101313
2010-04-14 23:42:23 +00:00
Douglas Gregor 064fdb2fe8 Always diagnose and complain about problems in
ResolveAddressOfOverloadedFunction when asked to complain. Previously,
we had some weird handshake where ResolveAddressOfOverloadedFunction
expected its caller to handle some of the diagnostics but not others,
and yet there was no way for the caller to know which case we were
in. Eliminate this madness, fixing <rdar://problem/7765884>.

llvm-svn: 101312
2010-04-14 23:11:21 +00:00
Alexis Hunt 1deb972b55 Fix 80-cols violtaions
llvm-svn: 101311
2010-04-14 23:07:37 +00:00
Johnny Chen 82c50b11fa Fixed another assert exposed by fuzzing. Now, the DisassembleVFPLdStMulFrm()
function checks whether we have a valid submode for VLDM/VSTM (must be either
"ia" or "db") before calling ARM_AM::getAM5Opc(AMSubMode, unsigned char).

llvm-svn: 101306
2010-04-14 22:37:17 +00:00
Jim Grosbach 32bb362655 Add -arm-long-calls option to force calls to be indirect. This makes the
kernel linker happier when dealing with kexts.

Radar 7805069

llvm-svn: 101303
2010-04-14 22:28:31 +00:00
Dan Gohman 20c87b1adf Fix TrackingVH to handle const Value subclasses.
llvm-svn: 101300
2010-04-14 22:24:25 +00:00
Dan Gohman 849833aea3 Remove a const here. This makes this function consistent with all the
other getOperand wrappers, and it makes it easier to use with DebugInfo
code, which isn't currently prepared to see const MDNode *.

llvm-svn: 101299
2010-04-14 22:23:05 +00:00
Dan Gohman 0b4df0425f Constify GetConstantStringInfo.
llvm-svn: 101298
2010-04-14 22:20:45 +00:00
Douglas Gregor 2d2d90750c Once we've emitted a fatal diagnostic, keep counting errors but with a
separate count of "suppressed" errors. This way, semantic analysis
bits that depend on the error count to determine whether problems
occured (e.g., some template argument deduction failures, jump-scope
checking) will not get confused.

The actual problem here is that a missing #include (which is a fatal
error) could cause the jump-scope checker to run on invalid code,
which it is not prepared to do. Trivial fix for both
<rdar://problem/7775941> and <rdar://problem/7775709>.

llvm-svn: 101297
2010-04-14 22:19:45 +00:00
Nicolas Geoffray 99bfbca6ec Don't use DILocation when processing a DebugLoc.
llvm-svn: 101294
2010-04-14 22:06:37 +00:00
Johnny Chen 9aaaf4d5fa For t2BFI disassembly, apply the same error checking as in r101205.
Change the error msg to read "Encoding error: msb < lsb".

llvm-svn: 101293
2010-04-14 22:04:45 +00:00
Dan Gohman 7a3dff329f Move a bunch of methods from CallSite to CallSiteBase, so that they can
be used in ImmutableCallSite too.

llvm-svn: 101292
2010-04-14 21:47:32 +00:00
Johnny Chen 7637827064 Fixed another assert exposed by fuzzing. The utility function getRegisterEnum()
was asserting because the (RegClass, RegNum) combination doesn't make sense from
an encoding point of view.

Since getRegisterEnum() is used all over the place, to change the code to check
for encoding error after each call would not only bloat the code, but also make
it less readable.  An Err flag is added to the ARMBasicMCBuilder where a client
can set a non-zero value to indicate some kind of error condition while building
up the MCInst.  ARMBasicMCBuilder::BuildIt() checks this flag and returns false
if a non-zero value is detected.

llvm-svn: 101290
2010-04-14 21:03:13 +00:00
Ted Kremenek ee457516e6 Make CXLanguage_Invalid the first enum value (with '0' as its value) in CXLanguageKind.
llvm-svn: 101287
2010-04-14 20:58:32 +00:00
Jakob Stoklund Olesen 938f2ae310 Remove unneeded types from test.
llvm-svn: 101286
2010-04-14 20:56:09 +00:00
Evan Cheng 21b588b678 - Code clean up to reduce indentation.
- TryToOptimizeStoreOfMallocToGlobal should check if TargetData is available and bail out if it is not. The transformations being done requires TD.

llvm-svn: 101285
2010-04-14 20:52:55 +00:00
Fariborz Jahanian b5795c01c4 Fix a -pedantic spurious warning involving @dynamic.
llvm-svn: 101284
2010-04-14 20:52:42 +00:00
Dan Gohman 33c46fde07 Use FunTy instead of hard-coding Function.
llvm-svn: 101283
2010-04-14 20:49:44 +00:00
Bob Wilson c05b887c84 Don't custom lower bit converts to ARM VMOVDRRD or VMOVDRR when the operand
does not have a legal type.  The legalizer does not know how to handle those
nodes.  Radar 7854640.

llvm-svn: 101282
2010-04-14 20:45:23 +00:00
Chris Lattner dd6697b4fa improve altivec c++ support by adding casts, patch by
Anton Yartsev!

llvm-svn: 101281
2010-04-14 20:35:39 +00:00
Dan Gohman 7a633cd750 Oops, make these public.
llvm-svn: 101280
2010-04-14 20:31:28 +00:00
Dan Gohman 0ebddbe1d9 Move getType() and getCaller() into CallSiteBase so that
ImmutableCallSite can use them too.

llvm-svn: 101279
2010-04-14 20:28:44 +00:00
Douglas Gregor 2fb18b746f Thread a Scope pointer into BuildRecoveryCallExpr to help typo
correction find names when a call failed. Fixes
<rdar://problem/7853795>.

llvm-svn: 101278
2010-04-14 20:27:54 +00:00
Evan Cheng 9e100384cb Trim tests and convert to FileCheck.
llvm-svn: 101277
2010-04-14 20:22:17 +00:00
Dan Gohman c87b74d913 Delete unneeeded arguments.
llvm-svn: 101276
2010-04-14 20:17:22 +00:00
Dan Gohman a3918ecdf5 Delete unused arguments.
llvm-svn: 101275
2010-04-14 20:05:00 +00:00
Douglas Gregor 280e1ee0ae Teach typo correction about various language keywords. We can't
generally recover from typos in keywords (since we would effectively
have to mangle the token stream). However, there are still benefits to
typo-correcting with keywords:
  - We don't make stupid suggestions when the user typed something
  that is similar to a keyword. 
  - We can suggest the keyword in a diagnostic (did you mean
  "static_cast"?), even if we can't recover and therefore don't have
  a fix-it.

llvm-svn: 101274
2010-04-14 20:04:41 +00:00
Dan Gohman 7deb447781 Factor out EH landing pad code into a separate function, and constify
a bunch of stuff to support it.

llvm-svn: 101273
2010-04-14 19:53:31 +00:00
Dan Gohman c2c08d19b8 Reset the debug location even if the instruction was a terminator.
llvm-svn: 101272
2010-04-14 19:30:02 +00:00
Dan Gohman a0e9a7285e Fix a missing #include.
llvm-svn: 101270
2010-04-14 18:57:18 +00:00
Dan Gohman cacd4f2401 Refine #includes.
llvm-svn: 101269
2010-04-14 18:49:17 +00:00
Dan Gohman d313a05a16 Split ISD::NodeType and a few related items out of SelectionDAGNodes.h
into a separate header to allow clients to use them without pulling in
SelectionDAG-specific declarations.

llvm-svn: 101268
2010-04-14 18:44:34 +00:00
Dan Gohman 8ebcbe949a Pull utility routines with no SelectionDAG dependence out of
SelectionDAGBuilder. FunctionLoweringInfo isn't an ideal place for
them to live, but it's better than SelectionDAGBuilder for now.

llvm-svn: 101267
2010-04-14 18:31:02 +00:00
Dan Gohman f5cca35750 Fix typos in comments.
llvm-svn: 101266
2010-04-14 18:24:06 +00:00
Gabor Greif fefdd42644 performance: cache the dereferenced use_iterator
llvm-svn: 101265
2010-04-14 18:13:29 +00:00
Dan Gohman fea9ba18ff Delete an obsolete comment.
llvm-svn: 101264
2010-04-14 17:40:25 +00:00
Dan Gohman 3215eae4a3 Delete an unused function.
llvm-svn: 101263
2010-04-14 17:22:02 +00:00
Dan Gohman 094fc7b09e Clear the FunctionLoweringInfo object before doing other things that
don't need it.

llvm-svn: 101262
2010-04-14 17:13:16 +00:00
Dan Gohman ad0b3ea3cc Move this assert out of SelectionDAGISel into FunctionLoweringInfo, and
drop the redundant #ifndef NDEBUG.

llvm-svn: 101261
2010-04-14 17:11:23 +00:00
Dan Gohman 0f405c8d73 Add a comment.
llvm-svn: 101260
2010-04-14 17:09:37 +00:00
Douglas Gregor fd0e2e31be Return the corrected DeclarationName from Sema::CorrectTypo rather
than just a bool indicating that correction occurred. No actual
functionality change (it's still always used like a bool), but this
refactoring will be used to support typo correction to keywords.

llvm-svn: 101259
2010-04-14 17:09:22 +00:00
Dan Gohman 2ca8fb229c Move the code for initialing the entry block livein set out of
SelectionDAGISel.

llvm-svn: 101258
2010-04-14 17:05:00 +00:00
Daniel Dunbar d51c1a6e09 IRgen/NeXT: Simplify to use AST record layout for getting offsets instead of the
IRgen record layout, which this code doesn't need to depend on.

llvm-svn: 101257
2010-04-14 17:02:21 +00:00
Dan Gohman 4bfb437ec9 Reorgnaize this code to be more tidy and readable.
llvm-svn: 101256
2010-04-14 17:02:07 +00:00