[PATCH] D155955: [Clang] Improve the handling of large arrays evaluation.

2023-07-24 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin added a comment. In D155955#4528571 , @efriedma wrote: > The UINT_MAX thing seems like a straightforward bug; if we have time to fix > it properly, I'd prefer not to add weird workarounds. Note sure what you mean. Making sure we use `size_t` fo

[PATCH] D155895: Anonymous unions should be transparent wrt `[[clang::trivial_abi]]`.

2023-07-24 Thread Łukasz Anforowicz via Phabricator via cfe-commits
lukasza updated this revision to Diff 543594. lukasza marked an inline comment as done. lukasza added a comment. Addressed feedback from @gribozavr2 CHANGES SINCE LAST ACTION https://reviews.llvm.org/D155895/new/ https://reviews.llvm.org/D155895 Files: clang/lib/Sema/SemaDeclCXX.cpp clan

[PATCH] D156133: [NFC][clang] Fix static analyzer concerns

2023-07-24 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! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D156133/new/ https://reviews.llvm.org/D156133

[PATCH] D155895: Anonymous unions should be transparent wrt `[[clang::trivial_abi]]`.

2023-07-24 Thread Łukasz Anforowicz via Phabricator via cfe-commits
lukasza added a comment. In D155895#4525417 , @gribozavr2 wrote: > @lukasza I think you forgot to upload an updated version of the patch. Ooops, sorry about that. I've been trying to use `arc`, but it seems that it has uploaded separate reviews at htt

[clang] dcb8911 - [clang] Fix specialization of non-templated member classes of class templates

2023-07-24 Thread via cfe-commits
Author: Podchishchaeva, Mariya Date: 2023-07-24T09:36:58-07:00 New Revision: dcb8911316bec81f4f52b40cf0de789f1839730b URL: https://github.com/llvm/llvm-project/commit/dcb8911316bec81f4f52b40cf0de789f1839730b DIFF: https://github.com/llvm/llvm-project/commit/dcb8911316bec81f4f52b40cf0de789f18397

[PATCH] D155705: [clang] Fix specialization of non-templated member classes of class templates

2023-07-24 Thread Mariya Podchishchaeva via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGdcb8911316be: [clang] Fix specialization of non-templated member classes of class templates (authored by Fznamznon). Changed prior to commit: https://reviews.llvm.org/D155705?vs=543478&id=543598#toc Re

[PATCH] D156056: [clang-tidy] Initialize DiagnosticEngine in ExpandModularHeaders

2023-07-24 Thread Piotr Zegar via Phabricator via cfe-commits
PiotrZSL updated this revision to Diff 543601. PiotrZSL marked 3 inline comments as done. PiotrZSL added a comment. Review comments fixes Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D156056/new/ https://reviews.llvm.org/D156056 Files: clang-too

[PATCH] D155955: [Clang] Improve the handling of large arrays evaluation.

2023-07-24 Thread Corentin Jabot via Phabricator via cfe-commits
cor3ntin updated this revision to Diff 543606. cor3ntin added a comment. Update release notes and commit message Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D155955/new/ https://reviews.llvm.org/D155955 Files: clang/docs/ReleaseNotes.rst clan

[PATCH] D155955: [Clang] Improve the handling of large arrays evaluation.

2023-07-24 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. > Note sure what you mean. Making sure we use size_t for all array extents is > not something that can be fixed overnight but more importantly, it does not > help: Would it not overflow, the allocation would still fail. Oh, right, it would be sizeof(APValue) * UINT_MAX

[PATCH] D156014: [Clang][NVPTX] Permit use of the alias attribute for NVPTX targets

2023-07-24 Thread Joseph Huber via Phabricator via cfe-commits
jhuber6 added inline comments. Comment at: clang/lib/Sema/SemaDeclAttr.cpp:1995 } - if (S.Context.getTargetInfo().getTriple().isNVPTX()) { -S.Diag(AL.getLoc(), diag::err_alias_not_supported_on_nvptx); jhuber6 wrote: > tra wrote: > > tra wrote: > > > Allow

[PATCH] D151761: clang-format: Add AlignConsecutiveShortCaseStatements

2023-07-24 Thread Owen Pan via Phabricator via cfe-commits
owenpan accepted this revision. owenpan added a comment. In D151761#4528389 , @galenelias wrote: > In D151761#4524653 , @owenpan wrote: > >> FWIW, I think we can use a shorter name `AlignConsecutiveCaseStatements

[PATCH] D151625: [clang] Add `clang::equality_operator_compares_members_lexicographically`

2023-07-24 Thread Amirreza Ashouri via Phabricator via cfe-commits
AMP999 added a comment. This attribute is trying to work around an issue with operator== instantiation, but according to https://cpplang.slack.com/archives/C6K47F8TT/p1689107603335019?thread_ts=1689107603.335019&cid=C6K47F8TT the problem is actually a bug in Clang. Shouldn't the Clang bug be fi

[clang-tools-extra] f617aaa - [clang-tidy][NFC] Improve release notes

2023-07-24 Thread Piotr Zegar via cfe-commits
Author: Piotr Zegar Date: 2023-07-24T17:02:04Z New Revision: f617aaa0d74c24e0fea8fb05c70ce7b532fdb66f URL: https://github.com/llvm/llvm-project/commit/f617aaa0d74c24e0fea8fb05c70ce7b532fdb66f DIFF: https://github.com/llvm/llvm-project/commit/f617aaa0d74c24e0fea8fb05c70ce7b532fdb66f.diff LOG: [

[clang] 841ff7c - [Driver][test] Clean up some xray tests

2023-07-24 Thread Fangrui Song via cfe-commits
Author: Fangrui Song Date: 2023-07-24T10:05:34-07:00 New Revision: 841ff7c6ca4c6fa9ff3ac6ba93e177462b7d668e URL: https://github.com/llvm/llvm-project/commit/841ff7c6ca4c6fa9ff3ac6ba93e177462b7d668e DIFF: https://github.com/llvm/llvm-project/commit/841ff7c6ca4c6fa9ff3ac6ba93e177462b7d668e.diff

[PATCH] D156127: Partially revert changes to test lang-std.cpp

2023-07-24 Thread Douglas Yung via Phabricator via cfe-commits
dyung added inline comments. Comment at: clang/test/Preprocessor/lang-std.cpp:1 +// UNSUPPORTED: target={{.*-(ps4|ps5)}} /// Test default standards. This should be unneeded now, we recently updated the PS platforms to default to c++17 like the rest of the compi

[PATCH] D154774: [Sema] Respect instantiated-from template's VisibilityAttr for two implicit/explicit instantiation cases

2023-07-24 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. Ping :) Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154774/new/ https://reviews.llvm.org/D154774 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/

