[clang] Thread Safety Analysis: Fix recursive capability alias resolution (PR #159921)

2025-09-22 Thread Marco Elver via cfe-commits
melver wrote: FYI - the refreshed Linux kernel series went out. In general, Linus Torvalds likes the feature, besides the name: https://lore.kernel.org/all/CAHk-=wgd-wcp0gpyaqnu7s9ci+fvfmanw1gm75mzf0zwdnl...@mail.gmail.com/ In the kernel we will have to choose yet another name ("Context Analysi

[clang] [clang-format] Correctly handle backward compatibility of C headers (PR #159908)

2025-09-22 Thread Björn Schäpers via cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request. https://github.com/llvm/llvm-project/pull/159908 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AArch64] Enable out-of-line atomics by default (PR #157241)

2025-09-22 Thread Brad Smith via cfe-commits
https://github.com/brad0 updated https://github.com/llvm/llvm-project/pull/157241 >From 9769f3a3171d3f77d57284cbf4045cb38466d463 Mon Sep 17 00:00:00 2001 From: Brad Smith Date: Sat, 6 Sep 2025 03:43:30 -0400 Subject: [PATCH] [AArch64] Enable out-of-line atomics by default --- clang/include/cl

[clang] [Clang] Support includes translated to module imports in -header-include-filtering=direct-per-file (PR #156756)

2025-09-22 Thread Sina Mahdavi via cfe-commits
https://github.com/sina-mahdavi updated https://github.com/llvm/llvm-project/pull/156756 >From 8ab5647fc5c51b42bb67ca46a063fa9815ea46f4 Mon Sep 17 00:00:00 2001 From: Sina Mahdavi Date: Wed, 3 Sep 2025 14:17:27 -0700 Subject: [PATCH 1/6] [Clang] Support includes translated to module imports in

[clang] [Driver] Enable __float128 support on X86 on Hurd (PR #160045)

2025-09-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Brad Smith (brad0) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/160045.diff 2 Files Affected: - (modified) clang/lib/Basic/Targets/OSTargets.h (+13-1) - (modified) clang/test/CodeGenCXX/float128-declarations.cpp (+

[clang] [Driver] Enable __float128 support on X86 on Hurd (PR #160045)

2025-09-22 Thread Brad Smith via cfe-commits
https://github.com/brad0 created https://github.com/llvm/llvm-project/pull/160045 None >From 2b1cbc307d9285cf9b41fd566ba1e21f142451c4 Mon Sep 17 00:00:00 2001 From: Brad Smith Date: Mon, 22 Sep 2025 04:05:21 -0400 Subject: [PATCH] [Driver] Enable __float128 support on X86 on Hurd --- clang/l

[clang] [clang-format] add option to control bin-packing keyworded parameters (PR #131605)

2025-09-22 Thread Eugene Shalygin via cfe-commits
https://github.com/zeule closed https://github.com/llvm/llvm-project/pull/131605 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] add option to control bin-packing keyworded parameters (PR #131605)

2025-09-22 Thread Eugene Shalygin via cfe-commits
zeule wrote: Thanks! https://github.com/llvm/llvm-project/pull/131605 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Driver] Enable __float128 support on X86 on Hurd (PR #160045)

2025-09-22 Thread Brad Smith via cfe-commits
brad0 wrote: cc @sthibaul https://github.com/llvm/llvm-project/pull/160045 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix crash with -lstdc++ in -ccc-print-phases (#160046) (PR #160047)

2025-09-22 Thread via cfe-commits
https://github.com/pzzp created https://github.com/llvm/llvm-project/pull/160047 None >From 42684cfbd295cefb5c4ace1584345028b65d5f5c Mon Sep 17 00:00:00 2001 From: zhoupeng12 Date: Mon, 22 Sep 2025 15:55:57 +0800 Subject: [PATCH] [clang] fix crash of `clang -ccc-print-phases -lstdc++` --- cla

[clang] [clang] Fix crash with -lstdc++ in -ccc-print-phases (#160046) (PR #160047)

2025-09-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (pzzp) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/160047.diff 1 Files Affected: - (modified) clang/lib/Driver/Driver.cpp (+9-1) ``diff diff --git a/clang/lib/Driver/Driver.cpp b/clang/lib/Driver/Dr

[clang] [clang] Fix crash with -lstdc++ in -ccc-print-phases (#160046) (PR #160047)

2025-09-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-driver Author: None (pzzp) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/160047.diff 1 Files Affected: - (modified) clang/lib/Driver/Driver.cpp (+9-1) ``diff diff --git a/clang/lib/Driver/Driver.cpp b/clang/lib/Dr

[clang] [clang] Fix crash with -lstdc++ in -ccc-print-phases (#160046) (PR #160047)

2025-09-22 Thread via cfe-commits
pzzp wrote: see https://github.com/llvm/llvm-project/issues/160046 https://github.com/llvm/llvm-project/pull/160047 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Add SpaceBeforeUnderscoreParens option for GNU gettext… (PR #159925)

2025-09-22 Thread via cfe-commits
klausgerlicher wrote: > In general, we want the new option to meet the > [requirements](https://clang.llvm.org/docs/ClangFormatStyleOptions.html#adding-additional-style-options). > Can you link to the relevant section in GNU coding standards? It seems that > this can be supported without a new

[clang] [clang-format] Add AllowBreakBeforeQtProperty option (PR #159909)

2025-09-22 Thread via cfe-commits
https://github.com/owenca edited https://github.com/llvm/llvm-project/pull/159909 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Add AllowBreakBeforeQtProperty option (PR #159909)

2025-09-22 Thread via cfe-commits
https://github.com/owenca closed https://github.com/llvm/llvm-project/pull/159909 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Add SpaceBeforeUnderscoreParens option for GNU gettext… (PR #159925)

2025-09-22 Thread via cfe-commits
https://github.com/kgerlich updated https://github.com/llvm/llvm-project/pull/159925 >From c28a8842fa8cd38de9edfa210769bf1d527ef3a7 Mon Sep 17 00:00:00 2001 From: Klaus Gerlicher Date: Sat, 20 Sep 2025 15:13:10 +0200 Subject: [PATCH] [clang-format] Add SpaceBetweenUnderscoreParens option for G

[clang] [clang-format] add option to control bin-packing keyworded parameters (PR #131605)

2025-09-22 Thread via cfe-commits
owenca wrote: @zeule I've merged #159909. Do you want to close this pull request? https://github.com/llvm/llvm-project/pull/131605 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libclc] [libclc] Fix ctest failures after 7f3661128b1e: adjust external check and make shuffle helpers static (PR #160036)

2025-09-22 Thread Matt Arsenault via cfe-commits
https://github.com/arsenm approved this pull request. https://github.com/llvm/llvm-project/pull/160036 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Thread Safety Analysis: Fix recursive capability alias resolution (PR #159921)

2025-09-22 Thread Marco Elver via cfe-commits
https://github.com/melver updated https://github.com/llvm/llvm-project/pull/159921 >From ac8aa378015cd4167e5b11de9b11d48aa7732ce2 Mon Sep 17 00:00:00 2001 From: Marco Elver Date: Sat, 20 Sep 2025 14:37:44 +0200 Subject: [PATCH] Thread Safety Analysis: Fix recursive capability alias resolution

[clang] Thread Safety Analysis: Fix recursive capability alias resolution (PR #159921)

2025-09-22 Thread Marco Elver via cfe-commits
https://github.com/melver ready_for_review https://github.com/llvm/llvm-project/pull/159921 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Thread Safety Analysis: Fix recursive capability alias resolution (PR #159921)

2025-09-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang @llvm/pr-subscribers-clang-analysis Author: Marco Elver (melver) Changes Fix a false positive in thread safety alias analysis caused by incorrect late resolution of aliases. The analysis previously failed to distinguish between an alias and its d

[clang-tools-extra] [clang-tidy] New Option Invalid Enum Default Initialization (PR #159220)

2025-09-22 Thread Balázs Kéri via cfe-commits
balazske wrote: Code is good, just documentation can be updated (`std::errc` is always ignored) and formatting should be fixed. https://github.com/llvm/llvm-project/pull/159220 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm

[clang] [flang] [llvm] [openmp] [Clang][OpenMP][LoopTransformations] Add support for "#pragma omp fuse" loop transformation directive and "looprange" clause (PR #139293)

2025-09-22 Thread Roger Ferrer Ibáñez via cfe-commits
@@ -1485,7 +1498,81 @@ class SemaOpenMP : public SemaBase { bool checkTransformableLoopNest( OpenMPDirectiveKind Kind, Stmt *AStmt, int NumLoops, SmallVectorImpl &LoopHelpers, - Stmt *&Body, SmallVectorImpl> &OriginalInits); + Stmt *&Body, SmallVectorImp

[clang-tools-extra] [clang-tidy] Fix `modernize-use-nullptr` crash on 32-bit Windows (PR #160023)

2025-09-22 Thread Victor Chernyakin via cfe-commits
localspook wrote: > LGTM, wish we could automatically detect that because this is very easy to > miss. Could we maybe remove & from tuple to always store values. cc @AaronBallman as maintainer of AST matchers https://github.com/llvm/llvm-project/pull/160023

[clang] [AArch64] Enable out-of-line atomics by default (PR #157241)

2025-09-22 Thread Brad Smith via cfe-commits
https://github.com/brad0 updated https://github.com/llvm/llvm-project/pull/157241 >From de2d938498e3f8ba0ae08da1d638570eb846f18f Mon Sep 17 00:00:00 2001 From: Brad Smith Date: Sat, 6 Sep 2025 03:43:30 -0400 Subject: [PATCH] [AArch64] Enable out-of-line atomics by default --- clang/include/cl

[clang] [Headers][X86] Allow SSE2/AVX2/AVX512F/AVX512BW/AVX512DQ integer arithmetic intrinsics to be used in constexpr (PR #157582)

2025-09-22 Thread Simon Pilgrim via cfe-commits
https://github.com/RKSimon auto_merge_enabled https://github.com/llvm/llvm-project/pull/157582 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Headers][X86] Allow basic AVX512 predicate ops to be used in constexpr (PR #159998)

2025-09-22 Thread Simon Pilgrim via cfe-commits
https://github.com/RKSimon commented: Thanks @fennecJ this structure looks fine to me - I've added kadd to the intrinsic list in #158646 as it should be as easy to support as the logic ops now. https://github.com/llvm/llvm-project/pull/159998 ___ cfe

[clang] [clang-format] Add SpaceBeforeUnderscoreParens option for GNU gettext… (PR #159925)

2025-09-22 Thread via cfe-commits
owenca wrote: > > In general, we want the new option to meet the > > [requirements](https://clang.llvm.org/docs/ClangFormatStyleOptions.html#adding-additional-style-options). > > Can you link to the relevant section in GNU coding standards? It seems > > that this can be supported without a new

[clang] [analyzer] Correct crash in Z3 wrapper (PR #158276)

2025-09-22 Thread via cfe-commits
https://github.com/vabridgers updated https://github.com/llvm/llvm-project/pull/158276 >From ea74454a493413fce0fb9917c4d25340d73bf913 Mon Sep 17 00:00:00 2001 From: Vince Bridgers Date: Fri, 12 Sep 2025 13:19:40 +0200 Subject: [PATCH] [analyzer] Correct crash in Z3 wrapper If a UnarySymExpr wi

[clang] [clang] Fix crash with -lstdc++ in -ccc-print-phases (PR #160047)

2025-09-22 Thread via cfe-commits
pzzp wrote: @frederick-vs-ja ok, thanks https://github.com/llvm/llvm-project/pull/160047 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][clang] Quote literal builtin attribute markers in Builtins.def docs (PR #160080)

2025-09-22 Thread Erich Keane via cfe-commits
erichkeane wrote: Hmm... the quotes make it less obvious that these aren't supposed to be quoted in the Builtins.def file, so I don't know if we should do that. I think I'd rather we make it clear that `N` is sometimes. IF we had a way of formatting this instead of comments, perhaps highligh

[clang] [clang][test] Add test for comma operator rejection in preprocessor conditionals (PR #155570)

2025-09-22 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: Sure, additional context never hurts. https://github.com/llvm/llvm-project/pull/155570 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][clang] Quote literal builtin attribute markers in Builtins.def docs (PR #160080)

2025-09-22 Thread Erich Keane via cfe-commits
erichkeane wrote: > > But I'm not sure what we could use reasonably. > > We could replace it w/ e.g. `*` and add a note along the lines of ‘where `*` > is any integer/index/whatever it’s actually supposed to be’ Asterisk seems pretty overloaded here... maybe the same except with `{num}` or so

[clang] [clang][bytecode] Use in `Expr::tryEvaluateString` (PR #160118)

2025-09-22 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/160118 Fixes #157492 >From 817af36fba48a42670afc91dc49a3ad748187363 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Tue, 16 Sep 2025 16:02:15 +0200 Subject: [PATCH] try evaluate string --- clang/

[clang] [NFC][clang] Quote literal builtin attribute markers in Builtins.def docs (PR #160080)

2025-09-22 Thread Erich Keane via cfe-commits
erichkeane wrote: > I noticed the comment: > > ``` > // This is only documentation for the database layout. This will be removed > once all builtin databases are converted to tablegen files > ``` > > Since it seems that not all builtins are converted yet, would it be clearer > to use a less

[clang] [NFC][clang] Quote literal builtin attribute markers in Builtins.def docs (PR #160080)

2025-09-22 Thread Radovan Božić via cfe-commits
bozicrHT wrote: > > > But I'm not sure what we could use reasonably. > > > > > > We could replace it w/ e.g. `*` and add a note along the lines of ‘where > > `*` is any integer/index/whatever it’s actually supposed to be’ > > Asterisk seems pretty overloaded here... maybe the same except with

[clang] [clang][test] Add test for comma operator rejection in preprocessor conditionals (PR #155570)

2025-09-22 Thread NohHyeon Kwon via cfe-commits
https://github.com/swote-git updated https://github.com/llvm/llvm-project/pull/155570 >From 36f751e7b92d8907bfe60f3c28748519578097c3 Mon Sep 17 00:00:00 2001 From: swote Date: Wed, 27 Aug 2025 16:34:13 +0900 Subject: [PATCH 1/3] [clang][test] Add tests for comma operator rejection in preproces

[clang-tools-extra] [clang-tidy] Add new check `modernize-use-structured-binding` (PR #158462)

2025-09-22 Thread via cfe-commits
flovent wrote: I just find out we should do some special handing for direct inited pair type, like: ``` { std::pair P{1, 1}; int x = P.first; int y = P.second; } { std::pair P(1, 1); int x = P.first; int y = P.second; } { std::pair P; int x = P.first; int y = P.second; }

[clang] 7818089 - [analyzer] Hotfix a boolean conversion crash in the Z3 SMTConv (#158276)

2025-09-22 Thread via cfe-commits
Author: vabridgers Date: 2025-09-22T09:38:16-05:00 New Revision: 78180892d5e869d39152c92438571c56d6e0daef URL: https://github.com/llvm/llvm-project/commit/78180892d5e869d39152c92438571c56d6e0daef DIFF: https://github.com/llvm/llvm-project/commit/78180892d5e869d39152c92438571c56d6e0daef.diff LO

[clang-tools-extra] [clang-tidy] Fix `modernize-use-nullptr` crash on 32-bit Windows (PR #160023)

2025-09-22 Thread Victor Chernyakin via cfe-commits
https://github.com/localspook updated https://github.com/llvm/llvm-project/pull/160023 >From 4071d5e2e717d03810ec8d0f7476253d1bb72ee1 Mon Sep 17 00:00:00 2001 From: Victor Chernyakin Date: Sun, 21 Sep 2025 19:15:46 -0700 Subject: [PATCH 1/4] [clang-tidy] Fix `modernize-use-nullptr` crash on 32-

[clang] [Clang][RVV][SVE] Cache getScalableVectorType lookups (PR #160108)

2025-09-22 Thread Shaoce SUN via cfe-commits
https://github.com/sunshaoce updated https://github.com/llvm/llvm-project/pull/160108 >From beb8b36b348437a8722a3f86cb9261351b568ca2 Mon Sep 17 00:00:00 2001 From: Shaoce SUN Date: Mon, 22 Sep 2025 21:36:23 +0800 Subject: [PATCH] [Clang][RVV][SVE]Cache getScalableVectorType lookups Currently,

[libclc] 7d1adab - [libclc] Fix ctest failures after 7f3661128b1e: adjust external check and make shuffle helpers static (#160036)

2025-09-22 Thread via cfe-commits
Author: Wenju He Date: 2025-09-22T15:55:49+08:00 New Revision: 7d1adab5a6f745f038bc774b8f2c381ae32845e0 URL: https://github.com/llvm/llvm-project/commit/7d1adab5a6f745f038bc774b8f2c381ae32845e0 DIFF: https://github.com/llvm/llvm-project/commit/7d1adab5a6f745f038bc774b8f2c381ae32845e0.diff LOG:

[clang] [NFC][Clang] Fix typo memody->memory (PR #160141)

2025-09-22 Thread Corentin Jabot via cfe-commits
https://github.com/cor3ntin approved this pull request. https://github.com/llvm/llvm-project/pull/160141 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][NFC] Create CodeGenShared component for shared code with ClangIR (PR #157936)

2025-09-22 Thread Andy Kaylor via cfe-commits
andykaylor wrote: > Another way of putting that is that you are cloning IRGen on autopilot and > making a lot of extra work for yourselves in the process. You should be > thinking carefully about what operations should stay abstract in ClangIR as > you go along rather than "following the known

[clang-tools-extra] [clang-tidy][NFC] http -> https (PR #160128)

2025-09-22 Thread Baranov Victor via cfe-commits
https://github.com/vbvictor approved this pull request. LGTM, thank you for the refactor https://github.com/llvm/llvm-project/pull/160128 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commit

[clang] [llvm] [mlir] [AMDGPU] Add the support for 45-bit buffer resource (PR #159702)

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

[clang] [llvm] [llvm][clang] Propagate VFS through LTO to `PGOOptions` (PR #159671)

2025-09-22 Thread Jan Svoboda via cfe-commits
https://github.com/jansvoboda11 updated https://github.com/llvm/llvm-project/pull/159671 >From a4982a04d210430b5805fcee68b047b664a4db7d Mon Sep 17 00:00:00 2001 From: Jan Svoboda Date: Wed, 16 Jul 2025 14:03:27 -0700 Subject: [PATCH 1/6] [llvm] Propagate VFS to LTO (step 1) --- llvm/lib/LTO/L

[clang] [llvm] [llvm][clang] Propagate VFS through LTO to `PGOOptions` (PR #159671)

2025-09-22 Thread Jan Svoboda via cfe-commits
https://github.com/jansvoboda11 updated https://github.com/llvm/llvm-project/pull/159671 >From 76f75d7123154922261d083bcb4a2bc00e050a47 Mon Sep 17 00:00:00 2001 From: Jan Svoboda Date: Wed, 16 Jul 2025 14:03:27 -0700 Subject: [PATCH 1/6] [llvm] Propagate VFS to LTO (step 1) --- llvm/lib/LTO/L

[clang] [llvm] [Offload] Change ELF machine type for SPIR-V OpenMP image (PR #159623)

2025-09-22 Thread Nick Sarnie via cfe-commits
https://github.com/sarnex edited https://github.com/llvm/llvm-project/pull/159623 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [llvm] [openmp] [Clang][OpenMP][LoopTransformations] Add support for "#pragma omp fuse" loop transformation directive and "looprange" clause (PR #139293)

2025-09-22 Thread Roger Ferrer Ibáñez via cfe-commits
https://github.com/rofirrim edited https://github.com/llvm/llvm-project/pull/139293 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [flang] [llvm] [openmp] [Clang][OpenMP][LoopTransformations] Add support for "#pragma omp fuse" loop transformation directive and "looprange" clause (PR #139293)

2025-09-22 Thread Roger Ferrer Ibáñez via cfe-commits
@@ -2487,6 +2487,19 @@ void ASTStmtWriter::VisitOMPInterchangeDirective(OMPInterchangeDirective *D) { Code = serialization::STMT_OMP_INTERCHANGE_DIRECTIVE; } +void ASTStmtWriter::VisitOMPCanonicalLoopSequenceTransformationDirective( +OMPCanonicalLoopSequenceTransformati

[clang-tools-extra] [clang-tidy] Rename 'cert-err52-cpp' to 'modernize-avoid-setjmp-longjmp' (PR #159813)

2025-09-22 Thread Baranov Victor via cfe-commits
@@ -3,7 +3,9 @@ cert-err52-cpp == -This check flags all call expressions involving ``setjmp()`` and ``longjmp()``. +The cert-err52-cpp check is an alias, please see vbvictor wrote: ```suggestion The `cert-err52-cpp` check is an alias, please see `

[clang] [Headers][X86] VectorExprEvaluator::VisitCallExpr - allow SSE/AVX2/AVX512 pack intrinsics to be used in constexpr (PR #156003)

2025-09-22 Thread Simon Pilgrim via cfe-commits
@@ -2604,6 +2604,52 @@ static bool interp__builtin_elementwise_int_binop( return true; } +static bool +interp__builtin_x86_pack(InterpState &S, CodePtr, const CallExpr *E, + llvm::function_ref PackFn) { + const auto *VT0 = E->getArg(0)->getType()->ca

[clang-tools-extra] [clang-tidy][NFC] let multi-line string first line does not wrap (PR #160019)

2025-09-22 Thread Congcong Cai via cfe-commits
https://github.com/HerrCai0907 closed https://github.com/llvm/llvm-project/pull/160019 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [clang][nfc] Define ConstRecursiveASTVisitor twin of RecursiveASTVisitor (PR #160065)

2025-09-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Arseniy Zaostrovnykh (necto) Changes Downstream whenever we reach out for a RecursiveASTVisitor we always have to add a few const_casts to shoe it in. This NFC patch introduces a const version of the same CRTP class. To reduce code duplica

[clang] [clang-tools-extra] [clang][nfc] Define ConstRecursiveASTVisitor twin of RecursiveASTVisitor (PR #160065)

2025-09-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-tidy Author: Arseniy Zaostrovnykh (necto) Changes Downstream whenever we reach out for a RecursiveASTVisitor we always have to add a few const_casts to shoe it in. This NFC patch introduces a const version of the same CRTP class. To reduce code du

[clang] [docs][OpenMP] Claim compound directive handling (PR #160077)

2025-09-22 Thread Krzysztof Parzyszek via cfe-commits
https://github.com/kparzysz closed https://github.com/llvm/llvm-project/pull/160077 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [clang][nfc] Define ConstRecursiveASTVisitor twin of RecursiveASTVisitor (PR #160065)

2025-09-22 Thread via cfe-commits
Sirraide wrote: > Downstream whenever we reach out for a RecursiveASTVisitor we always have to add a few const_casts to shoe it in. This NFC patch introduces a const version of the same CRTP class. Have you tried using `DynamicRecursiveASTVisitor`/`ConstDynamicRecursiveASTVisitor` instead? It

[clang] [Headers][X86] Allow SSE2/AVX2/AVX512F/AVX512BW/AVX512DQ integer arithmetic intrinsics to be used in constexpr (PR #157582)

2025-09-22 Thread Simon Pilgrim via cfe-commits
https://github.com/RKSimon closed https://github.com/llvm/llvm-project/pull/157582 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][test] Add test for comma operator rejection in preprocessor conditionals (PR #155570)

2025-09-22 Thread David Spickett via cfe-commits
@@ -0,0 +1,26 @@ +// RUN: %clang_cc1 -E -pedantic-errors %s -verify -std=c++98 +// RUN: %clang_cc1 -E -pedantic-errors %s -verify -std=c++11 +// RUN: %clang_cc1 -E -pedantic-errors %s -verify -std=c++14 +// RUN: %clang_cc1 -E -pedantic-errors %s -verify -std=c++17 +// RUN: %clang_

[clang] [clang] Fix crash with -lstdc++ in -ccc-print-phases (#160046) (PR #160047)

2025-09-22 Thread A. Jiang via cfe-commits
frederick-vs-ja wrote: > see #160046 Would you mind to use [GitHub's close/fix/resolve syntax](https://docs.github.com/en/issues/tracking-your-work-with-issues/linking-a-pull-request-to-an-issue#linking-a-pull-request-to-an-issue-using-a-keyword) (in the PR description)? https://github.com/ll

[clang] [clang][test] Add test for comma operator rejection in preprocessor conditionals (PR #155570)

2025-09-22 Thread David Spickett via cfe-commits
@@ -0,0 +1,26 @@ +// RUN: %clang_cc1 -E -pedantic-errors %s -verify -std=c++98 +// RUN: %clang_cc1 -E -pedantic-errors %s -verify -std=c++11 +// RUN: %clang_cc1 -E -pedantic-errors %s -verify -std=c++14 +// RUN: %clang_cc1 -E -pedantic-errors %s -verify -std=c++17 +// RUN: %clang_

[clang] [analyzer] Hotfix a boolean conversion crash in the Z3 SMTConv (PR #158276)

2025-09-22 Thread Balazs Benics via cfe-commits
https://github.com/steakhal edited https://github.com/llvm/llvm-project/pull/158276 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang-tools-extra] [clang-tidy] Rename 'cert-err52-cpp' to 'modernize-avoid-setjmp-longjmp' (PR #159813)

2025-09-22 Thread Baranov Victor via cfe-commits
@@ -0,0 +1,10 @@ +.. title:: clang-tidy - modernize-avoid-setjmp-longjmp + +modernize-avoid-setjmp-longjmp +== + +Flags all call expressions involving ``setjmp()`` and ``longjmp()``. + vbvictor wrote: One more sentence left: "Exceptio

[clang] [Headers][X86] Allow SSE2/AVX2/AVX512F/AVX512BW/AVX512DQ integer arithmetic intrinsics to be used in constexpr (PR #157582)

2025-09-22 Thread Simon Pilgrim via cfe-commits
https://github.com/RKSimon approved this pull request. LGTM - cheers! https://github.com/llvm/llvm-project/pull/157582 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-format] Add SpaceBeforeUnderscoreParens option for GNU gettext… (PR #159925)

2025-09-22 Thread via cfe-commits
owenca wrote: In general, we want the new option to meet the [requirements](https://clang.llvm.org/docs/ClangFormatStyleOptions.html#adding-additional-style-options). Can you link to the relevant section in GNU coding standards? It seems that this can be supported without a new option. https:

[clang] [analyzer] Correct crash in Z3 wrapper (PR #158276)

2025-09-22 Thread Balazs Benics via cfe-commits
https://github.com/steakhal edited https://github.com/llvm/llvm-project/pull/158276 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [clang][nfc] Define ConstRecursiveASTVisitor twin of RecursiveASTVisitor (PR #160065)

2025-09-22 Thread Corentin Jabot via cfe-commits
cor3ntin wrote: @Sirraide https://github.com/llvm/llvm-project/pull/160065 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][bytecode] Fix unknown size arrays crash in clang bytecode (PR #160015)

2025-09-22 Thread Osama Abdelkader via cfe-commits
https://github.com/osamakader updated https://github.com/llvm/llvm-project/pull/160015 >From b8dc9feae1a16c3a4276dfafca121232e5c154ac Mon Sep 17 00:00:00 2001 From: Osama Abdelkader Date: Mon, 22 Sep 2025 00:59:48 +0300 Subject: [PATCH] [clang][bytecode] Fix unknown size arrays crash in clang

[clang] [clang][bytecode] Fix unknown size arrays crash in clang bytecode (PR #160015)

2025-09-22 Thread Osama Abdelkader via cfe-commits
https://github.com/osamakader updated https://github.com/llvm/llvm-project/pull/160015 >From b8dc9feae1a16c3a4276dfafca121232e5c154ac Mon Sep 17 00:00:00 2001 From: Osama Abdelkader Date: Mon, 22 Sep 2025 00:59:48 +0300 Subject: [PATCH] [clang][bytecode] Fix unknown size arrays crash in clang

[clang] [clang][sema] Add nonnull attribute to builtin format functions (PR #158626)

2025-09-22 Thread via cfe-commits
@@ -0,0 +1,74 @@ +// RUN: %clang_cc1 -fsyntax-only -verify -Wnonnull -Wno-format-security %s + +#include +#include + +typedef struct _FILE FILE; + +int printf(char const* restrict, ...); +int __builtin_printf(char const* restrict, ...); +int fprintf(FILE* restrict, char const* r

[clang] [clang-format] Add AllowBreakBeforeQtProperty option (PR #159909)

2025-09-22 Thread Björn Schäpers via cfe-commits
https://github.com/HazardyKnusperkeks approved this pull request. https://github.com/llvm/llvm-project/pull/159909 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][sema] Add nonnull attribute to builtin format functions (PR #158626)

2025-09-22 Thread via cfe-commits
@@ -293,6 +293,34 @@ bool Builtin::Context::isScanfLike(unsigned ID, unsigned &FormatIdx, return isLike(ID, FormatIdx, HasVAListArg, "sS"); } +bool Builtin::Context::IsNonNull(unsigned ID, + llvm::SmallVectorImpl &Indxs) const { + + const ch

[clang] [NFC][clang] Quote literal builtin attribute markers in Builtins.def docs (PR #160080)

2025-09-22 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][sema] Add nonnull attribute to builtin format functions (PR #158626)

2025-09-22 Thread via cfe-commits
Sirraide wrote: > What do actual libc implementations do when they are passed a nullptr? Do any > of them define their behaviour? Glibc at least checks for null and returns `-1`; I haven’t been able to check other libc implementations. I also tried looking at the C standard, but from what I c

[clang] [NFC][clang] Quote literal builtin attribute markers in Builtins.def docs (PR #160080)

2025-09-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Radovan Božić (bozicrHT) Changes Clarify the documentation in Builtins.def by quoting literal attribute markers (e.g. 'n', 'r', 'U', 'N') to distinguish them from placeholders such as N in C. This avoids confusion and makes the att

[clang] [Clang][Driver][Hurd] Enable __float128 support on x86 on Hurd (PR #153925)

2025-09-22 Thread Brad Smith via cfe-commits
https://github.com/brad0 closed https://github.com/llvm/llvm-project/pull/153925 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [Offload] Change ELF machine type for SPIR-V OpenMP image (PR #159623)

2025-09-22 Thread Nick Sarnie via cfe-commits
https://github.com/sarnex updated https://github.com/llvm/llvm-project/pull/159623 >From 44d9db71dafd87e21fecf32653692b8389b3c7e5 Mon Sep 17 00:00:00 2001 From: "Sarnie, Nick" Date: Thu, 18 Sep 2025 11:52:51 -0700 Subject: [PATCH 1/2] [Offload] Change ELF machine type for SPIR-V OpenMP image S

[clang] [llvm] [Offload] Change ELF machine type for SPIR-V OpenMP image (PR #159623)

2025-09-22 Thread Nick Sarnie via cfe-commits
@@ -423,9 +423,10 @@ Error offloading::intel::containerizeOpenMPSPIRVImage( Header.Class = ELF::ELFCLASS64; Header.Data = ELF::ELFDATA2LSB; Header.Type = ELF::ET_DYN; - // Use an existing Intel machine type as there is not one specifically for - // Intel GPUs. - Header

[clang] 44e71c9 - [Headers][X86] Allow SSE2/AVX2/AVX512F/AVX512BW/AVX512DQ integer arithmetic intrinsics to be used in constexpr (#157582)

2025-09-22 Thread via cfe-commits
Author: don Date: 2025-09-22T08:51:44Z New Revision: 44e71c9416c8675538b9bf0dd2b02aae3735c545 URL: https://github.com/llvm/llvm-project/commit/44e71c9416c8675538b9bf0dd2b02aae3735c545 DIFF: https://github.com/llvm/llvm-project/commit/44e71c9416c8675538b9bf0dd2b02aae3735c545.diff LOG: [Headers]

[clang-tools-extra] [clang-tidy] Fix `modernize-use-nullptr` crash on 32-bit Windows (PR #160023)

2025-09-22 Thread Baranov Victor via cfe-commits
vbvictor wrote: > cc @AaronBallman as maintainer of AST matchers Should retry pinging after 6th of october (preferably give one more week), https://discourse.llvm.org/t/my-upcoming-availability/87851 https://github.com/llvm/llvm-project/pull/160023

[clang] [clang][bytecode] Only block pointers can be partially initialized (PR #160075)

2025-09-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timm Baeder (tbaederr) Changes So ignore the rest in `checkFullyInitialized()`. Fixes #160071 --- Full diff: https://github.com/llvm/llvm-project/pull/160075.diff 2 Files Affected: - (modified) clang/lib/AST/ByteCode/EvaluationResult.c

[clang] [docs][OpenMP] Claim compound directive handling (PR #160077)

2025-09-22 Thread Krzysztof Parzyszek via cfe-commits
https://github.com/kparzysz created https://github.com/llvm/llvm-project/pull/160077 None >From 8093619490ed0ef189e48dec25f3564ac2ab259e Mon Sep 17 00:00:00 2001 From: Krzysztof Parzyszek Date: Mon, 22 Sep 2025 06:31:15 -0500 Subject: [PATCH] [docs][OpenMP] Claim compound directive handling -

[clang] [clang]bytecode] Add degenerate pointers (PR #160086)

2025-09-22 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/160086 None >From 40c51d8bb280d3657ee7a18d795ed6faa30ba096 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Mon, 22 Sep 2025 08:19:20 +0200 Subject: [PATCH] [clang]bytecode] Add degenerate pointers

[clang] [NFC][clang] Quote literal builtin attribute markers in Builtins.def docs (PR #160080)

2025-09-22 Thread via cfe-commits
@@ -67,38 +67,38 @@ // The third value provided to the macro specifies information about attributes // of the function. These must be kept in sync with the predicates in the // Builtin::Context class. Currently we have: -// n -> nothrow -// r -> noreturn -// U -> pure -//

[clang] [clang][test] Add test for comma operator rejection in preprocessor conditionals (PR #155570)

2025-09-22 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: I'd love if this PR added tests for Core issues 1436 and 3017, but I don't see which wording we should test against. The only proposed resolution from 2012-02 from Richard is obviously incomplete. I think we shouldn't touch DR tests until more information from Core. https://git

[clang] [NFC][clang] Quote literal builtin attribute markers in Builtins.def docs (PR #160080)

2025-09-22 Thread via cfe-commits
Sirraide wrote: > ONE thought I just thought of: what if instead of THIS, we extracted this > Builtins.def file (which right now is a worthless/empty documentation-only > file) into the `InternalsManual.rst`, and just left a 'link' to it here > instead? That way we could use ITS 'this is code'

[clang] [Driver] Enable __float128 support on X86 on Hurd (PR #160045)

2025-09-22 Thread Samuel Thibault via cfe-commits
sthibaul wrote: Thanks! https://github.com/llvm/llvm-project/pull/160045 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [NFC][clang] Quote literal builtin attribute markers in Builtins.def docs (PR #160080)

2025-09-22 Thread Nikolas Klauser via cfe-commits
philnik777 wrote: > > and just left a 'link' to it here instead? > > Also, is there a reason why we can’t just delete this file entirely and put > the link e.g. in `Builtins.td`/`BuiltinsBase.td` Since this isn't useful for the tablegen files I'm not sure that makes a ton of sense. Maybe rath

[clang] [NFC][clang] Quote literal builtin attribute markers in Builtins.def docs (PR #160080)

2025-09-22 Thread Corentin Jabot via cfe-commits
cor3ntin wrote: I thought the plan was to get rid of Builtins.def entirely? Maybe it's not worth spending time on it. migrating to td files seems like a better use of time! https://github.com/llvm/llvm-project/pull/160080 ___ cfe-commits mailing list

[clang] [Clang][RVV][SVE] Cache getScalableVectorType lookups (PR #160108)

2025-09-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Shaoce SUN (sunshaoce) Changes Currently, RVV/SVE intrinsics are cached, but the corresponding type construction is not. As a result, `ASTContext::getScalableVectorType` can become a performance hotspot, since every query must run through

[clang-tools-extra] [clang-tidy] Add new check `modernize-use-structured-binding` (PR #158462)

2025-09-22 Thread via cfe-commits
@@ -0,0 +1,409 @@ +//===--===// +// +// Part of the LLVM Project, under the Apache License v2.0 with LLVM Exceptions. +// See https://llvm.org/LICENSE.txt for license information. +// SPDX-License-Identifier: Apa

[clang-tools-extra] [clang-tidy] Add new check `modernize-use-structured-binding` (PR #158462)

2025-09-22 Thread via cfe-commits
@@ -0,0 +1,433 @@ +// RUN: %check_clang_tidy -check-suffix=ALL,CPP20ORLATER -std=c++20-or-later %s modernize-use-structured-binding %t -- -- -I %S/Inputs/use-structured-binding/ +// RUN: %check_clang_tidy -check-suffix=ALL -std=c++17 %s modernize-use-structured-binding %t -- --

[clang] [NFC][clang] Quote literal builtin attribute markers in Builtins.def docs (PR #160080)

2025-09-22 Thread Erich Keane via cfe-commits
erichkeane wrote: > I thought the plan was to get rid of Builtins.def entirely? Maybe it's not > worth spending time on it. migrating to td files seems like a better use of > time! I believe there was that aspiration, yes, but based on how long it has been, and that the work has stalled, it s

[clang] [Clang] Assume type align in masked load / store builtins (PR #156063)

2025-09-22 Thread Joseph Huber via cfe-commits
jhuber6 wrote: Changed this to use the type's alignment. I can change the interface to use a `V *` instead of `vec *`. https://github.com/llvm/llvm-project/pull/156063 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-

[clang] Reapply "[Clang][CMake] Use IRPGO instead of FE PGO for Cmake Caches … (PR #160133)

2025-09-22 Thread Aiden Grossman via cfe-commits
https://github.com/boomanaiden154 created https://github.com/llvm/llvm-project/pull/160133 …(#155957)" This reverts commit 8ed489914e5bdfe65e1c8fdeec335f21cd7b33a1. This reapplies the original patch now that the issue in ControlHeightReduction (#159621) has been fixed in #159686. >From 52e87

[clang] [flang] [llvm] [openmp] [Clang][OpenMP][LoopTransformations] Add support for "#pragma omp fuse" loop transformation directive and "looprange" clause (PR #139293)

2025-09-22 Thread Roger Ferrer Ibáñez via cfe-commits
@@ -2487,6 +2487,19 @@ void ASTStmtWriter::VisitOMPInterchangeDirective(OMPInterchangeDirective *D) { Code = serialization::STMT_OMP_INTERCHANGE_DIRECTIVE; } +void ASTStmtWriter::VisitOMPCanonicalLoopSequenceTransformationDirective( +OMPCanonicalLoopSequenceTransformati

[clang] [clang][test] Add test for comma operator rejection in preprocessor conditionals (PR #155570)

2025-09-22 Thread David Spickett via cfe-commits
DavidSpickett wrote: Tests look fine to me now, but deferring to @Endilll as the domain expert here. https://github.com/llvm/llvm-project/pull/155570 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinf

[clang] [clang][bytecode] Fix unknown size arrays crash in clang bytecode (PR #160015)

2025-09-22 Thread Osama Abdelkader via cfe-commits
https://github.com/osamakader edited https://github.com/llvm/llvm-project/pull/160015 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

  1   2   3   4   >