summaryrefslogtreecommitdiffstats
path: root/clang
Commit message (Collapse)AuthorAgeFilesLines
...
* [Concepts] Add FoundDecl to ConceptSpecializationExpr serializationSaar Raz2020-03-102-0/+2
| | | | | | FoundDecl was missing from ConceptSpecializationExpr serialization - add it. (cherry picked from commit f9e63891597630405a4655298f06b193e4ceb384)
* [Concepts] Add null check for TemplateTypeParmType::getDecl() in ↵Saar Raz2020-03-062-1/+13
| | | | | | | | | | | GetContainedInventedTypeParmVisitor GetContainedInventedTypeParmVisitor would not account for the case where TemplateTypeParmType::getDecl() is nullptr, causing bug #45102. Add the nullptr check. (cherry picked from commit 865456d589e093582acaafd17d58ad1c0cce66af)
* clang-format release notes: Document the improvement with the ↵Sylvestre Ledru2020-03-051-0/+2
| | | | | | AlwaysBreakAfterReturnType option See https://reviews.llvm.org/D69573
* PR45083: Mark statement expressions as being dependent if they appear inRichard Smith2020-03-048-21/+51
| | | | | | | | | | dependent contexts. We previously assumed they were neither value- nor instantiation-dependent under any circumstances, which would lead to crashes and other misbehavior. (cherry picked from commit bdad0a1b79273733df9acc1be4e992fa5d70ec56)
* ReleaseNotes: Formatting and typo fixes.Peter Wu2020-03-041-31/+31
|
* Revert abb00753 "build: reduce CMake handling for zlib" (PR44780)Hans Wennborg2020-03-032-2/+11
| | | | | | | | | | | | | and follow-ups: a2ca1c2d "build: disable zlib by default on Windows" 2181bf40 "[CMake] Link against ZLIB::ZLIB" 1079c68a "Attempt to fix ZLIB CMake logic on Windows" This changed the output of llvm-config --system-libs, and more importantly it broke stand-alone builds. Instead of piling on more fix attempts, let's revert this to reduce the risk of more breakages. (cherry picked from commit 916be8fd6a0a0feea4cefcbeb0c22c65848d7a2e)
* Add C standard upgrade in clang-11 release noteNick Desaulniers2020-03-021-0/+6
| | | | | | | | | | | | | | Summary: As per rsmith (https://reviews.llvm.org/D75383). Reviewers: hans Reviewed By: hans Subscribers: cfe-commits, rsmith Tags: #clang Differential Revision: https://reviews.llvm.org/D75469
* Minor ReleaseNotes fixesHans Wennborg2020-03-021-33/+33
|
* clang-format: fix spacing in `operator const char*()`Krasimir Georgiev2020-03-022-4/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | Summary: Revision a75f8d98d7ac9e557b238a229a9a2647c71feed1 fixed spacing for operators, but caused the const and non-const versions to diverge: ``` // With Style.PointerAlignment = FormatStyle::PAS_Left: struct A { operator char*() { return ""; } operator const char *() const { return ""; } }; ``` The code was checking if the type specifier was directly preceded by `operator`. However there could be comments and `const/volatile` in between. Reviewers: mprobst Reviewed By: mprobst Subscribers: cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D72911 (cherry picked from commit 33463cfba2be7c8d6c08e666123cc34f114a1f3e)
* ReleaseNotes: remove in-progress warnings, tidy up a bitHans Wennborg2020-02-281-68/+16
|
* Re-generate docsHans Wennborg2020-02-281-55/+101
| | | | | | | | | | | | | | bin/clang-tblgen -gen-diag-docs -I../clang/include \ -I../clang/include/clang/Basic/ \ ../clang/include/clang/Basic/Diagnostic.td -o \ ../clang/docs/DiagnosticsReference.rst && \ bin/clang-tblgen -gen-attr-docs -I../clang/include \ ../clang/include/clang/Basic/Attr.td -o \ ../clang/docs/AttributeReference.rst && \ bin/clang-tblgen -gen-opt-docs -I../clang/include \ -I../clang/include/clang/Driver -I../llvm/include \ ../clang/include/clang/Driver/ClangOptionDocs.td -o \ ../clang/docs/ClangCommandLineReference.rst
* update clang-cl flag section in UsersManual.rstHans Wennborg2020-02-281-52/+101
|
* [ReleaseNotes] Add some items for clangFangrui Song2020-02-271-0/+8
|
* [ReleaseNotes] Add OpenCL release notesSven van Haastregt2020-02-271-3/+26
| | | | Differential Revision: https://reviews.llvm.org/D75125
* [ReleaseNotes] Fix typosSven van Haastregt2020-02-271-2/+2
|
* [ReleaseNotes] Mention -fmacro-prefix-map and -ffile-prefix-map.Peter Wu2020-02-271-0/+6
| | | | Differential revision: https://reviews.llvm.org/D75012
* Revert "make -fmodules-codegen and -fmodules-debuginfo work also with PCHs"Hans Wennborg2020-02-276-60/+11
| | | | | | | | This caused PR44953. See also the discussion on D74846. This reverts commit cbc9d22e49b434b6ceb2eb94b67079d02e0a7b74. (cherry picked from commit 7ea9a6e0220da36ff2fd1fbc29c2755be23e5166)
* [driver][darwin] Don't use -platform_version flag by default (PR44813)Hans Wennborg2020-02-275-10/+28
| | | | | | | | | | | | | | | | | The code in llvmorg-10-init-12188-g25ce33a6e4f is a breaking change for users of older linkers who don't pass a version parameter, which prevents a drop-in clang upgrade. Old tools can't know about what future tools will do, so as a general principle the burden should be new tools to be compatible by default. Also, for comparison, none of the other tests of Version within AddLinkArgs add any new behaviors unless the version is explicitly specified. Therefore, this patch changes the -platform_version behavior from opt-out to opt-in. Patch by David Major! Differential revision: https://reviews.llvm.org/D74784 (cherry picked from commit 5122e828701c88f8d53ee881bc68f3904454d154)
* [ASTMatchers] HasNameMatcher handles `extern "C"`Nathan James2020-02-272-1/+22
| | | | | | | | | | | | | | | | Summary: Fixes [[ https://bugs.llvm.org/show_bug.cgi?id=42193 | hasName AST matcher is confused by extern "C" in namespace. ]] Reviewers: klimek, aaron.ballman, gribozavr2 Reviewed By: aaron.ballman Subscribers: cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D75202 (cherry picked from commit 16cabf278fc8c14d415e677ce0bc40d46a6de30d)
* [RISCV] Add Clang and LLVM Release NotesSam Elliott2020-02-261-0/+21
|
* Put microsoft template parameter shadow warning behind separate flag (PR44794)Hans Wennborg2020-02-263-2/+14
| | | | | | Differential revision: https://reviews.llvm.org/D75121 (cherry picked from commit 41a6612ea8afc5254e4de3aca55628d37f0be433)
* [remark][diagnostics] [codegen] Fix PR44896Rong Xu2020-02-264-1/+30
| | | | | | | | | | | | | | | | | This patch fixes PR44896. For IR input files, option fdiscard-value-names should be ignored as we need named values in loadModule(). Commit 60d3947922 sets this option after loadModule() where valued names already created. This creates an inconsistent state in setNameImpl() that leads to a seg fault. This patch forces fdiscard-value-names to be false for IR input files. This patch also emits a warning of "ignoring -fdiscard-value-names" if option fdiscard-value-names is explictly enabled in the commandline for IR input files. Differential Revision: https://reviews.llvm.org/D74878 (cherry picked from commit 11857d49948b845dcfd7c7f78595095e3add012d)
* Strip preceeding -Xclang when stripping -fcolor-diagnostics or ↵Kadir Cetinkaya2020-02-261-0/+6
| | | | | | | | | | | | | | | | | | -fdiagnostics-color Summary: Fixes https://github.com/clangd/clangd/issues/279. We were removing the color options but not the preceeding -Xclang which causes errors since the -Xclang would now apply to the next option in the list of options. Now, when removing a color option, we check if there was a preceeding -Xclang and remove it as well. Patch By @DaanDeMeyer ! Reviewers: sammccall, kadircet Reviewed By: sammccall Subscribers: ilya-biryukov, usaxena95 Differential Revision: https://reviews.llvm.org/D75019 (cherry picked from commit da236f235028c82c2f0e00eea1f6f9c689bcae4a)
* [docs][WebAssembly] WebAssembly-specific release notes for 10.0.Dan Gohman2020-02-251-0/+3
|
* Add Control Flow Guard in Clang release notes.Hans Wennborg2020-02-251-0/+6
| | | | | | By Andrew Paverd! Differential revision: https://reviews.llvm.org/D75047
* Add -debug-info-kind=constructor to clang release notesAmy Huang2020-02-241-0/+4
|
* ReleaseNotes: ARM and AArch64Hans Wennborg2020-02-241-1/+1
| | | | By Kristof Beyls!
* ReleaseNotes: OpenMPHans Wennborg2020-02-241-1/+19
| | | | By Alexey Bataev!
* [docs] Add -Wmisleading-indentation to clang's release notes.Tyker2020-02-221-0/+4
|
* Add -std=c++20 flag, replace C++2a with C++20 throughout the ClangRichard Smith2020-02-1934-292/+312
| | | | | | | | | | | | | user interface and documentation, and update __cplusplus for C++20. WG21 considers the C++20 standard to be finished (even though it still has some more steps to pass through in the ISO process). The old flag names are accepted for compatibility, as usual, and we still have lots of references to C++2a in comments and identifiers; those can be cleaned up separately. (cherry picked from commit 24ad121582454e625bdad125c90d9ac0dae948c8)
* Restore functionality of --sysroot on FreeBSD after b18cb9c47Dimitry Andric2020-02-192-6/+15
| | | | | | | | | | | | | | | | | After b18cb9c47, clang would sometimes prefer the host C++ includes (e.g. in /usr/include/c++/v1) before those specified via --sysroot. While this behavior may be desirable on Linux, it is not so on FreeBSD, where we make extensive use of --sysroot during the build of the base system. In that case, clang must *not* search outside the sysroot, except for its own internal headers. Add an override addLibCxxIncludePaths() to restore the old behavior, which is to simply append /usr/include/c++/v1 to the specified sysroot. While here, apply clang-format to the FreeBSD specific toolchain files. Fixes PR44923. (cherry picked from commit 62654cab7e654384ba503d6b62b1054cde19a553)
* PR44890: Inherit explicitly-specified template arguments into base classRichard Smith2020-02-193-1/+25
| | | | | | deduction. (cherry picked from commit 34bd51f4b1d9f489e61becb662bdc72bb56dd277)
* [Clang] Limit -fintegrated-cc1 to only one TUAlexandre Ganea2020-02-135-18/+55
| | | | | | | | | | As discussed in https://reviews.llvm.org/D74447, this patch disables integrated-cc1 behavior if there's more than one job to be executed. This is meant to limit memory bloating, given that currently jobs don't clean up after execution (-disable-free is always active in cc1 mode). I see this behavior as temporary until release 10.0 ships (to ease merging of this patch), then we'll reevaluate the situation, see if D74447 makes more sense on the long term. Differential Revision: https://reviews.llvm.org/D74490 (cherry picked from commit 20f1abe306d030e99f56185a3aa077ffadf59b8a)
* Fix a reentrance bug with deserializing ObjC type parameters.John McCall2020-02-134-1/+26
| | | | | | | | | | | | | This is a longstanding bug that seems to have been hidden by a combination of (1) the normal flow being to deserialize the interface before deserializing its parameter and (2) a precise ordering of work that was apparently recently disturbed, perhaps by my abstract-serialization work or Bruno's ObjC module merging work. Fixes rdar://59153545. (cherry picked from commit 77b2ffc498e92cce7546d191f6712a3046300501)
* Fix type-dependency of bitfields in templatesElizabeth Andrews2020-02-133-1/+20
| | | | | | | | | | | | | This patch is a follow up to 878a24ee244a24. Name of bitfields with value-dependent width should be set as type-dependent. This patch adds the required value-dependency check and sets the type-dependency accordingly. Patch fixes PR44886 Differential revision: https://reviews.llvm.org/D72242 (cherry picked from commit a58017e5cae5be948fd1913b68d46553e87aa622)
* [Concepts] Add missing TPA commit to requires expression parsingSaar Raz2020-02-121-0/+1
| | | | | | | | | | If an error had occurred when annotating a scope spec during the tentative parse for a type-requirement, we would not revert nor commit the tentative parse, triggerring an assertion failure. Commit the TPA in this case and then do error recovery. (cherry picked from commit 271e495399170d69627c1acd591c9298cb0b5b4b)
* [Concepts] Do not check constraints if not all template arguments have been ↵Saar Raz2020-02-122-6/+15
| | | | | | | | | | | | | deduced We previously checked the constraints of instantiated function templates even in cases where PartialOverloading was true and not all template arguments have been deduced, which caused crashes in clangd (bug 44714). We now check if all arguments have been deduced before checking constraints in partial overloading scenarios. (cherry picked from commit 5fef14d932fe602bf998b8fb8a809ff85ca1e245)
* [X86] Cast to __v4hi instead of __m64 in the implementation of ↵Craig Topper2020-02-121-2/+2
| | | | | | | | | | | _mm_extract_pi16 and _mm_insert_pi16. __m64 is a vector of 1 long long. But the builtins these intrinsics are calling expect a vector of 4 shorts. Fixes PR44589 (cherry picked from commit 16b9410caa35da976fa5f3cf6dd3d6f3776d51ca)
* [OpenCL] Restrict addr space conversions in nested pointersAnastasia Stulova2020-02-128-17/+86
| | | | | | | | | | | | | | | | | | | | | | Address space conversion changes pointer representation. This commit disallows such conversions when they are not legal i.e. for the nested pointers even with compatible address spaces. Because the address space conversion in the nested levels can't be generated to modify the pointers correctly. The behavior implemented is as follows: - Any implicit conversions of nested pointers with different address spaces is rejected. - Any conversion of address spaces in nested pointers in safe casts (e.g. const_cast or static_cast) is rejected. - Conversion in low level C-style or reinterpret_cast is accepted but with a warning (this aligns with OpenCL C behavior). Fixes PR39674 Differential Revision: https://reviews.llvm.org/D73360 (cherry picked from commit 6064f426a18304e16b51cc79e74c9c2d55ef5a9c)
* [Clang][Driver] After default -fintegrated-cc1, make ↵Alexandre Ganea2020-02-123-2/+12
| | | | | | | | | | | | | llvm::report_fatal_error() generate preprocessed source + reproducer.sh again. Added a test for #pragma clang __debug llvm_fatal_error to test for the original issue. Added llvm::sys::Process::Exit() and replaced ::exit() in places where it was appropriate. This new function would call the current CrashRecoveryContext if one is running on the same thread; or call ::exit() otherwise. Fixes PR44705. Differential Revision: https://reviews.llvm.org/D73742 (cherry picked from commit faace365088a2a3a4cb1050a9facfc34a7a56577)
* Prefer __vector over vector keyword for altivecserge-sans-paille2020-02-111-2/+2
| | | | | | | | | | | `vector' uses the keyword-and-predefine mode from gcc, while __vector is reliably supported. As a side effect, it also makes the code consistent in its usage of __vector. Differential Revision: https://reviews.llvm.org/D74129 (cherry picked from commit 3185c30c54d0af5bffbff3bcfd721668d086ff10)
* Re-land "[Clang][Driver] Remove -M group options ..." and "[Clang] Avoid ↵Alexandre Ganea2020-02-108-17/+118
| | | | | | | | | | | crashing when generating crash diagnostics when '#pragma clang __debug ..." This re-lands commits f41ec709d9d388dc43469e6ac7f51b6313f7e4af (https://reviews.llvm.org/D74076) and commit 5fedc2b410853a6aef05e8edf19ebfc4e071e28f (https://reviews.llvm.org/D74070) The previous build break was caused by '#pragma clang __debug llvm_unreachable' used in a non-assert build. Move it to a separate test in crash-report-with-asserts.c. (cherry picked from commit 75f09b54429bee17a96e2ba7a2ac0f0a8a7f7e74)
* [analyzer] Add 10.0.0 release notes.Hans Wennborg2020-02-101-4/+18
| | | | | | Differential revision: https://reviews.llvm.org/D73966 By Kristóf Umann!
* [Clang] Remove unused #pragma clang __debug handle_crashAlexandre Ganea2020-02-101-5/+0
| | | | | | | | | As discussed in D70568, remove this because it isn't used anywhere, and I think it's better to go through real crashes for testing (#pragma clang __debug crash). Also remove the support function llvm::CrashRecoveryContext::HandleCrash() which was added at the same time by @ddunbar. Differential Revision: https://reviews.llvm.org/D74063 (cherry picked from commit 8ecde3ac34bbb5a8d53d8ec5cd32867658646df1)
* [analyzer] Fix a couple of bugs in HTML report generation.Artem Dergachev2020-02-105-1/+121
| | | | | | | | It should now produce valid HTML again. Differential Revision: https://reviews.llvm.org/D73993 (cherry picked from commit 482e236e569e8324f70778af1eb756923cd490dc)
* [cmake] Fix clang builds with BUILD_SHARED=ON and CLANG_LINK_CLANG_DYLIB=ONTom Stellard2020-02-101-1/+16
| | | | | | | | | | | | | | | | | | | Summary: We were linking all the clang objects and shared libraries into libclang-cpp.so, which was causing the command line options to be registered twice. Reviewers: beanz, mgorny Reviewed By: beanz, mgorny Subscribers: merge_guards_bot, mgorny, cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D68520 (cherry picked from commit ebcf25ea8100fc9987fd1edd1975194addc2fc05)
* [Concepts] Fix incorrect check when instantiating abbreviated template ↵Saar Raz2020-02-063-9/+47
| | | | | | | | | | | | | type-constraints We would incorrectly check whether the type-constraint had already been initialized, causing us to ignore the invented template type constraints entirely. Also, TemplateParameterList would store incorrect information about invented type parameters when it observed them before their type-constraint was initialized, so we recreate it after initializing the function type of an abbreviated template. (cherry picked from commit 38fd69995fc5a6f16e0aa132a46e5ccdbc2eebb3)
* [clang] Add release notes for the 10.x branch for things I've doneMartin Storsjö2020-02-051-0/+6
| | | | Differential Revision: https://reviews.llvm.org/D74028
* Don't warn about missing declarations for partial template specializationsAaron Puchert2020-02-052-0/+3
| | | | | | | | | | Summary: Just like templates, they are excepted from the ODR rule. Reviewed By: aaron.ballman, rsmith Differential Revision: https://reviews.llvm.org/D68923 (cherry picked from commit 27684ae66d5545f211c0ac4393d0ba2bf3b5b47c)
* Update for Clang 10 release notes in order to have reference to D66404.Andi-Bogdan Postelnicu2020-02-051-1/+18
| | | | | | | | | | | | Summary: Since `D66404` adds some significat modifications to the `CFG` we should include it in the release notes. Reviewers: hans Subscribers: cfe-commits Tags: #clang Differential Revision: https://reviews.llvm.org/D74031
OpenPOWER on IntegriCloud