[PATCH] D156142: Deterministic -gen-cdb-fragment-path filenames

2023-07-24 Thread Thomas Otto via Phabricator via cfe-commits
totph created this revision. totph added reviewers: jkorous, arphaman, ributzka. Herald added a subscriber: mgrang. Herald added a project: All. totph requested review of this revision. Herald added subscribers: cfe-commits, MaskRay. Herald added a project: clang. [clang] Deterministic `-gen-cdb-f

[PATCH] D156143: Add Adrian and David as owners for debug info

2023-07-24 Thread Reid Kleckner via Phabricator via cfe-commits
rnk created this revision. rnk added reviewers: aaron.ballman, aprantl, dblaikie. Herald added a project: All. rnk requested review of this revision. Herald added a project: clang. Repository: rG LLVM Github Monorepo https://reviews.llvm.org/D156143 Files: clang/CodeOwners.rst Index: clang

[PATCH] D155890: [clang-tidy] Add folly::Optional to unchecked-optional-access

2023-07-24 Thread Anton Dukeman via Phabricator via cfe-commits
adukeman updated this revision to Diff 543619. adukeman added a comment. Update calls to OptionalMemberCall to take a name matcher Supports treating calls to optional::has_value and optional::hasValue identically Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://review

[PATCH] D156143: Add Adrian and David as owners for debug info

2023-07-24 Thread Reid Kleckner via Phabricator via cfe-commits
rnk updated this revision to Diff 543618. rnk added a comment. - Fix escaping Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D156143/new/ https://reviews.llvm.org/D156143 Files: clang/CodeOwners.rst Index: clang/CodeOwners.rst ==

[PATCH] D156063: [Clang] Reject programs declaring namespace std to be inline

2023-07-24 Thread Mital Ashok via Phabricator via cfe-commits
MitalAshok accepted this revision. MitalAshok added a comment. This revision is now accepted and ready to land. Looks good! CHANGES SINCE LAST ACTION https://reviews.llvm.org/D156063/new/ https://reviews.llvm.org/D156063 ___ cfe-commits mailing lis

[PATCH] D155890: [clang-tidy] Add folly::Optional to unchecked-optional-access

2023-07-24 Thread Anton Dukeman via Phabricator via cfe-commits
adukeman marked 3 inline comments as done. adukeman added a comment. Thanks for all the comments! I think I've got them all addressed and tests are passing locally. In D155890#4528560 , @carlosgalvezp wrote: > The review is marked as accepted, should w

[clang] bed75fa - [Clang] Reject programs declaring namespace std to be inline

2023-07-24 Thread Po-yao Chang via cfe-commits
Author: Po-yao Chang Date: 2023-07-25T01:30:23+08:00 New Revision: bed75faf7d768f8375681db6a3fb7c3c35eeb5aa URL: https://github.com/llvm/llvm-project/commit/bed75faf7d768f8375681db6a3fb7c3c35eeb5aa DIFF: https://github.com/llvm/llvm-project/commit/bed75faf7d768f8375681db6a3fb7c3c35eeb5aa.diff

[PATCH] D156063: [Clang] Reject programs declaring namespace std to be inline

2023-07-24 Thread PoYao Chang via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rGbed75faf7d76: [Clang] Reject programs declaring namespace std to be inline (authored by rZhBoYao). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D156063/new/

[PATCH] D156063: [Clang] Reject programs declaring namespace std to be inline

2023-07-24 Thread PoYao Chang via Phabricator via cfe-commits
rZhBoYao added a comment. Thanks for all the suggestions and review comments! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D156063/new/ https://reviews.llvm.org/D156063 ___ cfe-commits mailing list cfe-c

[PATCH] D156154: [clang][ConstExprEmitter] handle IntegerLiterals and IntegralCasts

2023-07-24 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers created this revision. Herald added a project: All. nickdesaulniers requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. Improves the ability of ConstExprEmitter to evaluate constants. Found by adding asserts to ConstantEmitter:

[PATCH] D154123: [HIP] Start document HIP support by clang

2023-07-24 Thread Siu Chi Chan via Phabricator via cfe-commits
scchan added inline comments. Comment at: clang/docs/HIPSupport.rst:65 + + clang++ --offload-arch=gfx906 -xhip sample.cpp -o sample + missing --hip-link Comment at: clang/docs/HIPSupport.rst:77 + + clang++ --offload-arch=native -xhip sample

[PATCH] D156143: Add Adrian and David as owners for debug info

2023-07-24 Thread Paul Robinson via Phabricator via cfe-commits
probinson accepted this revision. probinson added a comment. LGTM Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D156143/new/ https://reviews.llvm.org/D156143 ___ cfe-commits mailing list cfe-commits@lists

[clang] 69593aa - [Headers][doc] Add misc non-AVX2 intrinsic descriptions

2023-07-24 Thread Paul Robinson via cfe-commits
Author: Paul Robinson Date: 2023-07-24T10:51:18-07:00 New Revision: 69593aa5c054cec6be6b822c073ccdc63748a68d URL: https://github.com/llvm/llvm-project/commit/69593aa5c054cec6be6b822c073ccdc63748a68d DIFF: https://github.com/llvm/llvm-project/commit/69593aa5c054cec6be6b822c073ccdc63748a68d.diff

[PATCH] D155859: [Headers][doc] Add misc non-AVX2 intrinsic descriptions

2023-07-24 Thread Paul Robinson 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 rG69593aa5c054: [Headers][doc] Add misc non-AVX2 intrinsic descriptions (authored by probinson). Herald added a project: clang. Repository: rG LLVM

[PATCH] D154123: [HIP] Start document HIP support by clang

2023-07-24 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm added inline comments. Comment at: clang/docs/HIPSupport.rst:65 + + clang++ --offload-arch=gfx906 -xhip sample.cpp -o sample + scchan wrote: > missing --hip-link What does hip-link do? Why is it needed? I never use it and it works CHANGES SINCE LAST AC

[clang] 7abb5fc - [DWARF] Make sure file entry for artificial functions has an MD5 checksum

2023-07-24 Thread Paul Robinson via cfe-commits
Author: Paul Robinson Date: 2023-07-24T10:53:10-07:00 New Revision: 7abb5fc618cec66841a8280d2a099a4c9c8cb91b URL: https://github.com/llvm/llvm-project/commit/7abb5fc618cec66841a8280d2a099a4c9c8cb91b DIFF: https://github.com/llvm/llvm-project/commit/7abb5fc618cec66841a8280d2a099a4c9c8cb91b.diff

[PATCH] D155991: [DWARF] Make sure file entry for artificial functions has an MD5 checksum

2023-07-24 Thread Paul Robinson 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 rG7abb5fc618ce: [DWARF] Make sure file entry for artificial functions has an MD5 checksum (authored by probinson). Herald added a project: clang. Repo

[PATCH] D156127: Partially revert changes to test lang-std.cpp

2023-07-24 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl marked an inline comment as done. yaxunl added inline comments. Comment at: clang/test/Preprocessor/lang-std.cpp:1 +// UNSUPPORTED: target={{.*-(ps4|ps5)}} /// Test default standards. dyung wrote: > This should be unneeded now, we recently updated the PS

[PATCH] D156127: Partially revert changes to test lang-std.cpp

2023-07-24 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl updated this revision to Diff 543640. yaxunl marked an inline comment as done. yaxunl added a reviewer: dyung. yaxunl added a comment. revised by comments CHANGES SINCE LAST ACTION https://reviews.llvm.org/D156127/new/ https://reviews.llvm.org/D156127 Files: clang/test/Preprocessor/

[PATCH] D154774: [Sema] Respect instantiated-from template's VisibilityAttr for two implicit/explicit instantiation cases

2023-07-24 Thread John McCall via Phabricator via cfe-commits
rjmccall added inline comments. Comment at: clang/lib/AST/Decl.cpp:380 +->getTemplatedDecl() +->hasAttr(); } Okay, this change seems wrong. A visibility attribute on

[PATCH] D156024: [clang-tidy] Add --experimental-disable-module-headers-parsing option

2023-07-24 Thread Piotr Zegar via Phabricator via cfe-commits
PiotrZSL updated this revision to Diff 543641. PiotrZSL retitled this revision from "[clang-tidy] Add --disable-modular-headers-expansion option" to "[clang-tidy] Add --experimental-disable-module-headers-parsing option". PiotrZSL added a comment. Rename of option + cleanup Repository: rG LL

[PATCH] D155890: [clang-tidy] Add folly::Optional to unchecked-optional-access

2023-07-24 Thread Piotr Zegar via Phabricator via cfe-commits
PiotrZSL added a comment. Some entry in release notes or/and check documentation would be welcome. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D155890/new/ https://reviews.llvm.org/D155890 ___ cfe-commi

[PATCH] D156156: [clang] Implement constexpr evaluation for `__builtin_{add,sub}c`

2023-07-24 Thread Daniel Bertalan via Phabricator via cfe-commits
BertalanD created this revision. BertalanD added reviewers: aaron.ballman, cjdb, erichkeane. Herald added a project: All. BertalanD requested review of this revision. Herald added a project: clang. Herald added a subscriber: cfe-commits. GCC has gained support for these multiprecision arithmetic b

[PATCH] D154123: [HIP] Start document HIP support by clang

2023-07-24 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl marked 2 inline comments as done. yaxunl added inline comments. Comment at: clang/docs/HIPSupport.rst:65 + + clang++ --offload-arch=gfx906 -xhip sample.cpp -o sample + arsenm wrote: > scchan wrote: > > missing --hip-link > What does hip-link do? Why is i

[clang] 47d1789 - Add Adrian and David as owners for debug info

2023-07-24 Thread Reid Kleckner via cfe-commits
Author: Reid Kleckner Date: 2023-07-24T11:11:35-07:00 New Revision: 47d178939e96d388c8d28dff2f937e340f12c31d URL: https://github.com/llvm/llvm-project/commit/47d178939e96d388c8d28dff2f937e340f12c31d DIFF: https://github.com/llvm/llvm-project/commit/47d178939e96d388c8d28dff2f937e340f12c31d.diff

[PATCH] D156143: Add Adrian and David as owners for debug info

2023-07-24 Thread Reid Kleckner 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 rG47d178939e96: Add Adrian and David as owners for debug info (authored by rnk). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION ht

[PATCH] D154123: [HIP] Start document HIP support by clang

2023-07-24 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl updated this revision to Diff 543652. yaxunl marked an inline comment as done. yaxunl added a comment. revised by comments CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154123/new/ https://reviews.llvm.org/D154123 Files: clang/docs/HIPSupport.rst Index: clang/docs/HIPSupport.

[PATCH] D112921: [clang] Enable sized deallocation by default in C++14 onwards

2023-07-24 Thread Mark de Wever via Phabricator via cfe-commits
Mordante added a comment. I noticed some of the CI jobs are still failing with the patch, I didn't look into them. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D112921/new/ https://reviews.llvm.org/D112921

[PATCH] D150338: [-Wunsafe-buffer-usage] Improving insertion of the [[clang::unsafe_buffer_usage]] attribute

2023-07-24 Thread Ziqing Luo via Phabricator via cfe-commits
ziqingluo-90 abandoned this revision. ziqingluo-90 added a comment. In D150338#4503802 , @ziqingluo-90 wrote: > Re-landed in `a07a6f6c74a03405eccdcd3832acb2187d8b9c21` > > Moved the use of `clang::Sema` from `UnsafeBufferAnalysis` to > `AnalysisBasedWar

