[clang] [clang-tools-extra] [flang] [lldb] [llvm] [mlir] [openmp] [polly] [Documentation] Always use SVG for dot-generated doxygen images. (PR #136843)

2025-04-24 Thread Petr Hosek via cfe-commits
https://github.com/petrhosek approved this pull request. https://github.com/llvm/llvm-project/pull/136843 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang-tools-extra] [clang] Hide the `TargetOptions` pointer from `CompilerInvocation` (PR #106271)

2025-04-24 Thread kadir çetinkaya via cfe-commits
@@ -216,7 +216,7 @@ enum OpenCLTypeKind : uint8_t { /// class TargetInfo : public TransferrableTargetInfo, public RefCountedBase { - std::shared_ptr TargetOpts; + TargetOptions *TargetOpts; kadircet wrote: sorry for delay here. i'd still

[clang] [CIR] Upstream initial support for fixed size VectorType (PR #136488)

2025-04-24 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/136488 >From d2c63cda1dff23ccb9f81f7d346a25f201945f78 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Sat, 19 Apr 2025 21:03:07 +0200 Subject: [PATCH 1/8] [CIR] Upstream initial support for fixed size VectorType

[clang] [CIR] Cleanup support for C functions (PR #136854)

2025-04-24 Thread Bruno Cardoso Lopes via cfe-commits
https://github.com/bcardosolopes approved this pull request. I don't have anything to say that wasn't covered, LGTM once Andy is happy! https://github.com/llvm/llvm-project/pull/136854 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lis

[clang] [NFC][CFI] Add tests for different reporting settings (PR #137225)

2025-04-24 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Vitaly Buka (vitalybuka) Changes 1. Trap 2. Abort from runtime 3. Recover from runtime 4. Abort from minimal runtime 5. Recover from minimal runtime They already work as expected. --- Full diff: https://github.com/llvm/llvm-project/pull/

[clang] [OpenACC][CIR] Implement 'num_gangs' lowering (PR #137216)

2025-04-24 Thread Erich Keane via cfe-commits
https://github.com/erichkeane updated https://github.com/llvm/llvm-project/pull/137216 >From f24d90d1f5882d008a19a8f48da8f25e4bae1d21 Mon Sep 17 00:00:00 2001 From: erichkeane Date: Thu, 24 Apr 2025 10:10:43 -0700 Subject: [PATCH 1/3] [OpenACC][CIR] Implement 'num_gangs' lowering This is simil

[clang] [CIR] Upstream support for name mangling (PR #137094)

2025-04-24 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 HEAD~1 HEAD --extensions cpp,h -- clang/lib/CIR/CodeGen/CIRGenCXXABI.h clang/include/

[clang] [CIR] Upstream support for name mangling (PR #137094)

2025-04-24 Thread Erich Keane via cfe-commits
https://github.com/erichkeane approved this pull request. https://github.com/llvm/llvm-project/pull/137094 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [alpha.webkit.UncheckedCallArgsChecker] Checker fails to recognize CanMakeCheckedPtrBase (PR #136500)

2025-04-24 Thread Rashmi Mudduluru via cfe-commits
https://github.com/t-rasmud approved this pull request. LGTM! https://github.com/llvm/llvm-project/pull/136500 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][analyzer][NFC] Add a helper for conjuring symbols at call events (PR #137182)

2025-04-24 Thread Fangyi Zhou via cfe-commits
@@ -853,7 +853,7 @@ void SmartPtrModeling::handleBoolConversion(const CallEvent &Call, const LocationContext *LC = C.getLocationContext(); InnerPointerVal = C.getSValBuilder().conjureSymbolVal( -CallExpr, LC, InnerPointerType, C.blockCount()); +Call, I

[clang] [clang][analyzer][NFC] Add a helper for conjuring symbols at call events (PR #137182)

2025-04-24 Thread Fangyi Zhou via cfe-commits
@@ -584,11 +584,9 @@ class StdLibraryFunctionsChecker const Summary &Summary, CheckerContext &C) const override { SValBuilder &SVB = C.getSValBuilder(); - NonLoc ErrnoSVal = - SVB.conjureSymbolVal(&Tag, Cal

[clang] [-Wunsafe-buffer-usage] Fix a bug that wrongly assumed CXXMethodDecl always has an identifier (PR #137248)

2025-04-24 Thread Ziqing Luo via cfe-commits
https://github.com/ziqingluo-90 closed https://github.com/llvm/llvm-project/pull/137248 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] be48c0d - [-Wunsafe-buffer-usage] Fix a bug that wrongly assumed CXXMethodDecl always has an identifier (#137248)

2025-04-24 Thread via cfe-commits
Author: Ziqing Luo Date: 2025-04-24T17:03:06-07:00 New Revision: be48c0df77413a237565a339c9ccc275b8256631 URL: https://github.com/llvm/llvm-project/commit/be48c0df77413a237565a339c9ccc275b8256631 DIFF: https://github.com/llvm/llvm-project/commit/be48c0df77413a237565a339c9ccc275b8256631.diff LO

[clang] [-Wunsafe-buffer-usage] Fix a bug that wrongly assumed CXXMethodDecl always has an identifier (PR #137248)

2025-04-24 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `lldb-x86_64-debian` running on `lldb-x86_64-debian` while building `clang` at step 6 "test". Full details are available at: https://lab.llvm.org/buildbot/#/builders/162/builds/20928 Here is the relevant piece of the build lo

[clang] [CIR] Fix calling defined functions (PR #137271)

2025-04-24 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor created https://github.com/llvm/llvm-project/pull/137271 Until now our function symbol lookup has been assuming that the function did not exist and creating a definition for it. This caused us to create a duplicate definition if we ever tried to call a function th

[clang] [CIR] Fix calling defined functions (PR #137271)

2025-04-24 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clangir Author: Andy Kaylor (andykaylor) Changes Until now our function symbol lookup has been assuming that the function did not exist and creating a definition for it. This caused us to create a duplicate definition if we ever tried to call a functio

[clang] Remove duplicate API (PR #132776)

2025-04-24 Thread Vlad Serebrennikov via cfe-commits
https://github.com/Endilll approved this pull request. I talked to Aaron offline whether there's a better way to mark duplicates as deprecated, but given the variety of C compilers that can consume this header, we don't think there's a better way than a doxygen comment https://github.com/llvm/

[clang] 70e303f - [webkit.UncountedLambdaCapturesChecker] Treat a call to lambda function via a variable as safe. (#135688)

2025-04-24 Thread via cfe-commits
Author: Ryosuke Niwa Date: 2025-04-24T17:10:05-07:00 New Revision: 70e303f11e1b9ac4af20d4fad5f1ec1c8ceb448e URL: https://github.com/llvm/llvm-project/commit/70e303f11e1b9ac4af20d4fad5f1ec1c8ceb448e DIFF: https://github.com/llvm/llvm-project/commit/70e303f11e1b9ac4af20d4fad5f1ec1c8ceb448e.diff

[clang] TODO (PR #137273)

2025-04-24 Thread Vitaly Buka via cfe-commits
https://github.com/vitalybuka created https://github.com/llvm/llvm-project/pull/137273 None >From ee49ae72cd437b98b921956908c6262431b6887a Mon Sep 17 00:00:00 2001 From: Vitaly Buka Date: Thu, 24 Apr 2025 17:10:58 -0700 Subject: [PATCH] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20initia

[clang] Remove duplicate API (PR #132776)

2025-04-24 Thread Vlad Serebrennikov via cfe-commits
Endilll wrote: @Jugst3r Let us know if this is ready to be merged. https://github.com/llvm/llvm-project/pull/132776 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [webkit.UncountedLambdaCapturesChecker] Treat a call to lambda function via a variable as safe. (PR #135688)

2025-04-24 Thread Ryosuke Niwa via cfe-commits
rniwa wrote: Thanks for the review! https://github.com/llvm/llvm-project/pull/135688 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 31b38d6 - [HLSL] Handle incomplete array types (#133508)

2025-04-24 Thread via cfe-commits
Author: Chris B Date: 2025-04-24T19:22:08-05:00 New Revision: 31b38d67f246066cbca9328a5b2dd66a31e71245 URL: https://github.com/llvm/llvm-project/commit/31b38d67f246066cbca9328a5b2dd66a31e71245 DIFF: https://github.com/llvm/llvm-project/commit/31b38d67f246066cbca9328a5b2dd66a31e71245.diff LOG:

[clang] [HLSL] Handle incomplete array types (PR #133508)

2025-04-24 Thread Chris B via cfe-commits
https://github.com/llvm-beanz closed https://github.com/llvm/llvm-project/pull/133508 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Upstream namepsace handling (PR #137253)

2025-04-24 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor closed https://github.com/llvm/llvm-project/pull/137253 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [DLCov 2/5] Implement DebugLoc coverage tracking (PR #107279)

2025-04-24 Thread Stephen Tozer via cfe-commits
SLTozer wrote: > Hi, I believe this merge is breaking external projects because you added > `#include "llvm/Config/config.h"` which is not available (see comments at the > top of that file). Reverted for now, will look into relanding without the inclusion issue later. https://github.com/llvm/

[clang] [clang] Ensure correct copying of records with authenticated fields (PR #136783)

2025-04-24 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `lldb-aarch64-ubuntu` running on `linaro-lldb-aarch64-ubuntu` while building `clang` at step 6 "test". Full details are available at: https://lab.llvm.org/buildbot/#/builders/59/builds/16608 Here is the relevant piece of the

[clang] Thread Safety Analysis: Support reentrant capabilities (PR #137133)

2025-04-24 Thread Aaron Puchert via cfe-commits
https://github.com/aaronpuchert commented: I think the biggest issue is that removing `const` from `FactEntry` does not work. You'll have to undo all those changes and instead create a new `FactEntry` for every lock/unlock. https://github.com/llvm/llvm-project/pull/137133 _

[clang] Thread Safety Analysis: Support reentrant capabilities (PR #137133)

2025-04-24 Thread Aaron Puchert via cfe-commits
@@ -1831,15 +1852,15 @@ void BuildLockset::handleCall(const Expr *Exp, const NamedDecl *D, assert(!Self); const auto *TagT = Exp->getType()->getAs(); if (D->hasAttrs() && TagT && Exp->isPRValue()) { - std::pair Placeholder = - Analyzer->SxBuilder.crea

[clang] TODO (PR #137273)

2025-04-24 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang @llvm/pr-subscribers-clang-driver Author: Vitaly Buka (vitalybuka) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/137273.diff 1 Files Affected: - (modified) clang/lib/Driver/SanitizerArgs.cpp (+2) ``diff diff --git

[clang] [webkit.UncountedLambdaCapturesChecker] Treat a call to lambda function via a variable as safe. (PR #135688)

2025-04-24 Thread Ryosuke Niwa via cfe-commits
https://github.com/rniwa closed https://github.com/llvm/llvm-project/pull/135688 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] TODO (PR #137273)

2025-04-24 Thread Vitaly Buka via cfe-commits
https://github.com/vitalybuka converted_to_draft https://github.com/llvm/llvm-project/pull/137273 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Thread Safety Analysis: Support reentrant capabilities (PR #137133)

2025-04-24 Thread Aaron Puchert via cfe-commits
@@ -434,6 +434,16 @@ class can be used as a capability. The string argument specifies the kind of capability in error messages, e.g. ``"mutex"``. See the ``Container`` example given above, or the ``Mutex`` class in :ref:`mutexheader`. +REENTRANT aaronpucher

[clang] Thread Safety Analysis: Support reentrant capabilities (PR #137133)

2025-04-24 Thread Aaron Puchert via cfe-commits
@@ -434,6 +434,16 @@ class can be used as a capability. The string argument specifies the kind of capability in error messages, e.g. ``"mutex"``. See the ``Container`` example given above, or the ``Mutex`` class in :ref:`mutexheader`. +REENTRANT +- + +``REENTRANT``

[clang] Thread Safety Analysis: Support reentrant capabilities (PR #137133)

2025-04-24 Thread Aaron Puchert via cfe-commits
@@ -6708,15 +6708,15 @@ int testAdoptShared() { } // namespace ReturnScopedLockable -#endif +#endif // __cpp_guaranteed_copy_elision aaronpuchert wrote: These changes are fine, but please just commit them separately. (No review required.) https://github.co

[clang] Thread Safety Analysis: Support reentrant capabilities (PR #137133)

2025-04-24 Thread Aaron Puchert via cfe-commits
@@ -271,26 +271,32 @@ class CFGWalker { // translateAttrExpr needs it, but that should be moved too. class CapabilityExpr { private: - /// The capability expression and whether it's negated. - llvm::PointerIntPair CapExpr; + /// The capability expression and flags. + llvm::

[clang] Thread Safety Analysis: Support reentrant capabilities (PR #137133)

2025-04-24 Thread Aaron Puchert via cfe-commits
@@ -103,6 +103,23 @@ static StringRef ClassifyDiagnostic(QualType VDT) { return "mutex"; } +static unsigned getCapabilityExprFlags(QualType VDT) { + unsigned Flags = 0; + + if (const auto *RT = VDT->getAs()) { +if (const auto *RD = RT->getDecl()) + if (RD->hasAttr

[clang] Thread Safety Analysis: Support reentrant capabilities (PR #137133)

2025-04-24 Thread Aaron Puchert via cfe-commits
@@ -163,15 +184,15 @@ using FactID = unsigned short; /// the analysis of a single routine. class FactManager { private: - std::vector> Facts; + std::vector> Facts; aaronpuchert wrote: This does not work, `FactEntry` has to remain `const`. See Delesley's comm

[clang] Thread Safety Analysis: Support reentrant capabilities (PR #137133)

2025-04-24 Thread Aaron Puchert via cfe-commits
@@ -271,26 +271,32 @@ class CFGWalker { // translateAttrExpr needs it, but that should be moved too. class CapabilityExpr { private: - /// The capability expression and whether it's negated. - llvm::PointerIntPair CapExpr; + /// The capability expression and flags. + llvm::

[clang] Thread Safety Analysis: Support reentrant capabilities (PR #137133)

2025-04-24 Thread Aaron Puchert via cfe-commits
https://github.com/aaronpuchert edited https://github.com/llvm/llvm-project/pull/137133 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][NFC] Explicitly delete copy ctor and assignment for CGAtomicOptionsRAII (PR #137275)

2025-04-24 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik created https://github.com/llvm/llvm-project/pull/137275 Static analysis flagged CGAtomicOptionsRAII as having an explicit destructor but not having explicit copy ctor and assignment. Rule of three says we should. We are just using this as an RAII object, no need for

[clang] [Clang][NFC] Explicitly delete copy ctor and assignment for CGAtomicOptionsRAII (PR #137275)

2025-04-24 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Shafik Yaghmour (shafik) Changes Static analysis flagged CGAtomicOptionsRAII as having an explicit destructor but not having explicit copy ctor and assignment. Rule of three says we should. We are just using this as an RAII object, no nee

[clang] [Clang][NFC] Explicitly delete copy ctor and assignment for CGAtomicOptionsRAII (PR #137275)

2025-04-24 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang-codegen Author: Shafik Yaghmour (shafik) Changes Static analysis flagged CGAtomicOptionsRAII as having an explicit destructor but not having explicit copy ctor and assignment. Rule of three says we should. We are just using this as an RAII object

[clang] [llvm] [DXIL] Remove incompatible metadata types when preparing DXIL. (PR #136386)

2025-04-24 Thread Joshua Batista via cfe-commits
https://github.com/bob80905 updated https://github.com/llvm/llvm-project/pull/136386 >From c1a89d6896edd29ff345dd8fdc30cd040f3760f3 Mon Sep 17 00:00:00 2001 From: Joshua Batista Date: Fri, 18 Apr 2025 16:06:18 -0700 Subject: [PATCH 1/4] add md node type filter, and test --- .../test/CodeGenHL

[clang] Mark CXX module initializer with PACBTI attributes (PR #133716)

2025-04-24 Thread Eli Friedman via cfe-commits
https://github.com/efriedma-quic approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/133716 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][CodeGen] Emit fake uses before musttail calls (PR #136867)

2025-04-24 Thread via cfe-commits
gulfemsavrun wrote: Is there anything that is blocking this PR to be merged? If it needs more time to review, could you please revert the original change and reland with this fix? This is blocking us to roll Clang in our project. https://github.com/llvm/llvm-project/pull/136867 ___

[clang] [clang] Adding an API to create a `CXStringSet` from a Vector of `StringRef`s (PR #136773)

2025-04-24 Thread Qiongsi Wu via cfe-commits
qiongsiwu wrote: > If the only use is in a downstream of Clang, do we need to upstream the > changes at all? We could always upstream once there's an in-tree need for the > functionality. No, we don't _need_ to upstream. I don't have a strong feeling - I am upstreaming it because functionally

[clang] default clause replaced by otherwise clause for metadirective in OpenMP 5.2 (PR #128640)

2025-04-24 Thread Alexey Bataev via cfe-commits
@@ -2785,6 +2797,13 @@ StmtResult Parser::ParseOpenMPDeclarativeOrExecutableDirective( return Directive; } } + if (CKind == OMPC_otherwise) { +// Check for 'otherwise' keyword. +if (Tok.is(tok::identifier) && +Tok.getIde

[clang] [clang] Implement address sanitizer on AIX (1/n) (PR #129925)

2025-04-24 Thread Jake Egan via cfe-commits
https://github.com/jakeegan edited https://github.com/llvm/llvm-project/pull/129925 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [mlir] [TableGen] Only store direct superclasses in Record (PR #123072)

2025-04-24 Thread Jay Foad via cfe-commits
jayfoad wrote: > reverse-ping - what's the plan for this please? To forget about it :) I think it's good to go now. https://github.com/llvm/llvm-project/pull/123072 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin

[clang] [Clang] Move OffloadArch enum to a generic location and add initial set of Intel OffloadArch values (PR #137070)

2025-04-24 Thread Justin Cai via cfe-commits
https://github.com/jzc updated https://github.com/llvm/llvm-project/pull/137070 >From 924f54246910cad42f97efe1bc3d3bdfec039ecb Mon Sep 17 00:00:00 2001 From: "Cai, Justin" Date: Mon, 14 Apr 2025 21:30:39 + Subject: [PATCH 1/2] [Clang] Move OffloadArch enum to a generic location and add init

[clang] [Clang][NFC[ Move OffloadArch enum to a generic location (PR #137070)

2025-04-24 Thread Justin Cai via cfe-commits
https://github.com/jzc edited https://github.com/llvm/llvm-project/pull/137070 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] fix unresolved dependent template specialization mangling (PR #135111)

2025-04-24 Thread Matheus Izvekov via cfe-commits
@@ -399,3 +399,20 @@ namespace type_qualifier { // CHECK: @_ZN14type_qualifier1gIPiEEvDTcmcvv_ELi1EE template void g(int); } + +namespace unresolved_template_specialization_type { + template struct enable_if {}; + struct Foo { +static const int value = true; + }; +

[clang] [analyzer] Workaround for unintended slowdown (scope increase) (PR #136720)

2025-04-24 Thread Donát Nagy via cfe-commits
@@ -2856,8 +2873,29 @@ void ExprEngine::processBranch( // conflicts with the widen-loop analysis option (which is off by // default). If we intend to support and stabilize the loop widening, // we must ensure that it 'plays nicely' with this logic. - if (

[clang] default clause replaced by otherwise clause for metadirective in OpenMP 5.2 (PR #128640)

2025-04-24 Thread Alexey Bataev via cfe-commits
@@ -78,10 +78,7 @@ void foo(void) { for (int i = 0; i < 16; i++) ; -#pragma omp metadirective when(user = {condition(0)} \ - : parallel for) otherwise() - for (int i=0; i<10; i++) -; + alexey-bataev wrote: Why moved t

[clang] default clause replaced by otherwise clause for metadirective in OpenMP 5.2 (PR #128640)

2025-04-24 Thread Alexey Bataev via cfe-commits
@@ -2759,6 +2759,18 @@ StmtResult Parser::ParseOpenMPDeclarativeOrExecutableDirective( OpenMPClauseKind CKind = Tok.isAnnotation() ? OMPC_unknown : getOpenMPClauseKind(PP.getSpelling(Tok)); + // C

[clang] c7fbaba - [clang] fix typo in CHECK line

2025-04-24 Thread Matheus Izvekov via cfe-commits
Author: Matheus Izvekov Date: 2025-04-24T13:01:39-03:00 New Revision: c7fbabaf87f9411fbcc48a33efaa76f0f03135e9 URL: https://github.com/llvm/llvm-project/commit/c7fbabaf87f9411fbcc48a33efaa76f0f03135e9 DIFF: https://github.com/llvm/llvm-project/commit/c7fbabaf87f9411fbcc48a33efaa76f0f03135e9.dif

[clang] [llvm] [DLCov 2/5] Implement DebugLoc coverage tracking (PR #107279)

2025-04-24 Thread Stephen Tozer via cfe-commits
https://github.com/SLTozer updated https://github.com/llvm/llvm-project/pull/107279 >From 55115af37710a80abbc2ec2ca5d96d1eea5827b4 Mon Sep 17 00:00:00 2001 From: Stephen Tozer Date: Wed, 4 Sep 2024 12:23:52 +0100 Subject: [PATCH 1/6] Add conditionally-enabled DebugLocKinds --- clang/lib/CodeG

[clang] [clang] Implement address sanitizer on AIX (1/n) (PR #129925)

2025-04-24 Thread Jake Egan via cfe-commits
https://github.com/jakeegan edited https://github.com/llvm/llvm-project/pull/129925 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][NFC] Move OffloadArch enum to a generic location (PR #137070)

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

[clang-tools-extra] [clang-tidy] Add check 'bugprone-invalid-enum-default-initialization' (PR #136823)

2025-04-24 Thread via cfe-commits
=?utf-8?q?Balázs_Kéri?= Message-ID: In-Reply-To: @@ -125,6 +125,12 @@ New checks Finds potentially erroneous calls to ``reset`` method on smart pointers when the pointee type also has a ``reset`` method. +- New :doc:`bugprone-invalid-enum-default-initialization

[clang] [CIR] Upstream TernaryOp (PR #137184)

2025-04-24 Thread Erich Keane via cfe-commits
@@ -1246,6 +1246,59 @@ def SelectOp : CIR_Op<"select", [Pure, }]; } +//===--===// +// TernaryOp +//===--===// + +def TernaryOp : CIR_Op<"te

[clang] default clause replaced by otherwise clause for metadirective in OpenMP 5.2 (PR #128640)

2025-04-24 Thread Alexey Bataev via cfe-commits
@@ -1660,6 +1660,10 @@ def err_omp_expected_colon : Error<"missing ':' in %0">; def err_omp_missing_comma : Error< "missing ',' after %0">; def err_omp_expected_context_selector : Error<"expected valid context selector in %0">; +def err_omp_unknown_clause a

[clang] [Clang][NFC[ Move OffloadArch enum to a generic location (PR #137070)

2025-04-24 Thread Joseph Huber via cfe-commits
@@ -0,0 +1,126 @@ +#include "clang/Basic/OffloadArch.h" + +#include "llvm/ADT/StringRef.h" + +#include + +namespace clang { + +namespace { +struct OffloadArchToStringMap { + OffloadArch arch; + const char *arch_name; + const char *virtual_arch_name; jhuber6 wr

[clang] [Clang][NFC] Move OffloadArch enum to a generic location (PR #137070)

2025-04-24 Thread Justin Cai via cfe-commits
https://github.com/jzc edited https://github.com/llvm/llvm-project/pull/137070 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] DO NOT MERGE: Identify places that need reserve. (PR #136543)

2025-04-24 Thread Jakub Kuderski via cfe-commits
@@ -2113,12 +2113,63 @@ void erase(Container &C, ValueType V) { C.erase(std::remove(C.begin(), C.end(), V), C.end()); } +namespace detail { +template +using check_has_member_iterator_category_t = +typename decltype(std::declval().begin())::iterator_category; + +template

[clang] [llvm] DO NOT MERGE: Identify places that need reserve. (PR #136543)

2025-04-24 Thread Jakub Kuderski via cfe-commits
https://github.com/kuhar commented: > I understand that you are working on improving the performance of > llvm::append_range. I'm interested and attempted to, but I have very few cycles these days (mostly weekends/holidays). The biggest blocker for me is setting up something I can quickly tes

[clang] [llvm] DO NOT MERGE: Identify places that need reserve. (PR #136543)

2025-04-24 Thread Jakub Kuderski via cfe-commits
@@ -2113,12 +2113,63 @@ void erase(Container &C, ValueType V) { C.erase(std::remove(C.begin(), C.end(), V), C.end()); } +namespace detail { +template +using check_has_member_iterator_category_t = +typename decltype(std::declval().begin())::iterator_category; + +template

[clang] [ARM] enable FENV_ACCESS pragma support for hard-float targets (PR #137101)

2025-04-24 Thread David Green via cfe-commits
davemgreen wrote: @john-brawn-arm did the work for AArch64, I'm not sure if he would have an idea how much work it would involve for the Arm backend. https://github.com/llvm/llvm-project/pull/137101 ___ cfe-commits mailing list cfe-commits@lists.llvm.

[clang] [llvm] DO NOT MERGE: Identify places that need reserve. (PR #136543)

2025-04-24 Thread Jakub Kuderski via cfe-commits
@@ -2113,12 +2113,63 @@ void erase(Container &C, ValueType V) { C.erase(std::remove(C.begin(), C.end(), V), C.end()); } +namespace detail { +template +using check_has_member_iterator_category_t = +typename decltype(std::declval().begin())::iterator_category; + +template

[clang] [llvm] DO NOT MERGE: Identify places that need reserve. (PR #136543)

2025-04-24 Thread Jakub Kuderski via cfe-commits
https://github.com/kuhar edited https://github.com/llvm/llvm-project/pull/136543 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][NFC] Move OffloadArch enum to a generic location (PR #137070)

2025-04-24 Thread Justin Cai via cfe-commits
https://github.com/jzc updated https://github.com/llvm/llvm-project/pull/137070 >From 924f54246910cad42f97efe1bc3d3bdfec039ecb Mon Sep 17 00:00:00 2001 From: "Cai, Justin" Date: Mon, 14 Apr 2025 21:30:39 + Subject: [PATCH 1/3] [Clang] Move OffloadArch enum to a generic location and add init

[clang] [llvm] [TargetVerifier][AMDGPU] Add TargetVerifier. (PR #123609)

2025-04-24 Thread via cfe-commits
https://github.com/jofrn updated https://github.com/llvm/llvm-project/pull/123609 >From 210b6d80bcfbbcd216f98199df386280724561e2 Mon Sep 17 00:00:00 2001 From: jofernau Date: Mon, 20 Jan 2025 04:51:26 -0800 Subject: [PATCH 01/13] [TargetVerifier][AMDGPU] Add TargetVerifier. This pass verifies

[clang] [-Wunsafe-buffer-usage] Fix a bug that wrongly assumed CXXMethodDecl always has an identifier (PR #137248)

2025-04-24 Thread Ziqing Luo via cfe-commits
ziqingluo-90 wrote: CC: @dtarditi https://github.com/llvm/llvm-project/pull/137248 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [TargetVerifier][AMDGPU] Add TargetVerifier. (PR #123609)

2025-04-24 Thread via cfe-commits
https://github.com/jofrn updated https://github.com/llvm/llvm-project/pull/123609 >From 210b6d80bcfbbcd216f98199df386280724561e2 Mon Sep 17 00:00:00 2001 From: jofernau Date: Mon, 20 Jan 2025 04:51:26 -0800 Subject: [PATCH 01/13] [TargetVerifier][AMDGPU] Add TargetVerifier. This pass verifies

[clang-tools-extra] [clang-tidy] Fix bugprone-tagged-union-member-count false-positive (PR #135831)

2025-04-24 Thread Baranov Victor via cfe-commits
=?utf-8?b?R8OhYm9yIFTDs3RodsOhcmk=?=,=?utf-8?b?R8OhYm9yIFTDs3RodsOhcmk=?=, =?utf-8?b?R8OhYm9yIFTDs3RodsOhcmk=?= Message-ID: In-Reply-To: @@ -28,6 +31,25 @@ Example: } Data; }; +The following example illustrates the exception for unions and enums from +system header fil

[clang-tools-extra] [clang-tidy] Fix bugprone-tagged-union-member-count false-positive (PR #135831)

2025-04-24 Thread Baranov Victor via cfe-commits
=?utf-8?b?R8OhYm9yIFTDs3RodsOhcmk=?=,=?utf-8?b?R8OhYm9yIFTDs3RodsOhcmk=?=, =?utf-8?b?R8OhYm9yIFTDs3RodsOhcmk=?Message-ID: In-Reply-To: https://github.com/vbvictor edited https://github.com/llvm/llvm-project/pull/135831 ___ cfe-commits mailing list cfe

[clang-tools-extra] [clang-tidy] Fix bugprone-tagged-union-member-count false-positive (PR #135831)

2025-04-24 Thread Baranov Victor via cfe-commits
=?utf-8?b?R8OhYm9yIFTDs3RodsOhcmk=?=,=?utf-8?b?R8OhYm9yIFTDs3RodsOhcmk=?=, =?utf-8?b?R8OhYm9yIFTDs3RodsOhcmk=?Message-ID: In-Reply-To: https://github.com/vbvictor commented: LGMT, with nit. Please wait for a review from someone with write access who will help merge this PR. https://github.com

[clang] [Driver][CFI] Allow CFI with minimal runtime (PR #137103)

2025-04-24 Thread Vitaly Buka via cfe-commits
https://github.com/vitalybuka updated https://github.com/llvm/llvm-project/pull/137103 >From b4ae58e13bbbc62272a900cac5e1f158c437e8c1 Mon Sep 17 00:00:00 2001 From: Vitaly Buka Date: Wed, 23 Apr 2025 18:16:42 -0700 Subject: [PATCH] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20change?= =?

[clang] [clang][analyzer][NFC] Add a helper for conjuring symbols at call events (PR #137182)

2025-04-24 Thread Fangyi Zhou via cfe-commits
https://github.com/fangyi-zhou updated https://github.com/llvm/llvm-project/pull/137182 >From 79e5875e75d46edcf15c5df536ac8f1d93e13a16 Mon Sep 17 00:00:00 2001 From: Fangyi Zhou Date: Thu, 24 Apr 2025 15:12:12 +0100 Subject: [PATCH 1/3] [clang][analyzer][NFC] Add a helper for conjuring symbols

[clang] [llvm] [TargetVerifier][AMDGPU] Add TargetVerifier. (PR #123609)

2025-04-24 Thread via cfe-commits
https://github.com/jofrn updated https://github.com/llvm/llvm-project/pull/123609 >From 210b6d80bcfbbcd216f98199df386280724561e2 Mon Sep 17 00:00:00 2001 From: jofernau Date: Mon, 20 Jan 2025 04:51:26 -0800 Subject: [PATCH 01/13] [TargetVerifier][AMDGPU] Add TargetVerifier. This pass verifies

[clang] [C] Warn on uninitialized const objects (PR #137166)

2025-04-24 Thread Erich Keane via cfe-commits
@@ -6496,6 +6496,17 @@ static bool canPerformArrayCopy(const InitializedEntity &Entity) { return false; } +static const FieldDecl *GetConstField(const RecordDecl *RD) { erichkeane wrote: Ah, just `assert(!LangOpts.CPlusPlus)` would be enough, but just `as

[clang] [C] Warn on uninitialized const objects (PR #137166)

2025-04-24 Thread Shafik Yaghmour via cfe-commits
@@ -0,0 +1,55 @@ +// RUN: %clang_cc1 -fsyntax-only -verify=c,unsafe -Wdefault-const-init %s +// RUN: %clang_cc1 -fsyntax-only -verify=c,unsafe -Wc++-compat %s +// RUN: %clang_cc1 -fsyntax-only -verify=unsafe %s +// RUN: %clang_cc1 -fsyntax-only -verify=c -Wdefault-const-init -Wno

[clang] [C] Warn on uninitialized const objects (PR #137166)

2025-04-24 Thread Shafik Yaghmour via cfe-commits
@@ -6496,6 +6496,17 @@ static bool canPerformArrayCopy(const InitializedEntity &Entity) { return false; } +static const FieldDecl *getConstField(const RecordDecl *RD) { + for (const FieldDecl *FD : RD->fields()) { +QualType QT = FD->getType(); +if (QT.isConstQualif

[clang] 425b953 - [clang][bytecode] Emit diagnostics from GetGlobalUnchecked (#137203)

2025-04-24 Thread via cfe-commits
Author: Timm Baeder Date: 2025-04-24T22:05:45+02:00 New Revision: 425b9539684be00f3c8ccde54dbab18ce9bc8ebd URL: https://github.com/llvm/llvm-project/commit/425b9539684be00f3c8ccde54dbab18ce9bc8ebd DIFF: https://github.com/llvm/llvm-project/commit/425b9539684be00f3c8ccde54dbab18ce9bc8ebd.diff L

[clang] [clang][bytecode] Emit diagnostics from GetGlobalUnchecked (PR #137203)

2025-04-24 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr closed https://github.com/llvm/llvm-project/pull/137203 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [TargetVerifier][AMDGPU] Add TargetVerifier. (PR #123609)

2025-04-24 Thread via cfe-commits
https://github.com/jofrn updated https://github.com/llvm/llvm-project/pull/123609 >From 210b6d80bcfbbcd216f98199df386280724561e2 Mon Sep 17 00:00:00 2001 From: jofernau Date: Mon, 20 Jan 2025 04:51:26 -0800 Subject: [PATCH 01/13] [TargetVerifier][AMDGPU] Add TargetVerifier. This pass verifies

[clang] [clang-repl] : Fix clang-repl crash with --cuda flag (PR #136404)

2025-04-24 Thread Vassil Vassilev via cfe-commits
@@ -760,8 +787,10 @@ std::unique_ptr Interpreter::GenModule() { return nullptr; } -CodeGenerator *Interpreter::getCodeGen() const { - FrontendAction *WrappedAct = Act->getWrapped(); +CodeGenerator *Interpreter::getCodeGen(IncrementalAction *Action) const { + if (!Action) +

[clang] [alpha.webkit.UncheckedCallArgsChecker] Checker fails to recognize CanMakeCheckedPtrBase (PR #136500)

2025-04-24 Thread Ryosuke Niwa via cfe-commits
rniwa wrote: Thank you for the review! https://github.com/llvm/llvm-project/pull/136500 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][bytecode] Allow forming pointers to fields of extern globals (PR #137211)

2025-04-24 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr updated https://github.com/llvm/llvm-project/pull/137211 >From 9388799f1a7bb4d6bbfc467db569aa61c4666445 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= Date: Thu, 24 Apr 2025 18:29:36 +0200 Subject: [PATCH] [clang][bytecode] Allow forming pointers to fie

[clang] [llvm] [HLSL] Run finalize linkage pass for all targets (PR #134260)

2025-04-24 Thread Steven Perron via cfe-commits
s-perron wrote: > The idea that a symbol should be externally visible before linking, and not > externally visible afterwards, isn't new: many platforms have some form of > symbol visibility. I'm not sure why you don't want to express that in LLVM > IR... having an implicit HLSL-specific rule

[clang] [Driver][CFI] Allow CFI with minimal runtime (PR #137103)

2025-04-24 Thread Vitaly Buka via cfe-commits
https://github.com/vitalybuka updated https://github.com/llvm/llvm-project/pull/137103 >From b4ae58e13bbbc62272a900cac5e1f158c437e8c1 Mon Sep 17 00:00:00 2001 From: Vitaly Buka Date: Wed, 23 Apr 2025 18:16:42 -0700 Subject: [PATCH] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20change?= =?

[clang] a7e5312 - [alpha.webkit.UncheckedCallArgsChecker] Checker fails to recognize CanMakeCheckedPtrBase (#136500)

2025-04-24 Thread via cfe-commits
Author: Ryosuke Niwa Date: 2025-04-24T13:15:27-07:00 New Revision: a7e53124eb1376b0f04a1f6d7d40a596532905b6 URL: https://github.com/llvm/llvm-project/commit/a7e53124eb1376b0f04a1f6d7d40a596532905b6 DIFF: https://github.com/llvm/llvm-project/commit/a7e53124eb1376b0f04a1f6d7d40a596532905b6.diff

[clang] [alpha.webkit.UncheckedCallArgsChecker] Checker fails to recognize CanMakeCheckedPtrBase (PR #136500)

2025-04-24 Thread Ryosuke Niwa via cfe-commits
https://github.com/rniwa closed https://github.com/llvm/llvm-project/pull/136500 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Driver][CFI] Allow CFI with minimal runtime (PR #137103)

2025-04-24 Thread Vitaly Buka via cfe-commits
https://github.com/vitalybuka updated https://github.com/llvm/llvm-project/pull/137103 >From b4ae58e13bbbc62272a900cac5e1f158c437e8c1 Mon Sep 17 00:00:00 2001 From: Vitaly Buka Date: Wed, 23 Apr 2025 18:16:42 -0700 Subject: [PATCH] =?UTF-8?q?[=F0=9D=98=80=F0=9D=97=BD=F0=9D=97=BF]=20change?= =?

[clang] [Driver][CFI] Allow CFI with minimal runtime (PR #137103)

2025-04-24 Thread Vitaly Buka via cfe-commits
vitalybuka wrote: > TODO: In a separate PRs I will add Codegen and runtime tests. Runtime #137245 Codegen #137225 https://github.com/llvm/llvm-project/pull/137103 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/m

[clang] [llvm] [HLSL][RootSignature] Add parsing of ShaderVisibility to DescriptorTable (PR #136751)

2025-04-24 Thread Finn Plummer via cfe-commits
https://github.com/inbelic updated https://github.com/llvm/llvm-project/pull/136751 >From bf4bb7a08445df8f65cbee8b98e674fbbd154965 Mon Sep 17 00:00:00 2001 From: Finn Plummer Date: Tue, 22 Apr 2025 19:42:50 + Subject: [PATCH] [HLSL][RootSignature] Add parsing of ShaderVisibility to Descrip

[clang] [llvm] [HLSL][RootSignature] Add parsing of ShaderVisibility to DescriptorTable (PR #136751)

2025-04-24 Thread Finn Plummer via cfe-commits
https://github.com/inbelic reopened https://github.com/llvm/llvm-project/pull/136751 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Upstream TernaryOp (PR #137184)

2025-04-24 Thread Morris Hafner via cfe-commits
https://github.com/mmha updated https://github.com/llvm/llvm-project/pull/137184 >From 1eed90e3859c2ad8d703708f89976cad8f0faeec Mon Sep 17 00:00:00 2001 From: Morris Hafner Date: Thu, 24 Apr 2025 16:12:37 +0200 Subject: [PATCH 1/2] [CIR] Upstream TernaryOp This patch adds TernaryOp to CIR plus

[clang] [Clang][NFC] Move OffloadArch enum to a generic location (PR #137070)

2025-04-24 Thread Nick Sarnie via cfe-commits
https://github.com/sarnex approved this pull request. https://github.com/llvm/llvm-project/pull/137070 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang][NFC] Move OffloadArch enum to a generic location (PR #137070)

2025-04-24 Thread Justin Cai via cfe-commits
https://github.com/jzc updated https://github.com/llvm/llvm-project/pull/137070 >From 924f54246910cad42f97efe1bc3d3bdfec039ecb Mon Sep 17 00:00:00 2001 From: "Cai, Justin" Date: Mon, 14 Apr 2025 21:30:39 + Subject: [PATCH 1/4] [Clang] Move OffloadArch enum to a generic location and add init

<    1   2   3   4   5   6   >