[PATCH] D97182: [clang] fix cmake wrong variable name from RTLIBS to RTLIB

2021-02-21 Thread Philip Lassen via Phabricator via cfe-commits
philass created this revision. philass added a reviewer: chandlerc. Herald added a subscriber: mgorny. philass requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. RTSLIBS should instread be RTLIB if (CLANG_DEFAULT_UNWINDLIB STREQUAL "")

[PATCH] D96147: [SEMA] Added warn_decl_shadow support for structured bindings

2021-02-21 Thread Richard Smith - zygoloid via Phabricator via cfe-commits
rsmith added a comment. Hm, before we go forward with this: can we get a test for the "shadows a structured binding" case, please? You might also need to add a new case to the "declaration shadows ..." warning text. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D96147: [SEMA] Added warn_decl_shadow support for structured bindings

2021-02-21 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. Looks good, thanks! Do you need someone to commit this for you? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D96147/new/

LLVM buildmaster will be restarted soon

2021-02-21 Thread Galina Kistanova via cfe-commits
Hello everyone, LLVM buildmaster will be restarted in the nearest hour. Thanks Galina ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[PATCH] D97137: Bug fix of clang-format, the AlignConsecutiveDeclarations option doesn't handle pointer properly

2021-02-21 Thread Darwin Xu via Phabricator via cfe-commits
darwin added inline comments. Comment at: clang/lib/Format/WhitespaceManager.cpp:716-717 break; if (Next->isOneOf(TT_StartOfName, TT_FunctionDeclarationName, tok::kw_operator)) return false; Maybe

[PATCH] D96777: [clang][driver] Set the input type to Fortran when reading from stdin

2021-02-21 Thread Sourabh Singh Tomar via Phabricator via cfe-commits
SouraVX accepted this revision. SouraVX added a comment. This revision is now accepted and ready to land. Thanks! for the patch. This code touches some of the `clang` part, Anyway changes are pretty self-explanatory. I'll leave this one to you, if you want land it or wait from someone from

[PATCH] D97137: Bug fix of https://bugs.llvm.org/show_bug.cgi?id=49175

2021-02-21 Thread Darwin Xu via Phabricator via cfe-commits
darwin added a comment. In D97137#2577794 , @HazardyKnusperkeks wrote: > Just out of curiosity, in which language is `Const` used? For example it is C's macro. I found this issue in our C code. It has many macros and one function was defined like

[PATCH] D96976: [analyzer] Fix reinterpret_cast handling for pointer-to-member

2021-02-21 Thread Deep Majumder via Phabricator via cfe-commits
RedDocMD added a comment. @vsavchenko, could you please review this? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D96976/new/ https://reviews.llvm.org/D96976 ___ cfe-commits mailing list

[PATCH] D96838: Add GNU attribute 'retain'

2021-02-21 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. In D96838#2578127 , @rjmccall wrote: > In D96838#2578101 , @MaskRay wrote: > >> In D96838#2578097 , @rjmccall wrote: >> >>> In D96838#2578083

[PATCH] D96838: Add GNU attribute 'retain'

2021-02-21 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. In D96838#2578101 , @MaskRay wrote: > In D96838#2578097 , @rjmccall wrote: > >> In D96838#2578083 , @MaskRay wrote: >> >>> In D96838#2578073

[PATCH] D96838: Add GNU attribute 'retain'

2021-02-21 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. In D96838#2578097 , @rjmccall wrote: > In D96838#2578083 , @MaskRay wrote: > >> In D96838#2578073 , @rjmccall wrote: >> >>> GCC 11 hasn't been

[PATCH] D96838: Add GNU attribute 'retain'

2021-02-21 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. In D96838#2578083 , @MaskRay wrote: > In D96838#2578073 , @rjmccall wrote: > >> GCC 11 hasn't been released yet, so can we still engage with GCC about the >> semantics of this attribute?

[PATCH] D93594: [X86] Pass to transform amx intrinsics to scalar operation.