[PATCH] D156127: Partially revert changes to test lang-std.cpp

2023-07-24 Thread Paul Robinson via Phabricator via cfe-commits
probinson added inline comments. Comment at: clang/test/Preprocessor/lang-std.cpp:4 // RUN: %clang_cc1 -dM -E %s | grep __cplusplus >%T-cpp-std.txt +// RUN: cat %T-cpp-std.txt | FileCheck --check-prefix=CXX17 %s + Use `--input-file` and there's one fewer process

[PATCH] D155452: [Flang] Add support for fsave-optimization-record

2023-07-24 Thread Andrzej Warzynski via Phabricator via cfe-commits
awarzynski accepted this revision. awarzynski added a comment. LGTM, thanks for the updates! (please address my comment in "frontend-forwarding.f90" before landing this) Comment at: flang/test/Driver/frontend-forwarding.f90:26 +! RUN: %flang -### %s 2>&1 \ +! RUN: -fopti

[PATCH] D156154: [clang][ConstExprEmitter] handle IntegerLiterals and IntegralCasts

2023-07-24 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. As a practical matter, I'm not sure this helps much; ExprConstant should be reasonably fast for simple integers. The performance issues only really show for structs/arrays. But maybe it helps a little to handle a few of the most common integer expressions. ===

[PATCH] D155890: [clang-tidy] Add folly::Optional to unchecked-optional-access

