summaryrefslogtreecommitdiffstats
path: root/clang
Commit message (Collapse)AuthorAgeFilesLines
* [Coverage] Suppress creating a code region if the same area is covered by an ↵Igor Kudrin2016-08-313-12/+33
| | | | | | | | | | | | expansion region. In most cases these code regions are just redundant, but sometimes they could be assigned to the counter of the parent code region instead of the counter of the nested block. Differential Revision: https://reviews.llvm.org/D23987 llvm-svn: 280199
* [AVX-512] Implement masked floating point logical operations with native IR ↵Craig Topper2016-08-315-350/+325
| | | | | | and remove the builtins. llvm-svn: 280197
* [X86] Use v2i64 vectors to implement _mm_and/andn/or/xor_pd.Craig Topper2016-08-312-9/+9
| | | | | | These will be reused when removing some builtins from avx512vldqintrin.h and this will make the tests for that change show a better number of vector elements. llvm-svn: 280196
* PR12298 et al: don't recursively instantiate a template specialization fromRichard Smith2016-08-3111-51/+206
| | | | | | | | | | | | | | | within the instantiation of that same specialization. This could previously happen for eagerly-instantiated function templates, variable templates, exception specifications, default arguments, and a handful of other cases. We still have an issue here for default template arguments that recursively make use of themselves and likewise for substitution into the type of a non-type template parameter, but in those cases we're producing a different entity each time, so they should instead be caught by the instantiation depth limit. However, currently we will typically run out of stack before we reach it. :( llvm-svn: 280190
* Concatenate two FileCheck lines in a test.Richard Trieu2016-08-311-8/+4
| | | | | | | | | 'cc1' is a valid sequence of hexadecimal and sometimes can occur in the path when testing. This can lead to FileCheck matching the incorrect occurance of the 'cc1' string and causing a test failure. Join two adjacent flags together into one check to prevent this. llvm-svn: 280189
* clangTooling: Update libdeps: LLVMOptions, since r280118.NAKAMURA Takumi2016-08-311-1/+4
| | | | llvm-svn: 280187
* clangTooling depends on ClangDriverOptions since r280118.NAKAMURA Takumi2016-08-311-0/+3
| | | | llvm-svn: 280186
* Don't try to run a test that generates code for x86 if it's not a registered ↵Richard Smith2016-08-301-0/+2
| | | | | | target. llvm-svn: 280178
* [analyzer] Use lazily created buffer in EmptyLocalizationContextCheckerDevin Coughlin2016-08-303-2/+20
| | | | | | | | | | | Fix a crash when relexing the underlying memory buffer to find incorrect arguments to NSLocalizedString(). With precompiled headers, the raw buffer may be NULL. Instead, use the source manager to get the buffer, which will lazily create the buffer for precompiled headers. rdar://problem/27429091 llvm-svn: 280174
* Driver: use the canonical static library namingSaleem Abdulrasool2016-08-303-9/+9
| | | | | | | | | | On Windows, static libraries are named lib<name>.lib while import libraries are named <name>.lib. Use the appropriate naming on itanium and msvc environments. This is setup properly so that if a dynamic builtins is used on Windows, it would do the right thing, although this is not currently wired through the driver (i.e. there is no equivalent to -{shared,static}-gcc). llvm-svn: 280169
* clang-format: Correctly calculate affected ranges when sorting #includes.Daniel Jasper2016-08-302-6/+18
| | | | | | affectedRanges takes a start and an end offset, not offset and length. llvm-svn: 280165
* [Modules] Add 'gnuinlineasm' to the 'requires-declaration' feature-list.Bruno Cardoso Lopes2016-08-307-0/+31
| | | | | | | | | | | | | This adds support for modules that require (no-)gnu-inline-asm environment, such as the compiler builtin cpuid submodule. This is the gnu-inline-asm variant of https://reviews.llvm.org/D23871 Differential Revision: https://reviews.llvm.org/D23905 rdar://problem/26931199 llvm-svn: 280159
* Fix memory leak by storing returned pointer in std::unique_ptrRichard Trieu2016-08-301-4/+3
| | | | llvm-svn: 280157
* [test] Pass a fake libLTO.dylib to a driver test which depends on itVedant Kumar2016-08-301-7/+7
| | | | | | | This makes it possible to run 'check-clang' on Darwin without building libLTO.dylib. See r280142 for more context. llvm-svn: 280150
* Revert "[test] Add libLTO as a clang test dependency on Darwin"Vedant Kumar2016-08-301-4/+0
| | | | | | | | This reverts commit r280142. Mehdi suggested a better way to fix up the test: just create a fake libLTO.dylib and tell the driver where to find it. Patch incoming... llvm-svn: 280149
* [test] Add libLTO as a clang test dependency on DarwinVedant Kumar2016-08-301-0/+4
| | | | | | | | | | | | | Running 'check-clang' on a stock checkout of llvm+clang doesn't work on Darwin, because test/Driver/darwin-ld-lto.c can't find libLTO.dylib. Add libLTO as a clang test dependency on Darwin to fix the problem. Note: We don't have this issue with check-all because libLTO is in the test-depends target. Differential Revision: https://reviews.llvm.org/D24042 llvm-svn: 280142
* PR29166: when merging declarations with typedef names for linkage purposes,Richard Smith2016-08-302-1/+2
| | | | | | | don't assume that the anonymous struct will be part of the most recent declaration of the typedef. llvm-svn: 280136
* Unrevert r280035 now that the clang-cl bug it exposed has been fixed byRichard Smith2016-08-3011-22/+108
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | r280133. Original commit message: C++ Modules TS: driver support for building modules. This works as follows: we add --precompile to the existing gamut of options for specifying how far to go when compiling an input (-E, -c, -S, etc.). This flag specifies that an input is taken to the precompilation step and no further, and this can be specified when building a .pcm from a module interface or when building a .pch from a header file. The .cppm extension (and some related extensions) are implicitly recognized as C++ module interface files. If --precompile is /not/ specified, the file is compiled (via a .pcm) to a .o file containing the code for the module (and then potentially also assembled and linked, if -S, -c, etc. are not specified). We do not yet suppress the emission of object code for other users of the module interface, so for now this will only work if everything in the .cppm file has vague linkage. As with the existing support for module-map modules, prebuilt modules can be provided as compiler inputs either via the -fmodule-file= command-line argument or via files named ModuleName.pcm in one of the directories specified via -fprebuilt-module-path=. This also exposes the -fmodules-ts cc1 flag in the driver. This is still experimental, and in particular, the concrete syntax is subject to change as the Modules TS evolves in the C++ committee. Unlike -fmodules, this flag does not enable support for implicitly loading module maps nor building modules via the module cache, but those features can be turned on separately and used in conjunction with the Modules TS support. llvm-svn: 280134
* PR30195: Fix clang-cl attempting to precompile bogus (non-precompilable) ↵Richard Smith2016-08-304-26/+55
| | | | | | input types. llvm-svn: 280133
* typo + indentation [NFC]Etienne Bergeron2016-08-302-2/+2
| | | | llvm-svn: 280127
* Basic/Targets.cpp: Add polaris10 and polaris11 gpusNiels Ole Salscheider2016-08-301-15/+17
| | | | | | Differential Revision: https://reviews.llvm.org/D23746 llvm-svn: 280120
* Fix colored diagnostics from toolsOlivier Goffart2016-08-302-0/+46
| | | | | | | | | | r271042 changed the way the diagnostic arguments are parsed. It assumes that the diagnostics options were already parsed by the "Driver". For tools using clang::Tooling, the diagnostics argument were not parsed. Differential Revision: https://reviews.llvm.org/D23837 llvm-svn: 280118
* Disable clang/test/SemaTemplate/instantiation-depth-default.cpp temporarily ↵NAKAMURA Takumi2016-08-301-0/+3
| | | | | | for targeting mingw32. It crashes. Investigating. llvm-svn: 280104
* [OpenCL] Make is_valid_event, create_user_event overloadable.Alexey Bader2016-08-301-2/+2
| | | | | | | | | | | | | | Summary: Make is_valid_event and create_user_event overloadable like other built-ins. Patch by Evgeniy Tyurin. Reviewers: bader, yaxunl Subscribers: Anastasia, cfe-commits Differential Revision: https://reviews.llvm.org/D23914 llvm-svn: 280097
* Fix typo in commentNico Weber2016-08-301-1/+1
| | | | llvm-svn: 280094
* [Hexagon] Use handleTargetFeaturesGroup to process target-specific featuresKrzysztof Parzyszek2016-08-302-32/+33
| | | | llvm-svn: 280093
* Revert r280035 (and followups r280057, r280085), it caused PR30195Nico Weber2016-08-3011-112/+22
| | | | llvm-svn: 280091
* Handle -mlong-calls on HexagonKrzysztof Parzyszek2016-08-304-6/+32
| | | | | | Differential Revision:://reviews.llvm.org/D22766 llvm-svn: 280089
* clang/test/Driver/modules-ts.cpp: Satisfy quoted filename.NAKAMURA Takumi2016-08-301-1/+1
| | | | | | | | On win32, backslashed filename is emitted like; -o "C:\\bb-win\\ninja-clang-i686-msc19-R\\build\\tools\\clang\\test\\Driver\\Output\\modules-ts.cpp.tmp.o" llvm-svn: 280085
* Fix for commit 280064 that break the build.Sjoerd Meijer2016-08-301-7/+0
| | | | llvm-svn: 280065
* This adds new options -fdenormal-fp-math and passes through option -ffast-mathSjoerd Meijer2016-08-3010-2/+79
| | | | | | | | | | to CC1, which are translated to function attributes and can e.g. be mapped on build attributes FP_exceptions and FP_denormal. Setting these build attributes allows better selection of floating point libraries. Differential Revision: https://reviews.llvm.org/D23840 llvm-svn: 280064
* Combine two FileCheck patterns to prevent overzealous matching of .*Richard Smith2016-08-301-2/+1
| | | | llvm-svn: 280057
* [PowerPC] Update the DWARF register-size tableHal Finkel2016-08-302-3/+138
| | | | | | | | | The PPC64 DWARF register-size table did not match the ABI specification (or GCC, for that matter). Fix that, and add a regression test. Fixes PR27931. llvm-svn: 280053
* [sanitizer-coverage] add two more modes of instrumentation: trace-div and ↵Kostya Serebryany2016-08-307-6/+41
| | | | | | trace-gep, mostly usaful for value-profile-based fuzzing; clang part llvm-svn: 280044
* [PowerPC] Add support for -mlongcallHal Finkel2016-08-302-0/+10
| | | | | | | | | Add support for GCC's PowerPC -mlongcall option; the backend supports the corresponding target feature as of r280040. Fixes PR19098. llvm-svn: 280041
* C++ Modules TS: driver support for building modules.Richard Smith2016-08-3011-22/+113
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This works as follows: we add --precompile to the existing gamut of options for specifying how far to go when compiling an input (-E, -c, -S, etc.). This flag specifies that an input is taken to the precompilation step and no further, and this can be specified when building a .pcm from a module interface or when building a .pch from a header file. The .cppm extension (and some related extensions) are implicitly recognized as C++ module interface files. If --precompile is /not/ specified, the file is compiled (via a .pcm) to a .o file containing the code for the module (and then potentially also assembled and linked, if -S, -c, etc. are not specified). We do not yet suppress the emission of object code for other users of the module interface, so for now this will only work if everything in the .cppm file has vague linkage. As with the existing support for module-map modules, prebuilt modules can be provided as compiler inputs either via the -fmodule-file= command-line argument or via files named ModuleName.pcm in one of the directories specified via -fprebuilt-module-path=. This also exposes the -fmodules-ts cc1 flag in the driver. This is still experimental, and in particular, the concrete syntax is subject to change as the Modules TS evolves in the C++ committee. Unlike -fmodules, this flag does not enable support for implicitly loading module maps nor building modules via the module cache, but those features can be turned on separately and used in conjunction with the Modules TS support. llvm-svn: 280035
* [cfi] Export __cfi_check when linking with -fsanitize-cfi-cross-dso.Evgeniy Stepanov2016-08-293-0/+28
| | | | | | Multi-DSO CFI model requires every DSO to export a __cfi_check function. llvm-svn: 280031
* Fix typo in test.Evgeniy Stepanov2016-08-291-1/+1
| | | | llvm-svn: 280028
* Fix a bug preventing the cause for a module file-not-found from being displayedAdrian Prantl2016-08-292-2/+2
| | | | llvm-svn: 280010
* Fix a bug preventing the cause of a module-out-of-date error from being printedAdrian Prantl2016-08-292-2/+2
| | | | llvm-svn: 280009
* Try to fix clang-offload-bunder.c test once moreReid Kleckner2016-08-291-2/+2
| | | | llvm-svn: 279978
* [Coverage] Prevent creating a redundant counter if a nested body ends with a ↵Igor Kudrin2016-08-292-1/+14
| | | | | | | | | | | | | | | | | macro. If there were several nested statements arranged in a way that all of them end up with the same macro, then the expansion of this macro was assigned with all the corresponding counters of these statements. As a result, the wrong counter value was shown for the macro in llvm-cov. This patch fixes the issue by preventing adding a counter for an expanded source range if it already has an assigned counter, which is expected to come from the most specific statement. Differential Revision: https://reviews.llvm.org/D23160 llvm-svn: 279962
* AST: improve layout of SimpleTypoCorrectorSaleem Abdulrasool2016-08-281-6/+5
| | | | | | | | | Add the "explicit" specifier to the single-argument constructor of SimpleTypoCorrector. Reorder the fields to remove excessive padding (8 bytes). Patch by Alexander Shaposhnikov! llvm-svn: 279946
* Fix a typo in the doc: overriden -> overriddenSylvestre Ledru2016-08-282-2/+2
| | | | llvm-svn: 279942
* clang-cl: Support MSVC2015's /validate-charset flag.Nico Weber2016-08-262-0/+10
| | | | | | | | | | | | | | | | | | | Clang always assumes that files are utf-8. If an invalidly encoded character is used in an identifier, clang always errors. If it's used in a character literal, clang warns Winvalid-source-encoding (on by default). Clang never checks the encoding of things in comments (adding this seems like a nice feature if it doesn't impact performance). For cl.exe /utf-8 (which enables /validate-charset), if a bad character is used in an identifier, it emits both an error and a warning. If it's used in a literal or a comment, it emits a warning. So mapping /validate-charset to -Winvalid-source-encoding seems like a fairly decent fit. https://reviews.llvm.org/D23945 llvm-svn: 279872
* clang-cl: Accept MSVC2015's '/utf-8' flag.Nico Weber2016-08-262-0/+2
| | | | | | Clang always behaves as if that's passed, so just ignore the flag. llvm-svn: 279869
* clang-cl: Accept MSVC 2015's `/execution-charset:utf-8` flag.Nico Weber2016-08-263-3/+10
| | | | | | | | | | Also makes -fexec-charset accept utf-8 case-insensitively. Like https://reviews.llvm.org/D23807, but for execution-charset. Also replace a few .lower() comparisons with equals_lower(). https://reviews.llvm.org/D23938 llvm-svn: 279866
* Don't diagnose non-modular includes when we are not compiling a module.Manman Ren2016-08-267-1/+62
| | | | | | | | | | | | | | This is triggered when we are compiling an implementation of a module, it has relative includes to a VFS-mapped module with umbrella headers. Currently we will find the real path to headers under the umbrella directory, but the umbrella directories are using virtual path. rdar://27951255 Thanks Ben and Richard for reviewing the patch! Differential Revision: http://reviews.llvm.org/D23858 llvm-svn: 279838
* Add support for -fdiagnostics-absolute-paths: printing absolute paths in ↵Hans Wennborg2016-08-2610-4/+50
| | | | | | | | diagnostics Differential Revision: https://reviews.llvm.org/D23816 llvm-svn: 279827
* Sort list of driver-known file extensions. It was previously approximatelyRichard Smith2016-08-261-25/+25
| | | | | | ordered by length then alphabetically; apply that order consistently. llvm-svn: 279799
OpenPOWER on IntegriCloud