[PATCH] D126780: [clang-tidy] `bugprone-use-after-move`: Fix handling of moves in lambda captures

2022-06-03 Thread Martin Böhme via Phabricator via cfe-commits
mboehme updated this revision to Diff 433972. mboehme added a comment. Added release notes. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126780/new/ https://reviews.llvm.org/D126780 Files: clang-tools-extra/clang-tidy/bugprone/UseAfterMoveCheck

[clang] 0d21863 - [Driver] Add multiarch path for RISC-V

2022-06-03 Thread Jonas Hahnfeld via cfe-commits
Author: Jonas Hahnfeld Date: 2022-06-03T09:10:34+02:00 New Revision: 0d2186373f73995cfcc45f445024fbc9841c99d6 URL: https://github.com/llvm/llvm-project/commit/0d2186373f73995cfcc45f445024fbc9841c99d6 DIFF: https://github.com/llvm/llvm-project/commit/0d2186373f73995cfcc45f445024fbc9841c99d6.diff

[PATCH] D126672: [Driver] Add multiarch path for RISC-V

2022-06-03 Thread Jonas Hahnfeld via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG0d2186373f73: [Driver] Add multiarch path for RISC-V (authored by Hahnfeld). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126672/new/ https://reviews.llvm.

[PATCH] D126780: [clang-tidy] `bugprone-use-after-move`: Fix handling of moves in lambda captures

2022-06-03 Thread Martin Böhme via Phabricator via cfe-commits
mboehme added a comment. In D126780#3552999 , @njames93 wrote: > LGTM, But please add a note to ReleaseNotes before landing. Thanks for reminding me! Done. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126

[PATCH] D126781: [CodeGen] Correctly handle weak symbols in the codegen

2022-06-03 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 433976. junaire added a comment. Update commit message Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126781/new/ https://reviews.llvm.org/D126781 Files: clang/lib/CodeGen/CodeGenModule.h clang/lib/CodeGen/

[clang-tools-extra] 8b90b25 - [clang-tidy] `bugprone-use-after-move`: Fix handling of moves in lambda captures

2022-06-03 Thread Martin Boehme via cfe-commits
Author: Martin Boehme Date: 2022-06-03T09:34:09+02:00 New Revision: 8b90b2539048a581052a4b0d7628ffba0cd582a9 URL: https://github.com/llvm/llvm-project/commit/8b90b2539048a581052a4b0d7628ffba0cd582a9 DIFF: https://github.com/llvm/llvm-project/commit/8b90b2539048a581052a4b0d7628ffba0cd582a9.diff

[PATCH] D126780: [clang-tidy] `bugprone-use-after-move`: Fix handling of moves in lambda captures

2022-06-03 Thread Martin Böhme via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG8b90b2539048: [clang-tidy] `bugprone-use-after-move`: Fix handling of moves in lambda captures (authored by mboehme). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llv

[PATCH] D119165: [clang-tidy] Add processing lambda captures at bugprone-use-after-move check

2022-06-03 Thread Martin Böhme via Phabricator via cfe-commits
mboehme added a comment. Note: https://reviews.llvm.org/D126780, which fixes the same bug as this patch, has now been landed. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D119165/new/ https://reviews.llvm.org/D119165 _

[PATCH] D126672: [Driver] Add multiarch path for RISC-V

2022-06-03 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. In D126672#3546782 , @Hahnfeld wrote: > In D126672#3546773 , @MaskRay wrote: > >> This needs a test. > > There are no tests for any of the other architectures. > >> Can Debian's riscv GCC

[PATCH] D124758: [analyzer] Implement assume in terms of assumeDual

2022-06-03 Thread Alex Brachet via Phabricator via cfe-commits
abrachet added a comment. As a heads up, because I'm not sure how often folks look at Github Issues. This patch causes a stack overflow on some Objective-C++ code. I have filed https://github.com/llvm/llvm-project/issues/55851. Could you take a look @martong? Repository: rG LLVM Github Mono

[clang] a459d1e - [clang][sema] Remove unused paramter from VerifyBitField

2022-06-03 Thread Timm Bäder via cfe-commits
Author: Timm Bäder Date: 2022-06-03T09:52:37+02:00 New Revision: a459d1eb2c779516652b3e6863cc3973d9bfbbef URL: https://github.com/llvm/llvm-project/commit/a459d1eb2c779516652b3e6863cc3973d9bfbbef DIFF: https://github.com/llvm/llvm-project/commit/a459d1eb2c779516652b3e6863cc3973d9bfbbef.diff LO

[clang] c698189 - [NFC] Format CGBuilder.h

2022-06-03 Thread Guillaume Chatelet via cfe-commits
Author: Guillaume Chatelet Date: 2022-06-03T07:54:01Z New Revision: c698189696d33e7304d94cd4212bd81818ea81a0 URL: https://github.com/llvm/llvm-project/commit/c698189696d33e7304d94cd4212bd81818ea81a0 DIFF: https://github.com/llvm/llvm-project/commit/c698189696d33e7304d94cd4212bd81818ea81a0.diff

[PATCH] D126903: [clang] Add support for __builtin_memset_inline