2023-07-24 Thread Anton Dukeman via Phabricator via cfe-commits
adukeman updated this revision to Diff 543659. adukeman added a comment. Update docs and run clang-format Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D155890/new/ https://reviews.llvm.org/D155890 Files: clang-tools-extra/docs/clang-tidy/checks

[PATCH] D156154: [clang][ConstExprEmitter] handle IntegerLiterals and IntegralCasts

2023-07-24 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers added a comment. In D156154#4529265 , @efriedma wrote: > As a practical matter, I'm not sure this helps much; ExprConstant should be > reasonably fast for simple integers. The performance issues only really show > for structs/arrays. B

[PATCH] D156154: [clang][ConstExprEmitter] handle IntegerLiterals and IntegralCasts

2023-07-24 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers updated this revision to Diff 543662. nickdesaulniers marked an inline comment as done. nickdesaulniers added a comment. - put back the IntegralCast, for now Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D156154/new/ https://reviews.

[PATCH] D156154: [clang][ConstExprEmitter] handle IntegerLiterals

2023-07-24 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers updated this revision to Diff 543665. nickdesaulniers retitled this revision from "[clang][ConstExprEmitter] handle IntegerLiterals and IntegralCasts" to "[clang][ConstExprEmitter] handle IntegerLiterals". nickdesaulniers added a comment. - remove mention of IntegralCasts from co

