[PATCH] D58164: Block+lambda: allow reference capture

2019-06-27 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. I'm not sure we've ever written down what the semantics of the block capture are actually supposed to be in this situation. I guess capturing a reference is the right thing to do? Is that what we generally do if this is a POD type? Repository: rC Clang CHANGES

[PATCH] D61809: [BPF] Preserve debuginfo array/union/struct type/access index

2019-06-27 Thread Yonghong Song via Phabricator via cfe-commits
yonghong-song marked 2 inline comments as done. yonghong-song added a comment. @rsmith I have proposed one clang intrinsic and three IR intrinsics for CO-RE. Could you take a look and share your opinions as well? Thanks! Comment at: docs/LanguageExtensions.rst:1958 +array

[PATCH] D63789: [ODRHash] Fix null pointer dereference for ObjC selectors with empty slots.

2019-06-27 Thread Richard Trieu via Phabricator via cfe-commits
rtrieu accepted this revision. rtrieu added a comment. This revision is now accepted and ready to land. LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63789/new/ https://reviews.llvm.org/D63789

[PATCH] D63789: [ODRHash] Fix null pointer dereference for ObjC selectors with empty slots.

2019-06-27 Thread Volodymyr Sapsai via Phabricator via cfe-commits
vsapsai updated this revision to Diff 206992. vsapsai added a comment. Herald added a project: clang. - Address review comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63789/new/ https://reviews.llvm.org/D63789 Files:

[PATCH] D63822: [Driver] Fix style issues of --print-supported-cpus

2019-06-27 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay updated this revision to Diff 206993. MaskRay added a comment. Restore a comment Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63822/new/ https://reviews.llvm.org/D63822 Files: include/clang/Driver/Options.td lib/Driver/Driver.cpp

[PATCH] D49754: Add -m(no-)spe, and e500 CPU definitions and support to clang

2019-06-27 Thread Justin Hibbits via Phabricator via cfe-commits
jhibbits marked an inline comment as done. jhibbits added inline comments. Comment at: lib/Basic/Targets/PPC.cpp:318 + Features["spe"] = llvm::StringSwitch(CPU) +.Case("e500", true) +.Case("8548", true) vit9696

[PATCH] D63822: [Driver] Fix style issues of --print-supported-cpus

2019-06-27 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay updated this revision to Diff 206989. MaskRay retitled this revision from "[Driver] Delete --print-supported-cpus in favor of -mcpu=? or -mtune=?" to "[Driver] Fix style issues of --print-supported-cpus". MaskRay added a comment. Repurpose Repository: rC Clang CHANGES SINCE LAST

[PATCH] D61809: [BPF] Preserve debuginfo array/union/struct type/access index

2019-06-27 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. The new approach to tracking expressions inside of __builtin_preserve_access_index seems okay. Please let @rsmith comment since he looked at this before. Comment at: docs/LanguageExtensions.rst:1958 +array subscript access and structure/union member

[PATCH] D63915: [analyzer][WIP] ReturnValueChecker: Model the guaranteed boolean return value of function calls

