summaryrefslogtreecommitdiffstats
path: root/clang/test
Commit message (Collapse)AuthorAgeFilesLines
...
* [X86] Add _mm_broadcastsd_pd intrinsicMichael Kuperstein2015-05-191-0/+5
| | | | | | _mm_broadcastsd_pd is basically an alias for _mm_movedup_pd, however the alias is only available from AVX2 forward. llvm-svn: 237698
* [X86] Added _mm256_bslli_epi128 and _mm256_bsrli_epi128.Michael Kuperstein2015-05-191-0/+10
| | | | | | These two intrinsics are alternative names for _mm256_slli_si256 and _mm256_srli_si256, respectively. llvm-svn: 237693
* [OPENMP] Fixed codegen for copying/initialization of array variables/parameters.Alexey Bataev2015-05-195-0/+112
| | | | | | This modification generates proper copyin/initialization sequences for array variables/parameters. Before they were considered as pointers, not arrays. llvm-svn: 237691
* [OPENMP] Prohibit VLAs in 'private/firstprivate' clauses of 'task' directive.Alexey Bataev2015-05-193-1/+11
| | | | | | Currently runtime does not allow to support variably modified types for 'private' and 'firstprivate' clauses in 'task' directives. llvm-svn: 237674
* [OPENMP] Prohibit variably modified types in 'copyprivate' clause.Alexey Bataev2015-05-191-2/+2
| | | | | | Runtime does not allow to work with VLAs in copyprivate clause. llvm-svn: 237672
* [OPENMP] Fixed analysis of function arguments and their data sharing attributes.Alexey Bataev2015-05-194-4/+30
| | | | | | Added proper analysis for types of function arguments. llvm-svn: 237670
* PR20073: promote "dereference of 'void*'" from Extension to ExtWarn.Richard Smith2015-05-192-6/+6
| | | | llvm-svn: 237652
* [modules] Support for merging a parsed definition of a static data member of ↵Richard Smith2015-05-191-0/+2
| | | | | | a class template into an imported but hidden definition. llvm-svn: 237647
* Revert changes to DefaultABIInfo accidentally introduced in r208733Reid Kleckner2015-05-181-0/+12
| | | | | | | | | | | | Also add trivial handling of transparent unions. PPC32, MSP430, and XCore apparently all rely on DefaultABIInfo. This should worry you, because DefaultABIInfo is not implementing the rules of any particular ABI. Fixes PR23097, patch by Andy Gibbs. llvm-svn: 237630
* [modules] Support for merging a parsed class template specialization ↵Richard Smith2015-05-181-0/+5
| | | | | | definition into an imported but hidden definition. llvm-svn: 237612
* [modules] When a file is listed as a non-textual header in a module map, don'tRichard Smith2015-05-181-3/+3
| | | | | | | | | | enter it more than once, even if it doesn't have #include guards -- we already know that it is intended to have the same effect every time it's included, and it's already had that effect. This particularly helps with local submodule visibility builds, where the include guard macro may not be visible in the includer, but will become visible the moment we enter the included file. llvm-svn: 237609
* Detect uses of mismatching forms of 'new' and 'delete'Ismail Pazarbasi2015-05-186-30/+318
| | | | | | | | | | | | | | | | | Emit warning when operand to `delete` is allocated with `new[]` or operand to `delete[]` is allocated with `new`. rev 2 update: `getNewExprFromInitListOrExpr` should return `dyn_cast_or_null` instead of `dyn_cast`, since `E` might be null. Reviewers: rtrieu, jordan_rose, rsmith Subscribers: majnemer, cfe-commits Differential Revision: http://reviews.llvm.org/D4661 llvm-svn: 237608
* Have -Wredundant-move ignore reference types.Richard Trieu2015-05-181-2/+26
| | | | | | | Don't give a warning when the type being moved is a reference type. Also uncomment two lines in the test case. llvm-svn: 237607
* [OPENMP] Fix for '#pragma omp task' codegen.Alexey Bataev2015-05-182-44/+42
| | | | | | | | | | | | | | | | | | Internal task structure must be generated like typedef struct kmp_task { void * shareds; kmp_routine_entry_t routine; kmp_int32 part_id; kmp_routine_entry_t destructors; } kmp_task_t; struct kmp_task_t_with_privates { kmp_task_t task_data; .kmp_private. privates; }; to avoid possible additional alignment bytes in first fields (shareds, routine, part_id and destructors). Runtime library is not aware of such kind additional alignment bytes. llvm-svn: 237561
* [modules] Move implicit creation of ImportDecls for #includes transformed ↵Richard Smith2015-05-182-4/+4
| | | | | | into module imports from the frontend into Sema where it belongs. llvm-svn: 237555
* [clang-cl] Enable C++14 when targeting 2015 compatibilityDavid Majnemer2015-05-181-0/+6
| | | | llvm-svn: 237553
* [modules] Refactor and simplify #include handling.Richard Smith2015-05-181-4/+0
| | | | | | | Fix a tiny bug where we'd try to load a module file for the module we're in the middle of building. llvm-svn: 237552
* clang/test/CodeGenOpenCL/opencl_types.cl: Tweak expressions according to ↵NAKAMURA Takumi2015-05-181-1/+1
| | | | | | | | | | | r237548. With MS mangler, the signature is: x86: define void @"\01?bad1@@$$J0YAXPAPAUocl_image1d@@PAPAUocl_image2d@@1@Z" (%opencl.image1d_t** %b, %opencl.image2d_t** %c, %opencl.image2d_t** %d) nounwind x64: define void @"\01?bad1@@$$J0YAXPEAPAUocl_image1d@@PEAPAUocl_image2d@@1@Z"(%opencl.image1d_t** %b, %opencl.image2d_t** %c, %opencl.image2d_t** %d) nounwind llvm-svn: 237551
* [modules] If we see a #include that maps to a module, but use of precompiled ↵Richard Smith2015-05-182-1/+2
| | | | | | modules is disabled, track submodule visibility anyway if -fmodules-local-submodule-visibility is enabled. This, in effect, gives modules semantics but without precompilation. llvm-svn: 237550
* [MS ABI] Give __attribute__((overloadable)) functions pretty namesDavid Majnemer2015-05-181-0/+3
| | | | | | | | It turns out that there is a mangling for 'extern "C"', it's only used by MSVC in /clr mode. Co-opt this mangling so that extern "C" functions marked overloadable get demangled nicely. llvm-svn: 237548
* [MS ABI] Function encodings are always encoded in template argumentsDavid Majnemer2015-05-181-0/+6
| | | | llvm-svn: 237547
* Don't leak TemplateIds when a plugin parses late-parsed templates at TU end.Nico Weber2015-05-171-0/+17
| | | | | | | | | | | | | | | | | | | | | | | | | In -fdelayed-template-parsing mode, templates that aren't used are not parsed at all. For some diagnostic plugins, this is a problem since they want to analyse the contents of the template function body. What has been suggested on cfe-dev [1] is to explicitly parse interesting templates in HandleTranslationUnit(); IWYU does this for example [2]. This is workable, but since the delayed parsing doesn't run below a call to ParseTopLevelDecl(), no DestroyTemplateIdAnnotationsRAIIObj object is on the stack to clean up TemplateIds that are created during parsing. To fix this, let ~Parser() clean them up in delayed template parsing mode instead of leaking (or asserting in +Assert builds). (r219810, relanded in r220400, fixed the same problem in incremental processing mode; the review thread of r219810 has a good discussion of the problem.) To test this, give the PrintFunctionNames plugin a flag to force parsing of a template and add a test that uses it in -fdelayed-template-parsing mode. Without the Parser.cpp change, that test asserts. 1: http://lists.cs.uiuc.edu/pipermail/cfe-dev/2014-August/038415.html 2: https://code.google.com/p/include-what-you-use/source/detail?r=566 llvm-svn: 237531
* Fix typo from r237482. "to reference of type" --> "to reference to type"Richard Trieu2015-05-166-13/+13
| | | | llvm-svn: 237507
* When emitting a dropped qualifier error, show which qualifiers are dropped.Richard Trieu2015-05-169-18/+61
| | | | llvm-svn: 237505
* [PPC64] Add vector pack/unpack support from ISA 2.07Bill Schmidt2015-05-162-2/+95
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds support for the following new instructions in the Power ISA 2.07: vpksdss vpksdus vpkudus vpkudum vupkhsw vupklsw These instructions are available through the vec_packs, vec_packsu, vec_unpackh, and vec_unpackl built-in interfaces. These are lane-sensitive instructions, so the built-ins have different implementations for big- and little-endian, and the instructions must be marked as killing the vector swap optimization for now. The first three instructions perform saturating pack operations. The fourth performs a modulo pack operation, which means it can be represented with a vector shuffle, and conversely the appropriate vector shuffles may cause this instruction to be generated. The other instructions are only generated via built-in support for now. I noticed during patch preparation that the macro __VSX__ was not previously predefined when the power8-vector or direct-move features are requested. This is an error, and I've corrected that here as well. Appropriate tests have been added. There is a companion patch to llvm for the rest of this support. llvm-svn: 237500
* clang/test/SemaCXX/attr-no-sanitize.cpp: Don't mix stdout and stderr for ↵NAKAMURA Takumi2015-05-161-2/+2
| | | | | | | | FileCheck. MSVCRT's stdio doesn't do line buffering. llvm-svn: 237492
* Reverse the order of types in the reference dropping qualifiers error.Richard Trieu2015-05-156-13/+13
| | | | | | | | The error has the form ... 'int' ... 'const int' ... dropped qualifiers. At first glance, it appears that the const qualifier is added. Reverse the types so that the second type is less qualified than the first. llvm-svn: 237482
* [modules] Add local submodule visibility support for declarations.Richard Smith2015-05-157-2/+28
| | | | | | | | | | | | With this change, enabling -fmodules-local-submodule-visibility results in name visibility rules being applied to submodules of the current module in addition to imported modules (that is, names no longer "leak" between submodules of the same top-level module). This also makes it much safer to textually include a non-modular library into a module: each submodule that textually includes that library will get its own "copy" of that library, and so the library becomes visible no matter which including submodule you import. llvm-svn: 237473
* Implement no_sanitize attribute.Peter Collingbourne2015-05-155-13/+111
| | | | | | Differential Revision: http://reviews.llvm.org/D9631 llvm-svn: 237463
* Limit set of types instantiated in FindInstantiatedDecl.Serge Pavlov2015-05-151-0/+37
| | | | | | | | Starting from r236426 FindInstantiatedDecl may instantiate types that are referenced before definition. This change limit the set of types that can be instantiated by this function. llvm-svn: 237434
* [OPENMP] Fixed bug in atomic update/capture/write constructs.Alexey Bataev2015-05-156-668/+382
| | | | | | Fixed a bug with codegen for destination atomic l-value with padding and junk in this padding bytes. llvm-svn: 237422
* Revert r237385, "[CodeGen] Reuse stack space from unused function results"NAKAMURA Takumi2015-05-151-125/+0
| | | | | | It broke clang stage2, at least tblgen. llvm-svn: 237418
* Add flag to enable native half typePirama Arumuga Nainar2015-05-141-36/+139
| | | | | | | | | | | | | | | | | | | Summary: r235215 enables support in LLVM for legalizing f16 type in the IR. AArch64 already had support for this. r235215 and some backend patches brought support for ARM, X86, X86-64, Mips and Mips64. This change exposes the LangOption 'NativeHalfType' in the command line, so the backend legalization can be used if desired. NativeHalfType is enabled for OpenCL (current behavior) or if '-fnative-half-type' is set. Reviewers: olista01, steven_wu, ab Subscribers: cfe-commits, srhines, aemerson Differential Revision: http://reviews.llvm.org/D9781 llvm-svn: 237406
* InstrProf: Only disable coverage in built-in macros, not all system macrosJustin Bogner2015-05-141-0/+24
| | | | | | | | | The issue I was trying to solve in r236547 was about built-in macros, but I disabled coverage in all system macros. This is actually a bit of overkill, and makes the display of coverage around system macros degrade unnecessarily. Instead, limit this to builtins specifically. llvm-svn: 237397
* Tweak availability checking to look through typedef declarations.Ted Kremenek2015-05-141-0/+16
| | | | llvm-svn: 237396
* Revert "Detect uses of mismatching forms of 'new' and 'delete'"Diego Novillo2015-05-146-317/+30
| | | | | | | | | This reverts commit 742dc9b6c9686ab52860b7da39c3a126d8a97fbc. This is generating multiple segfaults in our internal builds. Test case coming up shortly. llvm-svn: 237391
* Testing for the fix for bug 23429.Nemanja Ivanovic2015-05-141-0/+13
| | | | | | | | | Follow-up to commit for revision 236848. Just a test case for the macro definition under the right CPU/Arch. One combination was actually missed in the initial fix: - powerpc64-unknown-unknown -mcpu=pwr8 (rather than -mcpu=power8). llvm-svn: 237386
* [CodeGen] Reuse stack space from unused function resultsSergey Dmitrouk2015-05-141-0/+125
| | | | | | | | | | | | | | | | | | | | Summary: Space on stack allocated for unused structures returned by functions was unused even when it's lifetime didn't intersect with lifetime of any other objects that could use the same space. The test added also checks for named and auto objects. It seems to make sense to have this all in one place. Reviewers: aadg, rsmith, rjmccall, rnk Reviewed By: rnk Subscribers: asl, cfe-commits Differential Revision: http://reviews.llvm.org/D9743 llvm-svn: 237385
* DR295: cv-qualifiers on function types are ignored in C++.Richard Smith2015-05-141-5/+10
| | | | llvm-svn: 237383
* Update cxx_dr_status to latest issues list.Richard Smith2015-05-141-1/+1
| | | | llvm-svn: 237382
* Detect uses of mismatching forms of 'new' and 'delete'Ismail Pazarbasi2015-05-146-30/+317
| | | | | | | | | | | | | Emit warning when operand to `delete` is allocated with `new[]` or operand to `delete[]` is allocated with `new`. Reviewers: rtrieu, jordan_rose, rsmith Subscribers: majnemer, cfe-commits Differential Revision: http://reviews.llvm.org/D4661 llvm-svn: 237368
* Factor out SmallDataThresholdIkhlas Ajbar2015-05-142-15/+1
| | | | | | This patch factors out SmallDataThreshold code. llvm-svn: 237364
* [ARM] Add v8.1a architectureVladimir Sukharev2015-05-142-0/+38
| | | | | | | | | | | | | | Add support for ARMv8.1a architecture. Briefly it is described on http://community.arm.com/groups/processors/blog/2014/12/02/the-armv8-a-architecture-and-its-ongoing-development Reviewers: jmolloy, rengolin Subscribers: cfe-commits Differential Revision: http://reviews.llvm.org/D8799 llvm-svn: 237349
* [AArch64 ACLE] Allow to define poly64_t as 'unsigned long long' on LLP64 system.Kevin Qin2015-05-141-0/+2
| | | | | | This fixes PR23414 as well. llvm-svn: 237348
* clang/test/Frontend/dependency-gen-escaping.c: Appease win32 hosts. ↵NAKAMURA Takumi2015-05-141-1/+1
| | | | | | | Investigating. FIXME: Do we really emit single \ or escaped \\ along the context with -fms-compatibility -MG? llvm-svn: 237347
* [MS ABI] Add support for /Zc:sizedDeallocDavid Majnemer2015-05-141-0/+6
| | | | llvm-svn: 237344
* Fix buildbotsDavid Majnemer2015-05-141-1/+1
| | | | llvm-svn: 237338
* [MS ABI] __declspec(thread) behaves like thread_local in MSVC 2015David Majnemer2015-05-141-2/+15
| | | | | | | MSVC 2015 changed __declspec(thread) to make it behave like C++11's thread_local keyword instead of acting similarly to __thread. llvm-svn: 237337
* [clang-cl] Add /Qvec and /Qvec- to control vectorizationDavid Majnemer2015-05-141-0/+6
| | | | llvm-svn: 237335
* clang/test/Frontend/dependency-gen-escaping.c: Tweak r237296, to let '/' and ↵NAKAMURA Takumi2015-05-141-3/+7
| | | | | | '\\' distinguishd, to unbreak "--host=linux --target=msvc". llvm-svn: 237333
OpenPOWER on IntegriCloud