[clang] 27c9173 - [Clang] Remove unnecessary Decl transform & profiles for SizeOfPackExpr (#124533)

2025-01-27 Thread via cfe-commits
Author: Younan Zhang Date: 2025-01-27T23:04:57+08:00 New Revision: 27c917307563eae93c7fef9c3944e56e1f5b5f6d URL: https://github.com/llvm/llvm-project/commit/27c917307563eae93c7fef9c3944e56e1f5b5f6d DIFF: https://github.com/llvm/llvm-project/commit/27c917307563eae93c7fef9c3944e56e1f5b5f6d.diff

[clang] [llvm] [NFC][DebugInfo] Use iterators for instruction insertion in more places (PR #124291)

2025-01-27 Thread Orlando Cazalet-Hyams via cfe-commits
https://github.com/OCHyams approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/124291 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Warn when unique objects might be duplicated in shared libraries (PR #117622)

2025-01-27 Thread Hans Wennborg via cfe-commits
zmodem wrote: > I intend to make the warning on-by-default. However, it currently triggers at > several places in the LLVM project, breaking the CI. Fixing them is > nontrivial and cluttered up the PR, so I made it DefaultIgnore in order to > keep things focused. Should the PR be accepted I pl

[clang] [AMDGPU] Use the AMDGPUToolChain when targeting C/C++ directly (PR #99687)

2025-01-27 Thread Jon Chesterfield via cfe-commits
https://github.com/JonChesterfield approved this pull request. This is the right thing. amdgpu is completely usable without rocm libraries and already has out of tree users doing that. Needing to manually opt out of rocm libs when not using any of rocm is definitely annoying, especially in cont

[clang] [cindex] Add API to query the class methods of a type (PR #123539)

2025-01-27 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll commented: Python part of this looks fine to me. We need to rename `fields_visit_callback` to something else, but that's not in the scope of this PR. https://github.com/llvm/llvm-project/pull/123539 ___ cfe-commits mailing l

[clang] [OpenMP] Allow OMP6.0 features. (PR #122108)

2025-01-27 Thread Saiyedul Islam via cfe-commits
https://github.com/saiislam approved this pull request. Thank you for sticking up with this patch @zahiraam. It mostly looks ok to me, but please wait for @mjklemm and @Meinersbur reviews. https://github.com/llvm/llvm-project/pull/122108 ___ cfe-commit

[clang] [PGO] Add a clang option -fprofile-continuous that enables PGO continuous mode (PR #124353)

2025-01-27 Thread Wael Yehia via cfe-commits
@@ -3033,6 +3033,14 @@ indexed format, regardeless whether it is produced by frontend or the IR pass. overhead. ``prefer-atomic`` will be transformed to ``atomic`` when supported by the target, or ``single`` otherwise. +.. option:: -fprofile-continuous w2

[clang] [llvm] [RISCV] Add MIPS extensions (PR #121394)

2025-01-27 Thread Djordje Todorovic via cfe-commits
djolertrk wrote: @topperc looks ok now? https://github.com/llvm/llvm-project/pull/121394 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Address false positives in misc-redundant-expression checker (PR #122841)

2025-01-27 Thread via cfe-commits
@@ -290,7 +290,7 @@ Changes in existing checks - Improved :doc:`misc-redundant-expression ` check by extending the checker to detect floating point and integer literals in redundant - expressions. + expressions. Some macro related false positives had been removed. ---

[clang] [llvm] [RISCV] Add MIPS extensions (PR #121394)

2025-01-27 Thread Djordje Todorovic via cfe-commits
djtodoro wrote: @topperc Is it ok now? :) https://github.com/llvm/llvm-project/pull/121394 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Add configuration option PenaltyBreakBeforeMemberAccess (PR #118409)

2025-01-27 Thread Gedare Bloom via cfe-commits
@@ -22365,6 +22365,19 @@ TEST_F(FormatTest, BreakPenaltyAfterForLoopLParen) { Style); } +TEST_F(FormatTest, BreakPenaltyBeforeMemberAccess) { gedare wrote: I'm confused by the sorting request. I put it where it is lexicographically sorted. ht

[clang] [OpenMP] Allow OMP6.0 features. (PR #122108)

2025-01-27 Thread Michael Kruse via cfe-commits
@@ -1,46 +1,89 @@ -// RUN: %clang_cc1 -triple x86_64-apple-macos10.7.0 -verify=expected,omp45 -fopenmp -fopenmp-version=45 -fnoopenmp-use-tls -ferror-limit 100 -o - %s -// RUN: %clang_cc1 -triple x86_64-apple-macos10.7.0 -verify=expected,omp5,host5 -fopenmp -fopenmp-version=50

[clang] [OpenMP] Allow OMP6.0 features. (PR #122108)

2025-01-27 Thread Michael Kruse via cfe-commits
@@ -254,4 +256,3 @@ int main(int argc, char **argv) { foomain(argc,argv); // expected-note {{n instantiation of function template specialization 'foomain' requested here}} return 0; } - Meinersbur wrote: [nit] unrelated change https://github.com/llvm/llv

[clang] [clang] Fix heap-use-after-free in TryAnnotateTypeOrScopeTokenAfterScopeSpec (PR #124521)

2025-01-27 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: You need to add a test. We have ASan buildbots, but they only run post-merge. You can use `LLVM_USE_SANITIZER` [CMake option](https://llvm.org/docs/CMake.html#:~:text=llvm_use_sanitizer%3Astring) to check locally that Clang crashes on your test without the fix. https://github.c

[clang] Add configuration option PenaltyBreakBeforeMemberAccess (PR #118409)

2025-01-27 Thread Gedare Bloom via cfe-commits
@@ -4316,7 +4316,7 @@ unsigned TokenAnnotator::splitPenalty(const AnnotatedLine &Line, // aaa // .a.(); return !Right.NextOperator || !Right.NextOperator->Previous->closesScope() - ? 150 + ? Style.Pena

[clang] a01e1d4 - [clang][Sema] Handle dependent qualifier in HeuristicResolver::resolveDeclRefExpr() (#124515)

2025-01-27 Thread via cfe-commits
Author: Nathan Ridge Date: 2025-01-27T03:31:56-05:00 New Revision: a01e1d4e044ec0147e04a5af9ca54ede550f5dc1 URL: https://github.com/llvm/llvm-project/commit/a01e1d4e044ec0147e04a5af9ca54ede550f5dc1 DIFF: https://github.com/llvm/llvm-project/commit/a01e1d4e044ec0147e04a5af9ca54ede550f5dc1.diff

[clang-tools-extra] [clang-tidy] add AllowedTypes option to misc-const-correctness (PR #122951)

2025-01-27 Thread Baranov Victor via cfe-commits
vbvictor wrote: Ping https://github.com/llvm/llvm-project/pull/122951 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix a use-after-free in expression evaluation (PR #118480)

2025-01-27 Thread Viktoriia Bakalova via cfe-commits
VitaNuo wrote: > If anyone wants to take over/help, feel free to do so. SGTM. I could reproduce the issue, but then ran out of capacity. I'm not sure I'll be able to prioritize this soon vs. the module-related work. https://github.com/llvm/llvm-project/pull/118480

[clang-tools-extra] [clang-tidy] Refactor: removed typos in 'AllowedTypes' option in various checks (PR #122957)

2025-01-27 Thread Baranov Victor via cfe-commits
vbvictor wrote: @EugeneZelenko Ping I would also need assistance in merging this PR since I don't have write permissions. https://github.com/llvm/llvm-project/pull/122957 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/c

[clang] [clang] Add dump() support for lvalue APValues (PR #124476)

2025-01-27 Thread via cfe-commits
Timm =?utf-8?q?B=C3=A4der?= , Timm =?utf-8?q?B=C3=A4der?= , Timm =?utf-8?q?B=C3=A4der?= Message-ID: In-Reply-To: https://github.com/cor3ntin approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/124476 ___ cfe-commits mailing li

[clang] [llvm] [RISCV] Add MIPS extensions (PR #121394)

2025-01-27 Thread Djordje Todorovic via cfe-commits
@@ -514,6 +514,80 @@ class RVInstJhttps://github.com/llvm/llvm-project/pull/121394 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [RISCV] Add MIPS extensions (PR #121394)

2025-01-27 Thread Djordje Todorovic via cfe-commits
@@ -514,6 +514,80 @@ class RVInstJhttps://github.com/llvm/llvm-project/pull/121394 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix heap-use-after-free in TryAnnotateTypeOrScopeTokenAfterScopeSpec (PR #124521)

2025-01-27 Thread via cfe-commits
cor3ntin wrote: Do you have a test case for this? https://github.com/llvm/llvm-project/pull/124521 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix heap-use-after-free in TryAnnotateTypeOrScopeTokenAfterScopeSpec (PR #124521)

2025-01-27 Thread via cfe-commits
github-actions[bot] wrote: ⚠️ We detected that you are using a GitHub private e-mail address to contribute to the repo. Please turn off [Keep my email addresses private](https://github.com/settings/emails) setting in your account. See [LLVM Discourse](https://discourse.llvm.org/t/hidden-email

[clang] [llvm] [RISCV] Renaming muladdi to muliadd as per v0.5 spec. (PR #124237)

2025-01-27 Thread via cfe-commits
https://github.com/hchandel updated https://github.com/llvm/llvm-project/pull/124237 >From e83637504f6ddf5b21ca5e7351c7b83236f360b5 Mon Sep 17 00:00:00 2001 From: Harsh Chandel Date: Fri, 24 Jan 2025 12:38:13 +0530 Subject: [PATCH 1/2] [RISCV] Renaming muladdi to muliadd as per v0.5 spec. NFC

[clang] [clang][ASTImporter][test] Add test for importing explicit object parameter (PR #124305)

2025-01-27 Thread Michael Buch via cfe-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/124305 >From 2fbabc9802e09a175bd71624b2ff89a2d9b7f3a1 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Fri, 24 Jan 2025 11:59:42 + Subject: [PATCH 1/2] [clang][ASTImporter][test] Add test for importing explici

[clang] [Clang][OpenCL][AMDGPU] Allow a kernel to call another kernel (PR #115821)

2025-01-27 Thread Aniket Lal via cfe-commits
@@ -5692,7 +5692,10 @@ CGCallee CodeGenFunction::EmitCallee(const Expr *E) { // Resolve direct calls. } else if (auto DRE = dyn_cast(E)) { if (auto FD = dyn_cast(DRE->getDecl())) { - return EmitDirectCallee(*this, FD); + auto CalleeDecl = FD->hasAttr() +

[clang] [clang][ASTImporter][test] Add test for importing explicit object parameter (PR #124305)

2025-01-27 Thread Michael Buch via cfe-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/124305 >From 2fbabc9802e09a175bd71624b2ff89a2d9b7f3a1 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Fri, 24 Jan 2025 11:59:42 + Subject: [PATCH 1/3] [clang][ASTImporter][test] Add test for importing explici

[clang] [clang][ASTImporter] Import source location of explicit object parameter instead of copying it (PR #124305)

2025-01-27 Thread Michael Buch via cfe-commits
https://github.com/Michael137 edited https://github.com/llvm/llvm-project/pull/124305 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][OpenCL][AMDGPU] Allow a kernel to call another kernel (PR #115821)

2025-01-27 Thread Aniket Lal via cfe-commits
https://github.com/lalaniket8 deleted https://github.com/llvm/llvm-project/pull/115821 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][ASTImporter] Import source location of explicit object parameter instead of copying it (PR #124305)

2025-01-27 Thread Michael Buch via cfe-commits
@@ -3441,13 +3441,33 @@ TEST_P(ASTImporterOptionSpecificTestBase, ImportParmVarDecl) { ASSERT_TRUE(FromVar); ASSERT_TRUE(FromVar->hasUninstantiatedDefaultArg()); ASSERT_TRUE(FromVar->getUninstantiatedDefaultArg()); + ASSERT_FALSE(FromVar->isExplicitObjectParameter());

[clang] [clang][ASTImporter] Import source location of explicit object parameter instead of copying it (PR #124305)

2025-01-27 Thread Michael Buch via cfe-commits
https://github.com/Michael137 edited https://github.com/llvm/llvm-project/pull/124305 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][ASTImporter] Fix possible crash at import of function template (PR #124273)

2025-01-27 Thread Michael Buch via cfe-commits
=?utf-8?q?Bal=C3=A1zs_K=C3=A9ri?= Message-ID: In-Reply-To: https://github.com/Michael137 approved this pull request. https://github.com/llvm/llvm-project/pull/124273 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-

[clang] [llvm] [RISCV] Renaming muladdi to muliadd as per v0.5 spec. (PR #124237)

2025-01-27 Thread via cfe-commits
hchandel wrote: > Please can you check the extension version in LLVM is still correct, and if > not update it (including the docs and release notes) The extension version is changed to 0.3 in accordance with the spec. Please have a look at the changes. > This is not NFC either, so fix the PR ti

[clang] [clang][Sema] Handle dependent qualifier in HeuristicResolver::resolveDeclRefExpr() (PR #124515)

2025-01-27 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `clang-s390x-linux` running on `systemz-1` while building `clang` at step 5 "ninja check 1". Full details are available at: https://lab.llvm.org/buildbot/#/builders/42/builds/2985 Here is the relevant piece of the build log f

[clang] [Sema] Fix __array_rank queried type at template instantiation (PR #124491)

2025-01-27 Thread via cfe-commits
https://github.com/cor3ntin updated https://github.com/llvm/llvm-project/pull/124491 >From 9063b4f5ada77fa593b8e23e4706a2cd126e5858 Mon Sep 17 00:00:00 2001 From: v01dxyz Date: Sun, 26 Jan 2025 23:07:13 +0100 Subject: [PATCH] [Sema] Fix __array_rank queried type at template instantiation The

[clang] [Sema] Fix __array_rank queried type at template instantiation (PR #124491)

2025-01-27 Thread via cfe-commits
https://github.com/cor3ntin approved this pull request. https://github.com/llvm/llvm-project/pull/124491 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][analyzer][docs] Improve Annotations.rst (PR #122749)

2025-01-27 Thread Kristóf Umann via cfe-commits
https://github.com/Szelethus approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/122749 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Add configuration option PenaltyBreakBeforeMemberAccess (PR #118409)

2025-01-27 Thread Owen Pan via cfe-commits
@@ -22365,6 +22365,19 @@ TEST_F(FormatTest, BreakPenaltyAfterForLoopLParen) { Style); } +TEST_F(FormatTest, BreakPenaltyBeforeMemberAccess) { owenca wrote: Please move up this test to line 22307 to keep the `PenaltyBreak...` options (kind of)

[clang] [clang-format] Treat uppercase identifiers after struct as macros (PR #124397)

2025-01-27 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `flang-aarch64-dylib` running on `linaro-flang-aarch64-dylib` while building `clang` at step 5 "build-unified-tree". Full details are available at: https://lab.llvm.org/buildbot/#/builders/50/builds/9439 Here is the relevant

[clang] [clang] Fix heap-use-after-free in TryAnnotateTypeOrScopeTokenAfterScopeSpec (PR #124521)

2025-01-27 Thread via cfe-commits
https://github.com/Shivam7-1 created https://github.com/llvm/llvm-project/pull/124521 issue link: https://issues.oss-fuzz.com/issues/392279308 in this pull request addresses a heap-use-after-free vulnerability in the TryAnnotateTypeOrScopeTokenAfterScopeSpec function by adding a check to ensure

[clang] [Sema] Fix __array_rank queried type at template instantiation (PR #124491)

2025-01-27 Thread Robert Dazi via cfe-commits
https://github.com/v01dXYZ updated https://github.com/llvm/llvm-project/pull/124491 >From 9063b4f5ada77fa593b8e23e4706a2cd126e5858 Mon Sep 17 00:00:00 2001 From: v01dxyz Date: Sun, 26 Jan 2025 23:07:13 +0100 Subject: [PATCH] [Sema] Fix __array_rank queried type at template instantiation The t

[clang] 7211bf4 - [flang][driver] add negative from of -fsave-main-program (#124110)

2025-01-27 Thread via cfe-commits
Author: jeanPerier Date: 2025-01-27T10:51:23+01:00 New Revision: 7211bf48a62bfe3a181013f412f2fa6e112ae99f URL: https://github.com/llvm/llvm-project/commit/7211bf48a62bfe3a181013f412f2fa6e112ae99f DIFF: https://github.com/llvm/llvm-project/commit/7211bf48a62bfe3a181013f412f2fa6e112ae99f.diff LO

[clang] [flang] [flang][driver] add negative from of -fsave-main-program (PR #124110)

2025-01-27 Thread via cfe-commits
https://github.com/jeanPerier closed https://github.com/llvm/llvm-project/pull/124110 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] raise extension warning for unknown namespaced attributes (PR #120925)

2025-01-27 Thread via cfe-commits
cor3ntin wrote: Ultimately we want 1. I know all of these attributes, don't tell me about them 2. I know all of these attribute namespaces, don't tell me about them - which this patch is doing 3. Have a way to disable unknown attributes warnings for all unknown namespaces - which this patc

[clang] [X86][AVX10] Disable m[no-]avx10.1 and switch m[no-]avx10.2 to alias of 512 bit options (PR #124511)

2025-01-27 Thread Phoebe Wang via cfe-commits
phoebewang wrote: > > We also change -mno-avx10.[1,2]-512 to alias of 256 bit options to disable > > both 256 and 512 instructions. > > Why this? Because we expect m[no-]avx10.2 cover both 256 and 512 bit instructions. https://github.com/llvm/llvm-project/pull/124511 _

[clang] [clang] Fix heap-use-after-free in TryAnnotateTypeOrScopeTokenAfterScopeSpec (PR #124521)

2025-01-27 Thread via cfe-commits
Shivam7-1 wrote: Hii @cor3ntin testcase is present here https://issues.oss-fuzz.com/issues/392279308 https://oss-fuzz.com/download?testcase_id=5380708478025728 https://github.com/llvm/llvm-project/pull/124521 ___ cfe-commits mailing list cfe-commits@

[clang] [clang][Sema] Handle dependent qualifier in HeuristicResolver::resolveDeclRefExpr() (PR #124515)

2025-01-27 Thread Nathan Ridge via cfe-commits
https://github.com/HighCommander4 closed https://github.com/llvm/llvm-project/pull/124515 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [RISCV] Add MIPS extensions (PR #121394)

2025-01-27 Thread Djordje Todorovic via cfe-commits
https://github.com/djolertrk deleted https://github.com/llvm/llvm-project/pull/121394 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix heap-use-after-free in TryAnnotateTypeOrScopeTokenAfterScopeSpec (PR #124521)

2025-01-27 Thread via cfe-commits
github-actions[bot] wrote: :warning: C/C++ code formatter, clang-format found issues in your code. :warning: You can test this locally with the following command: ``bash git-clang-format --diff 9452ee4f750a849148a391ac75eb31220343fa1e 3c3dbfa63c27f4c7cd589a731845f9489f8e2b64 --e

[clang] [AST] Migrate away from PointerUnion::dyn_cast (NFC) (PR #124502)

2025-01-27 Thread Nikita Popov via cfe-commits
https://github.com/nikic approved this pull request. https://github.com/llvm/llvm-project/pull/124502 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Reapply CWG2369 "Ordering between constraints and substitution" (PR #122423)

2025-01-27 Thread via cfe-commits
https://github.com/cor3ntin edited https://github.com/llvm/llvm-project/pull/122423 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Reapply CWG2369 "Ordering between constraints and substitution" (PR #122423)

2025-01-27 Thread via cfe-commits
https://github.com/cor3ntin edited https://github.com/llvm/llvm-project/pull/122423 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Add configuration option PenaltyBreakBeforeMemberAccess (PR #118409)

2025-01-27 Thread Owen Pan via cfe-commits
@@ -22365,6 +22365,19 @@ TEST_F(FormatTest, BreakPenaltyAfterForLoopLParen) { Style); } +TEST_F(FormatTest, BreakPenaltyBeforeMemberAccess) { + FormatStyle Style = getLLVMStyle(); + Style.ColumnLimit = 8; + Style.PenaltyExcessCharacter = 15; + verifyFormat("

[clang] Add configuration option PenaltyBreakBeforeMemberAccess (PR #118409)

2025-01-27 Thread Owen Pan via cfe-commits
@@ -4316,7 +4316,7 @@ unsigned TokenAnnotator::splitPenalty(const AnnotatedLine &Line, // aaa // .a.(); return !Right.NextOperator || !Right.NextOperator->Previous->closesScope() - ? 150 + ? Style.Pena

[clang] [Clang] Reapply CWG2369 "Ordering between constraints and substitution" (PR #122423)

2025-01-27 Thread Younan Zhang via cfe-commits
@@ -5284,8 +5284,22 @@ void Sema::InstantiateFunctionDefinition(SourceLocation PointOfInstantiation, savedContext.pop(); } - DeclGroupRef DG(Function); - Consumer.HandleTopLevelDecl(DG); + // With CWG2369, we substitute constraints before instantiating the associate

[clang] 9452ee4 - [clang-format] Treat uppercase identifiers after struct as macros (#124397)

2025-01-27 Thread via cfe-commits
Author: Owen Pan Date: 2025-01-27T00:11:18-08:00 New Revision: 9452ee4f750a849148a391ac75eb31220343fa1e URL: https://github.com/llvm/llvm-project/commit/9452ee4f750a849148a391ac75eb31220343fa1e DIFF: https://github.com/llvm/llvm-project/commit/9452ee4f750a849148a391ac75eb31220343fa1e.diff LOG:

[clang] [clang-format] Treat uppercase identifiers after struct as macros (PR #124397)

2025-01-27 Thread Owen Pan via cfe-commits
https://github.com/owenca closed https://github.com/llvm/llvm-project/pull/124397 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Add -fwrapv-pointer flag (PR #122486)

2025-01-27 Thread Nikita Popov via cfe-commits
https://github.com/nikic updated https://github.com/llvm/llvm-project/pull/122486 >From 925f74cad21eb6c46514d1ae543ac202073baf27 Mon Sep 17 00:00:00 2001 From: Nikita Popov Date: Fri, 10 Jan 2025 17:01:07 +0100 Subject: [PATCH 1/5] [Clang] Add -fwrapv-pointer flag GCC supports three flags rela

[clang] [clang] Fix heap-use-after-free in TryAnnotateTypeOrScopeTokenAfterScopeSpec (PR #124521)

2025-01-27 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (Shivam7-1) Changes issue link: https://issues.oss-fuzz.com/issues/392279308 in this pull request addresses a heap-use-after-free vulnerability in the TryAnnotateTypeOrScopeTokenAfterScopeSpec function by adding a check to ensure tha

[clang] [clang] Fix heap-use-after-free in TryAnnotateTypeOrScopeTokenAfterScopeSpec (PR #124521)

2025-01-27 Thread via cfe-commits
github-actions[bot] wrote: Thank you for submitting a Pull Request (PR) to the LLVM Project! This PR will be automatically labeled and the relevant teams will be notified. If you wish to, you can add reviewers by using the "Reviewers" section on this page. If this is not working for you, it

[clang] [clang] Fix a use-after-free in expression evaluation (PR #118480)

2025-01-27 Thread kadir çetinkaya via cfe-commits
kadircet wrote: > ping, is this still a problem? yes, this is still happening. but I am currently lacking cycles to dig deeper into expression evaluation to see if this is the right fix given the reproducer. @VitaNuo was to take a look with some limited capacity, but I think she's also in a s

[clang] 87103a0 - [AArch64] Implement NEON FP8 vectors as VectorType (#123603)

2025-01-27 Thread via cfe-commits
Author: Momchil Velikov Date: 2025-01-27T10:41:53Z New Revision: 87103a016fbfd480e1d3bb8eba23c27a9c74e70d URL: https://github.com/llvm/llvm-project/commit/87103a016fbfd480e1d3bb8eba23c27a9c74e70d DIFF: https://github.com/llvm/llvm-project/commit/87103a016fbfd480e1d3bb8eba23c27a9c74e70d.diff LO

[clang] [nfc][analyzer] Add MemSpace trait to program state (PR #123003)

2025-01-27 Thread Donát Nagy via cfe-commits
NagyDonat wrote: > > > Have you considered changing `MemRegion::getMemorySpace()` into > > > `MemRegion::getMemorySpace(ProgramStateRef)`? > > > > > > I thought about this, but I decided against it since I am thinking that > > MemSpaces will eventually be their own separate thing, not part of

[clang] [AArch64] Implement NEON FP8 vectors as VectorType (PR #123603)

2025-01-27 Thread Momchil Velikov via cfe-commits
https://github.com/momchil-velikov closed https://github.com/llvm/llvm-project/pull/123603 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][ASTImporter] Import source location of explicit object parameter instead of copying it (PR #124305)

2025-01-27 Thread Michael Buch via cfe-commits
https://github.com/Michael137 updated https://github.com/llvm/llvm-project/pull/124305 >From 2fbabc9802e09a175bd71624b2ff89a2d9b7f3a1 Mon Sep 17 00:00:00 2001 From: Michael Buch Date: Fri, 24 Jan 2025 11:59:42 + Subject: [PATCH 1/4] [clang][ASTImporter][test] Add test for importing explici

[clang] [clang][ASTImporter] Fix possible crash at import of function template (PR #124273)

2025-01-27 Thread Michael Buch via cfe-commits
=?utf-8?q?Balázs_Kéri?= Message-ID: In-Reply-To: Michael137 wrote: > If this case is not handled, the following `setDescribedFunctionTemplate` > will run into an assertion. The case happens in the test code. What exactly > happens is that because of the `__get_first_arg` mismatch a field >

[clang] [OpenMP] Allow OMP6.0 features. (PR #122108)

2025-01-27 Thread Michael Kruse via cfe-commits
@@ -1,46 +1,89 @@ -// RUN: %clang_cc1 -triple x86_64-apple-macos10.7.0 -verify=expected,omp45 -fopenmp -fopenmp-version=45 -fnoopenmp-use-tls -ferror-limit 100 -o - %s -// RUN: %clang_cc1 -triple x86_64-apple-macos10.7.0 -verify=expected,omp5,host5 -fopenmp -fopenmp-version=50

[clang] Add configuration option PenaltyBreakBeforeMemberAccess (PR #118409)

2025-01-27 Thread Gedare Bloom via cfe-commits
@@ -4316,7 +4316,7 @@ unsigned TokenAnnotator::splitPenalty(const AnnotatedLine &Line, // aaa // .a.(); return !Right.NextOperator || !Right.NextOperator->Previous->closesScope() - ? 150 + ? Style.Pena

[clang] [OpenMP] Allow OMP6.0 features. (PR #122108)

2025-01-27 Thread Michael Kruse via cfe-commits
@@ -1,46 +1,89 @@ -// RUN: %clang_cc1 -triple x86_64-apple-macos10.7.0 -verify=expected,omp45 -fopenmp -fopenmp-version=45 -fnoopenmp-use-tls -ferror-limit 100 -o - %s -// RUN: %clang_cc1 -triple x86_64-apple-macos10.7.0 -verify=expected,omp5,host5 -fopenmp -fopenmp-version=50

[clang] [llvm] [AArch64] Add Neon FP8 conversion intrinsics (PR #123612)

2025-01-27 Thread Momchil Velikov via cfe-commits
https://github.com/momchil-velikov updated https://github.com/llvm/llvm-project/pull/123612 >From 7ff7e9588f6a76dcbe7deb2dc5f78055f71b476b Mon Sep 17 00:00:00 2001 From: Momchil Velikov Date: Fri, 6 Dec 2024 19:24:16 + Subject: [PATCH] [AArch64] Add Neon FP8 conversion intrinsics [fixup] A

[clang] e14962a - [NFC][DebugInfo] Use iterators for instruction insertion in more places (#124291)

2025-01-27 Thread via cfe-commits
Author: Jeremy Morse Date: 2025-01-27T15:25:17Z New Revision: e14962a39cc6476bebba65e5639b74b0318c7fc3 URL: https://github.com/llvm/llvm-project/commit/e14962a39cc6476bebba65e5639b74b0318c7fc3 DIFF: https://github.com/llvm/llvm-project/commit/e14962a39cc6476bebba65e5639b74b0318c7fc3.diff LOG:

[clang] [clang][ExprConst] Don't diagnose a non-existent init as not constant (PR #124575)

2025-01-27 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/124575 None >From c0cee82829632b0b3b78bfd00f1c03a9a565dfff Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Mon, 27 Jan 2025 16:55:05 +0100 Subject: [PATCH] [clang][ExprConst] Don't diagnose a non-e

[clang] [PGO] Add a clang option -fprofile-continuous that enables PGO continuous mode (PR #124353)

2025-01-27 Thread Wael Yehia via cfe-commits
@@ -1886,6 +1886,11 @@ def fprofile_update_EQ : Joined<["-"], "fprofile-update=">, Values<"atomic,prefer-atomic,single">, MetaVarName<"">, HelpText<"Set update method of profile counters">, MarshallingInfoFlag>; +def fprofile_continuous : Flag<["-"], "fprofile-cont

[clang] [llvm] [NFC][DebugInfo] Use iterators for instruction insertion in more places (PR #124291)

2025-01-27 Thread Jeremy Morse via cfe-commits
jmorse wrote: Ta; fixed some of the clang-format errors that are on lines that I've touched, however I'm leaving the clang-format errors that are adjacent (there are some pre-existing indentation issues too it seems). https://github.com/llvm/llvm-project/pull/124291 ___

[clang] [llvm] [mlir] [Offload] Rework offloading entry type to be more generic (PR #124018)

2025-01-27 Thread Jan Patrick Lehr via cfe-commits
@@ -24,11 +24,24 @@ namespace offloading { /// This is the record of an object that just be registered with the offloading /// runtime. struct EntryTy { + /// Reserved bytes used to detect an older version of the struct, always zero. + uint64_t Reserved = 0x0; + /// The cur

[clang-tools-extra] [clang-tidy] add AllowedTypes option to misc-const-correctness (PR #122951)

2025-01-27 Thread Baranov Victor via cfe-commits
https://github.com/vbvictor updated https://github.com/llvm/llvm-project/pull/122951 >From 841cfec5a0ab4ce5ce64e71facfb7becaf4340e8 Mon Sep 17 00:00:00 2001 From: Victor Baranov Date: Tue, 14 Jan 2025 22:05:43 +0300 Subject: [PATCH 1/6] [clang-tidy] add AllowedTypes to misc-const-correctness -

[clang] [lldb] [lldb] Analyze enum promotion type during parsing (PR #115005)

2025-01-27 Thread Ilia Kuklin via cfe-commits
https://github.com/kuilpd updated https://github.com/llvm/llvm-project/pull/115005 >From 4d797371598960baf7729d05590aa1a8c7077694 Mon Sep 17 00:00:00 2001 From: Ilia Kuklin Date: Mon, 4 Nov 2024 14:33:45 +0500 Subject: [PATCH 1/6] [lldb] Analyze enum promotion type during parsing --- clang/in

[clang] [Clang] Skip past code generation for unevaluated lambdas (PR #124572)

2025-01-27 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 created https://github.com/llvm/llvm-project/pull/124572 This is taken from https://github.com/llvm/llvm-project/pull/122423#discussion_r1930102632 as suggested by Corentin. Fixes #82926 >From f515e670d35365f14f063e02eb10cd41e3751937 Mon Sep 17 00:00:00 2001 From:

[clang-tools-extra] [clang-tidy] add AllowedTypes option to misc-const-correctness (PR #122951)

2025-01-27 Thread Baranov Victor via cfe-commits
@@ -196,3 +196,12 @@ Options // The following pointer may not become a 'int *const'. int *changing_pointee = &value; changing_pointee = &result; + +.. option:: AllowedTypes (default = '') vbvictor wrote: Placed default in last sentence. https://gi

[clang] [llvm] [mlir] [Offload] Rework offloading entry type to be more generic (PR #124018)

2025-01-27 Thread Shilei Tian via cfe-commits
@@ -317,6 +317,9 @@ GlobalVariable *createFatbinDesc(Module &M, ArrayRef Image, bool IsHIP, /// void __cudaRegisterTest(void **fatbinHandle) { /// for (struct __tgt_offload_entry *entry = &__start_cuda_offloading_entries; ///entry != &__stop_cuda_offloading_entries;

[clang] [flang] [llvm] [Clang] Remove ARCMigrate (PR #119269)

2025-01-27 Thread via cfe-commits
Sirraide wrote: ping https://github.com/llvm/llvm-project/pull/119269 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [mlir] [Offload] Rework offloading entry type to be more generic (PR #124018)

2025-01-27 Thread Shilei Tian via cfe-commits
@@ -317,6 +317,9 @@ GlobalVariable *createFatbinDesc(Module &M, ArrayRef Image, bool IsHIP, /// void __cudaRegisterTest(void **fatbinHandle) { /// for (struct __tgt_offload_entry *entry = &__start_cuda_offloading_entries; ///entry != &__stop_cuda_offloading_entries;

[clang] [llvm] [mlir] [Offload] Rework offloading entry type to be more generic (PR #124018)

2025-01-27 Thread Shilei Tian via cfe-commits
@@ -24,11 +24,24 @@ namespace offloading { /// This is the record of an object that just be registered with the offloading /// runtime. struct EntryTy { + /// Reserved bytes used to detect an older version of the struct, always zero. + uint64_t Reserved = 0x0; --

[clang] [llvm] [mlir] [Offload] Rework offloading entry type to be more generic (PR #124018)

2025-01-27 Thread Shilei Tian via cfe-commits
https://github.com/shiltian edited https://github.com/llvm/llvm-project/pull/124018 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [mlir] [Offload] Rework offloading entry type to be more generic (PR #124018)

2025-01-27 Thread Shilei Tian via cfe-commits
https://github.com/shiltian commented: This looks like some changes worth in the release note? https://github.com/llvm/llvm-project/pull/124018 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-

[clang] Add configuration option PenaltyBreakBeforeMemberAccess (PR #118409)

2025-01-27 Thread Gedare Bloom via cfe-commits
https://github.com/gedare updated https://github.com/llvm/llvm-project/pull/118409 >From 86bc2d2fe03d84879870eec1a8c10912076686c2 Mon Sep 17 00:00:00 2001 From: Gedare Bloom Date: Mon, 2 Dec 2024 15:16:39 -0700 Subject: [PATCH 1/5] [clang-format] Add PenaltyBreakBeforeMemberAccess Add a config

[clang] Add configuration option PenaltyBreakBeforeMemberAccess (PR #118409)

2025-01-27 Thread Gedare Bloom via cfe-commits
@@ -22365,6 +22365,19 @@ TEST_F(FormatTest, BreakPenaltyAfterForLoopLParen) { Style); } +TEST_F(FormatTest, BreakPenaltyBeforeMemberAccess) { + FormatStyle Style = getLLVMStyle(); + Style.ColumnLimit = 8; + Style.PenaltyExcessCharacter = 15; + verifyFormat("

[clang] [clang][ASTImporter] Fix possible crash at import of function template (PR #124273)

2025-01-27 Thread Balázs Kéri via cfe-commits
https://github.com/balazske updated https://github.com/llvm/llvm-project/pull/124273 From 4109a5166b544c33af333505883b414db7c0c14d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Bal=C3=A1zs=20K=C3=A9ri?= Date: Wed, 22 Jan 2025 17:55:51 +0100 Subject: [PATCH 1/3] fix test --- clang/lib/AST/ASTImport

[clang] [clang-format] add BinPackLongBracedLists style option (PR #112482)

2025-01-27 Thread Gedare Bloom via cfe-commits
gedare wrote: @owenca if you could take another look at this PR I'd appreciate it. https://github.com/llvm/llvm-project/pull/112482 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][counted_by] Refactor __builtin_dynamic_object_size on FAMs (PR #122198)

2025-01-27 Thread Bill Wendling via cfe-commits
bwendling wrote: Friendly Ping. https://github.com/llvm/llvm-project/pull/122198 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Address false positives in misc-redundant-expression checker (PR #122841)

2025-01-27 Thread via cfe-commits
https://github.com/earnol updated https://github.com/llvm/llvm-project/pull/122841 >From c26434fea8a3ebf546139805ab4f7ef5d2f4252d Mon Sep 17 00:00:00 2001 From: Vladislav Aranov Date: Mon, 13 Jan 2025 20:19:58 -0500 Subject: [PATCH 1/2] [clang-tidy] Address false positives in misc-redundant-ex

[clang] Optimize -Wunsafe-buffer-usage. (PR #124554)

2025-01-27 Thread Ilya Biryukov via cfe-commits
@@ -186,106 +205,202 @@ class MatchDescendantVisitor : public DynamicRecursiveASTVisitor { return DynamicRecursiveASTVisitor::TraverseStmt(Node); } + void set_ast_context(ASTContext &Context) { ActiveASTContext = &Context; } + + void set_handler(const UnsafeBufferUsag

[clang-tools-extra] [clang-tidy] add AllowedTypes option to misc-const-correctness (PR #122951)

2025-01-27 Thread Baranov Victor via cfe-commits
vbvictor wrote: > Please also fix preceding option defaults. Fixed preceding option defaults https://github.com/llvm/llvm-project/pull/122951 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-c

[clang] Optimize -Wunsafe-buffer-usage. (PR #124554)

2025-01-27 Thread Ilya Biryukov via cfe-commits
@@ -79,21 +81,39 @@ static std::string getDREAncestorString(const DeclRefExpr *DRE, } // namespace #endif /* NDEBUG */ -namespace clang::ast_matchers { +class CustomMatcher { ilya-biryukov wrote: this class must go into an anonymous `namespace {}` to avoid O

[clang] Optimize -Wunsafe-buffer-usage. (PR #124554)

2025-01-27 Thread Ilya Biryukov via cfe-commits
@@ -186,106 +205,202 @@ class MatchDescendantVisitor : public DynamicRecursiveASTVisitor { return DynamicRecursiveASTVisitor::TraverseStmt(Node); } + void set_ast_context(ASTContext &Context) { ActiveASTContext = &Context; } + + void set_handler(const UnsafeBufferUsag

[clang] Optimize -Wunsafe-buffer-usage. (PR #124554)

2025-01-27 Thread Ilya Biryukov via cfe-commits
@@ -186,106 +205,202 @@ class MatchDescendantVisitor : public DynamicRecursiveASTVisitor { return DynamicRecursiveASTVisitor::TraverseStmt(Node); } + void set_ast_context(ASTContext &Context) { ActiveASTContext = &Context; } + + void set_handler(const UnsafeBufferUsag

[clang] Optimize -Wunsafe-buffer-usage. (PR #124554)

2025-01-27 Thread Ilya Biryukov via cfe-commits
@@ -31,27 +35,34 @@ #define FIXABLE_GADGET(name) GADGET(name) #endif +/// A subset of the safe gadgets that may return multiple results. +#ifndef FIXABLE_GADGET_MULTY_RES +#define FIXABLE_GADGET_MULTY_RES(name) GADGET(name) +#endif + WARNING_GADGET(Increment) WARNING_GADGET(

[clang] Optimize -Wunsafe-buffer-usage. (PR #124554)

2025-01-27 Thread Ilya Biryukov via cfe-commits
https://github.com/ilya-biryukov edited https://github.com/llvm/llvm-project/pull/124554 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Optimize -Wunsafe-buffer-usage. (PR #124554)

2025-01-27 Thread Ilya Biryukov via cfe-commits
@@ -186,106 +205,202 @@ class MatchDescendantVisitor : public DynamicRecursiveASTVisitor { return DynamicRecursiveASTVisitor::TraverseStmt(Node); } + void set_ast_context(ASTContext &Context) { ActiveASTContext = &Context; } + + void set_handler(const UnsafeBufferUsag

<    1   2   3   4   5   6   >