summaryrefslogtreecommitdiffstats
path: root/clang
Commit message (Collapse)AuthorAgeFilesLines
...
* [analyzer] Improved cmake configuration for Z3Enrico Steffinlongo2018-10-133-15/+51
| | | | | | | | | | | | | | | | | | | | | | Summary: Enhanced support for Z3 in the cmake configuration of clang; now it is possible to specify any arbitrary Z3 install prefix (CLANG_ANALYZER_Z3_PREFIX) to cmake with lib (or bin) and include folders. Before the patch only in cmake default locations were searched (https://cmake.org/cmake/help/v3.4/command/find_path.html). Specifying any CLANG_ANALYZER_Z3_PREFIX will force also CLANG_ANALYZER_BUILD_Z3 to ON. Removed also Z3 4.5 version requirement since it was not checked, and now Clang works with Z3 4.7 Reviewers: NoQ, george.karpenkov, mikhail.ramalho Reviewed By: george.karpenkov Subscribers: rnkovacs, NoQ, esteffin, george.karpenkov, delcypher, ddcc, mgorny, xazax.hun, szepet, a.sidorin, Szelethus Tags: #clang Differential Revision: https://reviews.llvm.org/D50818 llvm-svn: 344464
* [analyzer] Small SMT API improvementEnrico Steffinlongo2018-10-132-2/+2
| | | | | | | | | | | | | | Summary: Removed const qualifier from reset method of SMTSolver and Z3Solver objects. Reviewers: mikhail.ramalho, george.karpenkov, NoQ, ddcc Reviewed By: NoQ Subscribers: xazax.hun, szepet, a.sidorin, Szelethus Differential Revision: https://reviews.llvm.org/D52031 llvm-svn: 344463
* Re-commit r344234 "clang-cl: Add /showFilenames option (PR31957)"Hans Wennborg2018-10-135-0/+46
| | | | | | | | The test was failing on e.g. PPC which can't target Windows. Fix by requiring X86 target in the test. Also, make sure the output goes to a temporary directory, since CWD may not be writable. llvm-svn: 344462
* [Analyzer] Iterator Checker - Part 10: Tests for iterators passed as parameterAdam Balogh2018-10-132-0/+35
| | | | | | | | | | In earlier Clang Static Analyzer versions `check::Bind() was not invoked for parameter passing, so we needed a trick which is not needed anymore. However add the tests to ensure its working. Differential Revision: https::/reviews.llvm.org/D32906 llvm-svn: 344443
* [OPENMP][NVPTX]Reduce memory usage in target region.Alexey Bataev2018-10-125-46/+33
| | | | | | | Additional reduction of the global memory usage in the target regions without parallel regions. llvm-svn: 344413
* [MinGW] Allow using LTO when lld is used as linkerMartin Storsjo2018-10-123-0/+17
| | | | | | Differential Revision: https://reviews.llvm.org/D53195 llvm-svn: 344412
* [python] [tests] Re-add once again, this time without WindowsMichal Gorny2018-10-121-1/+6
| | | | llvm-svn: 344411
* Revert rL344365: [tests] Readd Python binding tests to check-allSimon Pilgrim2018-10-121-2/+1
| | | | | | | | | | Windows buildbots are still not happy Now that both issues found out during the last iteration have been fixed, reenable the Python binding tests on buildbots. ........ llvm-svn: 344408
* [clang-format] Fix BraceWrapping AfterFunction for ObjC methodsBen Hamilton2018-10-122-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: > clang-format --version > clang-format version 7.0.0 (tags/RELEASE_700/final) > echo "@implementation Foo\n- (void)foo:(id)bar\n{\n}\n@end\n" |clang-format -style='{BreakBeforeBraces: Custom, BraceWrapping: {AfterFunction: true}}' ``` @implementation Foo - (void)foo:(id)bar { } @end ``` with patch: > bin/clang-format --version > clang-format version 8.0.0 (trunk 344285) > echo "@implementation Foo\n- (void)foo:(id)bar\n{\n}\n@end\n" |bin/clang-format -style='{BreakBeforeBraces: Custom, BraceWrapping: {AfterFunction: true}}' ``` @implementation Foo - (void)foo:(id)bar { } @end ``` Contributed by hultman@. Reviewers: benhamilton, jolesiak, klimek, Wizard Reviewed By: benhamilton Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D53197 llvm-svn: 344406
* Fix a clang::driver::ArgStringList usage I missed in rL344398. NFCI.Simon Pilgrim2018-10-121-1/+1
| | | | llvm-svn: 344400
* Consistently make llvm::opt::ArgStringList usage explicit to try and appease ↵Simon Pilgrim2018-10-123-12/+11
| | | | | | MSVC 2015 buildbots. NFCI. llvm-svn: 344398
* Revert r344375 "[Driver] check for exit code from SIGPIPE"Reid Kleckner2018-10-121-16/+7
| | | | | | This doesn't build on Windows. llvm-svn: 344389
* [Doc] fix second error in UsersManualJonas Toth2018-10-121-1/+1
| | | | llvm-svn: 344388
* [Doc] fix BB, add code-block typeJonas Toth2018-10-121-1/+1
| | | | llvm-svn: 344382
* [Driver] check for exit code from SIGPIPENick Desaulniers2018-10-121-7/+16
| | | | | | | | | | | | | | | | | | | | Summary: D53000 adds a special exit code for SIGPIPE (writing to a closed reader), and rather than print a fatal warning, skips printing the error. This can be seen commonly from piping into head, tee, or split. Fixes PR25349, rdar://problem/14285346, b/77310947. Reviewers: jfb Reviewed By: jfb Subscribers: cfe-commits, thakis, srhines Differential Revision: https://reviews.llvm.org/D53001 llvm-svn: 344375
* [CodeGen] Handle extern references to OBJC_CLASS_$_*Erik Pilkington2018-10-122-6/+26
| | | | | | | | | | | | | | | | | | | | | | Some ObjC users declare a extern variable named OBJC_CLASS_$_Foo, then use it's address as a Class. I.e., one could define isInstanceOfF: BOOL isInstanceOfF(id c) { extern void OBJC_CLASS_$_F; return [c class] == (Class)&OBJC_CLASS_$_F; } This leads to asserts in clang CodeGen if there is an @implementation of F in the same TU as an instance of this pattern, because CodeGen assumes that a variable named OBJC_CLASS_$_* has the right type. This commit fixes the problem by RAUWing the old (incorrectly typed) global with a new global, then removing the old global. rdar://45077269 Differential revision: https://reviews.llvm.org/D53154 llvm-svn: 344373
* [Driver] Add defaults for Android ARM FPUs.Dan Albert2018-10-122-0/+71
| | | | | | | | | | | | | | | | | Summary: Android mandates that devices have at least vfpv3-d16 until Marshmallow and NEON after that. Still honor the user's decision, but raise the defaults for Android targets. Reviewers: srhines, pirama, javed.absar, kristof.beyls, peter.smith Reviewed By: peter.smith Subscribers: peter.smith, rengolin, kristof.beyls, chrib, cfe-commits Differential Revision: https://reviews.llvm.org/D53121 llvm-svn: 344367
* [tests] Readd Python binding tests to check-allMichal Gorny2018-10-121-1/+2
| | | | | | | Now that both issues found out during the last iteration have been fixed, reenable the Python binding tests on buildbots. llvm-svn: 344365
* [python] [tests] Remove cdb lookup failure testMichal Gorny2018-10-121-5/+0
| | | | | | | | | | Remove the test checking for compilation db lookup failure. Since r342228, JSONCompilationDatabasePlugin infers compile commands for missing files, therefore making the lookup always succeed. Differential Revision: https://reviews.llvm.org/D53202 llvm-svn: 344364
* Make YAML quote forward slashes.Zachary Turner2018-10-122-9/+9
| | | | | | | | | | | | | | | | | If you have the string /usr/bin, prior to this patch it would not be quoted by our YAML serializer. But a string like C:\src would be, due to the presence of a backslash. This makes the quoting rules of basically every single file path different depending on the path syntax (posix vs. Windows). While technically not required by the YAML specification to quote forward slashes, when the behavior of paths is inconsistent it makes it difficult to portably write FileCheck lines that will work with either kind of path. Differential Revision: https://reviews.llvm.org/D53169 llvm-svn: 344359
* Revert "Make YAML quote forward slashes."Zachary Turner2018-10-122-9/+9
| | | | | | | | | | This reverts commit b86c16ad8c97dadc1f529da72a5bb74e9eaed344. This is being reverted because I forgot to write a useful commit message, so I'm going to resubmit it with an actual commit message. llvm-svn: 344358
* Make YAML quote forward slashes.Zachary Turner2018-10-122-9/+9
| | | | llvm-svn: 344357
* [OPENMP][NVPTX]Reduce memory usage in orphaned functions.Alexey Bataev2018-10-123-12/+83
| | | | | | | | | | | | if the function has globalized variables and called in context of target/teams/distribute regions, it does not need to globalize 32 copies of the same variables for memory coalescing, it is enough to have just one copy, because there is parallel region. Patch does this by adding call for `__kmpc_parallel_level` function and checking its return value. If the code sees that the parallel level is 0, then only one variable is allocated, not 32. llvm-svn: 344356
* Fix MSVC 2015 ambiguous symbol warning introduced by rL344337. NFCI.Simon Pilgrim2018-10-121-1/+1
| | | | llvm-svn: 344352
* Remove top-level using declaration from header files, as these aliases leak.Sam McCall2018-10-126-69/+59
| | | | | | | | | | Reviewers: ilya-biryukov Subscribers: arphaman, cfe-commits Differential Revision: https://reviews.llvm.org/D53135 llvm-svn: 344337
* [Tooling] Expose ExecutorName option.Eric Liu2018-10-122-1/+3
| | | | llvm-svn: 344335
* Fix Wdocumentation warning. NFCI.Simon Pilgrim2018-10-121-1/+1
| | | | llvm-svn: 344333
* [analyzer] Fix a bug in unexplored_first_location_queue iteration order.George Karpenkov2018-10-121-2/+2
| | | | | | Pointed out by Artem in post-commit review for https://reviews.llvm.org/D53058 llvm-svn: 344322
* Update user's manual documentation of profile remapping file to matchRichard Smith2018-10-111-5/+8
| | | | | | | | llvm-cxxmap documentation. Add a hint as to how to perform off-line profile data remapping. llvm-svn: 344319
* [analyzer] Experiment with an iteration order only based on location, and ↵George Karpenkov2018-10-115-2/+69
| | | | | | | | not using the stack frame Differential Revision: https://reviews.llvm.org/D53058 llvm-svn: 344313
* [analyzer] Avoid unneeded invalidation in RetainCountCheckerGeorge Karpenkov2018-10-111-19/+0
| | | | | | Differential Revision: https://reviews.llvm.org/D53168 llvm-svn: 344312
* [analyzer] Retain count checker for OSObject: recognize OSDynamicCastGeorge Karpenkov2018-10-112-2/+41
| | | | | | | | | | | For now, tresting the cast as a no-op, and disregarding the case where the output becomes null due to the type mismatch. rdar://45174557 Differential Revision: https://reviews.llvm.org/D53156 llvm-svn: 344311
* Revert "[Driver] Default Android toolchains to libc++."Dan Albert2018-10-113-62/+65
| | | | | | | | | Breaks some of the Android bots because they aren't expecting to need to explicitly set -stdlib. This reverts commit 031072f5048654b01a40f639633de1ff4e2f3dc8. llvm-svn: 344297
* [Driver] Default Android toolchains to libc++.Dan Albert2018-10-113-65/+62
| | | | | | | | | | | | Reviewers: srhines, pirama, EricWF Reviewed By: srhines Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D53109 llvm-svn: 344296
* [Driver] Default to `-z now` and `-z relro` on Android.Dan Albert2018-10-112-2/+5
| | | | | | | | | | | | | | | | | | Summary: RTLD_LAZY is not supported on Android (though failing to use `-z now` will work since it is assumed by the loader). RelRO is required. Reviewers: srhines, pirama Reviewed By: srhines Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D53117 llvm-svn: 344295
* [Driver] Fix --hash-style choice for Android.Dan Albert2018-10-112-5/+22
| | | | | | | | | | | | | | | | | Summary: Android supports GNU style hashes as of Marshmallow, so we should be generating both styles for pre-M targets and GNU hashes for newer targets. Reviewers: srhines, pirama Reviewed By: srhines Subscribers: cfe-commits Differential Revision: https://reviews.llvm.org/D53118 llvm-svn: 344293
* [python] [tests] Fix calling tests on WindowsMichal Gorny2018-10-111-1/+3
| | | | | | | | | Fix passing arguments to the Python test command to use 'env' builtin CMake command, in order to fix compatibility with Windows. Differential Revision: https://reviews.llvm.org/D53151 llvm-svn: 344288
* [HIP] Remove unused irif bitcode from testAaron Enye Shi2018-10-111-0/+0
| | | | | | | | | | This is part of previous commit [HIP] Replace irif library with hip.amdgcn.bc Reviewers: yaxunl Differential Revision: https://reviews.llvm.org/D52673 llvm-svn: 344285
* [HIP] Replace irif library with hip.amdgcn.bcAaron Enye Shi2018-10-113-3/+4
| | | | | | No longer use irif amdgcn library, instead we will use the previous fence functions from new hip.amdgcn.bc bitcode library. Update hip-device-libs.hip test as well. llvm-svn: 344281
* Revert "clang-cl: Add /showFilenames option (PR31957)"Sean Fertile2018-10-115-42/+0
| | | | | | | This reverts https://reviews.llvm.org/rL344234 which is causing failures on several bots due to invalid llvm.linker.options. llvm-svn: 344276
* [OPENMP][NVPTX]Reduce memory use for globalized vars inAlexey Bataev2018-10-112-12/+17
| | | | | | | | | | | target/teams/distribute regions. Previously introduced globalization scheme that uses memory coalescing scheme may increase memory usage fr the variables that are devlared in target/teams/distribute contexts. We don't need 32 copies of such variables, just 1. Patch reduces memory use in this case. llvm-svn: 344273
* Revert "[Lex] TokenConcatenation now takes const Preprocessor"Eric Liu2018-10-111-3/+3
| | | | | | This reverts commit r344262. This was an unintentional commit. llvm-svn: 344267
* clang-cl: set output of lit-test to a tmp file after r344234Eric Liu2018-10-111-4/+4
| | | | | | Some test frameworks do not allow output file in CWD. llvm-svn: 344266
* [python] [tests] Retab CMakeLists.txt for consistency (NFC)Michal Gorny2018-10-111-3/+3
| | | | llvm-svn: 344263
* [Lex] TokenConcatenation now takes const PreprocessorEric Liu2018-10-111-3/+3
| | | | | | Differential Revision: https://reviews.llvm.org/D52502 llvm-svn: 344262
* [tests] Remove Python tests from check-all due to breakageMichal Gorny2018-10-111-1/+1
| | | | | | | | | Remove the Python tests from default target in order to fix two kinds of breakage uncovered by enabling them: one failing test on Linux, and problem with the test command on Windows. Both to be addressed in followup revisions. llvm-svn: 344260
* Improve -Wshadow warnings with enumerators.Aaron Ballman2018-10-113-2/+17
| | | | | | | | | | | Addresses PR24718 by checking for enumerators that shadow other enumerators. Catches issues like: enum E1{e1}; void f(void) { enum E2{e1}; } llvm-svn: 344259
* [tests] Include Python binding tests in CMake rulesMichal Gorny2018-10-112-1/+12
| | | | | | | | | Add a new CMake rule check-clang-python to run the Python bindings' test suite, and include it in check-all. Differential Revision: https://reviews.llvm.org/D52840 llvm-svn: 344258
* Some improvements to the OpenBSD driver.Brad Smith2018-10-114-43/+66
| | | | | | | | - OpenBSD has switched to compiler_rt / libcxx - Fix sysroot and lib path handling - Some cleaning up llvm-svn: 344257
* Add support for 'dynamic_allocators' clause on 'requires' directive. ↵Patrick Lyster2018-10-1117-1/+101
| | | | | | Differential Revision: https://reviews.llvm.org/D53079 llvm-svn: 344249
OpenPOWER on IntegriCloud