summaryrefslogtreecommitdiffstats
path: root/clang/test
Commit message (Collapse)AuthorAgeFilesLines
* [modules] If we merge a template, also track that its parameters are merged soRichard Smith2015-06-171-4/+3
| | | | | | that we know when its default arguments should be visible. llvm-svn: 239936
* [modules] Improve diagnostic for a template-id that's invalid because a defaultRichard Smith2015-06-172-6/+16
| | | | | | argument is not visible. llvm-svn: 239934
* [ARM] Replace hard coded metadata arguments in tests with a regex.Ranjeet Singh2015-06-172-24/+24
| | | | | | Differential Revision: http://reviews.llvm.org/D10507 llvm-svn: 239932
* Move xtest to its own file to match the gcc header organization.Eric Christopher2015-06-171-0/+4
| | | | llvm-svn: 239926
* [fixit] Use overwriteChangedFiles() to deal with Windows mapped filesReid Kleckner2015-06-171-0/+318
| | | | | | Fixes one instance of PR17960. llvm-svn: 239920
* Fix clang/test/Headers/x86intrin-2.c. _readfsbase_u32() is provided in not ↵NAKAMURA Takumi2015-06-171-0/+2
| | | | | | i686 but x86-64. llvm-svn: 239896
* [OPENMP] Fixed failed test for reduction clause in simd constructs.Alexey Bataev2015-06-171-6/+6
| | | | llvm-svn: 239895
* [OPENMP] Code reformatting for omp simd codegen, NFC.Alexey Bataev2015-06-171-6/+6
| | | | llvm-svn: 239889
* Update the intel intrinsic headers to use the target attribute support.Eric Christopher2015-06-173-120/+144
| | | | | | | | | | | | | | | | | | | This involved removing the conditional inclusion and replacing them with target attributes matching the original conditional inclusion and checks. The testcase update removes the macro checks for each file and replaces them with usage of the __target__ attribute, e.g.: int __attribute__((__target__(("sse3")))) foo(int a) { _mm_mwait(0, 0); return 4; } This usage does require the enclosing function have the requisite __target__ attribute for inlining and code generation - also for any macro intrinsic uses in the enclosing function. There's no change for existing uses of the intrinsic headers. llvm-svn: 239883
* [OPENMP] Supported reduction clause in omp simd construct.Alexey Bataev2015-06-171-3/+30
| | | | | | | | | | | | | | | | The following code is generated for reduction clause within 'omp simd' loop construct: #pragma omp simd reduction(op:var) for (...) <body> alloca priv_var priv_var = <initial reduction value>; <loop_start>: <body> // references to original 'var' are replaced by 'priv_var' <loop_end>: var op= priv_var; llvm-svn: 239881
* parser: wordsmith diagnostic messageSaleem Abdulrasool2015-06-171-1/+1
| | | | | | Address post-commit commit about the wording of the warning. llvm-svn: 239879
* [modules] Fix merging of default template arguments onto friend templates.Richard Smith2015-06-162-0/+12
| | | | | | | | | Previously we'd complain about redefinition of default arguments when we instantiated a class with a friend template that inherits its default argument, because we propagate the default template arguemnt onto the friend when we reload the AST. llvm-svn: 239857
* Honor the objc_runtime_name attribute when encoding class/protocol names.Douglas Gregor2015-06-161-1/+15
| | | | | | | | While the rest of the Objective-C metadata seems to honor objc_runtime_name, the encoding strings produced by, e.g., @encode and property meta, were not. Fixes rdar://problem/21408305. llvm-svn: 239852
* Adjust clang side tests effected by 239795 before reapplying said changePhilip Reames2015-06-168-41/+41
| | | | llvm-svn: 239848
* parser: diagnose empty attribute blocksSaleem Abdulrasool2015-06-161-0/+2
| | | | | | | | | | | MS attributes do not permit empty attribute blocks. Correctly diagnose those. We continue to parse to ensure that we recover correctly. Because the block is empty, we do not need to skip any tokens. Bonus: tweak the comment that I updated but forgot to remove the function name in a previous commit. llvm-svn: 239846
* [Hexagon] unused-local-typedef warning test is passing.Colin LeMahieu2015-06-161-1/+0
| | | | llvm-svn: 239832
* [SystemZ] Mangle long double as __float128Ulrich Weigand2015-06-161-0/+2
| | | | | | | | | | | | | In r239421, the mangling of long double on PowerPC Linux targets was changed to use "g" instead of "e". This same change also needs to be done for SystemZ (all targets, since we support only Linux on SystemZ anyway). This is because an old ABI variant set "long double" to a 64-bit type equivalent to "double", and the "e" mangling code is still used to refer to that old ABI for compatibility reasons. llvm-svn: 239822
* [mips] Don't propagate -mfpxx by default if soft/single float were also set.Toma Tabacu2015-06-163-0/+222
| | | | | | | | | | | | | | | | | Summary: If the driver is only given -msoft-float/-mfloat-abi=soft or -msingle-float, we should refrain from propagating -mfpxx, unless it was explicitly given on the command line. Reviewers: atanasyan, dsanders Reviewed By: atanasyan, dsanders Subscribers: cfe-commits, mpf Differential Revision: http://reviews.llvm.org/D10387 llvm-svn: 239818
* [OPENMP] Support lastprivate clause in omp simd directive.Alexey Bataev2015-06-161-1/+8
| | | | | | Added codegen for lastprivate clauses within simd loop-based directives. llvm-svn: 239813
* [OPENMP] Remove last iteration separation for loop-based constructs.Alexey Bataev2015-06-161-11/+2
| | | | | | Previously the last iteration for simd loop-based OpenMP constructs were generated as a separate code. This feature is not required and codegen is simplified. llvm-svn: 239810
* InstrProf: Fix coverage mapping when "if" is a macroJustin Bogner2015-06-161-0/+14
| | | | | | | | | We were propagating the coverage map into the body of an if statement, but not into the condition thereafter. This is fine as long as the two locations are in the same virtual file, but they won't be when the "if" part of the statement is from a macro and the condition is not. llvm-svn: 239803
* [modules] Rename -fmodule-maps to -fimplicit-module-maps (and likewise forRichard Smith2015-06-161-0/+7
| | | | | | -fno-module-maps). The old names are preserved for compatibility. llvm-svn: 239792
* Commit some test changes somehow missed in r239789.Richard Smith2015-06-1611-30/+30
| | | | llvm-svn: 239791
* [modules] Simplify -cc1 interface for enabling implicit module maps.Richard Smith2015-06-16170-541/+541
| | | | | | | | | | | | | We used to have a flag to enable module maps, and two more flags to enable implicit module maps. This is all redundant; we don't need any flag for enabling module maps in the abstract, and we don't usually have -fno- flags for -cc1. We now have just a single flag, -fimplicit-module-maps, that enables implicitly searching the file system for module map files and loading them. The driver interface is unchanged for now. We should probably rename -fmodule-maps to -fimplicit-module-maps at some point. llvm-svn: 239789
* According to the OpenMP spec, all the preprocessor macros should be Samuel Antao2015-06-151-0/+31
| | | | | | expanded in OpenMP pragmas. This patch adds support for that in -E. llvm-svn: 239784
* [modules] Re-enable accidentally-disabled test.Richard Smith2015-06-151-6/+6
| | | | llvm-svn: 239783
* Debug Info: Turn on ODR type uniquing for (the C++ part of) Objective-C++.Adrian Prantl2015-06-151-1/+2
| | | | | | rdar://problem/20571359 llvm-svn: 239781
* Fix submodule test to pass on content addressable filesystems where inodes ↵Reid Kleckner2015-06-152-0/+2
| | | | | | would collide llvm-svn: 239765
* Protection against stack-based memory corruption errors using SafeStack: ↵Peter Collingbourne2015-06-153-0/+22
| | | | | | | | | | | | | | | | | | | | | | | | | Clang command line option and function attribute This patch adds the -fsanitize=safe-stack command line argument for clang, which enables the Safe Stack protection (see http://reviews.llvm.org/D6094 for the detailed description of the Safe Stack). This patch is our implementation of the safe stack on top of Clang. The patches make the following changes: - Add -fsanitize=safe-stack and -fno-sanitize=safe-stack options to clang to control safe stack usage (the safe stack is disabled by default). - Add __attribute__((no_sanitize("safe-stack"))) attribute to clang that can be used to disable the safe stack for individual functions even when enabled globally. Original patch by Volodymyr Kuznetsov and others at the Dependable Systems Lab at EPFL; updates and upstreaming by myself. Differential Revision: http://reviews.llvm.org/D6095 llvm-svn: 239762
* parser: improve diagnostics for MS attributesSaleem Abdulrasool2015-06-151-0/+3
| | | | | | | | Switch to using BalancedDelimiterTracker to get better diagnostics for unbalanced delimiters. This still does not handle any of the attributes, simply improves the parsing. llvm-svn: 239758
* Wildcard out some SSA value names from the ACLE intrinsic test caseReid Kleckner2015-06-151-6/+6
| | | | llvm-svn: 239757
* [Sparc] Make soft-float emit an error.James Y Knight2015-06-151-10/+8
| | | | | | | | | | | | LLVM does not and has not ever supported a soft-float ABI mode on Sparc, so don't pretend that it does. Also switch the default from "soft-float" -- which was actually hard-float because soft-float is unimplemented -- to hard-float. Differential Revision: http://reviews.llvm.org/D10457 llvm-svn: 239755
* [modules] Better support for redefinitions of an entity from the same module.Richard Smith2015-06-155-10/+15
| | | | | | | Support this across module save/reload and extend the 'missing import' diagnostics with a list of providing modules. llvm-svn: 239750
* This patch implements clang support for the ACLE special register intrinsicsLuke Cheeseman2015-06-155-0/+307
| | | | | | | | | | | | | in section 10.1, __arm_{w,r}sr{,p,64}. This includes arm_acle.h definitions with builtins and codegen to support these, the intrinsics are implemented by generating read/write_register calls which get appropriately lowered in the backend based on the register string provided. SemaChecking is also implemented to fault invalid parameters. Differential Revision: http://reviews.llvm.org/D9697 llvm-svn: 239737
* [analyzer] Remove ObjCContainersChecker size information when a ↵Devin Coughlin2015-06-151-0/+22
| | | | | | | | | | | | | CFMutableArrayRef escapes Update ObjCContainersChecker to be notified when pointers escape so it can remove size information for escaping CFMutableArrayRefs. When such pointers escape, un-analyzed code could mutate the array and cause the size information to be incorrect. rdar://problem/19406485 llvm-svn: 239709
* Add test for parsing the XOR operator in Intel syntax inline assembly.Michael Kuperstein2015-06-141-0/+2
| | | | | | | | | LLVM side of the patch was committed as r239695. Differential Revision: http://reviews.llvm.org/D10384 Patch by marina.yatsina@intel.com llvm-svn: 239696
* Add `-verify-ignore-unexpected` option to ignore unexpected diagnostics in ↵Eric Fiselier2015-06-131-0/+81
| | | | | | | | | | | | | | | | | | | | | VerifyDiagnosticsConsumer Summary: The goal of this patch is to make `-verify` easier to use when testing libc++. The `notes` attached to compile error diagnostics are numerous and relatively unstable when they reference libc++ header internals. This patch allows libc++ to write stable compilation failure tests by allowing unexpected diagnostic messages to be ignored where they are not relevant. This patch adds a new CC1 flag called `-verify-ignore-unexpected`. `-verify-ignore-unexpected` tells `VerifyDiagnosticsConsumer` to ignore *all* unexpected diagnostic messages. `-verify-ignore-unexpected=<LevelList>` can be used to only ignore certain diagnostic levels. `<LevelList>` is a comma separated list of diagnostic levels to ignore. The supported levels are `note`, `remark`, `warning` and `error`. Reviewers: bogner, grosser, EricWF Reviewed By: EricWF Subscribers: cfe-commits Differential Revision: http://reviews.llvm.org/D10138 llvm-svn: 239665
* Revert r239213: "clang-cl: Implement /GL in terms of -flto."Hans Wennborg2015-06-131-6/+0
| | | | | | | Reverting until it's easier to use this in a real-world build, e.g. when the linker can handle it. llvm-svn: 239656
* [CodeGen] Don't evaluate immediate inlineasm arguments using isICE().Ahmed Bougacha2015-06-131-0/+5
| | | | | | | | | | | Instead, just EvaluateAsInt(). Follow-up to r239549: rsmith points out that isICE() is expensive; seems like it's not the right concept anyway, as it fails on `static const' in C, and will actually trigger the assert below on: test/Sema/inline-asm-validate-x86.c llvm-svn: 239651
* [CodeGen] Use IRBuilder to create llvm.lifetime intrinsics.Alexey Samsonov2015-06-121-2/+4
| | | | | | | | | | | | | | | | | | | | Summary: In addition to easier syntax, IRBuilder makes sure to set correct debug locations for newly added instructions (bitcast and llvm.lifetime itself). This restores the original behavior, which was modified by r234581 (reapplied as r235553). Extend one of the tests to check for debug locations. Test Plan: regression test suite Reviewers: aadg, dblaikie Subscribers: cfe-commits, majnemer Differential Revision: http://reviews.llvm.org/D10418 llvm-svn: 239643
* [ms] Don't try to delay lookup for failures in SFINAE context (PR23823)Hans Wennborg2015-06-121-0/+10
| | | | | | | | | | | | | The underlying problem in PR23823 already existed before my recent change in r239558, but that change made it worse (failing not only for undeclared symbols, but also failed overload resolution). This makes Clang not try to delay the lookup in SFINAE context. I assume no current code is relying on SFINAE working with lookups that need to be delayed, because that never seems to have worked. Differential Revision: http://reviews.llvm.org/D10417 llvm-svn: 239639
* Quote the user provided string in the warning message and updateEric Christopher2015-06-121-2/+2
| | | | | | tests accordingly. llvm-svn: 239635
* [MS ABI] Lock-in the derived memptr rep. for base-to-derived conversionsDavid Majnemer2015-06-121-0/+11
| | | | | | | | | We would get this right in the case where an explicit cast was formed but not when we were performing an implicit conversion. This fixes PR23828. llvm-svn: 239625
* Allow case-insensitive values for -mcpu for AArch64 target in line with GCC.Gabor Ballabas2015-06-122-0/+18
| | | | | | | GCC allows case-insensitive values for -mcpu, -march and -mtune options. This patch implements the same behaviour for the -mcpu option for the AArch64 target. llvm-svn: 239619
* This patch makes the NEON intrinsics vget_lane_f16, vgetq_lane_f16,Luke Cheeseman2015-06-121-0/+24
| | | | | | | | vset_lane_f16 and vsetq_lane_f16 available in AArch32. Differential Revision: http://reviews.llvm.org/D10388 llvm-svn: 239610
* Revert commit r239481 as it is dependent on reverted llvm commit r239480.Teresa Johnson2015-06-121-10/+0
| | | | llvm-svn: 239588
* Add a warning for unsupported elements of the target attribute.Eric Christopher2015-06-121-0/+2
| | | | | | | | | Since we're ignoring the tune= and fpmath= attributes go ahead and add a warning alerting people to the fact that we're going to ignore that part of it during code generation and tie it to the attribute warning set. llvm-svn: 239583
* Handle fpmath= in the target attribute.Eric Christopher2015-06-121-0/+3
| | | | | | | | | | Right now we're ignoring the fpmath attribute since there's no backend support for a feature like this and to do so would require checking the validity of the strings and doing general subtarget feature parsing of valid and invalid features with the target attribute feature. llvm-svn: 239582
* Handle -mno-<feature> in target attribute strings by replacing theEric Christopher2015-06-121-0/+4
| | | | | | | -mno- with a -<feature> to match how we handle this in the rest of the frontend. llvm-svn: 239581
* Add support for tune= to the target attribute support by ignoring it.Eric Christopher2015-06-121-0/+4
| | | | | | | We don't currently support the -mtune option in any useful way so ignoring the annotation is fine. llvm-svn: 239580
OpenPOWER on IntegriCloud