[PATCH] D40508: Replace long type names in IR with hashes

2017-11-29 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. Are you trying to use LLVM struct type identity to infer information about the source program? That is not and has never been a guarantee. https://reviews.llvm.org/D40508 ___ cfe-commits mailing list cfe-commits@lists.llv

[PATCH] D40463: [analyzer] Fix false negative on post-increment of uninitialized variable.

2017-11-29 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added a comment. In https://reviews.llvm.org/D40463#939772, @dcoughlin wrote: > Thanks, this looks good to me! Awesome, thank you! > Do you have commit access or do you need someone to commit it for you? I do have commit access. Repository: rC Clang https://reviews.llvm.org/D4

[PATCH] D40508: Replace long type names in IR with hashes

2017-11-29 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff added a comment. In https://reviews.llvm.org/D40508#939513, @rjmccall wrote: > In https://reviews.llvm.org/D40508#938854, @sepavloff wrote: > > > In https://reviews.llvm.org/D40508#938686, @rjmccall wrote: > > > > > The LLVM linking model does not actually depend on struct type names >

[PATCH] D40637: [CMake] Support runtimes and monorepo layouts when looking for libc++

2017-11-29 Thread Petr Hosek via Phabricator via cfe-commits
phosek created this revision. Herald added subscribers: Sanitizers, llvm-commits, mgorny, kubamracek. Herald added a reviewer: EricWF. This also slightly refactors the code that's checking the directory presence which allows eliminating one unnecessary variable. Repository: rCRT Compiler Runti

[PATCH] D35894: [clangd] Code hover for Clangd