[PATCH] D153310: Add codegen for llvm pow builtin

2023-07-24 Thread Joshua Batista via Phabricator via cfe-commits
bob80905 added a comment. Ping, can someone please take a look? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D153310/new/ https://reviews.llvm.org/D153310 ___ cfe-commits mailing list cfe-commits@lists.l

[PATCH] D153310: Add codegen for llvm pow builtin

2023-07-24 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm added a comment. Code looks fine, patch title is a bit confusing. Don't say codegen, and say clang: Add elementwise pow builtin? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D153310/new/ https://reviews.llvm.org/D153310 ___

[PATCH] D156154: [clang][ConstExprEmitter] handle IntegerLiterals

2023-07-24 Thread Eli Friedman via Phabricator via cfe-commits
efriedma added a comment. We don't completely fall back if a subexpression fails to evaluate. EmitArrayInitialization etc. don't recursively visit; they use tryEmitPrivateForMemory, so we can fallback for subexpressions. (tryEmitPrivateForMemory can still fail for certain constructs, like the

[PATCH] D155890: [clang-tidy] Add folly::Optional to unchecked-optional-access

2023-07-24 Thread Piotr Zegar via Phabricator via cfe-commits
PiotrZSL added inline comments. Comment at: clang-tools-extra/docs/clang-tidy/checks/bugprone/unchecked-optional-access.rst:11 This check identifies unsafe accesses to values contained in -``std::optional``, ``absl::optional``, or ``base::Optional`` +``std::optional``, ``absl::

[PATCH] D156154: [clang][ConstExprEmitter] handle IntegerLiterals

2023-07-24 Thread Eli Friedman via Phabricator via cfe-commits
efriedma accepted this revision. efriedma added a comment. This revision is now accepted and ready to land. That said, skipping all those abstraction layers for the simplest cases is probably worth it; LGTM. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm

[PATCH] D153310: clang: Add elementwise pow builtin

2023-07-24 Thread Matt Arsenault via Phabricator via cfe-commits
arsenm accepted this revision. arsenm added inline comments. This revision is now accepted and ready to land. Comment at: clang/test/CodeGen/strictfp-elementwise-bulitins.cpp:223 +// CHECK-NEXT: entry: +// CHECK-NEXT:[[TMP0:%.*]] = tail call <4 x float> @llvm.pow.v4f32(<4 x

[PATCH] D154123: [HIP] Start document HIP support by clang

2023-07-24 Thread Siu Chi Chan via Phabricator via cfe-commits
scchan accepted this revision. scchan added a comment. This revision is now accepted and ready to land. LGTM thanks CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154123/new/ https://reviews.llvm.org/D154123 ___ cfe-commits mailing list cfe-co

[PATCH] D154550: [clang-format] Allow empty loops on a single line.

2023-07-24 Thread Gedare Bloom via Phabricator via cfe-commits
gedare planned changes to this revision. gedare added a comment. In D154550#4526386 , @owenpan wrote: > Like `while (a);`, `while (a) {}` is also an empty loop, so `NonEmpty` is > misleading if it excludes the former but not the latter. IMO we should jus

[PATCH] D156127: Partially revert changes to test lang-std.cpp

2023-07-24 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl updated this revision to Diff 543670. yaxunl added a comment. revised by comments CHANGES SINCE LAST ACTION https://reviews.llvm.org/D156127/new/ https://reviews.llvm.org/D156127 Files: clang/test/Preprocessor/lang-std.cpp Index: clang/test/Preprocessor/lang-std.cpp ==

[PATCH] D156127: Partially revert changes to test lang-std.cpp

2023-07-24 Thread Yaxun Liu via Phabricator via cfe-commits
yaxunl updated this revision to Diff 543671. yaxunl added a comment. fix typo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D156127/new/ https://reviews.llvm.org/D156127 Files: clang/test/Preprocessor/lang-std.cpp Index: clang/test/Preprocessor/lang-std.cpp =

[PATCH] D156090: [Driver][XRay][test] Mark these tests as supported on loongarch64

2023-07-24 Thread Fangrui Song via Phabricator via cfe-commits
MaskRay added a comment. Thank you for improving the XRay tests. I have cleaned up some xray tests in June but did not finish the remaining ones. This motivated me to properly fix them. I'll soon remove `clang/test/Driver/XRay/lit.cfg.py` after we no longer rely on the default target triple.

[PATCH] D156161: [clang-tidy] Add --experimental-enable-module-headers-parsing option

2023-07-24 Thread Piotr Zegar via Phabricator via cfe-commits
PiotrZSL created this revision. PiotrZSL added reviewers: njames93, carlosgalvezp, aaron.ballman. Herald added subscribers: kbarton, xazax.hun, nemanjai. Herald added a project: All. PiotrZSL requested review of this revision. Herald added a project: clang-tools-extra. Herald added a subscriber: cf

[PATCH] D155890: [clang-tidy] Add folly::Optional to unchecked-optional-access

2023-07-24 Thread Piotr Zegar via Phabricator via cfe-commits
PiotrZSL accepted this revision. PiotrZSL added a comment. +- LGTM, I will correct those nits and push it. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D155890/new/ https://reviews.llvm.org/D155890 ___ c

[PATCH] D156127: Partially revert changes to test lang-std.cpp

2023-07-24 Thread Paul Robinson via Phabricator via cfe-commits
probinson accepted this revision. probinson added a comment. This revision is now accepted and ready to land. LGTM CHANGES SINCE LAST ACTION https://reviews.llvm.org/D156127/new/ https://reviews.llvm.org/D156127 ___ cfe-commits mailing list cfe-com

[clang] 05c2c09 - [Driver][test] Remove XRay/lit.local.cfg

2023-07-24 Thread Fangrui Song via cfe-commits
Author: Fangrui Song Date: 2023-07-24T12:27:14-07:00 New Revision: 05c2c09bb1f10261f6f804a2d510c55d97b1584c URL: https://github.com/llvm/llvm-project/commit/05c2c09bb1f10261f6f804a2d510c55d97b1584c DIFF: https://github.com/llvm/llvm-project/commit/05c2c09bb1f10261f6f804a2d510c55d97b1584c.diff

[PATCH] D155794: [OpenMP][OpenMPIRBuilder] Migrate setPropertyExecutionMode() from Clang to OpenMPIRBuilder.

2023-07-24 Thread Raghu via Phabricator via cfe-commits
raghavendhra marked 2 inline comments as done. raghavendhra added inline comments. Comment at: llvm/lib/Frontend/OpenMP/OMPIRBuilder.cpp:4917 + LLVMCompilerUsed.emplace_back(GVMode); +} + jdoerfert wrote: > No `llvm::` here. Sorry, Can you please elaborate whic