2022-06-03 Thread Guillaume Chatelet via Phabricator via cfe-commits
gchatelet updated this revision to Diff 433978. gchatelet added a comment. - Rebase over formatted CGBuilder.h Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126903/new/ https://reviews.llvm.org/D126903 Files: clang/docs/LanguageExtensions.rst

[PATCH] D126781: [CodeGen] Keep track info of lazy-emitted symbols in ModuleBuilder

2022-06-03 Thread Vassil Vassilev via Phabricator via cfe-commits
v.g.vassilev added a comment. In D126781#3554845 , @rjmccall wrote: > Okay, I understand. So, first off, I wouldn't really call that a "weak" > symbol rather than, say, a lazily-emitted symbol; "weak" already has plenty > of different senses, and we sh

[PATCH] D126891: [clang-tidy] The check should ignore final classes

2022-06-03 Thread Balázs Benics via Phabricator via cfe-commits
steakhal added a comment. In D126891#3554039 , @carlosgalvezp wrote: > Hmm, `MostDerived` **does** have a public virtual destructor in your example > already - if the base class destructor is virtual, the child class destructor > is virtual. In that se

[PATCH] D126891: [clang-tidy] The check should ignore final classes

2022-06-03 Thread Carlos Galvez via Phabricator via cfe-commits
carlosgalvezp added a comment. In D126891#3555456 , @steakhal wrote: > In D126891#3554039 , @carlosgalvezp > wrote: > >> Hmm, `MostDerived` **does** have a public virtual destructor in your example >> already -

[PATCH] D126891: [clang-tidy] The check should ignore final classes

2022-06-03 Thread Carlos Galvez via Phabricator via cfe-commits
carlosgalvezp added a comment. Oh, I see the unit test now, indeed `Base` does not have a virtual destructor. LGTM then! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126891/new/ https://reviews.llvm.org/D126891 __

[PATCH] D126891: [clang-tidy] The check should ignore final classes

2022-06-03 Thread Carlos Galvez via Phabricator via cfe-commits
carlosgalvezp added inline comments. Comment at: clang-tools-extra/docs/ReleaseNotes.rst:170 + ` involving + `final` classes. The check will not diagnose `final` marked classes, since + those cannot be used as base classes, consequently they can not violate the ---

[PATCH] D126903: [clang] Add support for __builtin_memset_inline

2022-06-03 Thread Guillaume Chatelet via Phabricator via cfe-commits
gchatelet updated this revision to Diff 433982. gchatelet added a comment. - Fix sema checking Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126903/new/ https://reviews.llvm.org/D126903 Files: clang/docs/LanguageExtensions.rst clang/include/cl

[PATCH] D126903: [clang] Add support for __builtin_memset_inline

2022-06-03 Thread Guillaume Chatelet via Phabricator via cfe-commits
gchatelet marked 2 inline comments as done. gchatelet added inline comments. Comment at: clang/lib/Sema/SemaChecking.cpp:2293-2315 + case Builtin::BI__builtin_memset_inline: { +if (checkArgCount(*this, TheCall, 3)) + return ExprError(); +auto ArgArrayConversionFaile

[clang-tools-extra] b50542f - [clang-tidy] Add missing close quote in release notes.

2022-06-03 Thread Martin Boehme via cfe-commits
Author: Martin Boehme Date: 2022-06-03T10:33:57+02:00 New Revision: b50542f21e95800ca1d49b50bddd8e91e0f256fc URL: https://github.com/llvm/llvm-project/commit/b50542f21e95800ca1d49b50bddd8e91e0f256fc DIFF: https://github.com/llvm/llvm-project/commit/b50542f21e95800ca1d49b50bddd8e91e0f256fc.diff

[PATCH] D126880: [clang-tidy] Add cppcoreguidelines-avoid-const-or-ref-data-members check

2022-06-03 Thread David Friberg via Phabricator via cfe-commits
dfrib added inline comments. Comment at: clang-tools-extra/test/clang-tidy/checkers/cppcoreguidelines-avoid-const-or-ref-data-members.cpp:25 + +struct RefMember { + int &r; Differentiate between lvalue reference and rvalue reference members using these terms i

[PATCH] D126891: [clang-tidy] The check should ignore final classes

2022-06-03 Thread Balázs Benics via Phabricator via cfe-commits
steakhal added inline comments. Comment at: clang-tools-extra/docs/ReleaseNotes.rst:170 + ` involving + `final` classes. The check will not diagnose `final` marked classes, since + those cannot be used as base classes, consequently they can not violate the car

[PATCH] D126903: [clang] Add support for __builtin_memset_inline

