summaryrefslogtreecommitdiffstats
path: root/clang
Commit message (Collapse)AuthorAgeFilesLines
* XCore target: Pass through "-fverbose-asm" flag to xcc assembler.Robert Lytton2014-02-112-2/+5
| | | | llvm-svn: 201141
* clang-format: Support lambdas with namespace-qualified return types.Daniel Jasper2014-02-112-0/+2
| | | | | | | E.g.: Foo([]()->std::vector<int> { return { 2 }; }()); llvm-svn: 201139
* clang-format: Fix alignment of comments inside statements.Daniel Jasper2014-02-113-25/+35
| | | | | | | | | | | | | | Before: auto result = SomeObject // Calling someFunction on SomeObject .someFunction(); After: auto result = SomeObject // Calling someFunction on SomeObject .someFunction(); llvm-svn: 201138
* AAPCS: Do not split structs after CPRC allocated on stackOliver Stannard2014-02-112-43/+140
| | | | | | | | | | According to the AAPCS, we can split structs between GPRs and the stack, except for when an argument has already been allocated on the stack. This can occur when a large number of floating-point arguments fill up the VFP registers, and are alllocated on the stack before the general-purpose argument registers are full. llvm-svn: 201137
* Fix self-hosted -Werror build: delete comma at the end of enumerator listAlexey Samsonov2014-02-111-1/+1
| | | | llvm-svn: 201135
* Fix PCH deserialization bug with local static symbols being treated as local ↵Ted Kremenek2014-02-113-1/+28
| | | | | | | | | | | | | extern. This triggered a miscompilation of code using Boost's function_template.hpp when it was included inside a PCH file. A local static within that header would be treated as local extern, resulting in the wrong mangling. This only occurred during PCH deserialization. Fixes <rdar://problem/15975816> and <rdar://problem/15926311>. llvm-svn: 201130
* [analyzer] Inline C++ operator new when c++-inline-allocators is turned on.Jordan Rose2014-02-118-6/+67
| | | | | | | | | This will let us stage in the modeling of operator new. The -analyzer-config opton 'c++-inline-allocators' is currently off by default. Patch by Karthik Bhat! llvm-svn: 201122
* [stackprotector] Add command line option -fstack-protector-strongJosh Magee2014-02-119-10/+36
| | | | | | | | | | This option has the following effects: * It adds the sspstrong IR attribute to each function within the CU. * It defines the macro __SSP_STRONG__ with the value of 2. Differential Revision: http://llvm-reviews.chandlerc.com/D2717 llvm-svn: 201120
* [AArch64] Fixed vget/vset_lane_f16 implementationAna Pazos2014-02-102-39/+99
| | | | | | | | Replaced cast and vreinterepret operations with code to reinterpret bitwise the types float16_t and int16_t. llvm-svn: 201112
* Tests for DR351-370, plus update DR status page to match the latest core ↵Richard Smith2014-02-102-102/+612
| | | | | | issue list. llvm-svn: 201106
* MS ABI: Add support for #pragma pointers_to_membersDavid Majnemer2014-02-1019-23/+250
| | | | | | | | | | | | | | | | | | | Introduce a notion of a 'current representation method' for pointers-to-members. When starting out, this is set to 'best case' (representation method is chosen by examining the class, selecting the smallest representation that would work given the class definition or lack thereof). This pragma allows the translation unit to dictate exactly what representation to use, similar to how the inheritance model keywords operate. N.B. PCH support is forthcoming. Differential Revision: http://llvm-reviews.chandlerc.com/D2723 llvm-svn: 201105
* Basic: Clean up malformed pragma diagnosticsDavid Majnemer2014-02-107-50/+45
| | | | | | | Create a new diagnostic, -Wignored-pragmas and use it to handle any case where a pragma would have a side effect but is ignored. llvm-svn: 201102
* PR18777: This PR is already fixed; add regtest.Richard Smith2014-02-101-0/+5
| | | | llvm-svn: 201100
* Sema: Remove useless MSStructPragmaOn update in Sema::~SemaDavid Majnemer2014-02-101-1/+0
| | | | | | No functional change, this code was just superfluous. llvm-svn: 201099
* ARM: move vshll NEON implementation to common codeTim Northover2014-02-101-13/+10
| | | | | | | Now that both ARM backends use the same implementation for vshll operations, the code can be shared. This is also a necessary LLVM/Clang interface update. llvm-svn: 201094
* ARM: implement vshrn NEON intrinsic in terms of shr/truncTim Northover2014-02-101-13/+10
| | | | | | | Now the backend supports the natural LLVM IR, we can shamelessly steal the AArch64 front-end code to implement the vshrn intrinsic on 32-bit ARM. llvm-svn: 201086
* ASTUnit: simplify remapping files by using the exact same logic in PreprocessorDmitri Gribenko2014-02-101-16/+4
| | | | llvm-svn: 201082
* Fix Clang install rules to not set permissions on include/NAKAMURA Takumi2014-02-101-2/+2
| | | | | | | | | | | | | The CMake install(DIRECTORY) command documents that it sets permissions on directories it is asked to install. Since the <prefix>/include directory may not be exclusive to the LLVM/Clang installation, we should not ask CMake to manage permissions of that directory for us. Instead, give only our own include/clang and include/clang-c subdirectories to the install(DIRECTORY) command. Fixes PR4500. Patch by Brad King. llvm-svn: 201076
* [CMake] add_clang_library(): Use llvm_add_library.NAKAMURA Takumi2014-02-101-33/+17
| | | | | | CMAKE_MODULE_LINKER_FLAGS can be removed since llvm_add_library(MODULE) adds same flags to MODULE. llvm-svn: 201073
* PR18685: Ignore class template specializations as potentialKaelyn Uhrain2014-02-092-0/+23
| | | | | | | nested-name-specifiers for typos unless the typo already has a nested-name-specifier that is a template specialization. llvm-svn: 201056
* [libclang] While visiting a C++ destructor decl, keep the type identifier ↵Argyrios Kyrtzidis2014-02-092-3/+10
| | | | | | | | | | associated with the decl, don't turn it into a type ref. rdar://15907618 llvm-svn: 201042
* Clarify comment. Remove braces from single-statement block.David Blaikie2014-02-091-4/+4
| | | | llvm-svn: 201040
* Improve diagnostic for using non-class/namespace/scoped enum in a nested ↵David Blaikie2014-02-098-29/+37
| | | | | | | | | | | | | | | name specifier. Rather than simply saying "X is not a class or namespace", clarify what X is by providing the aka type in the case where X is a type, or pointing to the named declaration if there's an unambiguous one to refer to. In the ambiguous case, the ambiguities are already enumerated (though could be clarified by describing what kind of entities they are) Included a few FIXMEs in tests where some further improvements could be made. llvm-svn: 201038
* Preprocessor: Add __ALIGNOF_MAX_ALIGN_T__David Majnemer2014-02-092-0/+29
| | | | | | | | | | TargetInfo::getSuitableAlign() was introduced in r146762 and is defined as alignof(std::max_align_t). Introduce __ALIGNOF_MAX_ALIGN_T__ which exposes getSuitableAlign() so that libc++ may take advantage of it. llvm-svn: 201037
* PR16519, PR18009: When checking a partial specialization for uses of its ownRichard Smith2014-02-093-31/+156
| | | | | | | | | | template parameters, don't look for parameters of outer templates. If a problem is found in a default template argument, point the diagnostic at the partial specialization (with a note pointing at the default argument) instead of pointing it at the default argument and leaving it unclear which partial specialization os problematic. llvm-svn: 201031
* type_info objects are not unnamed_addr: the ABI requires us toJohn McCall2014-02-0815-170/+177
| | | | | | | | | | unique them and permits the implementation of dynamic_cast (and anything else which knows it's working with a complete class type) to compare their addresses directly. rdar://16005328 llvm-svn: 201020
* Move the -fms-compatibility using decl check after real access checkingReid Kleckner2014-02-082-4/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: This avoids false positives from -Wmicrosoft when name lookup would normally succeed in standard C++. This triggered on a common CRTP pattern in clang, where a derived class would have a private using decl to pull in members of a dependent base: class Verifier : InstVisitor<Verifier> { private: using InstVisitor<Verifier>::visit; ... void anything() { visit(); // warned here } }; Real access checks pass here because we're in the context of the Verifier, but the -Wmicrosoft extension was just looking for the private access specifier. Reviewers: rsmith CC: cfe-commits Differential Revision: http://llvm-reviews.chandlerc.com/D2679 llvm-svn: 201019
* PR18581: Attempt to complete the type in a VLA declaration before checkingRichard Smith2014-02-082-0/+15
| | | | | | whether it's POD. llvm-svn: 201018
* clang-cl: Alias /Zi and /Z7 to -gline-tables-onlyReid Kleckner2014-02-081-2/+3
| | | | | | | LLVM only knows how to emit Z7-style line tables on -win32, so there's no reason for clang to emit anything other than line info. llvm-svn: 201017
* MS ABI: Use the most recent decl to check the inheritance modelReid Kleckner2014-02-082-3/+8
| | | | | | This was crashing compilation of DeclContext::buildLookupImpl<>. llvm-svn: 201013
* Fix lifetime issue causing buildbot failures.Richard Smith2014-02-081-2/+2
| | | | llvm-svn: 201012
* Remove the -fhidden-weak-vtables -cc1 option. It was dead,John McCall2014-02-0814-186/+30
| | | | | | gross, and increasingly replaced through other mechanisms. llvm-svn: 201011
* ASTUnit: remove dead code in remapping filesDmitri Gribenko2014-02-082-76/+23
| | | | | | | ASTUnit contains code to remap files to other files on disk. This code is not used. We only remap files to MemoryBuffers. llvm-svn: 201010
* [analyzer] Objective-C object literals are always non-nil.Jordan Rose2014-02-083-7/+50
| | | | | | <rdar://problem/15999214> llvm-svn: 201007
* PR16638, DR1552: the exception specification on an implicitly-declaredRichard Smith2014-02-073-12/+19
| | | | | | | | | | | 'operator delete' or 'operator delete[]' is an explicit exception specification. Therefore we should diagnose 'void operator delete(void*)' instead of 'void operator delete(void*) noexcept'. This diagnostic remains an ExtWarn, since in practice people don't always include the exception specification in such a declaration. llvm-svn: 201002
* Fold together two repeated identical 'if's.Richard Smith2014-02-071-7/+5
| | | | llvm-svn: 201000
* Fix test from r200979 on WindowsBen Langmuir2014-02-071-1/+1
| | | | | | | | | Hopefully the last tweak needed to get this test working everywhere. Remove matching of the prefix of sys_header.h, which was never the point of the test anyway. This avoids dealing with path separators. llvm-svn: 200987
* Objective-C. Revert patch r193003 for furtherFariborz Jahanian2014-02-072-45/+4
| | | | | | internal discussions. // rdar://16006401 llvm-svn: 200986
* Fix test from r200979 on non-Darwin systemsBen Langmuir2014-02-071-7/+7
| | | | | | | Add a darwin triple to get the behaviour from isysroot that the test expects. llvm-svn: 200982
* [analyzer] Just silence all warnings coming out of std::basic_string.Jordan Rose2014-02-073-14/+35
| | | | | | | | | This means always walking the whole call stack for the end path node, but we'll assume that's always fairly tractable. <rdar://problem/15952973> llvm-svn: 200980
* Stat system dependencies when using -verify-pchBen Langmuir2014-02-077-22/+56
| | | | | | | | We don't stat the system headers to check for stalenes during regular PCH loading for performance reasons. When explicitly saying -verify-pch, we want to check all the dependencies - user or system. llvm-svn: 200979
* ASTUnit: ArrayRef'ize RemappedFilesDmitri Gribenko2014-02-074-28/+19
| | | | llvm-svn: 200975
* clang-format: Fix column limit violation for merged lines in macros.Daniel Jasper2014-02-072-0/+45
| | | | | | | | | | | | | | | | Before (81 columns): #define A \ void aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa() { return aaaaaaaa; } \ int i; After: #define A \ void aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa() { \ return aaaaaaaa; \ } \ int i; llvm-svn: 200974
* Fix AAPCS compliance for HFAs containing doubles and long doublesOliver Stannard2014-02-073-5/+40
| | | | | | | | | An HFA is defined as a struct containing floating point values of the same machine type. In the 32-bit ABI, double and long double have the same machine type, so a struct with a mixture of these types must be an HFA (assuming it meets the other criteria). llvm-svn: 200971
* clang-format: Fix range-based for-loop formatting.Daniel Jasper2014-02-072-0/+4
| | | | | | | | | | | | | | | Before: for (aaaaaaaaa aaaaaaaaaaaaaaaaaaaaa : aaaaaaaaaaaa.aaaaaaaaaaaa() .aaaaaaaaa() .a()) { } After: for (aaaaaaaaa aaaaaaaaaaaaaaaaaaaaa : aaaaaaaaaaaa.aaaaaaaaaaaa().aaaaaaaaa().a()) { } llvm-svn: 200968
* Document return value for FileManager::getNoncachedStatValue()Dmitri Gribenko2014-02-071-0/+2
| | | | llvm-svn: 200967
* Revert r194097: "With this patch -Wwrite-strings is still implemented with ↵Argyrios Kyrtzidis2014-02-075-8/+28
| | | | | | | | | | | | | the terrible hack of passing -fconst-strings to -cc1" Passing or not a language option based on diagnostic settings is a bad idea, it breaks using a PCH that was compiled with different diagnostic settings. Also add a test case to make sure we don't regress. llvm-svn: 200964
* MS ABI: Don't be so hasty to judge an inheritance modelDavid Majnemer2014-02-073-10/+20
| | | | | | | | If we are in the middle of defining the class, don't attempt to validate previously annotated declarations. We may not have seen base specifiers or virtual method declarations yet. llvm-svn: 200959
* Temporary fix for PR18473: Don't try to evaluate the initializer for aRichard Smith2014-02-062-7/+21
| | | | | | | | | | | | type-dependent variable, even if the initializer isn't value-dependent. This happens for ParenListExprs composed of non-value-dependent subexpressions, for instance. We should really give ParenListExprs (and InitListExprs) the type of the initialized entity if they're used to represent a dependent initialization (and if so, set them to be type-, value- and instantiation-dependent). llvm-svn: 200954
* Fixes PR18762, stop the StmtPrinter for ObjCPropertyRefExpr from crashing onRichard Trieu2014-02-062-1/+12
| | | | | | certain receiver types. llvm-svn: 200953
OpenPOWER on IntegriCloud