[PATCH] D134544: [clang-cl] Implement /ZH: flag

2022-09-23 Thread Hans Wennborg via Phabricator via cfe-commits
hans accepted this revision. hans added a comment. This revision is now accepted and ready to land. lgtm Comment at: clang/include/clang/Basic/CodeGenOptions.h:106 + enum SrcHashAlgorithm { +CSK_MD5, +CSK_SHA1, thakis wrote: > hans wrote: > > what

[PATCH] D134410: [clang][CodeGen] Add noundef metadata to load instructions (preliminary)

2022-09-23 Thread John McIver via Phabricator via cfe-commits
jmciver added a comment. The following are results from test-suite execution. LHS is a main build (17dde371e773 ) and the RHS is main with patch applied. The `results-subset.txt` is absent of unit, micro, and torture tests.

[PATCH] D134513: [RISCV][Clang] Replace all undef value with poison

2022-09-23 Thread Craig Topper via Phabricator via cfe-commits
craig.topper accepted this revision. craig.topper added a comment. This revision is now accepted and ready to land. LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D134513/new/ https://reviews.llvm.org/D134513

[PATCH] D134513: [RISCV][Clang] Replace all undef value with poison

2022-09-23 Thread Craig Topper via Phabricator via cfe-commits
craig.topper added a comment. LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D134513/new/ https://reviews.llvm.org/D134513 ___ cfe-commits mailing list cfe-commits@lists.llvm.org

[PATCH] D134461: [Clang] Warn when trying to deferencing void pointers in C

2022-09-23 Thread Jun Zhang via Phabricator via cfe-commits
junaire updated this revision to Diff 462643. junaire added a comment. Address comments. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D134461/new/ https://reviews.llvm.org/D134461 Files: clang/docs/ReleaseNotes.rst

[PATCH] D134461: [Clang] Warn when trying to deferencing void pointers in C

2022-09-23 Thread Jun Zhang via Phabricator via cfe-commits
junaire added inline comments. Comment at: clang/test/C/drs/dr1xx.c:140 /* The behavior changed between C89 and C99. */ - (void)&*p; /* c89only-warning {{ISO C forbids taking the address of an expression of type 'void'}} */ + (void)&*p; /* c89only-warning {{ISO C forbids

[PATCH] D133801: Extraction of a matcher for an unused value from an expression from the bugprone-unused-return-value check

2022-09-23 Thread Bartłomiej Cieślar via Phabricator via cfe-commits
barcisz added inline comments. Comment at: clang-tools-extra/unittests/clang-tidy/MatchersTest.cpp:2 +#include "utils/Matchers.h" +#include "../../clang/unittests/ASTMatchers/ASTMatchersTest.h" + njames93 wrote: > kwk wrote: > > njames93 wrote: > > > @kwk I seem

[PATCH] D134550: [Clang] Make Clang driver suggest '-Xclang' for CC1 options passed to the driver

2022-09-23 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay accepted this revision. MaskRay added a comment. This revision is now accepted and ready to land. I think this is fine. Driver options take precedence and cc1 options cannot be suggested. If the user writes a cc1-only option without `-Xclang`, they likely have the particular need and

[PATCH] D86049: RFC: Implement optional exportable wrapper function generation for objc_direct methods.

2022-09-23 Thread Puyan Lotfi via Phabricator via cfe-commits
plotfi added inline comments. Comment at: clang/include/clang/Basic/Attr.td:2251-2256 +def ObjCDirectVisible : Attr { + let Spellings = [Clang<"objc_direct_visible">]; + let Subjects = SubjectList<[ObjCMethod], ErrorDiag>; + let LangOpts = [ObjC]; + let Documentation =

[PATCH] D102107: [OpenMP] Codegen aggregate for outlined function captures

2022-09-23 Thread Dhruva Chakrabarti via Phabricator via cfe-commits
dhruvachak added a comment. In D102107#3812946 , @jdoerfert wrote: > In D102107#3812582 , @dhruvachak > wrote: > >> In D102107#3812554 , @dhruvachak >> wrote: >> >>>

[PATCH] D53847: [C++2a] P0634r3: Down with typename!

2022-09-23 Thread Alan Zhao via Phabricator via cfe-commits
ayzhao added a comment. In D53847#3809072 , @erichkeane wrote: > I think this is on the right track, but would like to see more work done on > that fixme before we commit (or at least better understand what is causing > this). I'm afraid of what else

[PATCH] D53847: [C++2a] P0634r3: Down with typename!

2022-09-23 Thread Alan Zhao via Phabricator via cfe-commits
ayzhao marked an inline comment as done. ayzhao added inline comments. Comment at: clang/lib/Sema/SemaDecl.cpp:367 +// with this method returning a non-null ParsedType? +if (isa(CurContext)) + return nullptr; ayzhao wrote: > ayzhao

[PATCH] D53847: [C++2a] P0634r3: Down with typename!

2022-09-23 Thread Alan Zhao via Phabricator via cfe-commits
ayzhao updated this revision to Diff 462633. ayzhao added a comment. remove the hack for the test p2-2.cpp and patch in patch in D134578 which fixes the test Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D134578: Add missing `struct` keyword to the test p2-2.cpp

2022-09-23 Thread Alan Zhao via Phabricator via cfe-commits
ayzhao created this revision. Herald added a project: All. ayzhao requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. While working on D53847 , I noticed that this test would fail once we started recognizing

[PATCH] D102147: [Clang][Coroutines] Implement P2014R0 Option 1 behind -fcoroutines-aligned-alloc

2022-09-23 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen abandoned this revision. ychen added a comment. Herald added a subscriber: MaskRay. Herald added a project: All. 327141f was landed as an alternative. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D97915: [Coroutines] Handle overaligned frame allocation

2022-09-23 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen abandoned this revision. ychen added a comment. Herald added a project: All. 327141f is landed as an alternative. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D97915/new/

[PATCH] D102107: [OpenMP] Codegen aggregate for outlined function captures

2022-09-23 Thread Johannes Doerfert via Phabricator via cfe-commits
jdoerfert added a comment. In D102107#3812582 , @dhruvachak wrote: > In D102107#3812554 , @dhruvachak > wrote: > >> Updated llvm tests. The following 3 tests still fail: >> >> LLVM ::

[PATCH] D133993: [HLSL] Remove global ctor/dtor variable for non-lib profile.

2022-09-23 Thread Xiang Li via Phabricator via cfe-commits
python3kgae updated this revision to Diff 462624. python3kgae marked an inline comment as done. python3kgae added a comment. Rebase for allow SV_GroupIndex in lib profile Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D133993/new/

[PATCH] D53847: [C++2a] P0634r3: Down with typename!

2022-09-23 Thread Alan Zhao via Phabricator via cfe-commits
ayzhao marked 2 inline comments as done. ayzhao added inline comments. Comment at: clang/lib/Sema/SemaDecl.cpp:367 +// with this method returning a non-null ParsedType? +if (isa(CurContext)) + return nullptr; ayzhao wrote: > erichkeane

[PATCH] D134468: [Driver] Ignore -fmsc-version= -fms-compatibility-version= values smaller than 19

2022-09-23 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. I am not a Windows driver user. This patch is entirely motivated by Windows discussions in D131465 and I want to make `/std:` default rule simple (say, clang 16 uses C++17 for every mode for Windows). If the `-fno-threadsafe-statics`

[PATCH] D53847: [C++2a] P0634r3: Down with typename!

2022-09-23 Thread Alan Zhao via Phabricator via cfe-commits
ayzhao added inline comments. Comment at: clang/lib/Sema/SemaDecl.cpp:367 +// with this method returning a non-null ParsedType? +if (isa(CurContext)) + return nullptr; erichkeane wrote: > Hmm... this scares me quite a bit, I don't really

[PATCH] D133574: [C2x] reject type definitions in offsetof

2022-09-23 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik added a comment. LGTM but I will Aaron give the final approval. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D133574/new/ https://reviews.llvm.org/D133574 ___ cfe-commits mailing list

[PATCH] D134507: [Clang] add missing ClangABICompat check

2022-09-23 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. In D134507#3811488 , @probinson wrote: > Would this be clearer if the BEFORE-15/AFTER-15 test cases used the same > template construct? Currently they are different so it's hard to work out > the effect of the change. In

[PATCH] D134542: [Concepts] Recover properly from a RecoveryExpr in a concept

2022-09-23 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen accepted this revision as: ychen. ychen added a comment. This revision is now accepted and ready to land. LGTM. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D134542/new/ https://reviews.llvm.org/D134542 ___ cfe-commits mailing list

[PATCH] D134542: [Concepts] Recover properly from a RecoveryExpr in a concept

2022-09-23 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. In D134542#3812292 , @erichkeane wrote: > In D134542#3812211 , @ychen wrote: > >> The patch looks good. Two high-level questions: >> >> - Does the similar thing happen for class templates?

[PATCH] D134544: [clang-cl] Implement /ZH: flag

2022-09-23 Thread Nico Weber via Phabricator via cfe-commits
thakis updated this revision to Diff 462596. thakis added a comment. don't accidentally add a flag for this to the gcc-style driver CHANGES SINCE LAST ACTION https://reviews.llvm.org/D134544/new/ https://reviews.llvm.org/D134544 Files: clang/include/clang/Basic/CodeGenOptions.def

[PATCH] D134544: [clang-cl] Implement /ZH: flag

2022-09-23 Thread Nico Weber via Phabricator via cfe-commits
thakis added inline comments. Comment at: clang/test/CodeGen/debug-info-file-checksum.c:3 +// RUN: %S/Inputs/debug-info-file-checksum.c -o - | FileCheck %s +// RUN: %clang -emit-llvm -S -g -gcodeview -gsrc-hash-algorithm=md5 -x c \ +// RUN:

[PATCH] D134544: [clang-cl] Implement /ZH: flag

2022-09-23 Thread Nico Weber via Phabricator via cfe-commits
thakis added inline comments. Comment at: clang/test/CodeGen/debug-info-file-checksum.c:3 +// RUN: %S/Inputs/debug-info-file-checksum.c -o - | FileCheck %s +// RUN: %clang -emit-llvm -S -g -gcodeview -gsrc-hash-algorithm=md5 -x c \ +// RUN:

[PATCH] D53847: [C++2a] P0634r3: Down with typename!

2022-09-23 Thread Alan Zhao via Phabricator via cfe-commits
ayzhao updated this revision to Diff 462587. ayzhao marked an inline comment as done. ayzhao added a comment. address some more review comments + rebase Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D53847/new/ https://reviews.llvm.org/D53847

[PATCH] D131465: C++/ObjC++: switch to gnu++17 as the default standard

2022-09-23 Thread Mike Hommey via Phabricator via cfe-commits
glandium added a comment. In D131465#3812424 , @rnk wrote: > I think both driver share the logic for MSVC version detection, which checks > for cl.exe on PATH and looks at the registry if that fails. > > I think we should try to lean towards making this

[PATCH] D102107: [OpenMP] Codegen aggregate for outlined function captures

2022-09-23 Thread Dhruva Chakrabarti via Phabricator via cfe-commits
dhruvachak added a comment. In D102107#3812554 , @dhruvachak wrote: > Updated llvm tests. The following 3 tests still fail: > > LLVM :: Transforms/OpenMP/spmdization_constant_prop.ll > LLVM ::

[PATCH] D134544: [clang-cl] Implement /ZH: flag

2022-09-23 Thread Paul Robinson via Phabricator via cfe-commits
probinson added inline comments. Comment at: clang/test/CodeGen/debug-info-file-checksum.c:3 +// RUN: %S/Inputs/debug-info-file-checksum.c -o - | FileCheck %s +// RUN: %clang -emit-llvm -S -g -gcodeview -gsrc-hash-algorithm=md5 -x c \ +// RUN:

[PATCH] D102107: [OpenMP] Codegen aggregate for outlined function captures

2022-09-23 Thread Dhruva Chakrabarti via Phabricator via cfe-commits
dhruvachak updated this revision to Diff 462582. dhruvachak added a comment. Updated llvm tests. The following 3 tests still fail: LLVM :: Transforms/OpenMP/spmdization_constant_prop.ll LLVM :: Transforms/OpenMP/spmdization_guarding_two_reaching_kernels.ll LLVM ::

[PATCH] D134544: [clang-cl] Implement /ZH: flag

2022-09-23 Thread Nico Weber via Phabricator via cfe-commits
thakis added inline comments. Comment at: clang/include/clang/Basic/CodeGenOptions.def:344 +/// Set debug info source file hashing algorithm +ENUM_CODEGENOPT(DebugSrcHashAlgorithm, SrcHashAlgorithm, 2, CSK_MD5) hans wrote: > ultra nit: period. But maybe the

[PATCH] D102107: [OpenMP] Codegen aggregate for outlined function captures

2022-09-23 Thread Dhruva Chakrabarti via Phabricator via cfe-commits
dhruvachak reopened this revision. dhruvachak added a comment. This revision is now accepted and ready to land. This patch was reverted. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D102107/new/ https://reviews.llvm.org/D102107

[PATCH] D134020: [clang][Interp] Handle enums

2022-09-23 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik accepted this revision. shafik added a comment. This revision is now accepted and ready to land. LGTM Comment at: clang/test/AST/Interp/enums.cpp:25 + SIX = FIVE + 2, + +}; Maybe some edge case values for enumerators like `__INT_MAX__ *2U +1U`

[PATCH] D98438: Clang: Allow selecting the hash algorithm for file checksums in debug info.

2022-09-23 Thread Arlo Siemsen via Phabricator via cfe-commits
arlosi abandoned this revision. arlosi added a comment. Closing in favor of D134544 Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D98438/new/ https://reviews.llvm.org/D98438

[clang] a3becb3 - [clang][AMDGPU] Temporarily disable clang atomic fadd test for gfx90a

2022-09-23 Thread Petar Avramovic via cfe-commits
Author: Petar Avramovic Date: 2022-09-23T21:49:16+02:00 New Revision: a3becb333d7faae695e18728e9b8fa3a3579a240 URL: https://github.com/llvm/llvm-project/commit/a3becb333d7faae695e18728e9b8fa3a3579a240 DIFF:

[PATCH] D134556: [Clang][OpenMP] Fix run time crash when use_device_addr is used.

2022-09-23 Thread Alexey Bataev via Phabricator via cfe-commits
ABataev added inline comments. Comment at: clang/lib/CodeGen/CGOpenMPRuntime.cpp:8561-8617 for (const auto *Cl : Clauses) { const auto *C = dyn_cast(Cl); if (!C) continue; for (const auto L : C->component_lists()) {

[PATCH] D130131: [HLSL] CodeGen hlsl cbuffer/tbuffer.

2022-09-23 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added reviewers: rjmccall, efriedma. aaron.ballman added a comment. No additional comments from me, but I don't feel comfortable signing off on the codegen bits; adding some codegen code owners. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D134352: [AArch64] Add Neoverse V2 CPU support

2022-09-23 Thread Matt D. via Phabricator via cfe-commits
Matt added inline comments. Comment at: llvm/include/llvm/Support/AArch64TargetParser.def:239 +AARCH64_CPU_NAME("neoverse-v2", ARMV9A, FK_NEON_FP_ARMV8, false, + (AArch64::AEK_SVE | AArch64::AEK_SVE2 | AArch64::AEK_SSBS | + AArch64::AEK_FP16 |

[PATCH] D131465: C++/ObjC++: switch to gnu++17 as the default standard

2022-09-23 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added a comment. In D131465#3812387 , @aaron.ballman wrote: > Does `clang-cl` set the `-fms-compatibility` version? If so, then it seems > like we'd probably want to key it off `-fms-compatibility`? I think both driver share the logic for MSVC

[PATCH] D86049: RFC: Implement optional exportable wrapper function generation for objc_direct methods.

2022-09-23 Thread Puyan Lotfi via Phabricator via cfe-commits
plotfi added a comment. In D86049#3812068 , @ahatanak wrote: > In D86049#3806898 , @plotfi wrote: > >> 1. Do we change the existing visibility behavior of objc methods? Yes / No > > I don't think we want to change

[PATCH] D86049: RFC: Implement optional exportable wrapper function generation for objc_direct methods.

2022-09-23 Thread Puyan Lotfi via Phabricator via cfe-commits
plotfi added a comment. In D86049#3812068 , @ahatanak wrote: > In D86049#3806898 , @plotfi wrote: > >> 1. Do we change the existing visibility behavior of objc methods? Yes / No > > I don't think we want to change

[PATCH] D134453: Introduce the `AlwaysIncludeTypeForNonTypeTemplateArgument` into printing policy

2022-09-23 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added inline comments. Comment at: clang/include/clang/AST/PrettyPrinter.h:307 + /// decltype(s) will be printed as "S" if enabled and as "S<{1,2}>" if disabled, + /// regardless if PrintCanonicalTypes is enabled. + unsigned

[clang] 0d18815 - Fix GH57943: Friend constraint checker didn't handle null decls.

2022-09-23 Thread Erich Keane via cfe-commits
Author: Erich Keane Date: 2022-09-23T12:21:56-07:00 New Revision: 0d18815baf6dffa682b0966f311041cfc7d8ff6d URL: https://github.com/llvm/llvm-project/commit/0d18815baf6dffa682b0966f311041cfc7d8ff6d DIFF: https://github.com/llvm/llvm-project/commit/0d18815baf6dffa682b0966f311041cfc7d8ff6d.diff

[PATCH] D131465: C++/ObjC++: switch to gnu++17 as the default standard

2022-09-23 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D131465#3810070 , @hans wrote: >> If we're all using `clang` for the command, we'd all get the same behavior, >> right? There's no expectation that `clang` and `cl` behave the same way, >> that's what `clang-cl` is

[PATCH] D134550: [Clang] Make Clang driver suggest '-Xclang' for CC1 options passed to the driver

2022-09-23 Thread Joseph Huber via Phabricator via cfe-commits
jhuber6 added a comment. In D134550#3812369 , @aaron.ballman wrote: > This is a neat idea, but I think we should think about it carefully. In > general, `-Xclang` is not something we want to actively recommend users use, > so do we really want to make

[PATCH] D133586: [clang] initialize type qualifiers for FunctionNoProtoType

2022-09-23 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 minor coding style nit, thank you! Comment at: clang/include/clang/AST/Type.h:3897-3898 + return

[PATCH] D134544: [clang-cl] Implement /ZH: flag

2022-09-23 Thread Hans Wennborg via Phabricator via cfe-commits
hans added a comment. nice! Comment at: clang/include/clang/Basic/CodeGenOptions.def:344 +/// Set debug info source file hashing algorithm +ENUM_CODEGENOPT(DebugSrcHashAlgorithm, SrcHashAlgorithm, 2, CSK_MD5) ultra nit: period. But maybe the comment is

[PATCH] D134550: [Clang] Make Clang driver suggest '-Xclang' for CC1 options passed to the driver

2022-09-23 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. This is a neat idea, but I think we should think about it carefully. In general, `-Xclang` is not something we want to actively recommend users use, so do we really want to make it easier for users to use? One potential problem that could be caused by this change

[PATCH] D134542: [Concepts] Recover properly from a RecoveryExpr in a concept

2022-09-23 Thread Erich Keane via Phabricator via cfe-commits
erichkeane updated this revision to Diff 462568. erichkeane added a comment. Changes as suggested by @ychen. Thanks! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D134542/new/ https://reviews.llvm.org/D134542 Files: clang/docs/ReleaseNotes.rst clang/include/clang/AST/ASTConcept.h

[PATCH] D134546: [clang-offload-bundler] extracting compatible bundle entry

2022-09-23 Thread Artem Belevich via Phabricator via cfe-commits
tra added inline comments. Comment at: clang/lib/Driver/OffloadBundler.cpp:1008 +auto Output = Worklist.begin(); +for (auto E = Worklist.end(); Output != E; Output++) { + if (isCodeObjectCompatible( saiislam wrote: > tra wrote: > > The patch

[clang] b1926f3 - Restore "[MemProf] Memprof profile matching and annotation"

2022-09-23 Thread Teresa Johnson via cfe-commits
Author: Teresa Johnson Date: 2022-09-23T11:38:47-07:00 New Revision: b1926f308f0939b365ee4940c7b1bd984b45e71a URL: https://github.com/llvm/llvm-project/commit/b1926f308f0939b365ee4940c7b1bd984b45e71a DIFF:

[PATCH] D134542: [Concepts] Recover properly from a RecoveryExpr in a concept

2022-09-23 Thread Erich Keane via Phabricator via cfe-commits
erichkeane marked 2 inline comments as done. erichkeane added a comment. In D134542#3812292 , @erichkeane wrote: > In D134542#3812211 , @ychen wrote: > >> The patch looks good. Two high-level questions: >> >> -

[PATCH] D128142: [MemProf] Memprof profile matching and annotation

2022-09-23 Thread Teresa Johnson via Phabricator via cfe-commits
tejohnson marked an inline comment as done. tejohnson added inline comments. Comment at: llvm/lib/Transforms/Instrumentation/PGOInstrumentation.cpp:1247 +uint32_t Column) { + return hash_combine(Function, LineOffset, Column); +}

[PATCH] D134544: [clang-cl] Implement /ZH: flag

2022-09-23 Thread Nico Weber via Phabricator via cfe-commits
thakis added a comment. In D134544#3811867 , @probinson wrote: > Probably we should reject the -gsrc... option if we're emitting DWARF, which > requires MD5 (at least so far). It's a cc1 option. As those aren't considered user facing, we don't do a lot

[PATCH] D134542: [Concepts] Recover properly from a RecoveryExpr in a concept

2022-09-23 Thread Erich Keane via Phabricator via cfe-commits
erichkeane marked 3 inline comments as done. erichkeane added a subscriber: tahonermann. erichkeane added a comment. In D134542#3812211 , @ychen wrote: > The patch looks good. Two high-level questions: > > - Does the similar thing happen for class

[PATCH] D134556: [Clang][OpenMP] Fix run time crash when use_device_addr is used.

2022-09-23 Thread Jennifer Yu via Phabricator via cfe-commits
jyu2 created this revision. jyu2 added reviewers: ABataev, jdoerfert, mikerice. jyu2 added a project: OpenMP. Herald added subscribers: guansong, yaxunl. Herald added a project: All. jyu2 requested review of this revision. Herald added subscribers: openmp-commits, cfe-commits, sstefan1. Herald

[PATCH] D134542: [Concepts] Recover properly from a RecoveryExpr in a concept

2022-09-23 Thread Yuanfang Chen via Phabricator via cfe-commits
ychen added a comment. The patch looks good. Two high-level questions: - Does the similar thing happen for class templates? Like a constraint expr of a partial specialization has an error. Maybe we don't assert in this case? - I suppose the constraint error does not always affect the overload

[PATCH] D134546: [clang-offload-bundler] extracting compatible bundle entry

2022-09-23 Thread Saiyedul Islam via Phabricator via cfe-commits
saiislam added a comment. The patch looks fine to me. Please wait for @tra 's final review. On a different note, can this compatibility testing logic be moved to a llvm library instead of clang's? I want to use it in OpenMP's AMDGPU plugin, which now links llvm libraries by default.

[PATCH] D134453: Introduce the `AlwaysIncludeTypeForNonTypeTemplateArgument` into printing policy

2022-09-23 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/include/clang/AST/PrettyPrinter.h:307 + /// decltype(s) will be printed as "S" if enabled and as "S<{1,2}>" if disabled, + /// regardless if PrintCanonicalTypes is enabled. + unsigned

[PATCH] D133705: [HIP] Fix unbundling archive

2022-09-23 Thread Artem Belevich via Phabricator via cfe-commits
tra accepted this revision. tra added inline comments. Comment at: clang/lib/Driver/Driver.cpp:2907-2908 +// which are not object files. Files with extension ".lib" is classified +// as TY_Object but they are actually archives, therefore should not be +

[PATCH] D133801: Extraction of a matcher for an unused value from an expression from the bugprone-unused-return-value check

2022-09-23 Thread Nathan James via Phabricator via cfe-commits
njames93 added inline comments. Comment at: clang-tools-extra/unittests/clang-tidy/MatchersTest.cpp:2 +#include "utils/Matchers.h" +#include "../../clang/unittests/ASTMatchers/ASTMatchersTest.h" + kwk wrote: > njames93 wrote: > > @kwk I seem to recall you saying

[PATCH] D134456: [PGO] Consider parent context when weighing branches with likelyhood.

2022-09-23 Thread Mark de Wever via Phabricator via cfe-commits
Mordante added a comment. When I implemented P0479R5 I didn't look at earlier revisions of the paper. I'm a bit surprised to see revision 2 had a lot more information. (At that time I was less familiar with WG21 papers, so I didn't consider looking at older papers or notice the missing

[PATCH] D134546: [clang-offload-bundler] extracting compatible bundle entry

2022-09-23 Thread Artem Belevich via Phabricator via cfe-commits
tra added inline comments. Comment at: clang/lib/Driver/OffloadBundler.cpp:1008 +auto Output = Worklist.begin(); +for (auto E = Worklist.end(); Output != E; Output++) { + if (isCodeObjectCompatible( The patch description implies that there are at

[PATCH] D134454: [Driver][Distro] Fix ArchLinux triplet and sysroot detection

2022-09-23 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers added a comment. Is it worth contacting the package maintainer for LLVM+clang for Arch-Linux in regards to this patch? Comment at: clang/lib/Driver/Distro.cpp:210 + // Sometimes the OS can't be detected from the triplet due to ambiguity, for + // eg.

[PATCH] D134235: [clang-doc] Clean up *Info constructors.

2022-09-23 Thread Brett Wilson via Phabricator via cfe-commits
brettw added inline comments. Comment at: clang-tools-extra/clang-doc/Representation.h:202 + bool IsFileInRootDir = false) : LineNumber(LineNumber), Filename(std::move(Filename)), IsFileInRootDir(IsFileInRootDir) {} paulkirth wrote: >

[PATCH] D86049: RFC: Implement optional exportable wrapper function generation for objc_direct methods.

2022-09-23 Thread Akira Hatanaka via Phabricator via cfe-commits
ahatanak added a comment. In D86049#3806898 , @plotfi wrote: > 1. Do we change the existing visibility behavior of objc methods? Yes / No I don't think we want to change the existing visibility behavior of non-direct objc methods. Is there a use reason

[PATCH] D134550: [Clang] Make Clang driver suggest '-Xclang' for CC1 options passed to the driver

2022-09-23 Thread Joseph Huber via Phabricator via cfe-commits
jhuber6 created this revision. jhuber6 added reviewers: MaskRay, aaron.ballman. Herald added a subscriber: StephenFan. Herald added a project: All. jhuber6 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. This patch adds an additional check

[PATCH] D134224: [clang][modules][deps] Report modulemaps describing excluded headers

2022-09-23 Thread Steven Johnson via Phabricator via cfe-commits
srj added a comment. This change has broken x86-32 builds, at least on Linux. /usr/local/google/home/srj/GitHub/llvm-project/16/llvm/include/llvm/ADT/PointerIntPair.h:136:25: error: static assertion failed: PointerIntPair with integer size too large for pointer 136 |

[PATCH] D134468: [Driver] Ignore -fmsc-version= -fms-compatibility-version= values smaller than 19

2022-09-23 Thread Tobias Hieta via Phabricator via cfe-commits
thieta added a comment. I think we should define a policy for this. I doubt we have many users on these older versions but I think maybe we should give deprecation messages for at least one release before we drop it? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D132379: [Support] Class for response file expansion

2022-09-23 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff added inline comments. Comment at: llvm/include/llvm/Support/CommandLine.h:2098 +public: + ExpansionContext(StringSaver , TokenizerCallback T, + llvm::vfs::FileSystem *FS = nullptr); rnk wrote: > StringSaver is a stateless class that

[PATCH] D132379: [Support] Class for response file expansion

2022-09-23 Thread Serge Pavlov via Phabricator via cfe-commits
sepavloff updated this revision to Diff 462528. sepavloff added a comment. Address reviewer's notes - Pass BumpPtrAllocator instead of StringSaver, - Use setter to specify file system object. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D134549: [clang] Add fix-it note to defaulted-function-deleted warning

2022-09-23 Thread Nathan James via Phabricator via cfe-commits
njames93 created this revision. njames93 added a reviewer: aaron.ballman. Herald added a subscriber: martong. Herald added a reviewer: shafik. Herald added a project: All. njames93 requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Adds a fix

[PATCH] D133586: [clang] initialize type qualifiers for FunctionNoProtoType

2022-09-23 Thread Richard Howell via Phabricator via cfe-commits
rmaz updated this revision to Diff 462518. rmaz added a comment. Remove unnecessary friend class Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D133586/new/ https://reviews.llvm.org/D133586 Files: clang/include/clang/AST/Type.h

[PATCH] D134468: [Driver] Ignore -fmsc-version= -fms-compatibility-version= values smaller than 19

2022-09-23 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a reviewer: clang-vendors. aaron.ballman added a subscriber: andrew.w.kaylor. aaron.ballman added a comment. Adding clang-vendors for awareness as this has the potential to impact folks vending clang. In D134468#3811882 , @probinson

[PATCH] D131465: C++/ObjC++: switch to gnu++17 as the default standard

2022-09-23 Thread Paul Robinson via Phabricator via cfe-commits
probinson added a comment. > The number of people likely to notice that PS4 is different from the other > targets seems far smaller than the number of people noticing the same for > Windows. But I've got no data to back that up, either. heh. There's a PS4 bot that notices. But the PS4

[PATCH] D134546: [clang-offload-bundler] extracting compatible bundle entry

2022-09-23 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl created this revision. yaxunl added reviewers: tra, saiislam, lamb-j. Herald added a project: All. yaxunl requested review of this revision. Herald added subscribers: sstefan1, MaskRay. Herald added a reviewer: jdoerfert. In HIP a library is usually compiled with default target ID e.g.

[PATCH] D134456: [PGO] Consider parent context when weighing branches with likelyhood.

2022-09-23 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D134456#3810769 , @serge-sans-paille wrote: > Shouldn't this be a situation where `-Wmisexpect` shold / could trigger? If we're going to let PGO override what the user explicitly wrote in their code, we definitely

[PATCH] D134468: [Driver] Ignore -fmsc-version= -fms-compatibility-version= values smaller than 19

2022-09-23 Thread Paul Robinson via Phabricator via cfe-commits
probinson added a comment. These kinds of compatibility changes generally should get a Discourse post for better visibility. Comment at: clang/docs/ReleaseNotes.rst:85 + a version smaller than ``19.0`` is now unsupported. + Or words to that effect. "19.0"

[PATCH] D98438: Clang: Allow selecting the hash algorithm for file checksums in debug info.

2022-09-23 Thread Paul Robinson via Phabricator via cfe-commits
probinson added a comment. So this one can be marked abandoned? You might need to commandeer it first. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D98438/new/ https://reviews.llvm.org/D98438 ___

[PATCH] D134544: [clang-cl] Implement /ZH: flag

2022-09-23 Thread Paul Robinson via Phabricator via cfe-commits
probinson added a project: debug-info. probinson added a comment. Probably we should reject the -gsrc... option if we're emitting DWARF, which requires MD5 (at least so far). CHANGES SINCE LAST ACTION https://reviews.llvm.org/D134544/new/ https://reviews.llvm.org/D134544

[PATCH] D133574: [C2x] reject type definitions in offsetof

2022-09-23 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added inline comments. Comment at: clang/include/clang/Basic/DiagnosticSemaKinds.td:1650 +def err_type_defined_in_offsetof : Error< + "%0 cannot be defined in '__builtin_offsetof'">; inclyc wrote: > aaron.ballman wrote: > > inclyc wrote: > > >

[PATCH] D133574: [C2x] reject type definitions in offsetof

2022-09-23 Thread YingChi Long via Phabricator via cfe-commits
inclyc added inline comments. Comment at: clang/include/clang/Basic/DiagnosticSemaKinds.td:1650 +def err_type_defined_in_offsetof : Error< + "%0 cannot be defined in '__builtin_offsetof'">; aaron.ballman wrote: > inclyc wrote: > > aaron.ballman wrote: > > >

[PATCH] D134544: [clang-cl] Implement /ZH: flag

2022-09-23 Thread Nico Weber via Phabricator via cfe-commits
thakis updated this revision to Diff 462503. thakis added a comment. tweak CHANGES SINCE LAST ACTION https://reviews.llvm.org/D134544/new/ https://reviews.llvm.org/D134544 Files: clang/include/clang/Basic/CodeGenOptions.def clang/include/clang/Basic/CodeGenOptions.h

[PATCH] D131963: [libc++] Add custom clang-tidy checks

2022-09-23 Thread Louis Dionne via Phabricator via cfe-commits
ldionne accepted this revision. ldionne added subscribers: smeenai, beanz. ldionne added a comment. This revision is now accepted and ready to land. I'd be fine with this as-is if it works in the CI. IIUC, the current blocker for this is that the `ClangConfig.cmake` installed by LLVM is not

[PATCH] D133574: [C2x] reject type definitions in offsetof

2022-09-23 Thread Aaron Ballman via Phabricator via cfe-commits
aaron.ballman added a comment. In D133574#3811496 , @inclyc wrote: > Emm, is it necessary to add a `LangOpts` check so that this change only > applies to c2x? If clang was invoked without `-std=c2x`, should we just > accept `offsetof` with definitions?

[clang] d20f9f8 - [Docs] [HLSL] Add IR reference for HLSL

2022-09-23 Thread Chris Bieneman via cfe-commits
Author: Chris Bieneman Date: 2022-09-23T10:29:54-05:00 New Revision: d20f9f8d2177cd02184bb2c2794af398ba355f61 URL: https://github.com/llvm/llvm-project/commit/d20f9f8d2177cd02184bb2c2794af398ba355f61 DIFF:

[PATCH] D134304: [Docs] [HLSL] Add IR reference for HLSL

2022-09-23 Thread Chris Bieneman via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGd20f9f8d2177: [Docs] [HLSL] Add IR reference for HLSL (authored by beanz). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D134304/new/

[PATCH] D98438: Clang: Allow selecting the hash algorithm for file checksums in debug info.

2022-09-23 Thread Nico Weber via Phabricator via cfe-commits
thakis added a comment. Herald added a subscriber: MaskRay. Herald added a project: All. I addressed pending comments, did some other minor tweaks, and uploaded the modified diff to D134544 . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION

[PATCH] D134544: [clang-cl] Implement /ZH: flag

2022-09-23 Thread Nico Weber via Phabricator via cfe-commits
thakis created this revision. thakis added a reviewer: hans. Herald added a project: All. thakis requested review of this revision. Herald added a subscriber: MaskRay. Based on a patch by Arlo Siemsen (D98438 )! https://reviews.llvm.org/D134544 Files:

[PATCH] D134542: [Concepts] Recover properly from a RecoveryExpr in a concept

2022-09-23 Thread Erich Keane via Phabricator via cfe-commits
erichkeane created this revision. erichkeane added a reviewer: clang-language-wg. Herald added a project: All. erichkeane requested review of this revision. Discovered by reducing a different problem, we currently assert because we failed to make the constraint expressions not dependent, since a

[PATCH] D134416: Allow getting template args for ClassTemplateSpecializations

2022-09-23 Thread Aaron Ballman via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGe8c78d8528a6: Allow getting template args for ClassTemplateSpecializations (authored by anderslanglands, committed by aaron.ballman). Changed prior to commit:

[clang] e8c78d8 - Allow getting template args for ClassTemplateSpecializations

2022-09-23 Thread Aaron Ballman via cfe-commits
Author: Anders Langlands Date: 2022-09-23T11:06:14-04:00 New Revision: e8c78d8528a6b7a96c93ea42749a3c0a03cd9b08 URL: https://github.com/llvm/llvm-project/commit/e8c78d8528a6b7a96c93ea42749a3c0a03cd9b08 DIFF:

[PATCH] D133586: [clang] initialize type qualifiers for FunctionNoProtoType

2022-09-23 Thread Richard Howell via Phabricator via cfe-commits
rmaz updated this revision to Diff 462483. rmaz added a comment. Return default Qualifiers for FunctionNoProtoType Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D133586/new/ https://reviews.llvm.org/D133586 Files: clang/include/clang/AST/Type.h

[PATCH] D134157: [Clang][LoongArch] Add inline asm support for constraints f/l/I/K

2022-09-23 Thread Renato Golin via Phabricator via cfe-commits
rengolin accepted this revision. rengolin added a comment. This revision is now accepted and ready to land. Thanks, looks good to me! I wouldn't split this in two commits. One of the benefits of having a monorepo is that we don't have to do that anymore. :) Comment at:

[PATCH] D133574: [C2x] reject type definitions in offsetof

2022-09-23 Thread YingChi Long via Phabricator via cfe-commits
inclyc added a comment. Emm, is it necessary to add a `LangOpts` check so that this change only applies to c2x? If clang was invoked without `-std=c2x`, should we just accept `offsetof` with definitions? Comment at: clang/include/clang/Basic/DiagnosticSemaKinds.td:1650 +def

[PATCH] D125683: [runtimes] Replace LIBCXX_ENABLE_STATIC_ABI_LIBRARY & friends by a new LIBCXX_CXX_ABI choice

2022-09-23 Thread Nikita Popov via Phabricator via cfe-commits
nikic requested changes to this revision. nikic added a comment. This revision now requires changes to proceed. I have some concerns about this change: - It makes it fundamentally impossible to link against a static system-libcxxabi (or any other `LIBCXX_CXX_ABI` option). This is currently

[PATCH] D134507: [Clang] add missing ClangABICompat check

2022-09-23 Thread Paul Robinson via Phabricator via cfe-commits
probinson added a comment. Hi @ychen I saw you updated the patch description, thanks. IIUC, the change causes some difference in the interpretation of particular template stuff. Would this be clearer if the BEFORE-15/AFTER-15 test cases used the same template construct? Currently they are

  1   2   >