2022-06-03 Thread Clement Courbet via Phabricator via cfe-commits
courbet added inline comments. Comment at: clang/test/Sema/builtins-memcpy-inline.cpp:11 +void test_memcpy_inline_invalid_arg_types() { + __builtin_memcpy_inline(1, 2, 3); // expected-error {{cannot initialize a parameter of type 'void *' with an rvalue of type 'int'}} +} -

[PATCH] D126291: [flang][Driver] Update link job on windows

2022-06-03 Thread Diana Picus via Phabricator via cfe-commits
rovka updated this revision to Diff 433988. rovka added a comment. - Update for MinGW. - Add `/subsystem:console` to help `link.exe` understand what's going on. Thanks for all the comments. I don't have a MinGW environment readily available for testing. @mmuetzel Could you test this? Alternative

[PATCH] D126880: [clang-tidy] Add cppcoreguidelines-avoid-const-or-ref-data-members check

2022-06-03 Thread Carlos Galvez via Phabricator via cfe-commits
carlosgalvezp updated this revision to Diff 433989. carlosgalvezp marked 4 inline comments as done. carlosgalvezp added a comment. Fix review comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126880/new/ https://reviews.llvm.org/D126880 Files

[PATCH] D126880: [clang-tidy] Add cppcoreguidelines-avoid-const-or-ref-data-members check

2022-06-03 Thread Carlos Galvez via Phabricator via cfe-commits
carlosgalvezp added a comment. Fixed comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126880/new/ https://reviews.llvm.org/D126880 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://li

[PATCH] D112916: Confusable identifiers detection

2022-06-03 Thread serge via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGb94db7ed7eaf: [clang-tidy] Confusable identifiers detection (authored by serge-sans-paille). Changed prior to commit: https://reviews.llvm.org/D112916?vs=410776&id=433991#toc Repository: rG LLVM Gith

[PATCH] D126291: [flang][Driver] Update link job on windows

2022-06-03 Thread Markus Mützel via Phabricator via cfe-commits
mmuetzel added a comment. In D126291#356 , @rovka wrote: > - Update for MinGW. > - Add `/subsystem:console` to help `link.exe` understand what's going on. > > Thanks for all the comments. I don't have a MinGW environment readily > available for testi

[PATCH] D125479: [pseudo] Fix the incorrect parameters-and-qualifiers rule.

2022-06-03 Thread Haojian Wu via Phabricator via cfe-commits
hokein added a comment. friendly ping. Comment at: clang-tools-extra/pseudo/test/glr.cpp:37 + +void foo2(int, ...); +// CHECK: declaration~simple-declaration := decl-specifier-seq init-declarator-list ; since we have the builtin pseudoCXX library now, we

[PATCH] D112916: Confusable identifiers detection

2022-06-03 Thread Nico Weber via Phabricator via cfe-commits
thakis added a comment. I haven't checked, but this probably doesn't do the right thing in cross builds (eg building a Mac/arm binary on a Mac/Intel machine - i think the gen_confusables binary will likely end up being an arm binary then, and it won't be able to run during the build). See https

[PATCH] D126956: [tbaa] Handle base classes in struct tbaa

2022-06-03 Thread Bruno De Fraine via Phabricator via cfe-commits
brunodf created this revision. brunodf added reviewers: jeroen.dobbelaere, eli.friedman. Herald added a subscriber: kosarev. Herald added a project: All. brunodf requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This is a fix for the miscompi

[PATCH] D126291: [flang][Driver] Update link job on windows

2022-06-03 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. In D126291#391 , @mmuetzel wrote: > ISTR, I somewhere read that Windows isn't a supported host currently. Is this > no longer the case?) Windows is supported: https://lab.llvm.org/buildbot/#/builders/172 :) > If you coul

[PATCH] D125919: Drop qualifiers from return types in C (DR423)

2022-06-03 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D125919#3554599 , @rjmccall wrote: > Ah, true, the standard doesn't describe it as a normal qualifier. From the > DR, it sounds like the committee certainly expected that this reasoning would > also apply to `_Atomic`,

[PATCH] D125479: [pseudo] Fix the incorrect parameters-and-qualifiers rule.

2022-06-03 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/pseudo/test/glr.cpp:37 + +void foo2(int, ...); +// CHECK: declaration~simple-declaration := decl-specifier-seq init-declarator-l

[clang-tools-extra] 8df2b1a - [pp-trace] Print HashLoc in InclusionDirective callback

2022-06-03 Thread via cfe-commits
Author: CHIANG, YU-HSUN (Tommy Chiang, oToToT) Date: 2022-06-03T19:29:59+08:00 New Revision: 8df2b1a866800b41984bd7721b244a9821810764 URL: https://github.com/llvm/llvm-project/commit/8df2b1a866800b41984bd7721b244a9821810764 DIFF: https://github.com/llvm/llvm-project/commit/8df2b1a866800b41984bd

[PATCH] D125373: [pp-trace] Print HashLoc in InclusionDirective callback

2022-06-03 Thread Tommy Chiang via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG8df2b1a86680: [pp-trace] Print HashLoc in InclusionDirective callback (authored by oToToT). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D125373/new/ https:

[PATCH] D112916: Confusable identifiers detection

2022-06-03 Thread Nico Weber via Phabricator via cfe-commits
thakis added inline comments. Comment at: clang-tools-extra/clang-tidy/misc/ConfusableTable/build_confusable_table.cpp:55 + std::sort(Entries.begin(), Entries.end()); + errs() << "Parsed " << Entries.size() << " Entries\n"; + Could we not print this line? The

[clang-tools-extra] 180bae0 - [gn build] (manually) port b94db7ed7eaf (Confusables.inc)

2022-06-03 Thread Nico Weber via cfe-commits
Author: Nico Weber Date: 2022-06-03T07:49:28-04:00 New Revision: 180bae08a04d4dc724cb5e6f2ea9df8641a3f657 URL: https://github.com/llvm/llvm-project/commit/180bae08a04d4dc724cb5e6f2ea9df8641a3f657 DIFF: https://github.com/llvm/llvm-project/commit/180bae08a04d4dc724cb5e6f2ea9df8641a3f657.diff LO

[PATCH] D126759: [clang][dataflow] Model calls returning optionals

2022-06-03 Thread Stanislav Gatev via Phabricator via cfe-commits
sgatev updated this revision to Diff 434000. sgatev added a comment. Address comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126759/new/ https://reviews.llvm.org/D126759 Files: clang/lib/Analysis/FlowSensitive/Models/UncheckedOptionalAcc

[clang] 166f9be - Update old mailing list link in the nullability doc

2022-06-03 Thread Hans Wennborg via cfe-commits
Author: Hans Wennborg Date: 2022-06-03T14:23:41+02:00 New Revision: 166f9be330dd36e2ef27d4c0023b78b8257f0909 URL: https://github.com/llvm/llvm-project/commit/166f9be330dd36e2ef27d4c0023b78b8257f0909 DIFF: https://github.com/llvm/llvm-project/commit/166f9be330dd36e2ef27d4c0023b78b8257f0909.diff

[PATCH] D126189: [C++20][Modules] Build module static initializers per P1874R1.

2022-06-03 Thread Iain Sandoe via Phabricator via cfe-commits
iains updated this revision to Diff 434003. iains edited the summary of this revision. iains added a comment. rebased and updated previously, this was not doing the right thing for module implementation units which were being processed as if they were interfaces, so we've introduced a module imp

[PATCH] D126959: [C++20][Modules] Introduce an implementation module.

2022-06-03 Thread Iain Sandoe via Phabricator via cfe-commits
iains created this revision. Herald added a project: All. iains added reviewers: urnathan, ChuanqiXu. iains added a subscriber: clang-modules. iains published this revision for review. iains added a comment. Herald added a project: clang. Herald added a subscriber: cfe-commits. we need to distingu

[clang] 3472b6e - Updating more entries in the C DR Status page

2022-06-03 Thread Aaron Ballman via cfe-commits
Author: Aaron Ballman Date: 2022-06-03T08:29:06-04:00 New Revision: 3472b6eb0a70f6b3ae45078d79d1c5b350da9c24 URL: https://github.com/llvm/llvm-project/commit/3472b6eb0a70f6b3ae45078d79d1c5b350da9c24 DIFF: https://github.com/llvm/llvm-project/commit/3472b6eb0a70f6b3ae45078d79d1c5b350da9c24.diff

[PATCH] D124918: [clang-tidy] Add a new check for non-trivial unused variables.

2022-06-03 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel added a comment. Luca, Can you expand the description to give a better intuition as to what this check is finding that the diagnostic does not? The example is good, but it would be helpful if you could phrase the general rule being enforced. Similarly, that would be helpful in the doc

[PATCH] D126944: [Clang] Fix memory leak due to TemplateArgumentListInfo used in AST node.

2022-06-03 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/include/clang/AST/DeclTemplate.h:2776 void setTemplateArgsInfo(const TemplateArgumentListInfo &ArgsInfo); + void setTemplateArgsInfo(const ASTTemplateArgumentListInfo *ArgsInfo); Can we make it a prereq

[PATCH] D126937: Fix memleak in VarTemplateSpecializationDecl

2022-06-03 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D126937#3555243 , @browneee wrote: > I was also looking into fixing this: https://reviews.llvm.org/D126944 > > I'm not yet sure if my changes are correct. I did a review on https://reviews.llvm.org/D126944, but I'll let

[PATCH] D126960: [clang][sema] Unary not boolean to int conversion

2022-06-03 Thread Ashley Roll via Phabricator via cfe-commits
AshleyRoll created this revision. AshleyRoll added a reviewer: rsmith. Herald added a project: All. AshleyRoll requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. I have modifyed GetExprRange() to capture the promotion of boolean values to ints

[PATCH] D126818: Itanium ABI: Implement mangling for constrained friends

2022-06-03 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added a comment. In D126818#3554617 , @tahonermann wrote: > I wonder if I'm reading (temp.friend)p9` sentence 2 > correctly. Which of these > should it be parsed as? > > 1. A (friend function

[clang] 1896df1 - Correct the behavior of this test for non-Windows targets

2022-06-03 Thread Aaron Ballman via cfe-commits
Author: Aaron Ballman Date: 2022-06-03T09:00:05-04:00 New Revision: 1896df18cc5b588760f75cc2c21d64c772cf0e4c URL: https://github.com/llvm/llvm-project/commit/1896df18cc5b588760f75cc2c21d64c772cf0e4c DIFF: https://github.com/llvm/llvm-project/commit/1896df18cc5b588760f75cc2c21d64c772cf0e4c.diff

[PATCH] D126291: [flang][Driver] Update link job on windows

2022-06-03 Thread Markus Mützel via Phabricator via cfe-commits
mmuetzel added a comment. I checked out the LLVM repository from https://github.com/llvm/llvm-project.git and applied your patch with `patch -Np0 -i D126291.433988.patch`. After some failing attempts, I finally found a configuration for which building succeeded. I struggled with duplicate symbo

[PATCH] D126291: [flang][Driver] Update link job on windows

2022-06-03 Thread Diana Picus via Phabricator via cfe-commits
rovka added a comment. @mmuetzel Thanks for looking into this! I think since you're passing `-DCLANG_DEFAULT_RTLIB=compiler-rt`, you might indeed need to build compiler-rt (or at least the builtins part of it). FYI, I'll be out of office until Wednesday, but I'll definitely check all the comme

[PATCH] D112916: Confusable identifiers detection

2022-06-03 Thread Nico Weber via Phabricator via cfe-commits
thakis added a comment. This also makes clang-tidy crash for fairly normal inputs, see below. Comment at: clang-tools-extra/clang-tidy/misc/Homoglyph.cpp:84 + if (const auto *ND = Result.Nodes.getNodeAs("nameddecl")) { +StringRef NDName = ND->getName(); +auto &Mapped =

[clang-tools-extra] 88052fd - check_clang_tidy.py: Update run line to python3

2022-06-03 Thread Nico Weber via cfe-commits
Author: Nico Weber Date: 2022-06-03T09:28:09-04:00 New Revision: 88052fd241267a09a4e612505f589ae371b91398 URL: https://github.com/llvm/llvm-project/commit/88052fd241267a09a4e612505f589ae371b91398 DIFF: https://github.com/llvm/llvm-project/commit/88052fd241267a09a4e612505f589ae371b91398.diff LO

[PATCH] D112916: Confusable identifiers detection

2022-06-03 Thread Nico Weber via Phabricator via cfe-commits
thakis added a comment. Reverted in 371e6f8b7fb94c444083ba115fd8edf17d6ba05c for now. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112916/new/ https://reviews.llvm.org/D112916

[PATCH] D126291: [flang][Driver] Update link job on windows

2022-06-03 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. Thanks for checking @mmuetzel ! In D126291#3555780 , @mmuetzel wrote: > I ended up using these switches: > > cmake \ > -Sllvm \ > -Bbuild \ > -GNinja \ > -DCMAKE_INSTALL_PREFIX=pkg \ > -DCMAKE_C_COMPILER=

[PATCH] D126759: [clang][dataflow] Model calls returning optionals

2022-06-03 Thread Stanislav Gatev via Phabricator via cfe-commits
sgatev marked an inline comment as done. sgatev added inline comments. Comment at: clang/lib/Analysis/FlowSensitive/Models/UncheckedOptionalAccessModel.cpp:161 +auto possiblyAliasedOptionalType() { + return hasUnqualifiedDesugaredType( xazax.hun wrote: > Does

[PATCH] D126291: [flang][Driver] Update link job on windows

2022-06-03 Thread Martin Storsjö via Phabricator via cfe-commits
mstorsjo added a comment. In D126291#3555805 , @awarzynski wrote: > Like @rovka pointed out, skipping `CLANG_DEFAULT_RTLIB` should solve your > issue with missing libs Skipping that woulnd't help/work in the clang64 environment in msys2; there's no li

[clang] 65e710c - [clang][dataflow] Model calls returning optionals

2022-06-03 Thread Stanislav Gatev via cfe-commits
Author: Stanislav Gatev Date: 2022-06-03T13:38:22Z New Revision: 65e710c3fc036706ec20b357a1bfce9cbadf5705 URL: https://github.com/llvm/llvm-project/commit/65e710c3fc036706ec20b357a1bfce9cbadf5705 DIFF: https://github.com/llvm/llvm-project/commit/65e710c3fc036706ec20b357a1bfce9cbadf5705.diff LO

[PATCH] D126759: [clang][dataflow] Model calls returning optionals

2022-06-03 Thread Stanislav Gatev via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. sgatev marked an inline comment as done. Closed by commit rG65e710c3fc03: [clang][dataflow] Model calls returning optionals (authored by sgatev). Repository: rG LLVM

[PATCH] D126902: [Attributes] Remove AttrSyntax and migrate uses to AttributeCommonInfo::Syntax (NFC)

2022-06-03 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. LGTM aside from a request to switch to an assert. Thanks for this cleanup! Comment at: clang/utils/TableGen/ClangAttrEmitter.cpp:3368 + fn("C2x", C2x); + OS <

[PATCH] D126291: [flang][Driver] Update link job on windows

2022-06-03 Thread Markus Mützel via Phabricator via cfe-commits
mmuetzel added a comment. Thank you for the suggestions. In the meantime, I added `-DLLVM_ENABLE_PROJECTS="clang;compiler-rt;mlir;flang;llvm" -DCOMPILER_RT_USE_BUILTINS_LIBRARY=ON` to the compiler flags which seems to have advanced a bit further. Now, I get the following when trying to compile

[PATCH] D124918: [clang-tidy] Add a new check for non-trivial unused variables.

2022-06-03 Thread Andy Soffer via Phabricator via cfe-commits
asoffer added inline comments. Comment at: clang-tools-extra/clang-tidy/performance/UnusedNoSideEffectCheck.cpp:90 +if (!Op->isAssignmentOp()) { + markSideEffectFree(Op->getRHS()); +} Perhaps I'm not understanding precisely what `markSideEffectFree`

[PATCH] D126818: Itanium ABI: Implement mangling for constrained friends

2022-06-03 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. I'm a bit uneasy that this is implementing something that's not yet been accepted into the Itanium ABI document. That runs the risk of requiring an ABI break if the Itanium document changes directions before finalizing. Also, what should we be doing for the Micros

[PATCH] D126291: [flang][Driver] Update link job on windows

2022-06-03 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. Nice! In D126291#3555835 , @mmuetzel wrote: > Is this still a configuration error? No :) Clearly the following `if` block from `tools::addFortranRuntimeLibs` is not entered: if (TC.getTriple().isKnownWindowsMSVCEnvironmen

[PATCH] D126291: [flang][Driver] Update link job on windows

2022-06-03 Thread Markus Mützel via Phabricator via cfe-commits
mmuetzel added a comment. In D126291#3555848 , @awarzynski wrote: > Nice! > > In D126291#3555835 , @mmuetzel > wrote: > >> Is this still a configuration error? > > No :) Clearly the following `if` block from `to

[clang] efbf013 - Only issue warning for subtraction involving null pointers on live code paths

2022-06-03 Thread Jamie Schmeiser via cfe-commits
Author: Jamie Schmeiser Date: 2022-06-03T10:10:37-04:00 New Revision: efbf0136b4108692ddd1a852b3f5b232c10d2097 URL: https://github.com/llvm/llvm-project/commit/efbf0136b4108692ddd1a852b3f5b232c10d2097 DIFF: https://github.com/llvm/llvm-project/commit/efbf0136b4108692ddd1a852b3f5b232c10d2097.dif

[PATCH] D126816: Only issue warning for subtraction involving null pointers on live code paths

2022-06-03 Thread Jamie Schmeiser via Phabricator via cfe-commits
This revision was landed with ongoing or failed builds. This revision was automatically updated to reflect the committed changes. Closed by commit rGefbf0136b410: Only issue warning for subtraction involving null pointers on live code paths (authored by jamieschmeiser). Repository: rG LLVM Gith

[PATCH] D126864: [clang] Introduce -fstrict-flex-arrays for stricter handling of flexible arrays

2022-06-03 Thread Dávid Bolvanský via Phabricator via cfe-commits
xbolva00 added inline comments. Comment at: clang/docs/ClangCommandLineReference.rst:2624 +.. option:: -fstrict-flex-array + arrays Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126864/new/ https://reviews.llvm.

[PATCH] D126818: Itanium ABI: Implement mangling for constrained friends

2022-06-03 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added a comment. In D126818#3555843 , @aaron.ballman wrote: > I'm a bit uneasy that this is implementing something that's not yet been > accepted into the Itanium ABI document. That runs the risk of requiring an > ABI break if the Itanium do

[PATCH] D124762: [WinEHPrepare] Avoid truncation of EH funclets with GNUstep ObjC runtime

2022-06-03 Thread Stefan Gränitz via Phabricator via cfe-commits
sgraenitz updated this revision to Diff 434020. sgraenitz added a comment. Fix unchecked nullptr compiler crash and assertion Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D124762/new/ https://reviews.llvm.org/D124762 Files: clang/lib/CodeGen/CGC

[PATCH] D126291: [flang][Driver] Update link job on windows

2022-06-03 Thread Markus Mützel via Phabricator via cfe-commits
mmuetzel added a comment. I made this additional change: From 26cee469225e80ac9bae22ebb6e60d47373fc19d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Markus=20M=C3=BCtzel?= Date: Fri, 3 Jun 2022 16:23:47 +0200 Subject: [PATCH] MinGW --- clang/lib/Driver/ToolChains/MinGW.cpp | 7 +++

[PATCH] D124762: [WinEHPrepare] Avoid truncation of EH funclets with GNUstep ObjC runtime

2022-06-03 Thread Stefan Gränitz via Phabricator via cfe-commits
sgraenitz updated this revision to Diff 434023. sgraenitz added a comment. Herald added subscribers: jsji, pengfei. LLVM CodeGen: check that presence of bundle operands avoids truncation Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D124762/new/ htt

[PATCH] D124762: [WinEHPrepare] Avoid truncation of EH funclets with GNUstep ObjC runtime

2022-06-03 Thread Stefan Gränitz via Phabricator via cfe-commits
sgraenitz updated this revision to Diff 434024. sgraenitz added a comment. Clang frontend: check that 'funclet' bundle operands are emitted for Pre-ISel intrinsics Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D124762/new/ https://reviews.llvm.org/

[PATCH] D124918: [clang-tidy] Add a new check for non-trivial unused variables.

2022-06-03 Thread Luca Versari via Phabricator via cfe-commits
veluca93 marked 5 inline comments as done. veluca93 added a comment. In D124918#3555719 , @ymandel wrote: > Luca, > > Can you expand the description to give a better intuition as to what this > check is finding that the diagnostic does not? The example i

[PATCH] D124918: [clang-tidy] Add a new check for non-trivial unused variables.

2022-06-03 Thread Luca Versari via Phabricator via cfe-commits
veluca93 updated this revision to Diff 434026. veluca93 marked 3 inline comments as done. veluca93 added a comment. Respond to comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D124918/new/ https://reviews.llvm.org/D124918 Files: clang-tools

[PATCH] D126725: [pseudo] rename pseudo-gen -> clang-pseudo-gen. NFC

2022-06-03 Thread Nico Weber via Phabricator via cfe-commits
thakis added a comment. Renaming this seems like a great change to me fwiw :) Comment at: llvm/utils/gn/secondary/clang-tools-extra/pseudo/gen/BUILD.gn:1 -executable("pseudo-gen") { +executable("clang-pseudo-gen") { configs += [ "//llvm/utils/gn/build:clang_code" ] -

[PATCH] D126291: [flang][Driver] Update link job on windows

2022-06-03 Thread Markus Mützel via Phabricator via cfe-commits
mmuetzel added a comment. In case you don't receive notifications on edits. (Please forgive the noise if you do.) After applying this additional patch: From d74a276679778b943b1e2e50f5dd45f65c530252 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Markus=20M=C3=BCtzel?= Date: Fri, 3 Jun 2022 16:36

[PATCH] D126291: [flang][Driver] Update link job on windows

2022-06-03 Thread Markus Mützel via Phabricator via cfe-commits
mmuetzel added inline comments. Comment at: clang/lib/Driver/ToolChains/MSVC.cpp:140 +// defined in flang's runtime libraries. +if (TC.getTriple().isKnownWindowsMSVCEnvironment()) + CmdArgs.push_back("/subsystem:console"); Is the MSVC toolchain used

[PATCH] D124762: [WinEHPrepare] Avoid truncation of EH funclets with GNUstep ObjC runtime

2022-06-03 Thread Stefan Gränitz via Phabricator via cfe-commits
sgraenitz marked an inline comment as done. sgraenitz added a comment. My follow-up got delayed, because I hit another bug, which appears to be a regression in release 14. This is why I wrote the tests for release/13.x and I still have to port them back to mainline, so this is *not yet ready to

[PATCH] D124762: [WinEHPrepare] Avoid truncation of EH funclets with GNUstep ObjC runtime

2022-06-03 Thread Stefan Gränitz via Phabricator via cfe-commits
sgraenitz added a comment. For illustration, truncations look like this: F23303573: Screenshot 2022-06-02 at 15.35.19.png F23303572: Screenshot 2022-06-02 at 19.06.41.png Repository: rG LLVM Github Monorepo CHANGES

[PATCH] D126853: [clang-tidy] `bugprone-use-after-move`: Don't warn on self-moves.

2022-06-03 Thread Nathan James via Phabricator via cfe-commits
njames93 accepted this revision. njames93 added a comment. LGTM. I feel that this case should produce a warning akin to the no self assignment diagnostics, obviously nothing to do with this check though. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.or

[PATCH] D126719: [clang-cl] Add support for /kernel

2022-06-03 Thread Nico Weber via Phabricator via cfe-commits
thakis accepted this revision. thakis added a comment. This revision is now accepted and ready to land. Looking pretty good! Comment at: clang/lib/Driver/ToolChains/Clang.cpp:7620 + std::vector Arches = {"IA32"}; + SupportedArches.insert(Arches.begin(), Arches.end()

[PATCH] D126902: [Attributes] Remove AttrSyntax and migrate uses to AttributeCommonInfo::Syntax (NFC)

2022-06-03 Thread Leonard Grey via Phabricator via cfe-commits
lgrey updated this revision to Diff 434036. lgrey added a comment. Add assert CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126902/new/ https://reviews.llvm.org/D126902 Files: clang/include/clang/Basic/Attributes.h clang/lib/Basic/Attributes.cpp clang/lib/Lex/PPMacroExpansion.cpp

[PATCH] D126291: [flang][Driver] Update link job on windows

2022-06-03 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski added a comment. In D126291#3555966 , @mmuetzel wrote: > In case you don't receive notifications on edits. (Please forgive the noise > if you do.) That's not a problem at all! > After applying this additional patch (not the one in the previo

[PATCH] D126959: [C++20][Modules] Introduce an implementation module.

2022-06-03 Thread Tom Honermann via Phabricator via cfe-commits
tahonermann added a comment. > Implementation modules are never serialized (-emit-module-interface for an > implementation unit is diagnosed and rejected). Never? Or just not via -emit-module-interface? I would expect to be able to serialize via -emit-ast. Repository: rG LLVM Github Monorep

[PATCH] D126969: Allow use of an elaborated type specifier in a _Generic association in C++

2022-06-03 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman created this revision. aaron.ballman added reviewers: erichkeane, jyknight, clang-language-wg. Herald added a project: All. aaron.ballman requested review of this revision. Herald added a project: clang. Currently, Clang accepts this code in C mode (where the tag is required to be u

[PATCH] D126291: [flang][Driver] Update link job on windows

2022-06-03 Thread Markus Mützel via Phabricator via cfe-commits
mmuetzel added a comment. The error message I get without `-lc++`: ld.lld: error: undefined symbol: std::__1::mutex::lock() >>> referenced by libFortranRuntime.a(io-api.cpp.obj):(Fortran::runtime::io::IoStatementState* Fortran::runtime::io::BeginExternalListIO<(Fortran::runtime::io::Directi

[PATCH] D126864: [clang] Introduce -fstrict-flex-arrays for stricter handling of flexible arrays

2022-06-03 Thread serge via Phabricator via cfe-commits
serge-sans-paille updated this revision to Diff 434040. serge-sans-paille added a comment. Fix typo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126864/new/ https://reviews.llvm.org/D126864 Files: clang/docs/ClangCommandLineReference.rst clang/docs/ReleaseNotes.rst clang/include

[PATCH] D126959: [C++20][Modules] Introduce an implementation module.

2022-06-03 Thread Iain Sandoe via Phabricator via cfe-commits
iains added a comment. In D126959#3556074 , @tahonermann wrote: >> Implementation modules are never serialized (-emit-module-interface for an >> implementation unit is diagnosed and rejected). > > Never? Or just not via -emit-module-interface? I would e

[PATCH] D112916: Confusable identifiers detection

2022-06-03 Thread serge via Phabricator via cfe-commits
serge-sans-paille added a comment. Thanks @thakis for the post-commit review. I'll give it another try next week. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112916/new/ https://reviews.llvm.org/D112916 __

[clang] dd6bcdb - [Attributes] Remove AttrSyntax and migrate uses to AttributeCommonInfo::Syntax (NFC)

2022-06-03 Thread Leonard Grey via cfe-commits
Author: Leonard Grey Date: 2022-06-03T12:11:48-04:00 New Revision: dd6bcdbf21716c56d3defd7f4cacddc7befd5de1 URL: https://github.com/llvm/llvm-project/commit/dd6bcdbf21716c56d3defd7f4cacddc7befd5de1 DIFF: https://github.com/llvm/llvm-project/commit/dd6bcdbf21716c56d3defd7f4cacddc7befd5de1.diff

[PATCH] D126902: [Attributes] Remove AttrSyntax and migrate uses to AttributeCommonInfo::Syntax (NFC)

2022-06-03 Thread Leonard Grey via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGdd6bcdbf2171: [Attributes] Remove AttrSyntax and migrate uses to AttributeCommonInfo::Syntax… (authored by lgrey). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.o

[PATCH] D126969: Allow use of an elaborated type specifier in a _Generic association in C++

2022-06-03 Thread Erich Keane via Phabricator via cfe-commits
erichkeane added a comment. This mostly/all seems reasonable to me, and the diagnostics, while not perfect, are IMO a vast improvement. Comment at: clang/include/clang/Sema/DeclSpec.h:2068 case DeclaratorContext::TrailingReturnVar: +case DeclaratorContext::Association

[PATCH] D126972: [clang][dataflow] Modify optional-checker to handle type aliases.

2022-06-03 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel created this revision. ymandel added reviewers: xazax.hun, sgatev. Herald added subscribers: tschuett, steakhal, jeroen.dobbelaere, rnkovacs. Herald added a project: All. ymandel requested review of this revision. Herald added a project: clang. Previously, type aliases were not handled (an

[PATCH] D126972: [clang][dataflow] Modify optional-checker to handle type aliases.

2022-06-03 Thread Stanislav Gatev via Phabricator via cfe-commits
sgatev accepted this revision. sgatev added inline comments. This revision is now accepted and ready to land. Comment at: clang/unittests/Analysis/FlowSensitive/UncheckedOptionalAccessModelTest.cpp:2217 +// Verifies that the check sees through aliases. +TEST_P(UncheckedOptiona

[PATCH] D126972: [clang][dataflow] Modify optional-checker to handle type aliases.

2022-06-03 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel updated this revision to Diff 434048. ymandel marked an inline comment as done. ymandel added a comment. address comments Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D126972/new/ https://reviews.llvm.org/D126972 Files: clang/lib/Analysi

[PATCH] D126972: [clang][dataflow] Modify `optional` model to handle type aliases.

2022-06-03 Thread Gábor Horváth via Phabricator via cfe-commits
xazax.hun accepted this revision. xazax.hun added a comment. This patch looks good to me. On the other hand, I was wondering whether functions like this would be handled: pair f(); array g(); MyStructWithOptionals h(); And so on. In general, I wonder if it is a better approach to be able

[PATCH] D126973: [clang][dataflow] Relax assumption that `AggregateStorageLocations` correspond to struct type.

2022-06-03 Thread Yitzhak Mandelbaum via Phabricator via cfe-commits
ymandel created this revision. ymandel added reviewers: xazax.hun, sgatev. Herald added subscribers: tschuett, steakhal, rnkovacs. Herald added a project: All. ymandel requested review of this revision. Herald added a project: clang. Currently, when an `AggregateStorageLocation` is mapped to a `St

[PATCH] D126864: [clang] Introduce -fstrict-flex-arrays for stricter handling of flexible arrays

2022-06-03 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. Probably IsTailPaddedMemberArray() in SemaChecking.cpp and isFlexibleArrayMemberExpr() in CGExpr.cpp should also check for this flag. Not sure if there's anything else that does similar checks; the static analyzer has its own flag consider-single-element-arrays-as-fle

  1   2   3   >