[PATCH] D154007: Reland "Try to implement lambdas with inalloca parameters by forwarding without use of inallocas."

2023-07-24 Thread Reid Kleckner via Phabricator via cfe-commits
rnk added inline comments. Comment at: clang/lib/CodeGen/CGClass.cpp:3095 + StringRef CallOpName = CallOpFn->getName(); + std::string ImplName = ("__impl" + CallOpName).str(); + akhuang wrote: > The old code tried to find the "" part of the function name and >

[PATCH] D156161: [clang-tidy] Add --experimental-enable-module-headers-parsing option

2023-07-24 Thread Carlos Galvez via Phabricator via cfe-commits
carlosgalvezp added a comment. Please squash into previous patch, I see no reason to make them into separate commits. The first one is missing Release Notes, for example. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D156161/new/ https://reviews.ll

[clang-tools-extra] 2f0630f - [clang-tidy] Add folly::Optional to unchecked-optional-access

2023-07-24 Thread Piotr Zegar via cfe-commits
Author: Anton Dukeman Date: 2023-07-24T19:42:19Z New Revision: 2f0630f8bc91e81fd5948e82164cf82ae595caf2 URL: https://github.com/llvm/llvm-project/commit/2f0630f8bc91e81fd5948e82164cf82ae595caf2 DIFF: https://github.com/llvm/llvm-project/commit/2f0630f8bc91e81fd5948e82164cf82ae595caf2.diff LOG:

[PATCH] D156024: [clang-tidy] Add --experimental-disable-module-headers-parsing option

