summaryrefslogtreecommitdiffstats
path: root/clang/lib
Commit message (Collapse)AuthorAgeFilesLines
...
* When adding built-in operator candidates for overload resolutionDouglas Gregor2012-06-041-26/+110
| | | | | | | | involving 'restrict', place restrict on the pointer type rather than on the pointee type. Also make sure that we gather restrict from the pointer type. Fixes PR12854 and the major part of PR11093. llvm-svn: 157910
* Make disabling SSE levels also disable AVX and FMA.Craig Topper2012-06-031-6/+13
| | | | llvm-svn: 157907
* Make AES and PCLMUL features imply SSE2 as that's needed to get the right ↵Craig Topper2012-06-031-3/+4
| | | | | | types defined. llvm-svn: 157906
* Add fma feature flag for Intel FMA instructions.Craig Topper2012-06-031-2/+21
| | | | llvm-svn: 157904
* Improve fixit for comparison operator on lhs of bitwise operator.Nico Weber2012-06-031-1/+1
| | | | | | | | | | | | | | | | Before: test.cc:2:18: note: place parentheses around the == expression to silence this warning if (0 == flags & 0xdd) ^ ( ) Now: test.cc:2:18: note: place parentheses around the == expression to silence this warning if (0 == flags & 0xdd) ^ ( ) llvm-svn: 157897
* Initialize the non-target-dependent fields of the Preprocessor in its ↵Argyrios Kyrtzidis2012-06-021-48/+47
| | | | | | | | | | | constructor so we can destroy it even if it was constructed with "DelayInitialization = true", and we didn't end up calling Preprocessor::Initialize. Fixes crashes in rdar://11558355 llvm-svn: 157892
* ToolInvocation::mapVirtualFile(): Tweak for Win32. Handle the key as native ↵NAKAMURA Takumi2012-06-021-1/+3
| | | | | | path. llvm-svn: 157889
* MIPS: Factor out code selects the float ABI as determined by -msoft-float,Simon Atanasyan2012-06-021-15/+22
| | | | | | | -mhard-float, and -mfloat-abi= to the new function getMipsFloatABI. That simplifies reuse of this code. llvm-svn: 157888
* Fix typos found by http://github.com/lyda/misspell-checkBenjamin Kramer2012-06-028-10/+10
| | | | llvm-svn: 157886
* Implementation of a "soft opt-in" option for -Wimplicit-fallthrough ↵Alexander Kornienko2012-06-021-5/+16
| | | | | | diagnostics: -Wimplicit-fallthrough-per-method llvm-svn: 157871
* [analyzer] Rely on canBeInlined utility instead of checking CallExprAnna Zaks2012-06-022-2/+3
| | | | | | | | explicitly. This will make it easier to add inlining support to more expressions. llvm-svn: 157870
* [analyzer] Fix a spurious undef value warning.Anna Zaks2012-06-011-1/+9
| | | | | | | | | | | | When we timeout or exceed a max number of blocks within an inlined function, we retry with no inlining starting from a node right before the CallEnter node. We assume the state of that node is the state of the program before we start evaluating the call. However, the node pruning removes this node as unimportant. Teach the node pruning to keep the predecessors of the call enter nodes. llvm-svn: 157860
* [analyzer] Fix lack of coverage after empty inlined function.Anna Zaks2012-06-011-0/+2
| | | | | | | We should not stop exploring the path after we return from an empty function. llvm-svn: 157859
* Disable diagnosic path pruning for ReturnUndefChecker.Ted Kremenek2012-06-011-0/+1
| | | | llvm-svn: 157851
* static analyzer: add inlining support for directly called blocks.Ted Kremenek2012-06-015-69/+180
| | | | llvm-svn: 157833
* Don't allow multiple correction candidates that have the same identifierKaelyn Uhrain2012-06-011-25/+53
| | | | | | | | but different nested name specifiers to quietly clobber each other so only one remains if they do not refer to the same NamedDecl. Fixes PR12951. llvm-svn: 157823
* Support C++11 enum forward declarations.Eric Christopher2012-06-011-1/+2
| | | | | | Part of rdar://11570854 llvm-svn: 157787
* [arcmt] Use CFBridgingRetain/CFBridgingRelease instead of ↵Argyrios Kyrtzidis2012-06-014-25/+58
| | | | | | | | | | __bridge_retained/__bridge_transfer when migrating. rdar://11569198 llvm-svn: 157785
* Anonymous union members within a struct are now properly handled as an ↵Aaron Ballman2012-06-011-1/+1
| | | | | | unevaluated field in C++11 mode. This fixes PR12866. llvm-svn: 157784
* In TypoCorrectionConsumer, BestResults to CorrectionResults to lessenKaelyn Uhrain2012-05-311-14/+19
| | | | | | | | | | the confusion among all of the uses of Best* in relation to the set of possible typo correction results. Also add a method to return the set of typo corrections that have the single best edit distance--it returns the second half of the first pair in TypoEditDistanceMap (with getBestEditDistance already returning the first half). llvm-svn: 157781
* objc: properties of NSObject attribute mustFariborz Jahanian2012-05-311-1/+9
| | | | | | | have correct pointer type or issue error, instead of crashing in IRGen. // rdar:// 11569860 llvm-svn: 157780
* [analyzer] Fix BugType memory leak in IdempotentOperationChecker.Tom Care2012-05-311-1/+4
| | | | llvm-svn: 157772
* [analyzer] Cleanup for r157721.Anna Zaks2012-05-311-11/+9
| | | | | | | | | | We should lock the number of elements after the initial parsing is complete. Recursive AST visitors in AnalyzesConsumer and CallGarph can trigger lazy pch deserialization resulting in more calls to HandleTopLevelDecl and appending to the LocalTUDecls list. We should ignore those. llvm-svn: 157762
* Fix an object lifetime issue in clang/Tooling.Alexander Kornienko2012-05-311-6/+9
| | | | llvm-svn: 157759
* Allow some BugReports to opt-out of PathDiagnostic callstack pruning until ↵Ted Kremenek2012-05-315-3/+9
| | | | | | | | | we have significantly improved the pruning heuristics. The current heuristics are pretty good, but they make diagnostics for uninitialized variables warnings particularly useless in some cases. llvm-svn: 157734
* Add builtin for pclmulqdq instruction.Craig Topper2012-05-312-7/+37
| | | | llvm-svn: 157733
* Change wording of 'memcpy' type mismatch warning and remove fixit.Anna Zaks2012-05-301-16/+10
| | | | | | As per comments following r157659. llvm-svn: 157722
* [analyzer]Fix another occurrence of iterator invalidation (LocalTUDecls)Anna Zaks2012-05-301-3/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | Follow up in r155693, r155680. Prevents a hard to reproduce crash with the following stack trace: 3 libsystem_c.dylib 0x00007ff55a835050 _sigtramp + 18446744029881443184 4 clang 0x0000000106218e97 (anonymous namespace)::AnalysisConsumer::HandleTranslationUnit(clang::ASTContext&) + 519 5 clang 0x0000000105cf3002 clang::ParseAST(clang::Sema&, bool, bool) + 690 6 clang 0x00000001059a41d8 clang::ASTFrontendAction::ExecuteAction() + 312 7 clang 0x00000001059a3df7 clang::FrontendAction::Execute() + 231 8 clang 0x00000001059b0ecc clang::CompilerInstance::ExecuteAction(clang::FrontendAction&) + 860 9 clang 0x000000010595e451 clang::ExecuteCompilerInvocation(clang::CompilerInstance*) + 961 10 clang 0x0000000105947f29 cc1_main(char const**, char const**, char const*, void*) + 969 11 clang 0x0000000105958259 main + 473 12 clang 0x0000000105947b34 start + 52 llvm-svn: 157721
* Suggest '%@' for Objective-C objects in ObjC format strings.Jordan Rose2012-05-301-1/+23
| | | | llvm-svn: 157716
* Disable -Wunique-enum for anonymous enums.David Blaikie2012-05-301-2/+4
| | | | | | | | | | | | | This is a large class of false positives where anonymous enums are used to declare constants (see Clang's Diagnostics.h for example). A small number of true positives could probably be found in this bucket by still warning if the anonymous enum is used in a declarator (enum { ... } x;) but so far we don't believe this to be a source of significant benefit so I haven't bothered to preserve those cases. General offline review/acknowledgment by rtrieu. llvm-svn: 157713
* objective-c: revert r157407. It broke a projectFariborz Jahanian2012-05-301-4/+0
| | | | | | and reported as PR12959. // rdar://11499742 llvm-svn: 157697
* Adds a toString method to Replacement, which helps debugging.Manuel Klimek2012-05-301-0/+8
| | | | | | Adds missing header guards to Refactoring.h. llvm-svn: 157694
* Fixed a memory leak in clang/Tooling.Alexander Kornienko2012-05-301-2/+1
| | | | llvm-svn: 157687
* SSE4A should not imply LZCNT and POPCNT. FMA4 should imply SSE4A. Add ↵Craig Topper2012-05-301-3/+5
| | | | | | missing break at the end of btver1 feature list. llvm-svn: 157680
* Update FIXME. ABM is already covered by LZCNT and POPCNT.Craig Topper2012-05-301-1/+1
| | | | llvm-svn: 157676
* Remove some extra braces.Eric Christopher2012-05-301-3/+2
| | | | llvm-svn: 157667
* Add new -Wunique-enum which will warn on enums which all elements have theRichard Trieu2012-05-301-0/+43
| | | | | | | | | | | | same value and were initialized with literals. Clang will warn on code like this: enum A { FIRST = 1, SECOND = 1 }; llvm-svn: 157666
* Add fixits for memory access warnings.Anna Zaks2012-05-301-5/+35
| | | | | | | Also, do not display the builtin name and macro expansion when the function is a builtin. llvm-svn: 157659
* objc: position of 'fixit' was off by one.Fariborz Jahanian2012-05-291-1/+1
| | | | | | This patch fixes it. // rdar://11488351 llvm-svn: 157646
* objective-c: fix a sema and IRGen crash when propertyFariborz Jahanian2012-05-293-9/+13
| | | | | | | | getter result type is safe but does not match with property type resulting in spurious warning followed by crash in IRGen. // rdar://11515196 llvm-svn: 157641
* Install ammintrin.h in the cmake build.Benjamin Kramer2012-05-291-0/+1
| | | | llvm-svn: 157639
* Add an ammintrin.h header for SSE4a intrinsics.Benjamin Kramer2012-05-292-1/+73
| | | | | | | This is a clean-room implementation based on public documentation and I tried to validate it as much as possible against gcc. llvm-svn: 157638
* MIPS: Pass -KPIC argument to MIPS assembler if necessary.Simon Atanasyan2012-05-291-0/+12
| | | | llvm-svn: 157635
* Factor out the code retrieves the last PIC related argument fromSimon Atanasyan2012-05-292-16/+67
| | | | | | | the Clang::ConstructJob() to the new ArgList::getLastArg() routine with eight argument. That simplifies reusing of this code. llvm-svn: 157633
* Define __SSE4A__ when targeting new AMD CPUs.Benjamin Kramer2012-05-291-1/+11
| | | | | | This doesn't really fit the existing SSELevel so it gets an extra flag. llvm-svn: 157630
* Fix indenting.David Blaikie2012-05-291-25/+25
| | | | llvm-svn: 157628
* Sparc is bigendian.Roman Divacky2012-05-291-1/+0
| | | | llvm-svn: 157626
* Make Clang driver pass the last option from -g group to the compiler.Alexey Samsonov2012-05-291-6/+13
| | | | | | Leave a better fixme for different debug info flags llvm-svn: 157602
* Use fewer temporaries mangling APSInt objects. The performance differenceCharles Davis2012-05-291-6/+7
| | | | | | | is negligible, but it makes the code clearer. Based on a suggestion by Jordy Rose. llvm-svn: 157601
* OpenCL: Fix vector conditional operator CodeGen for the case wherePeter Collingbourne2012-05-291-1/+1
| | | | | | the operands are vectors of doubles. llvm-svn: 157596
OpenPOWER on IntegriCloud