2017-11-29 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle added inline comments. Comment at: clangd/ClangdUnit.cpp:1117 + + if (!DeclVector.empty()) { +const Decl *LocationDecl = DeclVector[0]; malaperle wrote: > malaperle wrote: > > malaperle wrote: > > > I think we need to simplify this part a bit. I'll

[PATCH] D40567: Always show template parameters in IR type names

2017-11-29 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff added a comment. In https://reviews.llvm.org/D40567#940025, @rsmith wrote: > What actual problem is this solving? These IR type names exist only for the > convenience of humans reading the IR, and making them long (potentially > extremely long) by including template arguments seems li

[PATCH] D38845: [ASTImporter] Support importing UnresolvedMemberExpr, DependentNameType, DependentScopeDeclRefExpr

2017-11-29 Thread Peter Szecsi via Phabricator via cfe-commits
szepet marked an inline comment as done. szepet added inline comments. Comment at: unittests/AST/ASTImporterTest.cpp:611 + EXPECT_TRUE(testImport("template struct S;" + "template void declToImport() {" + " S::foo;" -

[PATCH] D40625: Harmonizing attribute GNU/C++ spellings

2017-11-29 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: include/clang/Basic/Attr.td:602 def AnalyzerNoReturn : InheritableAttr { - let Spellings = [GNU<"analyzer_noreturn">]; + let Spellings = [Clang<"analyzer_noreturn">]; let Documentation = [Undocumented]; Hmm, should

[PATCH] D39347: Fix __has_unique_object_representations based on rsmith's input

2017-11-29 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added a comment. In https://reviews.llvm.org/D39347#940015, @rsmith wrote: > Thanks for your patience, this turned out to be surprisingly complicated. Of course! Thank you as well for your input, I was surprised at how complicated this ended up being as well! https://reviews.llvm

[PATCH] D40567: Always show template parameters in IR type names

2017-11-29 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. What actual problem is this solving? These IR type names exist only for the convenience of humans reading the IR, and making them long (potentially extremely long) by including template arguments seems likely to hinder that more than it helps. https://reviews.llvm.org/

[PATCH] D39347: Fix __has_unique_object_representations based on rsmith's input

2017-11-29 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith accepted this revision. rsmith added a comment. This revision is now accepted and ready to land. Thanks for your patience, this turned out to be surprisingly complicated. https://reviews.llvm.org/D39347 ___ cfe-commits mailing list cfe-commit

[PATCH] D39347: Fix __has_unique_object_representations based on rsmith's input

2017-11-29 Thread Erich Keane via Phabricator via cfe-commits
erichkeane updated this revision to Diff 124863. erichkeane added a comment. Fix for trailing padding BITS, which obviously won't be merged. https://reviews.llvm.org/D39347 Files: include/clang/AST/ASTContext.h include/clang/AST/Type.h lib/AST/ASTContext.cpp lib/AST/CXXABI.h lib/AST/I

[PATCH] D39347: Fix __has_unique_object_representations based on rsmith's input

2017-11-29 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added inline comments. Comment at: lib/AST/ASTContext.cpp:2200 + Layout.getBaseClassOffset(Base->getAsCXXRecordDecl()); + CharUnits BaseSize = Context.getTypeSizeInChars(Base); + if (BaseOffset != CurOffset) rsmith wrote: > erichkean

[PATCH] D39347: Fix __has_unique_object_representations based on rsmith's input

2017-11-29 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: lib/AST/ASTContext.cpp:2200 + Layout.getBaseClassOffset(Base->getAsCXXRecordDecl()); + CharUnits BaseSize = Context.getTypeSizeInChars(Base); + if (BaseOffset != CurOffset) erichkeane wrote: > rsmith wr

[PATCH] D40580: [clang-tidy] Adding Fuchsia checker for multiple inheritance

2017-11-29 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: docs/clang-tidy/checks/fuchsia-multiple-inheritance.rst:46 + +See the features disallowed in Fuchsia at https://fuchsia.googlesource.com/zircon/+/master/docs/cxx.md juliehockett wrote: > alexfh wrote: > > This is not abo

[PATCH] D39347: Fix __has_unique_object_representations based on rsmith's input

2017-11-29 Thread Erich Keane via Phabricator via cfe-commits
erichkeane updated this revision to Diff 124859. erichkeane added a comment. Fixed the 'tail padding' mechanism to work correctly as suggested by @rsmith https://reviews.llvm.org/D39347 Files: include/clang/AST/ASTContext.h include/clang/AST/Type.h lib/AST/ASTContext.cpp lib/AST/CXXABI.

[PATCH] D40563: [SemaCodeComplete] Allow passing out scope specifiers in qualified-id completions via completion context.

2017-11-29 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added a comment. If nothing uses `getCXXScopeSpecifier` right now we can't really test it with a clang or c-index-test regression test. A completion unit test could work here. I don't think we actually have existing completion unit tests though, so you would have to create one from scr

[PATCH] D40562: [Sema] Ignore decls in namespaces when global decls are not wanted.

2017-11-29 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added a comment. Here's a simple test that breaks: $ cat test.cpp namespace ns { void func(); } ns:: // complete $ c-index-test -code-completion-at=test.cpp:5:1 test.cpp FunctionDecl:{ResultType void}{TypedText func}{LeftParen (}{RightParen )} (50) Completion contexts

[PATCH] D40562: [Sema] Ignore decls in namespaces when global decls are not wanted.

2017-11-29 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added a comment. This change breaks cached completions for declarations in namespaces in libclang. What exactly are you trying to achieve here? We could introduce another flag maybe. https://reviews.llvm.org/D40562 ___ cfe-commits mailing

[PATCH] D40580: [clang-tidy] Adding Fuchsia checker for multiple inheritance

2017-11-29 Thread Julie Hockett via Phabricator via cfe-commits
juliehockett added inline comments. Comment at: docs/clang-tidy/checks/fuchsia-multiple-inheritance.rst:46 + +See the features disallowed in Fuchsia at https://fuchsia.googlesource.com/zircon/+/master/docs/cxx.md alexfh wrote: > This is not about the check, rath

[PATCH] D40580: [clang-tidy] Adding Fuchsia checker for multiple inheritance

2017-11-29 Thread Julie Hockett via Phabricator via cfe-commits
juliehockett updated this revision to Diff 124853. juliehockett added a comment. Rebasing for updated Release Notes -- so much nicer :) https://reviews.llvm.org/D40580 Files: clang-tidy/fuchsia/CMakeLists.txt clang-tidy/fuchsia/FuchsiaTidyModule.cpp clang-tidy/fuchsia/MultipleInheritanceC

[PATCH] D35109: [Analyzer] SValBuilder Comparison Rearrangement

2017-11-29 Thread George Karpenkov via Phabricator via cfe-commits
george.karpenkov added a comment. > If the type extension approach is proven to be sound I lack the full context here, but in my experience Z3 is really great for proving whether certain operations may or may not overflow, using the built-in bitvector type. (I'm not sure though if that is what

r319388 - [XRay][clang] Introduce -fxray-always-emit-customevents

2017-11-29 Thread Dean Michael Berris via cfe-commits
Author: dberris Date: Wed Nov 29 16:04:54 2017 New Revision: 319388 URL: http://llvm.org/viewvc/llvm-project?rev=319388&view=rev Log: [XRay][clang] Introduce -fxray-always-emit-customevents Summary: The -fxray-always-emit-customevents flag instructs clang to always emit the LLVM IR for calls to t

[PATCH] D40601: [XRay][clang] Introduce -fxray-always-emit-customevents

2017-11-29 Thread Dean Michael Berris via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL319388: [XRay][clang] Introduce -fxray-always-emit-customevents (authored by dberris). Changed prior to commit: https://reviews.llvm.org/D40601?vs=124842&id=124846#toc Repository: rL LLVM https://re

[PATCH] D39347: Fix __has_unique_object_representations based on rsmith's input

2017-11-29 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added inline comments. Comment at: lib/AST/ASTContext.cpp:2200 + Layout.getBaseClassOffset(Base->getAsCXXRecordDecl()); + CharUnits BaseSize = Context.getTypeSizeInChars(Base); + if (BaseOffset != CurOffset) rsmith wrote: > erichkean

[PATCH] D39347: Fix __has_unique_object_representations based on rsmith's input

2017-11-29 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: lib/AST/ASTContext.cpp:2200 + Layout.getBaseClassOffset(Base->getAsCXXRecordDecl()); + CharUnits BaseSize = Context.getTypeSizeInChars(Base); + if (BaseOffset != CurOffset) erichkeane wrote: > rsmith wr

[PATCH] D40601: [XRay][clang] Introduce -fxray-always-emit-customevents

2017-11-29 Thread Dean Michael Berris via Phabricator via cfe-commits
dberris added inline comments. Comment at: clang/lib/Driver/XRayArgs.cpp:32-33 constexpr char XRayNeverInstrumentOption[] = "-fxray-never-instrument="; +constexpr char XRayAlwaysEmitCustomEventsOption[] = +"-fxray-always-emit-customevents"; } // namespace d

[PATCH] D40601: [XRay][clang] Introduce -fxray-always-emit-customevents

2017-11-29 Thread Dean Michael Berris via Phabricator via cfe-commits
dberris updated this revision to Diff 124842. dberris marked an inline comment as done. dberris edited the summary of this revision. dberris added a comment. Updated description, address review comment(s). https://reviews.llvm.org/D40601 Files: clang/include/clang/Basic/LangOptions.def clan

[PATCH] D39347: Fix __has_unique_object_representations based on rsmith's input

2017-11-29 Thread Erich Keane via Phabricator via cfe-commits
erichkeane marked an inline comment as done. erichkeane added inline comments. Comment at: lib/AST/ASTContext.cpp:2200 + Layout.getBaseClassOffset(Base->getAsCXXRecordDecl()); + CharUnits BaseSize = Context.getTypeSizeInChars(Base); + if (BaseOffset != CurOffse

[PATCH] D40621: MS ABI: Treat explicit instantiation definitions of dllimport function templates as explicit instantiation decls (PR35435)

2017-11-29 Thread Hans Wennborg via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL319386: MS ABI: Treat explicit instantiation definitions of dllimport function… (authored by hans). Changed prior to commit: https://reviews.llvm.org/D40621?vs=124808&id=124839#toc Repository: rL LLV

r319386 - MS ABI: Treat explicit instantiation definitions of dllimport function templates as explicit instantiation decls (PR35435)

2017-11-29 Thread Hans Wennborg via cfe-commits
Author: hans Date: Wed Nov 29 15:44:11 2017 New Revision: 319386 URL: http://llvm.org/viewvc/llvm-project?rev=319386&view=rev Log: MS ABI: Treat explicit instantiation definitions of dllimport function templates as explicit instantiation decls (PR35435) This matches MSVC's behaviour, and we alre

[PATCH] D35894: [clangd] Code hover for Clangd

2017-11-29 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle added inline comments. Comment at: clangd/ClangdUnit.cpp:1071 +Location getDeclarationLocation(ParsedAST &AST, +const SourceRange &ValSourceRange) { llvm::ErrorOr Comment at: clangd/ClangdUnit.cpp:107

[PATCH] D35894: [clangd] Code hover for Clangd

2017-11-29 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle added a comment. I copy/pasted the comments again so that you don't miss them. Comment at: clangd/ClangdUnit.cpp:1117 + + if (!DeclVector.empty()) { +const Decl *LocationDecl = DeclVector[0]; malaperle wrote: > malaperle wrote: > > I think we nee

[PATCH] D38425: [clangd] Document highlights for clangd

2017-11-29 Thread William Enright via Phabricator via cfe-commits
Nebiroth updated this revision to Diff 124834. Nebiroth added a comment. Fixed wrong content header making the test fail Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D38425 Files: clangd/ClangdLSPServer.cpp clangd/ClangdLSPServer.h clangd/ClangdServer.cpp clangd/Clangd

[PATCH] D35894: [clangd] Code hover for Clangd

2017-11-29 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle requested changes to this revision. malaperle added inline comments. This revision now requires changes to proceed. Comment at: clangd/Protocol.cpp:498 +// Default Hover values +Hover H; +return json::obj{ remove, we have to return the conte

[PATCH] D35894: [clangd] Code hover for Clangd

2017-11-29 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle added inline comments. Comment at: clangd/ClangdUnit.cpp:1117 + + if (!DeclVector.empty()) { +const Decl *LocationDecl = DeclVector[0]; malaperle wrote: > I think we need to simplify this part a bit. I'll try to find a way. Feel > free to wait unt

[PATCH] D39347: Fix __has_unique_object_representations based on rsmith's input

2017-11-29 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added inline comments. Comment at: lib/AST/ASTContext.cpp:2200 + Layout.getBaseClassOffset(Base->getAsCXXRecordDecl()); + CharUnits BaseSize = Context.getTypeSizeInChars(Base); + if (BaseOffset != CurOffset) On reflection, I don't think

[PATCH] D40198: [CUDA] Tweak CUDA wrappers to make cuda-9 work with libc++

2017-11-29 Thread Artem Belevich via Phabricator via cfe-commits
tra added a comment. ping. https://reviews.llvm.org/D40198 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D35894: [clangd] Code hover for Clangd

2017-11-29 Thread William Enright via Phabricator via cfe-commits
Nebiroth updated this revision to Diff 124833. Nebiroth added a comment. Herald added a subscriber: klimek. Invalid FileEntries now return llvm:ErrorOr Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D35894 Files: clangd/ClangdLSPServer.cpp clangd/ClangdLSPServer.h clangd/C

[PATCH] D40574: Bounds check argument_with_type_tag attribute.

2017-11-29 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman closed this revision. aaron.ballman added a comment. In https://reviews.llvm.org/D40574#939693, @mattd wrote: > Thanks for the approval Aaron. I do not have commit access, would you mind > submitting this on my behalf? Happy to do so -- I've commit in r319383, thank you for the

r319383 - Perform a bounds check on a function's argument list before accessing any index value specified by an 'argument_with_type_tag' attribute. Fixes PR28520.

2017-11-29 Thread Aaron Ballman via cfe-commits
Author: aaronballman Date: Wed Nov 29 15:10:14 2017 New Revision: 319383 URL: http://llvm.org/viewvc/llvm-project?rev=319383&view=rev Log: Perform a bounds check on a function's argument list before accessing any index value specified by an 'argument_with_type_tag' attribute. Fixes PR28520. Patc

[PATCH] D40625: Harmonizing attribute GNU/C++ spellings

2017-11-29 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman created this revision. Herald added subscribers: kristof.beyls, Anastasia, mehdi_amini, aemerson. Based on discussions at the WG21 meeting in Albuquerque and follow-up email discussions, I believe the correct approach to exposing attributes from Clang is to provide them with GNU-st

[PATCH] D40463: [analyzer] Fix false negative on post-increment of uninitialized variable.

2017-11-29 Thread Devin Coughlin via Phabricator via cfe-commits
dcoughlin accepted this revision. dcoughlin added a comment. This revision is now accepted and ready to land. Thanks, this looks good to me! Do you have commit access or do you need someone to commit it for you? Comment at: lib/StaticAnalyzer/Checkers/UndefinedAssignmentChecke

r319376 - [AST] Fix some Clang-tidy modernize and Include What You Use warnings; other minor fixes (NFC).

2017-11-29 Thread Eugene Zelenko via cfe-commits
Author: eugenezelenko Date: Wed Nov 29 14:39:22 2017 New Revision: 319376 URL: http://llvm.org/viewvc/llvm-project?rev=319376&view=rev Log: [AST] Fix some Clang-tidy modernize and Include What You Use warnings; other minor fixes (NFC). Modified: cfe/trunk/include/clang/AST/DeclTemplate.h

[PATCH] D40580: [clang-tidy] Adding Fuchsia checker for multiple inheritance

2017-11-29 Thread Eugene Zelenko via Phabricator via cfe-commits
Eugene.Zelenko added a comment. Please rebase from trunk. I just enforced some order in chaos of Release Notes :-) https://reviews.llvm.org/D40580 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinf

r319373 - [Coverage] Emit gap areas in braces-optional statements (PR35387)

2017-11-29 Thread Vedant Kumar via cfe-commits
Author: vedantk Date: Wed Nov 29 14:25:14 2017 New Revision: 319373 URL: http://llvm.org/viewvc/llvm-project?rev=319373&view=rev Log: [Coverage] Emit gap areas in braces-optional statements (PR35387) Emit a gap area starting after the r-paren location and ending at the start of the body for the b

[PATCH] D40528: add new check to find NSError init invocation

2017-11-29 Thread Yan Zhang via Phabricator via cfe-commits
Wizard added inline comments. Comment at: docs/clang-tidy/checks/objc-avoid-nserror-init.rst:10 +``errorWithDomain:code:userInfo:`` to create new NSError objects instead +of ``[NSError alloc] init]``. Otherwise it will lead to a warning message +during compilation in Xcode. -

[PATCH] D40528: add new check to find NSError init invocation

2017-11-29 Thread Yan Zhang via Phabricator via cfe-commits
Wizard updated this revision to Diff 124818. Wizard marked 3 inline comments as done. Wizard added a comment. address comments Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D40528 Files: clang-tidy/objc/AvoidNserrorInitCheck.cpp clang-tidy/objc/AvoidNserrorInitCheck.h cla

[clang-tools-extra] r319369 - [Documentation] Sort Clang-tidy changes next way: new modules, new checks, renamed checks, extended checks, new check aliases.

2017-11-29 Thread Eugene Zelenko via cfe-commits
Author: eugenezelenko Date: Wed Nov 29 14:17:39 2017 New Revision: 319369 URL: http://llvm.org/viewvc/llvm-project?rev=319369&view=rev Log: [Documentation] Sort Clang-tidy changes next way: new modules, new checks, renamed checks, extended checks, new check aliases. Sort checks in each section a

[PATCH] D40574: Bounds check argument_with_type_tag attribute.

2017-11-29 Thread Matt Davis via Phabricator via cfe-commits
mattd marked an inline comment as done. mattd added a comment. Thanks for the approval Aaron. I do not have commit access, would you mind submitting this on my behalf? https://reviews.llvm.org/D40574 ___ cfe-commits mailing list cfe-commits@lists.

Re: r319297 - Toolchain: Normalize dwarf, sjlj and seh eh

2017-11-29 Thread Martin Storsjö via cfe-commits
On Wed, 29 Nov 2017, Martin Storsjö via cfe-commits wrote: On Wed, 29 Nov 2017, Reid Kleckner wrote: On Wed, Nov 29, 2017 at 12:21 PM, Martin Storsjö wrote: On Wed, 29 Nov 2017, Martell Malone via cfe-commits wrote: Thanks for letting me know Reid. I’ll in work a

[PATCH] D40588: [OpenMP] Diagnose undeclared variables on declare target clause

2017-11-29 Thread Kelvin Li via Phabricator via cfe-commits
kkwli0 updated this revision to Diff 124811. kkwli0 added a comment. The assert occurs in VarOrFuncDeclFilterCCC::ValidateCandidate when clang::Sema::CorrectTypo is called. https://reviews.llvm.org/D40588 Files: lib/Sema/SemaOpenMP.cpp test/OpenMP/declare_target_messages.cpp Index: test/

[PATCH] D35894: [clangd] Code hover for Clangd

2017-11-29 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle added inline comments. Comment at: clangd/ClangdUnit.cpp:1029 + SourceLocation LocStart = ValSourceRange.getBegin(); + SourceLocation LocEnd = Lexer::getLocForEndOfToken(ValSourceRange.getEnd(), 0, + SourceMgr, Lang

Re: r319297 - Toolchain: Normalize dwarf, sjlj and seh eh

2017-11-29 Thread Martin Storsjö via cfe-commits
On Wed, 29 Nov 2017, Reid Kleckner wrote: On Wed, Nov 29, 2017 at 12:21 PM, Martin Storsjö wrote: On Wed, 29 Nov 2017, Martell Malone via cfe-commits wrote: Thanks for letting me know Reid. I’ll in work and won’t be able to access the repo until lunch t

[PATCH] D40588: [OpenMP] Diagnose undeclared variables on declare target clause

2017-11-29 Thread Kelvin Li via Phabricator via cfe-commits
kkwli0 added a comment. The original case has the variables named "foo1" and foo2". Using "foo1" or "foo2" causes the assert! I update the description. https://reviews.llvm.org/D40588 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http:/

[PATCH] D38425: [clangd] Document highlights for clangd

2017-11-29 Thread William Enright via Phabricator via cfe-commits
Nebiroth updated this revision to Diff 124810. Nebiroth added a comment. Added verification for llvm::Expected in onDocumentHighlight Removed unused variable in ClangdUnit Repository: rCTE Clang Tools Extra https://reviews.llvm.org/D38425 Files: clangd/ClangdLSPServer.cpp clangd/ClangdLS

Re: r319297 - Toolchain: Normalize dwarf, sjlj and seh eh

2017-11-29 Thread Reid Kleckner via cfe-commits
On Wed, Nov 29, 2017 at 12:21 PM, Martin Storsjö wrote: > On Wed, 29 Nov 2017, Martell Malone via cfe-commits wrote: > >> Thanks for letting me know Reid. >> I’ll in work and won’t be able to access the repo until lunch time. (~3 >> hours) >> Feel free to revert if it is not trivial. >> >> The ea

[PATCH] D40621: MS ABI: Treat explicit instantiation definitions of dllimport function templates as explicit instantiation decls (PR35435)

2017-11-29 Thread Reid Kleckner via Phabricator via cfe-commits
rnk accepted this revision. rnk added a comment. This revision is now accepted and ready to land. Looks good, thanks! https://reviews.llvm.org/D40621 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listi

r319364 - Reformat switch statement added in r319297, NFC

2017-11-29 Thread Reid Kleckner via cfe-commits
Author: rnk Date: Wed Nov 29 13:36:00 2017 New Revision: 319364 URL: http://llvm.org/viewvc/llvm-project?rev=319364&view=rev Log: Reformat switch statement added in r319297, NFC Modified: cfe/trunk/lib/Driver/ToolChains/Clang.cpp Modified: cfe/trunk/lib/Driver/ToolChains/Clang.cpp URL: http

r319363 - [EH] Use __CxxFrameHandler3 for C++ EH in MS environments

2017-11-29 Thread Reid Kleckner via cfe-commits
Author: rnk Date: Wed Nov 29 13:35:34 2017 New Revision: 319363 URL: http://llvm.org/viewvc/llvm-project?rev=319363&view=rev Log: [EH] Use __CxxFrameHandler3 for C++ EH in MS environments Fixes regression introduced by r319297. MSVC environments still use SEH unwind opcodes but they should use th

[PATCH] D40563: [SemaCodeComplete] Allow passing out scope specifiers in qualified-id completions via completion context.

2017-11-29 Thread Eric Liu via Phabricator via cfe-commits
ioeric added a comment. In https://reviews.llvm.org/D40563#939555, @arphaman wrote: > Could you please add a test? Any tip on how this should be tested? I couldn't find any existing unit test for either SemaCodeComplete or code completion context (under `clang/unittests`). It might be possibl

r319362 - [OPENMP] Allow only loop control variables in distribute simd

2017-11-29 Thread Alexey Bataev via cfe-commits
Author: abataev Date: Wed Nov 29 13:31:48 2017 New Revision: 319362 URL: http://llvm.org/viewvc/llvm-project?rev=319362&view=rev Log: [OPENMP] Allow only loop control variables in distribute simd directives. According to the OpenMP standard, only loop control variables can be used in linear claus

[PATCH] D40574: Bounds check argument_with_type_tag attribute.

2017-11-29 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. Thanks, LGTM! https://reviews.llvm.org/D40574 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin

[PATCH] D40621: MS ABI: Treat explicit instantiation definitions of dllimport function templates as explicit instantiation decls (PR35435)

2017-11-29 Thread Hans Wennborg via Phabricator via cfe-commits
hans created this revision. This matches MSVC's behaviour, and we already do it for class templates since r270897. https://reviews.llvm.org/D40621 Files: lib/Sema/SemaTemplate.cpp test/CodeGenCXX/dllimport.cpp Index: test/CodeGenCXX/dllimport.cpp =

[PATCH] D40611: Add has definition AST matcher

2017-11-29 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman closed this revision. aaron.ballman added a comment. Commit in r319360 https://reviews.llvm.org/D40611 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

r319360 - Add the hasDefinition() AST matcher to match class declarations that also have a definition.

2017-11-29 Thread Aaron Ballman via cfe-commits
Author: aaronballman Date: Wed Nov 29 13:21:51 2017 New Revision: 319360 URL: http://llvm.org/viewvc/llvm-project?rev=319360&view=rev Log: Add the hasDefinition() AST matcher to match class declarations that also have a definition. Patch by Julie Hockett. Modified: cfe/trunk/docs/LibASTMatc

[PATCH] D40611: Add has definition AST matcher

2017-11-29 Thread Julie Hockett via Phabricator via cfe-commits
juliehockett added a comment. That'd be great -- thank you! I did request commit rights, so hopefully I'll be able to do it myself next time. https://reviews.llvm.org/D40611 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm

[PATCH] D35894: [clangd] Code hover for Clangd

2017-11-29 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle added inline comments. Comment at: clangd/ClangdUnit.h:320 + +StringRef getDataBufferFromSourceRange(ParsedAST &AST, SourceRange SR, + Location L); I think this can be only in the source file, in a an anonymous name

[PATCH] D40618: [SourceLocations] Use stronger sort predicate to remove non-deterministic ordering

2017-11-29 Thread Mandeep Singh Grang via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rC319357: [SourceLocations] Use stronger sort predicate to remove non-deterministic… (authored by mgrang). Repository: rC Clang https://reviews.llvm.org/D40618 Files: tools/libclang/CIndex.cpp Index

[PATCH] D40618: [SourceLocations] Use stronger sort predicate to remove non-deterministic ordering

2017-11-29 Thread Mandeep Singh Grang via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL319357: [SourceLocations] Use stronger sort predicate to remove non-deterministic… (authored by mgrang). Changed prior to commit: https://reviews.llvm.org/D40618?vs=124798&id=124804#toc Repository: r

r319357 - [SourceLocations] Use stronger sort predicate to remove non-deterministic ordering

2017-11-29 Thread Mandeep Singh Grang via cfe-commits
Author: mgrang Date: Wed Nov 29 12:55:13 2017 New Revision: 319357 URL: http://llvm.org/viewvc/llvm-project?rev=319357&view=rev Log: [SourceLocations] Use stronger sort predicate to remove non-deterministic ordering Summary: This fixes the following failure uncovered by D39245: Clang :: Index/

[PATCH] D40611: Add has definition AST matcher

2017-11-29 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman accepted this revision. aaron.ballman added a comment. This revision is now accepted and ready to land. Aside from a minor commenting nit, LGTM! Do you need me to commit this on your behalf? (If so, I can take care of the commenting fix.) Comment at: include/clan

[PATCH] D40256: [ARM] disable FPU features when using soft floating point.

2017-11-29 Thread Eli Friedman via Phabricator via cfe-commits
efriedma accepted this revision. efriedma added a comment. This revision is now accepted and ready to land. LGTM https://reviews.llvm.org/D40256 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/c

[PATCH] D40563: [SemaCodeComplete] Allow passing out scope specifiers in qualified-id completions via completion context.

2017-11-29 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman added a comment. Could you please add a test? https://reviews.llvm.org/D40563 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D35894: [clangd] Code hover for Clangd

2017-11-29 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle added inline comments. Comment at: clangd/ClangdUnit.cpp:1135 +RawComment *RC = +AST.getASTContext().getRawCommentForDeclNoCache(LocationDecl); +if (RC) { Not sure why but I don't get the comments when I hover on "push_back"

[PATCH] D40618: [SourceLocations] Use stronger sort predicate to remove non-deterministic ordering

2017-11-29 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman accepted this revision. arphaman added a comment. This revision is now accepted and ready to land. Thanks, LGTM Repository: rC Clang https://reviews.llvm.org/D40618 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llv

[PATCH] D39627: Fix vtable not receiving hidden visibility when using push(visibility)

2017-11-29 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. You probably just need to pass a "-triple" flag so we don't use Windows mangling or something like that. Repository: rL LLVM https://reviews.llvm.org/D39627 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http:/

[PATCH] D40594: [InstCombine] miscompile of __builtin_fmod

2017-11-29 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. By many years of precedent, the "frem" instruction is supposed to match the C fmod(), as opposed to something else like the C99 remainder(); probably worth clarifying in LangRef. https://reviews.llvm.org/D40594 ___ cfe-co

Re: r319297 - Toolchain: Normalize dwarf, sjlj and seh eh

2017-11-29 Thread Martin Storsjö via cfe-commits
On Wed, 29 Nov 2017, Martell Malone via cfe-commits wrote: Thanks for letting me know Reid. I’ll in work and won’t be able to access the repo until lunch time. (~3 hours) Feel free to revert if it is not trivial. The easy fix might be to change to == x86_64 from != x86 For is Windows in the def

[PATCH] D40508: Replace long type names in IR with hashes

2017-11-29 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. In https://reviews.llvm.org/D40508#938854, @sepavloff wrote: > In https://reviews.llvm.org/D40508#938686, @rjmccall wrote: > > > In https://reviews.llvm.org/D40508#938675, @sepavloff wrote: > > > > > In https://reviews.llvm.org/D40508#938040, @rjmccall wrote: > > > > > >

[PATCH] D40618: [SourceLocations] Use stronger sort predicate to remove non-deterministic ordering

2017-11-29 Thread Mandeep Singh Grang via Phabricator via cfe-commits
mgrang added inline comments. Comment at: tools/libclang/CIndex.cpp:1028 SourceLocation L_B = B->getLocStart(); -assert(L_A.isValid() && L_B.isValid()); -return SM.isBeforeInTranslationUnit(L_A, L_B); +return L_A != L_B ? + SM.isBeforeInTranslationUnit(

Re: [llvm-dev] LLVM buildmaster is back to work now but two builders remain OFF

2017-11-29 Thread Greg Bedwell via cfe-commits
Hopefully these two should be good to re-enable as of r319330. -Greg On 29 November 2017 at 16:23, Greg Bedwell wrote: > > Two slaves remain off for now as they produce a lot of warnings and > their log files are way too big. > > I think https://reviews.llvm.org/D40603 will fix this issue. > >

[PATCH] D40618: [SourceLocations] Use stronger sort predicate to remove non-deterministic ordering

2017-11-29 Thread Mandeep Singh Grang via Phabricator via cfe-commits
mgrang created this revision. This fixes the following failure uncovered by https://reviews.llvm.org/D39245: Clang :: Index/getcursor-preamble.m Repository: rC Clang https://reviews.llvm.org/D40618 Files: tools/libclang/CIndex.cpp Index: tools/libclang/CIndex.cpp =

[PATCH] D40601: [XRay][clang] Introduce -fxray-always-emit-customevents

2017-11-29 Thread David Blaikie via Phabricator via cfe-commits
dblaikie accepted this revision. dblaikie added a comment. This revision is now accepted and ready to land. Not totally clear to me why this feature is desirable, but assume you've got use cases/reasons :) Comment at: clang/lib/Driver/XRayArgs.cpp:32-33 constexpr char XRayNev

[PATCH] D40568: design document for a hardware-assisted memory safety (HWAMS) tool, similar to AddressSanitizer

2017-11-29 Thread Kostya Serebryany via Phabricator via cfe-commits
kcc updated this revision to Diff 124797. kcc added a comment. rephrase the sources of asan overhead Repository: rC Clang https://reviews.llvm.org/D40568 Files: docs/TaggedAddressSanitizerDesign.rst Index: docs/TaggedAddressSanitizerDesign.rst =

[PATCH] D40568: design document for a hardware-assisted memory safety (HWAMS) tool, similar to AddressSanitizer

2017-11-29 Thread Evgenii Stepanov via Phabricator via cfe-commits
eugenis added inline comments. Comment at: docs/TaggedAddressSanitizerDesign.rst:22 +*quarantine* to find use-after-free. +The shadow, the redzones, and the quarantine are the +major sources of AddressSanitizer's memory overhead. kcc wrote: > davidxl wrote: > > W

[PATCH] D40527: [libclang] Record parsing invocation to a temporary file when requested by client

2017-11-29 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman updated this revision to Diff 124788. arphaman added a comment. - Capture OS only. - Guard toolchain path accessor with a mutex. Repository: rC Clang https://reviews.llvm.org/D40527 Files: include/clang-c/Index.h test/Index/record-parsing-invocation.c tools/c-index-test/c-inde

[PATCH] D40527: [libclang] Record parsing invocation to a temporary file when requested by client

2017-11-29 Thread Alex Lorenz via Phabricator via cfe-commits
arphaman marked an inline comment as done. arphaman added inline comments. Comment at: tools/libclang/CIndexer.cpp:131 + if (!File.empty()) +llvm::sys::fs::remove(File); +} jkorous-apple wrote: > Just a thought - since we are not propagating errors from cons

[PATCH] D40574: Bounds check argument_with_type_tag attribute.

2017-11-29 Thread Matt Davis via Phabricator via cfe-commits
mattd marked 6 inline comments as done. mattd added inline comments. Comment at: test/Sema/error-type-safety.cpp:3-4 + +static const int test_void + __attribute__((type_tag_for_datatype(test, void))) = 0; + aaron.ballman wrote: > Is this declaration necessary? H

[PATCH] D40569: Use default IR alignment for cleanup.dest.slot.

2017-11-29 Thread Jacob Young via Phabricator via cfe-commits
jacobly added a comment. Could someone commit this for me? Thanks. Repository: rC Clang https://reviews.llvm.org/D40569 ___ cfe-commits mailing list cfe-commits@lists.llvm.org http://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D40574: Bounds check argument_with_type_tag attribute.

2017-11-29 Thread Matt Davis via Phabricator via cfe-commits
mattd updated this revision to Diff 124783. mattd added a comment. - Removed the new lines. - Added white space between the data type and pointer character. - Updated the test to check the exact bounds, and over-bounds cases - Combined the diagnostic messages into one via 'select' https://revi

[PATCH] D40463: [analyzer] Fix false negative on post-increment of uninitialized variable.

2017-11-29 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun added inline comments. Comment at: lib/StaticAnalyzer/Checkers/UndefinedAssignmentChecker.cpp:64 +if (const UnaryOperator *U = dyn_cast(StoreE)) { + str = "The expression of the unary operator is an uninitialized value. " +"The computed value will a

r319336 - [clang-cl] Alias /wd4018 to -Wno-sign-compare

2017-11-29 Thread Reid Kleckner via cfe-commits
Author: rnk Date: Wed Nov 29 10:45:03 2017 New Revision: 319336 URL: http://llvm.org/viewvc/llvm-project?rev=319336&view=rev Log: [clang-cl] Alias /wd4018 to -Wno-sign-compare This warning is known to be noisy and projects frequently disable it. In particular, this should make building isl as bun

Re: r319297 - Toolchain: Normalize dwarf, sjlj and seh eh

2017-11-29 Thread Martell Malone via cfe-commits
Thanks for letting me know Reid. I’ll in work and won’t be able to access the repo until lunch time. (~3 hours) Feel free to revert if it is not trivial. The easy fix might be to change to == x86_64 from != x86 For is Windows in the default toolchain. That should restore the old behavior. I’m cur

[PATCH] D40463: [analyzer] Fix false negative on post-increment of uninitialized variable.

2017-11-29 Thread Roman Lebedev via Phabricator via cfe-commits
lebedev.ri added inline comments. Comment at: lib/StaticAnalyzer/Checkers/UndefinedAssignmentChecker.cpp:64 +if (const UnaryOperator *U = dyn_cast(StoreE)) { + str = "The expression of the unary operator is an uninitialized value. " +"The computed value will

[PATCH] D39279: Stringizing raw string literals containing newline

2017-11-29 Thread Taewook Oh via Phabricator via cfe-commits
twoh added a comment. @jkorous-apple Thanks for the comments! Yeah, I was thinking of O(lenght_of_string) approach, but considering the complicatedness of the implementation (I guess the real implementation would be a bit more complex than your pseudo implementation to handle quote and '\n\r' '

r319333 - [analyzer] Fix unreachable creating PathDiagnosticLocation with widen-loops=true

2017-11-29 Thread Devin Coughlin via cfe-commits
Author: dcoughlin Date: Wed Nov 29 10:25:37 2017 New Revision: 319333 URL: http://llvm.org/viewvc/llvm-project?rev=319333&view=rev Log: [analyzer] Fix unreachable creating PathDiagnosticLocation with widen-loops=true In the original design of the analyzer, it was assumed that a BlockEntrance does

[PATCH] D37187: [Analyzer] Fix Bug 25609 - Assertion UNREACHABLE: 'Unexpected ProgramPoint' with widen-loops=true

2017-11-29 Thread Devin Coughlin via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rL319333: [analyzer] Fix unreachable creating PathDiagnosticLocation with widen-loops=true (authored by dcoughlin). Changed prior to commit: https://reviews.llvm.org/D37187?vs=124549&id=124778#toc Reposi

[PATCH] D35894: [clangd] Code hover for Clangd

2017-11-29 Thread Marc-Andre Laperle via Phabricator via cfe-commits
malaperle added inline comments. Comment at: clangd/Protocol.h:453 +struct MarkedString { + /** + * MarkedString can be used to render human readable text. It is either a The doc should use /// like the others https://reviews.llvm.org/D35894 _

r319332 - [OPENMP] Do not allow `linear` clauses on non-simd distribute

2017-11-29 Thread Alexey Bataev via cfe-commits
Author: abataev Date: Wed Nov 29 10:20:04 2017 New Revision: 319332 URL: http://llvm.org/viewvc/llvm-project?rev=319332&view=rev Log: [OPENMP] Do not allow `linear` clauses on non-simd distribute directives. `linear` clause is not allowed on non-simd distribute-based directives. Removed: cfe

  1   2   >