2019-06-27 Thread Csaba Dabis via Phabricator via cfe-commits
Charusso planned changes to this revision. Charusso marked 2 inline comments as done. Charusso added a comment. Heavily WIP, see inline. Comment at: clang/test/Analysis/return-value-guaranteed.cpp:37 +bool parseFile() { + clang_analyzer_eval(error() == true); // FIXME:

[PATCH] D63915: [analyzer][WIP] ReturnValueChecker: Model the guaranteed boolean return value of function calls

2019-06-27 Thread Csaba Dabis via Phabricator via cfe-commits
Charusso created this revision. Charusso added reviewers: NoQ, xazax.hun, ravikandhadai, baloghadamsoftware, Szelethus. Charusso added a project: clang. Herald added subscribers: cfe-commits, dkrupp, donat.nagy, mikhail.ramalho, a.sidorin, rnkovacs, szepet, mgorny. Options: -

[PATCH] D63718: [ADT] Implement llvm::bsearch() with std::partition_point()

2019-06-27 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. Ping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63718/new/ https://reviews.llvm.org/D63718 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D63845: [WIP] Create a clang attribute that lets users specify LLVM attributes

2019-06-27 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert added a comment. In D63845#1560605 , @aaron.ballman wrote: > In D63845#1559995 , @lebedev.ri > wrote: > > > What's the target use-case here? What can't be solved with normal > > attributes? > With

[PATCH] D52847: [clang-doc] Handle anonymous namespaces

2019-06-27 Thread Julie Hockett via Phabricator via cfe-commits
juliehockett updated this revision to Diff 206979. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D52847/new/ https://reviews.llvm.org/D52847 Files: clang-tools-extra/clang-doc/Representation.cpp clang-tools-extra/clang-doc/Representation.h clang-tools-extra/clang-doc/Serialize.cpp

[PATCH] D63911: [clang-doc] Serialize child namespaces and records

2019-06-27 Thread Julie Hockett via Phabricator via cfe-commits
juliehockett added inline comments. Comment at: clang-tools-extra/clang-doc/Serialize.cpp:341 + Parent->USR = ParentUSR; + Parent->ChildNamespaces.emplace_back(I->USR, I->Name, InfoType::IT_namespace); + return {std::unique_ptr{std::move(I)}, You're probably

[PATCH] D62556: [analyzer] NFC: CallDescription: Implement describing C library functions.

2019-06-27 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ updated this revision to Diff 206978. NoQ marked 4 inline comments as done. NoQ added a comment. Fxd. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D62556/new/ https://reviews.llvm.org/D62556 Files: clang/include/clang/StaticAnalyzer/Core/PathSensitive/CallEvent.h

[PATCH] D62556: [analyzer] NFC: CallDescription: Implement describing C library functions.

2019-06-27 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ added inline comments. Comment at: clang/include/clang/StaticAnalyzer/Core/PathSensitive/CallEvent.h:1064 // e.g. "{a, b}" represent the qualified names, like "a::b". std::vector QualifiedName; unsigned RequiredArgs; a_sidorin wrote: > Not for this

[PATCH] D63912: [ObjC] Add a warning for implicit conversions of a constant non-boolean value to BOOL

2019-06-27 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington created this revision. erik.pilkington added reviewers: rjmccall, steven_wu. Herald added subscribers: dexonsmith, jkorous. Herald added a project: clang. erik.pilkington added a reviewer: arphaman. On macOS, BOOL is a typedef for signed char, but it should never hold a value

[PATCH] D63911: [clang-doc] Serialize child namespaces and records

2019-06-27 Thread Diego Astiazarán via Phabricator via cfe-commits
DiegoAstiazaran created this revision. DiegoAstiazaran added reviewers: juliehockett, jakehehrlich, lebedev.ri. DiegoAstiazaran added a project: clang-tools-extra. Serialization of child namespaces and records is now handled. Namespaces can have child records and child namespaces. Records can

[PATCH] D63908: hwasan: Improve precision of checks using short granule tags.

2019-06-27 Thread Peter Collingbourne via Phabricator via cfe-commits
pcc created this revision. pcc added a reviewer: eugenis. Herald added subscribers: Sanitizers, cfe-commits, jfb, hiraditya, javed.absar, kubamracek. Herald added projects: clang, Sanitizers, LLVM. A short granule is a granule of size between 1 and `TG-1` bytes. The size of a short granule is

[PATCH] D63907: [clang-scan-deps] Implementation of dependency scanner over minimized sources

2019-06-27 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman created this revision. arphaman added reviewers: Bigcheese, aganea. Herald added subscribers: tschuett, dexonsmith, jkorous, mgorny. Herald added a project: clang. This patch implements the fast dependency scanning mode in `clang-scan-deps`: the preprocessing is done on files that are

[PATCH] D63048: Update __VERSION__ to remove the hardcoded 4.2.1 version

2019-06-27 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added a comment. I'd be in favor of removing them. Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63048/new/ https://reviews.llvm.org/D63048 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D63533: [analyzer] Fix clang-tidy crash on GCCAsmStmt

2019-06-27 Thread Nathan Huckleberry via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL364605: [analyzer] Fix clang-tidy crash on GCCAsmStmt (authored by Nathan-Huckleberry, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit:

r364605 - [analyzer] Fix clang-tidy crash on GCCAsmStmt

2019-06-27 Thread Nathan Huckleberry via cfe-commits
Author: nathan-huckleberry Date: Thu Jun 27 15:46:40 2019 New Revision: 364605 URL: http://llvm.org/viewvc/llvm-project?rev=364605=rev Log: [analyzer] Fix clang-tidy crash on GCCAsmStmt Summary: Added entry in switch statement to recognize GCCAsmStmt as a possible block terminator. Handling to

[PATCH] D63533: [analyzer] Fix clang-tidy crash on GCCAsmStmt

2019-06-27 Thread Nathan Huckleberry via Phabricator via cfe-commits
Nathan-Huckleberry updated this revision to Diff 206954. Nathan-Huckleberry added a comment. - Minor style change on assert Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63533/new/ https://reviews.llvm.org/D63533 Files:

[libclc] r364604 - Creating release candidate rc3 from release_801 branch

2019-06-27 Thread Tom Stellard via cfe-commits
Author: tstellar Date: Thu Jun 27 15:33:04 2019 New Revision: 364604 URL: http://llvm.org/viewvc/llvm-project?rev=364604=rev Log: Creating release candidate rc3 from release_801 branch Added: libclc/tags/RELEASE_801/rc3/ - copied from r364603, libclc/branches/release_80/

[libunwind] r364604 - Creating release candidate rc3 from release_801 branch

2019-06-27 Thread Tom Stellard via cfe-commits
Author: tstellar Date: Thu Jun 27 15:33:04 2019 New Revision: 364604 URL: http://llvm.org/viewvc/llvm-project?rev=364604=rev Log: Creating release candidate rc3 from release_801 branch Added: libunwind/tags/RELEASE_801/rc3/ - copied from r364603, libunwind/branches/release_80/

[PATCH] D62648: [Sema][Typo] Fix assertion failure for expressions with multiple typos

2019-06-27 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith accepted this revision. rsmith added inline comments. This revision is now accepted and ready to land. Comment at: lib/Sema/SemaExprCXX.cpp:7762-7764 + llvm::SmallDenseMap NewTransformCache; + auto SavedTransformCache = TransformCache; + TransformCache =

[PATCH] D62441: [analyzer] NFC: Introduce a convenient CallDescriptionMap class.

2019-06-27 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ updated this revision to Diff 206951. NoQ added a comment. Indeed. Subtle! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D62441/new/ https://reviews.llvm.org/D62441 Files: clang/include/clang/StaticAnalyzer/Core/PathSensitive/CallEvent.h

[PATCH] D63623: [clang-tidy] new check: bugprone-posix-return

2019-06-27 Thread Jian Cai via Phabricator via cfe-commits
jcai19 updated this revision to Diff 206947. jcai19 added a comment. Update test names. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63623/new/ https://reviews.llvm.org/D63623 Files: clang-tools-extra/clang-tidy/bugprone/BugproneTidyModule.cpp

[PATCH] D63623: [clang-tidy] new check: bugprone-posix-return

2019-06-27 Thread Jian Cai via Phabricator via cfe-commits
jcai19 marked 2 inline comments as done. jcai19 added inline comments. Comment at: clang-tools-extra/test/clang-tidy/bugprone-posix-return.cpp:96 + if (posix_fadvise(0, 0, 0, 0) < 0) {} + if (posix_fadvise(0, 0, 0, 0) >= 0) {} else {} + if (posix_fadvise(0, 0, 0, 0) == -1) {}

[PATCH] D63623: [clang-tidy] new check: bugprone-posix-return

2019-06-27 Thread Jian Cai via Phabricator via cfe-commits
jcai19 updated this revision to Diff 206946. jcai19 added a comment. Update the check to catch redundant code and update the warning message to be more speicific. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63623/new/

[PATCH] D63857: [clang-doc] Structured HTML generator

2019-06-27 Thread Jake Ehrlich via Phabricator via cfe-commits
jakehehrlich added a comment. Overall looks better. One of my comments causes a sweeping change to occur so I'll respond back after thats done. Comment at: clang-tools-extra/clang-doc/HTMLGenerator.cpp:91 +struct HTMLFile { + llvm::SmallString<16> DoctypeDecl{""}; +

[PATCH] D63533: [analyzer] Fix clang-tidy crash on GCCAsmStmt

2019-06-27 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers added inline comments. Comment at: clang/lib/StaticAnalyzer/Core/CoreEngine.cpp:401 + case Stmt::GCCAsmStmtClass: +assert(cast(Term)->isAsmGoto() == true && "Encountered GCCAsmStmt without labels"); +// TODO: Handle jumping to labels

r364595 - Pattern match struct types in test case.

2019-06-27 Thread Akira Hatanaka via cfe-commits
Author: ahatanak Date: Thu Jun 27 14:16:19 2019 New Revision: 364595 URL: http://llvm.org/viewvc/llvm-project?rev=364595=rev Log: Pattern match struct types in test case. This simplifies the test cases in a patch I'm planning to send later. Modified:

[PATCH] D63533: [analyzer] Fix clang-tidy crash on GCCAsmStmt

2019-06-27 Thread Artem Dergachev via Phabricator via cfe-commits
NoQ accepted this revision. NoQ added a comment. This revision is now accepted and ready to land. Looks great now, thanks! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63533/new/ https://reviews.llvm.org/D63533

[PATCH] D63894: [CXX] Exercise all paths through these tests

2019-06-27 Thread Paul Robinson via Phabricator via cfe-commits
probinson created this revision. probinson added a reviewer: rsmith. Herald added a project: clang. Herald added a subscriber: cfe-commits. These 3 tests have dialect-based conditionals, but weren't running Clang with enough different dialects to actually enable those conditional sections.

[PATCH] D63857: [clang-doc] Structured HTML generator

2019-06-27 Thread Diego Astiazarán via Phabricator via cfe-commits
DiegoAstiazaran updated this revision to Diff 206920. DiegoAstiazaran marked 7 inline comments as done. DiegoAstiazaran added a comment. Fix TagType enum name and members. Add anonymous namespace. Separate the implementation from the definition for some functions. Use emplace_back instead of

[PATCH] D63533: [analyzer] Fix clang-tidy crash on GCCAsmStmt

2019-06-27 Thread Nathan Huckleberry via Phabricator via cfe-commits
Nathan-Huckleberry updated this revision to Diff 206919. Nathan-Huckleberry added a comment. - Add assertion message and simplify test case Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63533/new/ https://reviews.llvm.org/D63533 Files:

[PATCH] D63893: [clang-tidy] Extend TransformerClangTidyCheck to support adding includes.

2019-06-27 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel created this revision. ymandel added reviewers: ilya-biryukov, gribozavr. Herald added a subscriber: xazax.hun. Herald added a project: clang. ymandel added a parent revision: D63892: [LibTooling] Extend `RewriteRule` with support for adding includes.. This revision implements support

[PATCH] D63892: [LibTooling] Extend `RewriteRule` with support for adding includes.

2019-06-27 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel created this revision. ymandel added reviewers: ilya-biryukov, gribozavr. Herald added a project: clang. This revision allows users to specify the insertion of an included directive (at the top of the file being rewritten) as part of a rewrite rule. These directives are bundled with

[PATCH] D62293: [modules] Add PP callbacks for entering and leaving a submodule.

2019-06-27 Thread Vassil Vassilev via Phabricator via cfe-commits
v.g.vassilev updated this revision to Diff 206887. v.g.vassilev marked an inline comment as done. v.g.vassilev added a comment. Add comments, add missing callbacks. Thanks Richard! Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D62293/new/

[PATCH] D63889: Check possible warnings on global initializers for reachability

2019-06-27 Thread Nathan Huckleberry via Phabricator via cfe-commits
Nathan-Huckleberry created this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Create CFG for initializers and perform analysis based warnings on global variables Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D63889 Files:

[PATCH] D63538: [analyzer][CFG] Return the correct terminator condition

2019-06-27 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added a comment. This change will be really useful for the lifetime analysis as well! Thanks! I have one concern though. The analyzer is using linerarized (or threaded) CFGs with every subexpression being a separate entry in the basic blocks. Will your change give sensible answers

r364575 - [OPENMP]Generate correctly implicit flags for mapped data.

2019-06-27 Thread Alexey Bataev via cfe-commits
Author: abataev Date: Thu Jun 27 11:53:07 2019 New Revision: 364575 URL: http://llvm.org/viewvc/llvm-project?rev=364575=rev Log: [OPENMP]Generate correctly implicit flags for mapped data. Implicit flag must not be emitted for explicitly specified firstprivate variables, but for implicitly

[PATCH] D62829: [clang-tidy] Check for dynamically initialized statics in headers.

2019-06-27 Thread Charles Zhang via Phabricator via cfe-commits
czhang added a comment. ping CHANGES SINCE LAST ACTION https://reviews.llvm.org/D62829/new/ https://reviews.llvm.org/D62829 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D59474: [OpenMP 5.0] Codegen support for user-defined mappers

2019-06-27 Thread Lingda Li via Phabricator via cfe-commits
lildmh updated this revision to Diff 206895. lildmh added a comment. Change the type of size from `size_t` to `int64_t`, and rebase CHANGES SINCE LAST ACTION https://reviews.llvm.org/D59474/new/ https://reviews.llvm.org/D59474 Files: include/clang/AST/GlobalDecl.h lib/AST/ASTContext.cpp

[PATCH] D63856: [ObjC] Add a -Wtautological-compare warning for BOOL

2019-06-27 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. In D63856#1561132 , @erik.pilkington wrote: > In D63856#1561112 , @rjmccall wrote: > > > In D63856#1560213 , > > @erik.pilkington wrote: > > > >

[PATCH] D62961: [AST] Add new Type queries for sizeless types

2019-06-27 Thread Richard Sandiford via Phabricator via cfe-commits
rsandifo-arm updated this revision to Diff 206894. rsandifo-arm added a comment. - Update for new version of D62960 Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D62961/new/ https://reviews.llvm.org/D62961 Files:

[PATCH] D62960: SVE opaque type for C intrinsics demo

2019-06-27 Thread Richard Sandiford via Phabricator via cfe-commits
rsandifo-arm marked 7 inline comments as done. rsandifo-arm added a comment. Thanks for the reviews! Comment at: include/clang/Basic/AArch64SVEACLETypes.def:10 +// +// This file defines the database about various builtin singleton types. +// rovka wrote: >

[PATCH] D63856: [ObjC] Add a -Wtautological-compare warning for BOOL

2019-06-27 Thread Erik Pilkington via Phabricator via cfe-commits
erik.pilkington added a comment. In D63856#1561112 , @rjmccall wrote: > In D63856#1560213 , @erik.pilkington > wrote: > > > In D63856#1560180 , @rjmccall > > wrote: > > >

[PATCH] D62977: [clang-tidy]: Google: new check 'google-upgrade-googletest-case'

2019-06-27 Thread Alex Strelnikov via Phabricator via cfe-commits
astrelni marked 4 inline comments as done. astrelni added a comment. In D62977#1560879 , @lebedev.ri wrote: > Looks reasonable. I did not review the check itself though. > Are `test/clang-tidy/google-upgrade-googletest-case-nosuite.cpp` and >

[PATCH] D62960: SVE opaque type for C intrinsics demo

2019-06-27 Thread Richard Sandiford via Phabricator via cfe-commits
rsandifo-arm updated this revision to Diff 206891. rsandifo-arm added a comment. - Fix comments in AArch64SVEACLETypes.def - Rename BUILTIN_TYPE to SVE_TYPE and use it where possible - Report errors for TODOs instead of using llvm_unreachable - Add a test for the errors - Formatting fixes

[PATCH] D62977: [clang-tidy]: Google: new check 'google-upgrade-googletest-case'

2019-06-27 Thread Alex Strelnikov via Phabricator via cfe-commits
astrelni updated this revision to Diff 206889. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D62977/new/ https://reviews.llvm.org/D62977 Files: clang-tools-extra/clang-tidy/google/CMakeLists.txt clang-tools-extra/clang-tidy/google/GoogleTidyModule.cpp

[PATCH] D59474: [OpenMP 5.0] Codegen support for user-defined mappers

2019-06-27 Thread Lingda Li via Phabricator via cfe-commits
lildmh marked an inline comment as done. lildmh added inline comments. Comment at: lib/CodeGen/CGOpenMPRuntime.cpp:8739 +/// // For each component specified by this mapper: +/// if (currentComponent.hasMapper()) +/// (*currentComponent.Mapper())(rt_mapper_handle,

[PATCH] D63856: [ObjC] Add a -Wtautological-compare warning for BOOL

2019-06-27 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. In D63856#1560213 , @erik.pilkington wrote: > In D63856#1560180 , @rjmccall wrote: > > > This only applies to relational operators, right? I'm a little > > uncomfortable with calling

[PATCH] D59474: [OpenMP 5.0] Codegen support for user-defined mappers

2019-06-27 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: lib/CodeGen/CGOpenMPRuntime.cpp:8739 +/// // For each component specified by this mapper: +/// if (currentComponent.hasMapper()) +/// (*currentComponent.Mapper())(rt_mapper_handle, arg_base, arg_begin,

[PATCH] D63773: [clangd] dummy variable extraction on a function scope

2019-06-27 Thread Shaurya Gupta via Phabricator via cfe-commits
SureYeaah marked 14 inline comments as done. SureYeaah added inline comments. Comment at: clang-tools-extra/clangd/refactor/tweaks/ExtractVariable.cpp:173 + // give up if extraction will take a variable out of scope + if (!extractionAllowed(ParStmt, N, M)) +

[PATCH] D59474: [OpenMP 5.0] Codegen support for user-defined mappers

2019-06-27 Thread Lingda Li via Phabricator via cfe-commits
lildmh marked an inline comment as done. lildmh added inline comments. Comment at: lib/CodeGen/CGOpenMPRuntime.cpp:8739 +/// // For each component specified by this mapper: +/// if (currentComponent.hasMapper()) +/// (*currentComponent.Mapper())(rt_mapper_handle,

[PATCH] D59474: [OpenMP 5.0] Codegen support for user-defined mappers

2019-06-27 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: lib/CodeGen/CGOpenMPRuntime.cpp:8739 +/// // For each component specified by this mapper: +/// if (currentComponent.hasMapper()) +/// (*currentComponent.Mapper())(rt_mapper_handle, arg_base, arg_begin,

[PATCH] D59474: [OpenMP 5.0] Codegen support for user-defined mappers

2019-06-27 Thread Lingda Li via Phabricator via cfe-commits
lildmh marked an inline comment as done. lildmh added inline comments. Comment at: lib/CodeGen/CGOpenMPRuntime.cpp:8739 +/// // For each component specified by this mapper: +/// if (currentComponent.hasMapper()) +/// (*currentComponent.Mapper())(rt_mapper_handle,

[PATCH] D61809: [BPF] Preserve debuginfo array/union/struct type/access index

2019-06-27 Thread Yonghong Song via Phabricator via cfe-commits
yonghong-song added a comment. @eli.friedman Hi, Just ping. I have removed getParents() for ASTContext and added description of the new intrinsic in language doc. Could you take a look? Thanks! Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D61809/new/

[PATCH] D59474: [OpenMP 5.0] Codegen support for user-defined mappers

2019-06-27 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: lib/CodeGen/CGOpenMPRuntime.cpp:8739 +/// // For each component specified by this mapper: +/// if (currentComponent.hasMapper()) +/// (*currentComponent.Mapper())(rt_mapper_handle, arg_base, arg_begin,

[PATCH] D59474: [OpenMP 5.0] Codegen support for user-defined mappers

2019-06-27 Thread Lingda Li via Phabricator via cfe-commits
lildmh marked an inline comment as done. lildmh added inline comments. Comment at: lib/CodeGen/CGOpenMPRuntime.cpp:8739 +/// // For each component specified by this mapper: +/// if (currentComponent.hasMapper()) +/// (*currentComponent.Mapper())(rt_mapper_handle,

[PATCH] D59474: [OpenMP 5.0] Codegen support for user-defined mappers

2019-06-27 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: lib/CodeGen/CGOpenMPRuntime.cpp:8739 +/// // For each component specified by this mapper: +/// if (currentComponent.hasMapper()) +/// (*currentComponent.Mapper())(rt_mapper_handle, arg_base, arg_begin,

[PATCH] D63756: [AMDGPU] Increased the number of implicit argument bytes for both OpenCL and HIP (CLANG).

2019-06-27 Thread Christudasan Devadasan via Phabricator via cfe-commits
cdevadas added a comment. I have created the review for adding the metadata in the backend. https://reviews.llvm.org/D63886 Marking the current review depended on D63886 . Repository: rC Clang CHANGES SINCE LAST ACTION

[PATCH] D59474: [OpenMP 5.0] Codegen support for user-defined mappers

2019-06-27 Thread Lingda Li via Phabricator via cfe-commits
lildmh marked an inline comment as done. lildmh added inline comments. Comment at: lib/CodeGen/CGOpenMPRuntime.cpp:8739 +/// // For each component specified by this mapper: +/// if (currentComponent.hasMapper()) +/// (*currentComponent.Mapper())(rt_mapper_handle,

[PATCH] D63518: BitStream reader: propagate errors

2019-06-27 Thread JF Bastien via Phabricator via cfe-commits
jfb marked 2 inline comments as done. jfb added a subscriber: hans. jfb added inline comments. Comment at: llvm/trunk/lib/Bitcode/Reader/BitcodeReader.cpp:205 + return MaybeBitCode.takeError(); +switch (unsigned BitCode = MaybeBitCode.get()) { default: // Default

[PATCH] D63878: [CTU] Add missing statistics

2019-06-27 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun accepted this revision. xazax.hun added a comment. This revision is now accepted and ready to land. LGTM! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63878/new/ https://reviews.llvm.org/D63878

[PATCH] D63638: [clang][NewPM] Add new pass manager RUN lines to avx512f-builtins.c

2019-06-27 Thread Craig Topper via Phabricator via cfe-commits
craig.topper added a comment. In D63638#1560846 , @spatel wrote: > I skimmed D63174 but haven't applied either > of these patches to test locally, so I may not have the full picture. > > IMO, we do not want clang

[PATCH] D60455: [SYCL] Implement SYCL device code outlining

2019-06-27 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
Fznamznon updated this revision to Diff 206873. Fznamznon added a comment. Minor fix Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D60455/new/ https://reviews.llvm.org/D60455 Files: clang/include/clang/Basic/Attr.td

[PATCH] D62648: [Sema][Typo] Fix assertion failure for expressions with multiple typos

2019-06-27 Thread David Goldman via Phabricator via cfe-commits
dgoldman added inline comments. Comment at: lib/Sema/SemaExprCXX.cpp:7762-7764 + llvm::SmallDenseMap NewTransformCache; + auto SavedTransformCache = TransformCache; + TransformCache = NewTransformCache; Should I do the same `std::move` and `clear`

[PATCH] D62648: [Sema][Typo] Fix assertion failure for expressions with multiple typos

2019-06-27 Thread David Goldman via Phabricator via cfe-commits
dgoldman updated this revision to Diff 206870. dgoldman marked 9 inline comments as done. dgoldman added a comment. - Minor fixes Repository: rC Clang CHANGES SINCE LAST ACTION https://reviews.llvm.org/D62648/new/ https://reviews.llvm.org/D62648 Files: lib/Sema/SemaExprCXX.cpp

[PATCH] D63821: [clangd] Added C++ API code for semantic highlighting

2019-06-27 Thread Johan Vikström via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL364551: [clangd] Emit semantic highlighting tokens when the main AST is built. (authored by jvikstrom, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior

[clang-tools-extra] r364551 - [clangd] Emit semantic highlighting tokens when the main AST is built.

2019-06-27 Thread Johan Vikstrom via cfe-commits
Author: jvikstrom Date: Thu Jun 27 08:13:03 2019 New Revision: 364551 URL: http://llvm.org/viewvc/llvm-project?rev=364551=rev Log: [clangd] Emit semantic highlighting tokens when the main AST is built. Differential Revision: https://reviews.llvm.org/D63821 Modified:

[PATCH] D63638: [clang][NewPM] Add new pass manager RUN lines to avx512f-builtins.c

2019-06-27 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. In D63638#1560846 , @spatel wrote: > I skimmed D63174 but haven't applied either > of these patches to test locally, so I may not have the full picture. > > IMO, we do not want clang

[PATCH] D63821: [clangd] Added C++ API code for semantic highlighting

2019-06-27 Thread Haojian Wu via Phabricator via cfe-commits
hokein accepted this revision. hokein added a comment. This revision is now accepted and ready to land. Let's rephrase the commit message, I think this patch is just to "emit the semantic highlighting tokens when the main AST is built". Comment at:

[PATCH] D62977: [clang-tidy]: Google: new check 'google-upgrade-googletest-case'

2019-06-27 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri resigned from this revision. lebedev.ri added a comment. Looks reasonable. I did not review the check itself though. Are `test/clang-tidy/google-upgrade-googletest-case-nosuite.cpp` and `test/clang-tidy/google-upgrade-googletest-case.cpp ` identical other than the included header and

[PATCH] D60455: [SYCL] Implement SYCL device code outlining

2019-06-27 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
Fznamznon updated this revision to Diff 206861. Fznamznon added a comment. Added warning diagnostic for `sycl_kernel` attribute. Now if the `sycl_kernel` attribute applied to a function which doesn't meet requirements for OpenCL kernel generation, attribute will be ignored and diagnostic will

[PATCH] D63638: [clang][NewPM] Add new pass manager RUN lines to avx512f-builtins.c

2019-06-27 Thread Sanjay Patel via Phabricator via cfe-commits
spatel added a comment. I skimmed D63174 but haven't applied either of these patches to test locally, so I may not have the full picture. IMO, we do not want clang regression tests running -instcombine/-instsimplify. That can cause clang tests to break when an

[PATCH] D63773: [clangd] dummy variable extraction on a function scope

2019-06-27 Thread Sam McCall via Phabricator via cfe-commits
sammccall added a comment. Please forgive the mix of high-level and low-level comments here. Happy to discuss further of course! Comment at: clang-tools-extra/clangd/refactor/tweaks/ExtractVariable.cpp:55 +// checks whether any variable in a given expr is declared in the

[PATCH] D62977: [clang-tidy]: Google: new check 'google-upgrade-googletest-case'

2019-06-27 Thread Alex Strelnikov via Phabricator via cfe-commits
astrelni added a comment. In D62977#1559649 , @lebedev.ri wrote: > In D62977#1559637 , @astrelni wrote: > > > In D62977#1559628 , @lebedev.ri > > wrote: > > > > > It

[PATCH] D62977: [clang-tidy]: Google: new check 'google-upgrade-googletest-case'

2019-06-27 Thread Alex Strelnikov via Phabricator via cfe-commits
astrelni updated this revision to Diff 206855. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D62977/new/ https://reviews.llvm.org/D62977 Files: clang-tools-extra/clang-tidy/google/CMakeLists.txt clang-tools-extra/clang-tidy/google/GoogleTidyModule.cpp

[PATCH] D63878: [CTU] Add missing statistics

2019-06-27 Thread Gabor Marton via Phabricator via cfe-commits
martong created this revision. martong added a reviewer: xazax.hun. Herald added subscribers: cfe-commits, gamesh411, Szelethus, dkrupp, rnkovacs. Herald added a project: clang. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D63878 Files:

[PATCH] D63821: [clangd] Added C++ API code for semantic highlighting

2019-06-27 Thread Johan Vikström via Phabricator via cfe-commits
jvikstrom updated this revision to Diff 206854. jvikstrom marked 2 inline comments as done. jvikstrom added a comment. Made test safe again Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63821/new/ https://reviews.llvm.org/D63821 Files:

[PATCH] D63876: [OpenCL] Define CLK_NULL_EVENT without cast

2019-06-27 Thread Sven van Haastregt via Phabricator via cfe-commits
svenvh created this revision. svenvh added reviewers: Anastasia, yaxunl. Herald added a project: clang. Herald added a subscriber: cfe-commits. Defining CLK_NULL_EVENT with a `(void*)` cast has the (unintended?) side-effect that the address space will be fixed (as generic in OpenCL 2.0 mode).

[PATCH] D63872: [clangd] Fix a case where we fail to detect a header-declared symbol in rename.

2019-06-27 Thread Haojian Wu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL364537: [clangd] Fix a case where we fail to detect a header-declared symbol in rename. (authored by hokein, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed

[clang-tools-extra] r364537 - [clangd] Fix a case where we fail to detect a header-declared symbol in rename.

2019-06-27 Thread Haojian Wu via cfe-commits
Author: hokein Date: Thu Jun 27 06:24:10 2019 New Revision: 364537 URL: http://llvm.org/viewvc/llvm-project?rev=364537=rev Log: [clangd] Fix a case where we fail to detect a header-declared symbol in rename. Summary: Failing case: ``` #include "foo.h" void fo^o() {} ``` getRenameDecl()

[PATCH] D63821: [clangd] Added C++ API code for semantic highlighting

2019-06-27 Thread Haojian Wu via Phabricator via cfe-commits
hokein added inline comments. Comment at: clang-tools-extra/clangd/ClangdLSPServer.h:60 + void + onHighlightingsReady(PathRef File, + std::vector Highlightings) override; jvikstrom wrote: > hokein wrote: > > nit: you can remove this

[PATCH] D63872: [clangd] Fix a case where we fail to detect a header-declared symbol in rename.

2019-06-27 Thread Sam McCall via Phabricator via cfe-commits
sammccall accepted this revision. sammccall added inline comments. This revision is now accepted and ready to land. Comment at: clang-tools-extra/clangd/refactor/Rename.cpp:157 assert(RenameDecl && "symbol must be found at this point"); + RenameDecl =

[PATCH] D63872: [clangd] Fix a case where we fail to detect a header-declared symbol in rename.

2019-06-27 Thread Haojian Wu via Phabricator via cfe-commits
hokein added inline comments. Comment at: clang-tools-extra/clangd/refactor/Rename.cpp:157 assert(RenameDecl && "symbol must be found at this point"); + RenameDecl = cast(RenameDecl->getCanonicalDecl()); if (auto Reject = renamableWithinFile(*RenameDecl, File, Index)) {

[PATCH] D63872: [clangd] Fix a case where we fail to detect a header-declared symbol in rename.

2019-06-27 Thread Haojian Wu via Phabricator via cfe-commits
hokein updated this revision to Diff 206844. hokein marked 2 inline comments as done. hokein added a comment. Address comment. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63872/new/ https://reviews.llvm.org/D63872 Files:

[PATCH] D63082: [Diagnostics] Added support for -Wint-in-bool-context

2019-06-27 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 updated this revision to Diff 206842. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63082/new/ https://reviews.llvm.org/D63082 Files: include/clang/Basic/DiagnosticGroups.td include/clang/Basic/DiagnosticSemaKinds.td lib/Sema/SemaChecking.cpp test/Analysis/misc-ps.c

[PATCH] D63821: [clangd] Added C++ API code for semantic highlighting

2019-06-27 Thread Johan Vikström via Phabricator via cfe-commits
jvikstrom marked an inline comment as done. jvikstrom added inline comments. Comment at: clang-tools-extra/clangd/ClangdLSPServer.h:60 + void + onHighlightingsReady(PathRef File, + std::vector Highlightings) override; hokein wrote: > nit:

[PATCH] D63821: [clangd] Added C++ API code for semantic highlighting

2019-06-27 Thread Johan Vikström via Phabricator via cfe-commits
jvikstrom updated this revision to Diff 206841. jvikstrom marked an inline comment as done. jvikstrom added a comment. Simplified test. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63821/new/ https://reviews.llvm.org/D63821 Files:

[clang-tools-extra] r364535 - [clang-tidy] Fix NDEBUG build [NFC]

2019-06-27 Thread Mikael Holmen via cfe-commits
Author: uabelho Date: Thu Jun 27 05:47:57 2019 New Revision: 364535 URL: http://llvm.org/viewvc/llvm-project?rev=364535=rev Log: [clang-tidy] Fix NDEBUG build [NFC] Modified: clang-tools-extra/trunk/clang-tidy/utils/TransformerClangTidyCheck.cpp Modified:

[PATCH] D63082: [Diagnostics] Added support for -Wint-in-bool-context

2019-06-27 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added a comment. Alternative “* in boolean context; did you mean to compare it?” CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63082/new/ https://reviews.llvm.org/D63082 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D63559: [clangd] Added functionality for getting semantic highlights for variable and function declarations

2019-06-27 Thread Haojian Wu via Phabricator via cfe-commits
hokein closed this revision. hokein added a comment. the patch was landed in rL364421 , not sure why it was not associated with this review. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D63559/new/

[PATCH] D63821: [clangd] Added C++ API code for semantic highlighting

2019-06-27 Thread Haojian Wu via Phabricator via cfe-commits
hokein added inline comments. Comment at: clang-tools-extra/clangd/ClangdLSPServer.h:60 + void + onHighlightingsReady(PathRef File, + std::vector Highlightings) override; nit: you can remove this override, since we have provided an empty

[PATCH] D63082: [Diagnostics] Added support for -Wint-in-bool-context

2019-06-27 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added a comment. “Perhaps appending something about the resulting value always being true|false would help most of these diagnostics be more obvious” I dont know, this could only diagnose constant multiplications (maybe this is already handled by some “always true” check). Anyway, I

[PATCH] D63874: [clangd] No need to setTraversalScope in SemanticHighlighting.

2019-06-27 Thread Haojian Wu via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL364528: [clangd] No need to setTraversalScope in SemanticHighlighting. (authored by hokein, committed by ). Herald added a project: LLVM. Herald added a subscriber: llvm-commits. Changed prior to commit:

  1   2   >