2021-02-21 Thread Pengfei Wang via Phabricator via cfe-commits
pengfei added inline comments. Comment at: llvm/lib/Target/X86/X86LowerAMXIntrinsics.cpp:490 + Instruction = *II++; + if (match(, m_Intrinsic()) || + match(, m_Intrinsic()) || Should be better to use ``` if (auto *Inst = dyn_cast&*II++)

[PATCH] D96838: Add GNU attribute 'retain'

2021-02-21 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. In D96838#2578073 , @rjmccall wrote: > GCC 11 hasn't been released yet, so can we still engage with GCC about the > semantics of this attribute? This is a very low-level attribute, and I don't > understand why it was made

[PATCH] D96838: Add GNU attribute 'retain'

2021-02-21 Thread John McCall via Phabricator via cfe-commits
rjmccall added a comment. GCC 11 hasn't been released yet, so can we still engage with GCC about the semantics of this attribute? This is a very low-level attribute, and I don't understand why it was made separate instead of just having `used` add the appropriate section flag on targets that

[PATCH] D97150: [clang-tidy] Simplify suspicious memset usage check

2021-02-21 Thread Nathan James via Phabricator via cfe-commits
njames93 accepted this revision. njames93 added inline comments. This revision is now accepted and ready to land. Comment at: clang-tools-extra/clang-tidy/bugprone/SuspiciousMemsetUsageCheck.cpp:39 - unless( - eachOf(hasArgument(0,

[PATCH] D97156: [ASTMatchers] Make Param functors variadic

2021-02-21 Thread Nathan James via Phabricator via cfe-commits
njames93 added a reviewer: klimek. njames93 requested changes to this revision. njames93 added a comment. This revision now requires changes to proceed. This change is going to break the dump_ast_matchers script. So that will need updating to ensure everything is all correct. Repository: rG

[PATCH] D97158: [ASTMatchers] Make nullPointerConstant usable at top-level

2021-02-21 Thread Nathan James via Phabricator via cfe-commits
njames93 added a comment. Won't this change require a regeneration of the documentation `clang/docs/tools/dump_ast_matchers.py` Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D97158/new/ https://reviews.llvm.org/D97158

[PATCH] D96838: Add GNU attribute 'retain'

2021-02-21 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay updated this revision to Diff 325336. MaskRay marked 5 inline comments as done. MaskRay edited the summary of this revision. MaskRay added a comment. Comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D96838/new/

[PATCH] D96838: Add GNU attribute 'retain'

2021-02-21 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added inline comments. Comment at: clang/include/clang/Basic/Attr.td:2655 + +def Retain : InheritableAttr { + let Spellings = [GCC<"retain">]; aaron.ballman wrote: > Should this be a target-specific attribute as it only has effects on ELF > targets? As

[PATCH] D97137: Bug fix of https://bugs.llvm.org/show_bug.cgi?id=49175

2021-02-21 Thread Björn Schäpers via Phabricator via cfe-commits
HazardyKnusperkeks added a comment. Just out of curiosity, in which language is `Const` used? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D97137/new/ https://reviews.llvm.org/D97137 ___ cfe-commits

[PATCH] D97161: Improve diagnostic for ignored GNU 'used' attribute

2021-02-21 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay created this revision. MaskRay added a reviewer: aaron.ballman. MaskRay requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D97161 Files:

[PATCH] D95745: Support unwinding from inline assembly

2021-02-21 Thread Paul via Phabricator via cfe-commits
cynecx updated this revision to Diff 325328. cynecx added a comment. clang-format CHANGES SINCE LAST ACTION https://reviews.llvm.org/D95745/new/ https://reviews.llvm.org/D95745 Files: clang/lib/Basic/TargetInfo.cpp clang/lib/CodeGen/CGStmt.cpp clang/lib/Sema/SemaStmtAsm.cpp

[PATCH] D95745: Support unwinding from inline assembly

2021-02-21 Thread Paul via Phabricator via cfe-commits
cynecx added a comment. @rnk This is ready for a proper review :) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D95745/new/ https://reviews.llvm.org/D95745 ___ cfe-commits mailing list

[PATCH] D95745: Support unwinding from inline assembly

2021-02-21 Thread Paul via Phabricator via cfe-commits
cynecx updated this revision to Diff 325323. cynecx edited the summary of this revision. cynecx added a comment. Herald added a subscriber: pengfei. Added tests and updated splitted patchset. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D95745/new/

[PATCH] D97158: [ASTMatchers] Make nullPointerConstant usable at top-level

2021-02-21 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added reviewers: aaron.ballman, njames93. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D97158 Files:

[PATCH] D97156: [ASTMatchers] Make Param functors variadic

2021-02-21 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 325319. steveire added a comment. Update comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D97156/new/ https://reviews.llvm.org/D97156 Files: clang/include/clang/ASTMatchers/ASTMatchers.h

[PATCH] D97156: [ASTMatchers] Make Param functors variadic

2021-02-21 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added a comment. This was part of an early attempt to implement `mapAnyOf`. It's not needed, but it seems like a better idea to have one variadic class than multiple Param1/2 classes. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D97156: [ASTMatchers] Make Param functors variadic

2021-02-21 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added reviewers: aaron.ballman, njames93. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D97156 Files:

[PATCH] D97137: Bug fix of https://bugs.llvm.org/show_bug.cgi?id=49175

2021-02-21 Thread MyDeveloperDay via Phabricator via cfe-commits
MyDeveloperDay added inline comments. Comment at: clang/unittests/Format/FormatTest.cpp:14261 + "unsigned int Const* c;", + Alignment); } can you test west const too? ``` Const unsigned int* c; const unsigned int* d; Const unsigned

[PATCH] D96838: Add GNU attribute 'retain'

2021-02-21 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/include/clang/Basic/Attr.td:2655 + +def Retain : InheritableAttr { + let Spellings = [GCC<"retain">]; Should this be a target-specific attribute as it only has effects on ELF targets?

[PATCH] D97153: [clang-tidy] Simplify boolean expr scheck

2021-02-21 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added reviewers: aaron.ballman, njames93. Herald added a subscriber: xazax.hun. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo

[PATCH] D97152: [clang-tidy] Simplify special member functions check

2021-02-21 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added reviewers: aaron.ballman, njames93. Herald added subscribers: kbarton, xazax.hun, nemanjai. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo

[PATCH] D97151: [clang-tidy] Simplify redundant branch condition check

2021-02-21 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added reviewers: aaron.ballman, njames93. Herald added a subscriber: xazax.hun. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo

[PATCH] D97150: [clang-tidy] Simplify suspicious memset usage check

2021-02-21 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added reviewers: aaron.ballman, njames93. Herald added a subscriber: xazax.hun. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo

[PATCH] D97149: [clang-tidy] Simplify suspicious enum usage check

2021-02-21 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added reviewers: aaron.ballman, njames93. Herald added a subscriber: xazax.hun. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo

[PATCH] D97147: [clang-tidy] Simplify redundant member init check

2021-02-21 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added reviewers: aaron.ballman, njames93. Herald added a subscriber: xazax.hun. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo

[PATCH] D97142: [clang-tidy] Simplify unused RAII check

2021-02-21 Thread Nathan James via Phabricator via cfe-commits
njames93 added inline comments. Comment at: clang-tools-extra/test/clang-tidy/checkers/bugprone-unused-raii.cpp:49-53 +struct CtorDefaultArg { + CtorDefaultArg(int i = 0); + ~CtorDefaultArg(); +}; + Its not obvious from the code, but this should work if there

[PATCH] D97145: [clang-tidy] Simplify default member init check

2021-02-21 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added reviewers: aaron.ballman, njames93. Herald added a subscriber: xazax.hun. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo

[PATCH] D97144: [clang-tidy] Simplify shrink to fit check

2021-02-21 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added reviewers: aaron.ballman, njames93. Herald added a subscriber: xazax.hun. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Repository: rG LLVM Github Monorepo

[PATCH] D97142: [clang-tidy] Simplify unused RAII check

2021-02-21 Thread Stephen Kelly via Phabricator via cfe-commits
steveire created this revision. steveire added reviewers: aaron.ballman, njames93. Herald added a subscriber: xazax.hun. steveire requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Fix handling of default construction where the constructor

[PATCH] D89065: [clang] Tweaked fixit for static assert with no message

2021-02-21 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 325287. njames93 added a comment. Add recompile test to ensure fix-its are correct Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D89065/new/ https://reviews.llvm.org/D89065 Files:

[PATCH] D96853: [clang][AVR] Support variable decorator '__flash'

2021-02-21 Thread Ben Shi via Phabricator via cfe-commits
benshi001 updated this revision to Diff 325286. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D96853/new/ https://reviews.llvm.org/D96853 Files: clang/include/clang/Basic/DiagnosticSemaKinds.td clang/lib/Basic/Targets/AVR.cpp clang/lib/CodeGen/TargetInfo.cpp

[PATCH] D96853: [clang][AVR] Support variable decorator '__flash'

2021-02-21 Thread Ben Shi via Phabricator via cfe-commits
benshi001 updated this revision to Diff 325285. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D96853/new/ https://reviews.llvm.org/D96853 Files: clang/include/clang/Basic/DiagnosticSemaKinds.td clang/lib/Basic/Targets/AVR.cpp clang/lib/CodeGen/TargetInfo.cpp

[PATCH] D97121: [clang-tidy] Add a single fix mode to clang-tidy

2021-02-21 Thread Nathan James via Phabricator via cfe-commits
njames93 created this revision. njames93 added reviewers: aaron.ballman, steveire. Herald added subscribers: usaxena95, kadircet, arphaman, kbarton, xazax.hun, nemanjai. njames93 updated this revision to Diff 325234. njames93 added a comment. njames93 updated this revision to Diff 325238.

[PATCH] D89065: [clang] Tweaked fixit for static assert with no message

2021-02-21 Thread Nathan James via Phabricator via cfe-commits
njames93 updated this revision to Diff 325284. njames93 added a comment. Add tests for fixits. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D89065/new/ https://reviews.llvm.org/D89065 Files: clang/lib/Parse/ParseDeclCXX.cpp

[PATCH] D97137: Bug fix of https://bugs.llvm.org/show_bug.cgi?id=49175

2021-02-21 Thread Marek Kurdej via Phabricator via cfe-commits
curdeius added a comment. Seems pretty ok at a first glance. I'll have a deeper look this week. Please update the revision title to something more comprehensible and move the bug link to the summary. Comment at: clang/unittests/Format/FormatTest.cpp:14257 + +

[PATCH] D89065: [clang] Tweaked fixit for static assert with no message

2021-02-21 Thread Nathan James via Phabricator via cfe-commits
njames93 added inline comments. Comment at: clang/lib/Parse/ParseDeclCXX.cpp:874 /// [C++0x] static_assert-declaration: /// static_assert ( constant-expression , string-literal ) ; /// aaron.ballman wrote: > xbolva00 wrote: > > Do we warn for: >

[PATCH] D96222: Handle uninstantiated templates in redundant get check

2021-02-21 Thread Stephen Kelly via Phabricator via cfe-commits
steveire added inline comments. Comment at: clang-tools-extra/clang-tidy/readability/RedundantSmartptrGetCheck.cpp:21-45 + return expr( + anyOf(cxxMemberCallExpr( + on(expr(anyOf(hasType(OnClass), +

[PATCH] D96222: [clang-tidy] Simplify redundant smartptr get check

2021-02-21 Thread Stephen Kelly via Phabricator via cfe-commits
steveire updated this revision to Diff 325283. steveire added a comment. Update Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D96222/new/ https://reviews.llvm.org/D96222 Files:

[PATCH] D97138: [Driver] replace argc_ with argc

2021-02-21 Thread Shao-Ce Sun via Phabricator via cfe-commits
achieveartificialintelligence created this revision. achieveartificialintelligence added reviewers: MaskRay, jhenderson, aganea, richard.barton.arm, sameeranjoshi. Herald added a reviewer: awarzynski. achieveartificialintelligence requested review of this revision. Herald added a project: clang.