2023-07-24 Thread Carlos Galvez via Phabricator via cfe-commits
carlosgalvezp added inline comments. Comment at: clang-tools-extra/clang-tidy/ClangTidyDiagnosticConsumer.h:202 + bool canEnableModuleHeadersParsing() const { +return !DisableModuleHeadersParsing; Add docs? Comment at: clang-tools-extra/

[PATCH] D155890: [clang-tidy] Add folly::Optional to unchecked-optional-access

2023-07-24 Thread Piotr Zegar 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 rG2f0630f8bc91: [clang-tidy] Add folly::Optional to unchecked-optional-access (authored by Anton Dukeman , committed by PiotrZSL)

[PATCH] D154130: [lit][clang] Avoid realpath on Windows due to MAX_PATH limitations

2023-07-24 Thread Tristan Labelle via Phabricator via cfe-commits
MrTrillian updated this revision to Diff 543677. MrTrillian added a comment. Fixed `clang-format` issues and improved test comment. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D154130/new/ https://reviews.llvm.org/D154130 Files: clang/include/clang/Basic/FileManager.h clang/lib/Ba

[PATCH] D155394: [clang][Interp] Implement __builtin_fpclassify

2023-07-24 Thread Joshua Cranmer via Phabricator via cfe-commits
jcranmer-intel added inline comments. Comment at: clang/test/AST/Interp/builtin-functions.cpp:121-130 + char classify_nan [__builtin_fpclassify(+1, -1, -1, -1, -1, __builtin_nan(""))]; + char classify_snan[__builtin_fpclassify(+1, -1, -1, -1, -1, __builtin_nans(""))];

[PATCH] D156161: [clang-tidy] Add --experimental-enable-module-headers-parsing option

2023-07-24 Thread Piotr Zegar via Phabricator via cfe-commits
PiotrZSL added a comment. @carlosgalvezp My plan was to push first change regardless (so they would be some workaround, even if hidden & undocumented), and second only if approved. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D156161/new/ https://

[PATCH] D156024: [clang-tidy] Add --experimental-disable-module-headers-parsing option

2023-07-24 Thread Piotr Zegar via Phabricator via cfe-commits
PiotrZSL added inline comments. Comment at: clang-tools-extra/clang-tidy/ClangTidyDiagnosticConsumer.h:202 + bool canEnableModuleHeadersParsing() const { +return !DisableModuleHeadersParsing; carlosgalvezp wrote: > Add docs? for function ? It's straight fo

[clang-tools-extra] 992fa7b - [clang-tidy] Initialize DiagnosticEngine in ExpandModularHeaders

2023-07-24 Thread Piotr Zegar via cfe-commits
Author: Piotr Zegar Date: 2023-07-24T19:43:47Z New Revision: 992fa7be3438bce61cfba7c0e0b07d9d1ddcc05b URL: https://github.com/llvm/llvm-project/commit/992fa7be3438bce61cfba7c0e0b07d9d1ddcc05b DIFF: https://github.com/llvm/llvm-project/commit/992fa7be3438bce61cfba7c0e0b07d9d1ddcc05b.diff LOG: [

[PATCH] D156056: [clang-tidy] Initialize DiagnosticEngine in ExpandModularHeaders

2023-07-24 Thread Piotr Zegar 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 rG992fa7be3438: [clang-tidy] Initialize DiagnosticEngine in ExpandModularHeaders (authored by PiotrZSL). Repository: rG LLVM Github Monorepo CHANGE

[PATCH] D151761: clang-format: Add AlignConsecutiveShortCaseStatements

2023-07-24 Thread Björn Schäpers via Phabricator via cfe-commits
HazardyKnusperkeks accepted this revision. HazardyKnusperkeks added a comment. All of those variants are fine by me, but I'd stick with the current version, because it is linked to `AllowShortCaseLabelsOnASingleLine`. CHANGES SINCE LAST ACTION https://reviews.llvm.org/D151761/new/ https://re

[PATCH] D95299: Fix truncated __OPENMP_NVPTX__ preprocessor condition

2023-07-24 Thread Mehdi AMINI via Phabricator via cfe-commits
mehdi_amini added a comment. Herald added a subscriber: wangpc. @r-burns : what should I use for the authorship (name/pseudo and email)? Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D95299/new/ https://reviews.llvm.org/D95299 _

[PATCH] D95299: Fix truncated __OPENMP_NVPTX__ preprocessor condition

2023-07-24 Thread Ryan Burns via Phabricator via cfe-commits
r-burns added a comment. Hi! You can credit Ryan Burns . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D95299/new/ https://reviews.llvm.org/D95299 ___ cfe-commits mailing list cfe-commits@lists.llvm.org h

[PATCH] D153914: [clang-cl] Enable concatenation of predefined identifiers

2023-07-24 Thread Tom Honermann via Phabricator via cfe-commits
tahonermann added inline comments. Comment at: clang/lib/Sema/SemaExpr.cpp:2010-2013 +OS << "R\"EFLPM(" + << PredefinedExpr::ComputeName(getPredefinedExprKind(Tok.getKind()), + currentDecl) + << ")EFLPM\""; RIs

[PATCH] D153914: [clang-cl] Enable concatenation of predefined identifiers

2023-07-24 Thread Tom Honermann via Phabricator via cfe-commits
tahonermann added inline comments. Comment at: clang/test/Sema/ms_predefined_expr.cpp:156 +static_assert(__FUNCTION__ ""_len == 14); // expected-warning{{string literal concatenation of predefined identifier '__FUNCTION__' is a Microsoft extension}} } Here

[PATCH] D76096: [clang] allow const structs/unions/arrays to be constant expressions for C

2023-07-24 Thread Nick Desaulniers via Phabricator via cfe-commits
nickdesaulniers added a comment. Posting quick benchmarks of linux kernel builds: ac524886094db58112ca176e1d727330a94634a8 + D151587 + D76096 + D156154

[PATCH] D150226: [Clang] Remove ability to downgrade warning on the diagnostic for setting a non fixed enum to a value outside the range of the enumeration values

2023-07-24 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added a comment. > I think getting new system headers is harder for projects to deal with, so I > think I'm now in agreement with you that we should enable the warning as an > error in system headers. Awesome - glad we're on the same page :) CHANGES SINCE LAST ACTION https://review

[PATCH] D153536: [Clang] Implement P2169 A nice placeholder with no name

2023-07-24 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added a comment. In D153536#4521156 , @hubert.reinterpretcast wrote: > In D153536#4512897 , @dblaikie > wrote: > >> but at least at a first blush I can't reproduce the failures shown... > > @dblaikie, y

[PATCH] D156128: [Clang][AArch64] Fix up immediate range of f64f64 mopa/mops intrinsics

2023-07-24 Thread Bryan Chan via Phabricator via cfe-commits
bryanpkc added inline comments. Comment at: clang/include/clang/Basic/arm_sme.td:254 [IsStreaming, IsSharedZA], - [ImmCheck<0, ImmCheck0_3>]>; + [ImmCheck<0, ImmCheck0_0>]>; }

[PATCH] D155991: [DWARF] Make sure file entry for artificial functions has an MD5 checksum

2023-07-24 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added a comment. Any memory usage measurements to check this doesn't have a significant adverse impact by copying all the strings? (or performance by having to do string rather than pointer equality comparisons?) Could/should we do the lookup on the CU filename before it goes into the

[clang] b54294e - [clang][ConstantEmitter] have tryEmitPrivate[ForVarInit] try ConstExprEmitter fast-path first

2023-07-24 Thread Nick Desaulniers via cfe-commits
Author: Nick Desaulniers Date: 2023-07-24T13:50:45-07:00 New Revision: b54294e2c9596088aaf557b221bcf471745864bc URL: https://github.com/llvm/llvm-project/commit/b54294e2c9596088aaf557b221bcf471745864bc DIFF: https://github.com/llvm/llvm-project/commit/b54294e2c9596088aaf557b221bcf471745864bc.di

[PATCH] D151587: [clang][ConstantEmitter] have tryEmitPrivate[ForVarInit] try ConstExprEmitter fast-path first

2023-07-24 Thread Nick Desaulniers 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 rGb54294e2c959: [clang][ConstantEmitter] have tryEmitPrivate[ForVarInit] try ConstExprEmitter… (authored by nickdesaulniers). Repository: rG LLVM Gi

[PATCH] D156143: Add Adrian and David as owners for debug info

2023-07-24 Thread David Blaikie via Phabricator via cfe-commits
dblaikie added a comment. Sounds good, thanks! Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D156143/new/ https://reviews.llvm.org/D156143 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://l

[PATCH] D154130: [lit][clang] Avoid realpath on Windows due to MAX_PATH limitations

2023-07-24 Thread Tom Honermann via Phabricator via cfe-commits
tahonermann added a comment. > Marking comments as resolved per my reply. I'm not sure if that's best > practice! Yes, that is fine. Comment at: clang/test/Lexer/case-insensitive-include-win.c:5-9 +// Note: We must use the real path here, because the logic to detect case +//

[clang] 3a98e73 - clang: Add elementwise pow builtin

2023-07-24 Thread Joshua Batista via cfe-commits
Author: Joshua Batista Date: 2023-07-24T14:03:58-07:00 New Revision: 3a98e73169e1d8e4fbb739462eea62445db1a6c8 URL: https://github.com/llvm/llvm-project/commit/3a98e73169e1d8e4fbb739462eea62445db1a6c8 DIFF: https://github.com/llvm/llvm-project/commit/3a98e73169e1d8e4fbb739462eea62445db1a6c8.diff

[PATCH] D153310: clang: Add elementwise pow builtin

2023-07-24 Thread Joshua Batista via Phabricator via cfe-commits
This revision was automatically updated to reflect the committed changes. Closed by commit rG3a98e73169e1: clang: Add elementwise pow builtin (authored by bob80905). Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D153310/new/ https://reviews.llvm.org

[PATCH] D155794: [OpenMP][OpenMPIRBuilder] Migrate setPropertyExecutionMode() from Clang to OpenMPIRBuilder.

2023-07-24 Thread Raghu via Phabricator via cfe-commits
raghavendhra updated this revision to Diff 543696. raghavendhra added a comment. Addressed review comments by making setPropertyExecutionMode() to return a Global Value instead of void. Rebased patch. Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D1

[PATCH] D156064: [SemaCXX] Recognise initializer_list injected-class-name types as initializer_lists

2023-07-24 Thread Mital Ashok via Phabricator via cfe-commits
MitalAshok updated this revision to Diff 543697. MitalAshok added a comment. Remove now unneeded FIXME Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D156064/new/ https://reviews.llvm.org/D156064 Files: clang/docs/ReleaseNotes.rst clang/lib/Sema

[PATCH] D156032: Implement CWG2137 (list-initialization from objects of the same type)

2023-07-24 Thread Mital Ashok via Phabricator via cfe-commits
MitalAshok updated this revision to Diff 543699. MitalAshok added a comment. Add CWG2311 fix too Too much code and tests rely on elision of `T{ T_prvalue }` in C++17, so add change to allow that to be elided when this does not pick a initializer-list constructor. Repository: rG LLVM Github

[PATCH] D156024: [clang-tidy] Add --experimental-disable-module-headers-parsing option

2023-07-24 Thread Piotr Zegar via Phabricator via cfe-commits
PiotrZSL abandoned this revision. PiotrZSL added a comment. Will be integrated into D156161 . Repository: rG LLVM Github Monorepo CHANGES SINCE LAST ACTION https://reviews.llvm.org/D156024/new/ https://reviews.llvm.org/D156024

[PATCH] D154893: [Clang] Fix some triviality computations

2023-07-24 Thread Shafik Yaghmour via Phabricator via cfe-commits
shafik added inline comments. Comment at: clang/include/clang/AST/DeclCXX.h:1269 /// Determine whether this class has a non-trivial copy constructor /// (C++ [class.copy]p6, C++11 [class.copy]p12) bool hasNonTrivialCopyConstructor() const { philnik wrote

<    1   2   3   4   >