[clang] [libclang/C++] Fix clang_File_isEqual for in-memory files (PR #135773)

2025-04-23 Thread Aaron Ballman via cfe-commits
AaronBallman wrote: > LGTM, but how this fares against our stability guarantees for libclang APIs? > Do we need `clang_File_isEqual2`? I think this is a bug fix and so it meets our requirements. The ABI is stable, but we can fix logic bugs. https://github.com/llvm/llvm-project/pull/135773 ___

[clang] [llvm] Reland "[HLSL][RootSignature] Implement initial parsing of the descriptor table clause params" (PR #136740)

2025-04-23 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `sanitizer-x86_64-linux-android` running on `sanitizer-buildbot-android` while building `clang,llvm` at step 2 "annotate". Full details are available at: https://lab.llvm.org/buildbot/#/builders/186/builds/8449 Here is the r

[clang] [llvm] [NFC][RootSignatures] Conform to new std::optional calling conventions (PR #136747)

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

[clang] [Clang] Make the result type of sizeof/pointer subtraction/size_t lit… (PR #136542)

2025-04-23 Thread John McCall via cfe-commits
rjmccall wrote: That is not possible, and this is exactly what I'm worried about with all this discussion about making `size_t` more "built-in". `size_t` is specified to be a typedef of a (platform-dependent) standard integer type, and it needs to continue to behave that way; we cannot actuall

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

2025-04-23 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman commented: Where is this new API expected to be used? https://github.com/llvm/llvm-project/pull/136773 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Upstream enum support (PR #136807)

2025-04-23 Thread Bruno Cardoso Lopes via cfe-commits
https://github.com/bcardosolopes edited https://github.com/llvm/llvm-project/pull/136807 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][Modules] Diagnose mismatching pcm dependencies in explicit buiilds (PR #137068)

2025-04-23 Thread Jan Svoboda via cfe-commits
@@ -3311,11 +3312,22 @@ ASTReader::ReadControlBlock(ModuleFile &F, SignatureBytes.end()); Blob = Blob.substr(ASTFileSignature::size); +// Use BaseDirectoryAsWritten to ensure we use the same path in the +

[clang] [Clang,debuginfo] added vtt parameter in destructor DISubroutineType (PR #130674)

2025-04-23 Thread Reid Kleckner via cfe-commits
Markus =?utf-8?q?Gschoßmann?= , Markus =?utf-8?q?Gschoßmann?= , Markus =?utf-8?q?Gschoßmann?= , Markus =?utf-8?q?Gschoßmann?= Message-ID: In-Reply-To: rnk wrote: The actual underlying issue appears to come from ae0d224 / #91310 , which added `CodeGenModule::EmitExternalFunctionDeclaration`,

[clang] 0e0a166 - Revert unintentional diff from cd826d6e840ed33ad88458c862da5f9fcc6e908c

2025-04-23 Thread Reid Kleckner via cfe-commits
Author: Reid Kleckner Date: 2025-04-23T22:30:44Z New Revision: 0e0a1665fa340b9f1934d12aff818064aaf289ef URL: https://github.com/llvm/llvm-project/commit/0e0a1665fa340b9f1934d12aff818064aaf289ef DIFF: https://github.com/llvm/llvm-project/commit/0e0a1665fa340b9f1934d12aff818064aaf289ef.diff LOG:

[clang] [llvm] [OpenMP] Update the bitcode library install and search path (PR #136754)

2025-04-23 Thread Michael Kruse via cfe-commits
@@ -2794,6 +2794,11 @@ void tools::addOpenMPDeviceRTL(const Driver &D, for (const auto &LibPath : HostTC.getFilePaths()) LibraryPaths.emplace_back(LibPath); + // Check the target specific library path for the triple as well. + SmallString<128> P(D.Dir); + llvm::sys::p

[clang-tools-extra] [clangd] Strip invalid fromRanges for outgoing calls (PR #134657)

2025-04-23 Thread Hampus Adolfsson via cfe-commits
HampusAdolfsson wrote: @HighCommander4 Thanks, looks good to me! I don't have commit access, so feel free to merge this if you're happy with it. https://github.com/llvm/llvm-project/pull/134657 ___ cfe-commits mailing list cfe-commits@lists.llvm.org h

[clang] [clang][TSA] Make RequiresCapability a DeclOrType attribute (PR #67095)

2025-04-23 Thread Timm Baeder via cfe-commits
@@ -136,6 +136,17 @@ int main(void) { // Cleanup happens automatically -> no warning. } + /// Function pointers + { +int __attribute__((requires_capability(&mu1))) (*function_ptr)(int) = Foo_fun1; + +function_ptr(5); // expected-warning {{calling function 'fun

[clang-tools-extra] [clangd] Strip invalid fromRanges for outgoing calls (PR #134657)

2025-04-23 Thread Hampus Adolfsson via cfe-commits
https://github.com/HampusAdolfsson updated https://github.com/llvm/llvm-project/pull/134657 >From 162b0535fc2ae745441404231e6b3bf3882b974e Mon Sep 17 00:00:00 2001 From: Hampus Adolfsson Date: Mon, 7 Apr 2025 14:51:03 +0200 Subject: [PATCH 1/3] [clangd] Strip invalid fromRanges for outgoing cal

[clang] [llvm] [RISCV] Add Andes A45/AX45 processor definition (PR #136832)

2025-04-23 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-risc-v Author: Jim Lin (tclin914) Changes Andes A45/AX45 are 32/64bit in-order dual-issue 8-stage pipeline linux-capable CPU implementing the RV[32|64]IMAFDC_Zba_Zbb_Zbs ISA extensions. They are developed by Andes Technology https://www.andeste

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

2025-04-23 Thread Younan Zhang via cfe-commits
https://github.com/zyn0217 updated https://github.com/llvm/llvm-project/pull/122423 >From 56bacf47c53aca276ae4fa6aa2972b7eda152ddd Mon Sep 17 00:00:00 2001 From: Younan Zhang Date: Fri, 10 Jan 2025 09:46:24 +0800 Subject: [PATCH 1/9] Reapply "[Clang] Implement CWG2369 "Ordering between constra

[clang] [llvm] Checking scripts (PR #136829)

2025-04-23 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-amdgpu Author: None (blazie2004) Changes --- Patch is 75.64 MiB, truncated to 20.00 KiB below, full version: https://github.com/llvm/llvm-project/pull/136829.diff 4551 Files Affected: - (added) check_remote_class_check.py (+86) - (added)

[clang] [Clang] Enable -fextend-lifetimes at -Og (PR #118026)

2025-04-23 Thread Stephen Tozer via cfe-commits
SLTozer wrote: > Any ideas why we might be hitting this issue? This happens during a built > with `-Og`, and issue does not remove if I remove `-Og` flag. At a glance that looks like it could be related, we generate (no-op) cleanup as part of -fextend-variable-liveness. I'll look into this, bu

[clang] [llvm] [MIPS] Add FeatureMSA to i6400 and i6500 cores (PR #134985)

2025-04-23 Thread Mallikarjuna Gouda via cfe-commits
https://github.com/mgoudar updated https://github.com/llvm/llvm-project/pull/134985 >From 36a78bb9fe38781fa8ea126aeae5b7ed48140651 Mon Sep 17 00:00:00 2001 From: Mallikarjuna Gouda Date: Tue, 1 Apr 2025 12:35:27 +0530 Subject: [PATCH 1/6] [MIPS] Add FeatureMSA to i6400 and i6500 cores i6400 an

[clang] [llvm] Branch1 (PR #136834)

2025-04-23 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (blazie2004) Changes --- Full diff: https://github.com/llvm/llvm-project/pull/136834.diff 1 Files Affected: - (modified) clang/lib/AST/ASTConsumer.cpp (+52-8) ``diff diff --git a/clang/lib/AST/ASTConsumer.cpp b/clang/li

[clang] [llvm] [mlir] [NVPTX] Add support for Shared Cluster Memory address space [2/2] (PR #136768)

2025-04-23 Thread Guray Ozen via cfe-commits
grypp wrote: Can we please not merge anything without review? https://github.com/llvm/llvm-project/pull/136768 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Branch1 (PR #136834)

2025-04-23 Thread A. Jiang via cfe-commits
https://github.com/frederick-vs-ja requested changes to this pull request. IIUC the changes should go to some test file, not `clang/lib/AST/ASTConsumer.cpp`. https://github.com/llvm/llvm-project/pull/136834 ___ cfe-commits mailing list cfe-commits@lis

[clang] 0de2f64 - [clang] XFAIL the `Xclangas.s` test on AIX. (#136744)

2025-04-23 Thread via cfe-commits
Author: Alex Rønne Petersen Date: 2025-04-23T11:40:36+02:00 New Revision: 0de2f64e652a1b8c1e051635c98fb2b69c6b2c62 URL: https://github.com/llvm/llvm-project/commit/0de2f64e652a1b8c1e051635c98fb2b69c6b2c62 DIFF: https://github.com/llvm/llvm-project/commit/0de2f64e652a1b8c1e051635c98fb2b69c6b2c62

[clang] [llvm] Branch1 (PR #136834)

2025-04-23 Thread via cfe-commits
https://github.com/blazie2004 closed https://github.com/llvm/llvm-project/pull/136834 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] XFAIL the `Xclangas.s` test on AIX. (PR #136744)

2025-04-23 Thread Alex Rønne Petersen via cfe-commits
https://github.com/alexrp closed https://github.com/llvm/llvm-project/pull/136744 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][ptrauth] add support for options parameter to __ptrauth (PR #136828)

2025-04-23 Thread via cfe-commits
@@ -8374,20 +8376,212 @@ static void HandlePtrAuthQualifier(ASTContext &Ctx, QualType &T, IsInvalid |= !S.checkPointerAuthDiscriminatorArg( ExtraDiscriminatorArg, Sema::PADAK_ExtraDiscPtrAuth, ExtraDiscriminator); - if (IsInvalid) { -Attr.setInvalid(); -retur

[clang] [llvm] Branch1 (PR #136834)

2025-04-23 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] Warning as error for fold expressions over comparison operators (PR #136836)

2025-04-23 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: cor3ntin (cor3ntin) Changes We made chained comparisons an error. Fold-expressions over a comparison operator produce chained comparisons, so we should be consistent there too. We only emit the warning when instantiating the fold expressi

[clang] [clang-format] Correctly identify include guards (PR #137112)

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

[clang] [clang][ptrauth] add support for options parameter to __ptrauth (PR #136828)

2025-04-23 Thread Oliver Hunt via cfe-commits
https://github.com/ojhunt created https://github.com/llvm/llvm-project/pull/136828 This PR adds support for an 'options' parameter for the __ptrauth qualifier. The initial version only exposes the authehntication modes: * "strip" * "sign-and-strip" * "sign-and-auth" There are other options

[clang] [clang][ptrauth] add support for options parameter to __ptrauth (PR #136828)

2025-04-23 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,c,h -- clang/test/CodeGen/ptrauth-stripping.c clang/tes

[clang] [clang][ptrauth] add support for options parameter to __ptrauth (PR #136828)

2025-04-23 Thread Oliver Hunt via cfe-commits
ojhunt wrote: The tests in this PR are dependent on #136828, and the included tests have non-sequential numbers as the tests include other options that are not supported by this PR, to try and limit the complexity of this PR to just the parsing and existing functionality. https://github.com/l

[clang] [clang][ptrauth] add support for options parameter to __ptrauth (PR #136828)

2025-04-23 Thread Oliver Hunt via cfe-commits
@@ -8374,20 +8376,191 @@ static void HandlePtrAuthQualifier(ASTContext &Ctx, QualType &T, IsInvalid |= !S.checkPointerAuthDiscriminatorArg( ExtraDiscriminatorArg, Sema::PADAK_ExtraDiscPtrAuth, ExtraDiscriminator); - if (IsInvalid) { -Attr.setInvalid(); -retur

[clang] [llvm] Checking scripts (PR #136829)

2025-04-23 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] [llvm] Checking scripts (PR #136829)

2025-04-23 Thread via cfe-commits
https://github.com/blazie2004 created https://github.com/llvm/llvm-project/pull/136829 None error: too big or took too long to generate ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][ptrauth] add support for options parameter to __ptrauth (PR #136828)

2025-04-23 Thread Oliver Hunt via cfe-commits
@@ -8374,20 +8376,191 @@ static void HandlePtrAuthQualifier(ASTContext &Ctx, QualType &T, IsInvalid |= !S.checkPointerAuthDiscriminatorArg( ExtraDiscriminatorArg, Sema::PADAK_ExtraDiscPtrAuth, ExtraDiscriminator); - if (IsInvalid) { -Attr.setInvalid(); -retur

[clang] [llvm] Checking scripts (PR #136829)

2025-04-23 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (blazie2004) Changes --- Patch is 75.64 MiB, truncated to 20.00 KiB below, full version: https://github.com/llvm/llvm-project/pull/136829.diff 4551 Files Affected: - (added) check_remote_class_check.py (+86) - (added) check_rem

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

2025-04-23 Thread Piotr Zegar via cfe-commits
@@ -0,0 +1,116 @@ +// RUN: %check_clang_tidy -std=c++17 %s bugprone-invalid-enum-default-initialization %t + PiotrZSL wrote: Add test with enum forward declaration only, and with enum without enumerators. For those there should be no requirement in initializatio

[clang] [clang][ptrauth] add support for options parameter to __ptrauth (PR #136828)

2025-04-23 Thread Oliver Hunt via cfe-commits
@@ -8374,20 +8376,191 @@ static void HandlePtrAuthQualifier(ASTContext &Ctx, QualType &T, IsInvalid |= !S.checkPointerAuthDiscriminatorArg( ExtraDiscriminatorArg, Sema::PADAK_ExtraDiscPtrAuth, ExtraDiscriminator); - if (IsInvalid) { -Attr.setInvalid(); -retur

[clang] [llvm] [MIPS] Add FeatureMSA to i6400 and i6500 cores (PR #134985)

2025-04-23 Thread Mallikarjuna Gouda via cfe-commits
https://github.com/mgoudar updated https://github.com/llvm/llvm-project/pull/134985 >From 36a78bb9fe38781fa8ea126aeae5b7ed48140651 Mon Sep 17 00:00:00 2001 From: Mallikarjuna Gouda Date: Tue, 1 Apr 2025 12:35:27 +0530 Subject: [PATCH 1/5] [MIPS] Add FeatureMSA to i6400 and i6500 cores i6400 an

[clang] [clang][ptrauth] add support for options parameter to __ptrauth (PR #136828)

2025-04-23 Thread Oliver Hunt via cfe-commits
ojhunt wrote: This PR is a draft as it will need to be updated to merged correctly, and verify test output (conflicts, unintentional mismatches coming from splitting out the PR) after #136828 https://github.com/llvm/llvm-project/pull/136828 ___ cfe-c

[clang] [clang][ptrauth] add support for options parameter to __ptrauth (PR #136828)

2025-04-23 Thread Oliver Hunt via cfe-commits
https://github.com/ojhunt updated https://github.com/llvm/llvm-project/pull/136828 >From b3de41c15edc527154e461e5b0df61642599b45e Mon Sep 17 00:00:00 2001 From: Oliver Hunt Date: Wed, 23 Apr 2025 01:43:00 -0700 Subject: [PATCH 1/2] [clang][ptrauth] add support for options parameter to __ptraut

[clang] [llvm] Checking scripts (PR #136829)

2025-04-23 Thread via cfe-commits
https://github.com/blazie2004 closed https://github.com/llvm/llvm-project/pull/136829 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [RISCV] Add Andes A45/AX45 processor definition (PR #136832)

2025-04-23 Thread Jim Lin via cfe-commits
https://github.com/tclin914 created https://github.com/llvm/llvm-project/pull/136832 Andes A45/AX45 are 32/64bit in-order dual-issue 8-stage pipeline linux-capable CPU implementing the RV[32|64]IMAFDC_Zba_Zbb_Zbs ISA extensions. They are developed by Andes Technology https://www.andestech.com,

[clang] [clang][ptrauth] add support for options parameter to __ptrauth (PR #136828)

2025-04-23 Thread Oliver Hunt via cfe-commits
@@ -8350,14 +8350,16 @@ static void HandleNeonVectorTypeAttr(QualType &CurType, const ParsedAttr &Attr, /// Handle the __ptrauth qualifier. static void HandlePtrAuthQualifier(ASTContext &Ctx, QualType &T, const ParsedAttr &Attr, Sema &S) { -

[clang] [clang][ARM][AArch64] Don't require arm_acle header for universally defined intrinsics (PR #136742)

2025-04-23 Thread Martin Storsjö via cfe-commits
mstorsjo wrote: I think we should revert https://github.com/llvm/llvm-project/pull/128222 if we can't move forward with this one soon. Unfortunately I'm not sure if I'm qualified to review it. https://github.com/llvm/llvm-project/pull/136742 ___ cfe-

[clang] [clang][ptrauth] add support for options parameter to __ptrauth (PR #136828)

2025-04-23 Thread Oliver Hunt via cfe-commits
@@ -8374,20 +8376,212 @@ static void HandlePtrAuthQualifier(ASTContext &Ctx, QualType &T, IsInvalid |= !S.checkPointerAuthDiscriminatorArg( ExtraDiscriminatorArg, Sema::PADAK_ExtraDiscPtrAuth, ExtraDiscriminator); - if (IsInvalid) { -Attr.setInvalid(); -retur

[clang] [CIR] Create CIR_TypedAttr common class (PR #136852)

2025-04-23 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Henrich Lauko (xlauko) Changes Introduce common base class for attributes with single type parameter. This mirrors incubator changes introduced in https://github.com/llvm/clangir/pull/1583 --- Full diff: https://github.com/llvm/llvm-proje

[clang] [CUDA][HIP] Add a __device__ version of std::__glibcxx_assert_fail() (PR #136133)

2025-04-23 Thread Juan Manuel Martinez Caamaño via cfe-commits
@@ -0,0 +1,35 @@ +// libstdc++ uses the non-constexpr function std::__glibcxx_assert_fail() +// to trigger compilation errors when the __glibcxx_assert(cond) macro +// is used in a constexpr context. +// Compilation fails when using code from the libstdc++ (such as std::array) on

[clang] [CIR] Create CIR_TypedAttr common class (PR #136852)

2025-04-23 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clangir Author: Henrich Lauko (xlauko) Changes Introduce common base class for attributes with single type parameter. This mirrors incubator changes introduced in https://github.com/llvm/clangir/pull/1583 --- Full diff: https://github.com/llvm/llvm-pro

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

2025-04-23 Thread Balázs Benics via cfe-commits
https://github.com/balazs-benics-sonarsource edited https://github.com/llvm/llvm-project/pull/136720 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

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

2025-04-23 Thread Balázs Benics via cfe-commits
@@ -0,0 +1,198 @@ +// RUN: %clang_analyze_cc1 -analyzer-checker=core,debug.ExprInspection -verify=expected,default %s +// RUN: %clang_analyze_cc1 -analyzer-checker=core,debug.ExprInspection -analyzer-config legacy-inlining-prevention=false -verify=expected,disabled %s + +int get

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

2025-04-23 Thread Balázs Benics via cfe-commits
balazs-benics-sonarsource wrote: One other note. We should backport this fix to clang-20 once it lands to main. https://github.com/llvm/llvm-project/pull/136720 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mail

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

2025-04-23 Thread Balázs Benics via cfe-commits
@@ -0,0 +1,198 @@ +// RUN: %clang_analyze_cc1 -analyzer-checker=core,debug.ExprInspection -verify=expected,default %s +// RUN: %clang_analyze_cc1 -analyzer-checker=core,debug.ExprInspection -analyzer-config legacy-inlining-prevention=false -verify=expected,disabled %s + +int get

[clang] [Clang] Warning as error for fold expressions over comparison operators (PR #136836)

2025-04-23 Thread Aaron Ballman via cfe-commits
https://github.com/AaronBallman approved this pull request. LGTM with a minor rewording and reformatting of the diagnostic message. https://github.com/llvm/llvm-project/pull/136836 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.l

[clang] [Clang] Warning as error for fold expressions over comparison operators (PR #136836)

2025-04-23 Thread Aaron Ballman via cfe-commits
@@ -7138,6 +7138,13 @@ def warn_consecutive_comparison : Warning< "chained comparison 'X %0 Y %1 Z' does not behave the same as a mathematical expression">, InGroup, DefaultError; +def warn_comparison_in_fold_expression +: Warning< + "comparison in a fold exp

[clang] [AArch64] Update __gcsss intrinsic to match revised ACLE specification (PR #136850)

2025-04-23 Thread via cfe-commits
https://github.com/sivan-shani converted_to_draft https://github.com/llvm/llvm-project/pull/136850 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Allow simpler visibility annotations when targeting win32 and mingw (PR #133699)

2025-04-23 Thread Hans Wennborg via cfe-commits
zmodem wrote: I too had trouble understanding this change based on the description. Could you give a concrete example of how mingw and msvc disagree on where to put the attribute, and explain how this pr changes things? Taking a step back, how will this simplify libc++'s visibility annotations

[clang] [clang][ptrauth] add support for options parameter to __ptrauth (PR #136828)

2025-04-23 Thread Oliver Hunt via cfe-commits
@@ -8374,20 +8376,212 @@ static void HandlePtrAuthQualifier(ASTContext &Ctx, QualType &T, IsInvalid |= !S.checkPointerAuthDiscriminatorArg( ExtraDiscriminatorArg, Sema::PADAK_ExtraDiscPtrAuth, ExtraDiscriminator); - if (IsInvalid) { -Attr.setInvalid(); -retur

[clang] [Clang] diagnose deleted/default redeclaration of defined friend functions (PR #136717)

2025-04-23 Thread Yanzuo Liu via cfe-commits
https://github.com/zwuis commented: LGTM https://github.com/llvm/llvm-project/pull/136717 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CUDA][HIP] Add a __device__ version of std::__glibcxx_assert_fail() (PR #136133)

2025-04-23 Thread Juan Manuel Martinez Caamaño via cfe-commits
https://github.com/jmmartinez updated https://github.com/llvm/llvm-project/pull/136133 From b433add1b7c2027b89cdd9be11680c0a9a59e807 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Juan=20Manuel=20Martinez=20Caama=C3=B1o?= Date: Thu, 17 Apr 2025 13:41:55 +0200 Subject: [PATCH] [CUDA][HIP] Add a __devi

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

2025-04-23 Thread Jan Svoboda via cfe-commits
@@ -107,15 +107,28 @@ CXString createCXString(CXStringBuf *buf) { return Str; } -CXStringSet *createSet(const std::vector &Strings) { +template +static CXStringSet *createSetImpl(ArrayRef Strings) { jansvoboda11 wrote: Nit: If you switched the order of tem

[clang] [llvm] [RISCV] Allow `Zicsr`/`Zifencei` to duplicate with `g` (PR #136842)

2025-04-23 Thread Luke Lau via cfe-commits
https://github.com/lukel97 approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/136842 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [RISCV] Allow `Zicsr`/`Zifencei` to duplicate with `g` (PR #136842)

2025-04-23 Thread Luke Lau via cfe-commits
@@ -717,6 +716,15 @@ RISCVISAInfo::parseArchString(StringRef Arch, bool EnableExperimentalExtension, } while (!Ext.empty()); } + // We add Zicsr/Zifenci as final to allow duplicated "zicsr"/"zifencei". lukel97 wrote: Nit, give an example that it's dup

[libclc] [libclc] Build for OpenCL 3.0 (PR #135733)

2025-04-23 Thread Wenju He via cfe-commits
https://github.com/wenju-he edited https://github.com/llvm/llvm-project/pull/135733 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [openmp] [OpenMP] Change build of OpenMP device runtime to be a separate runtime (PR #136729)

2025-04-23 Thread Joseph Huber via cfe-commits
@@ -122,35 +130,41 @@ else() get_clang_resource_dir(LIBOMP_HEADERS_INSTALL_PATH SUBDIR include) endif() -# Build host runtime library, after LIBOMPTARGET variables are set since they are needed -# to enable time profiling support in the OpenMP runtime. -add_subdirectory(run

[clang] Fix a crash in constant evaluation of ExtVectorElementExprs (PR #136771)

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

[clang] [C] Add (new) -Wimplicit-void-ptr-cast to -Wc++-compat (PR #136855)

2025-04-23 Thread Erich Keane via cfe-commits
@@ -0,0 +1,28 @@ +// RUN: %clang_cc1 -fsyntax-only -verify -Wimplicit-void-ptr-cast %s +// RUN: %clang_cc1 -fsyntax-only -verify -Wc++-compat %s +// RUN: %clang_cc1 -fsyntax-only -verify=good %s +// RUN: %clang_cc1 -fsyntax-only -verify=good -Wc++-compat -Wno-implicit-void-ptr-ca

[clang] [llvm] [Clang][llvm] Implement fp8 FMOP4A intrinsics (PR #130127)

2025-04-23 Thread Virginia Cangelosi via cfe-commits
https://github.com/virginia-cangelosi closed https://github.com/llvm/llvm-project/pull/130127 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix a crash in constant evaluation of ExtVectorElementExprs (PR #136771)

2025-04-23 Thread Erich Keane via cfe-commits
@@ -9197,7 +9197,10 @@ bool LValueExprEvaluator::VisitExtVectorElementExpr( if (Success) { Result.setFrom(Info.Ctx, Val); -const auto *VT = E->getBase()->getType()->castAs(); +QualType BaseType = E->getBase()->getType(); +if (E->isArrow()) er

[clang] [llvm] [OpenMP] Update the bitcode library install and search path (PR #136754)

2025-04-23 Thread Joseph Huber via cfe-commits
@@ -2794,6 +2794,11 @@ void tools::addOpenMPDeviceRTL(const Driver &D, for (const auto &LibPath : HostTC.getFilePaths()) LibraryPaths.emplace_back(LibPath); + // Check the target specific library path for the triple as well. + SmallString<128> P(D.Dir); + llvm::sys::p

[clang] 6d0d50f - [OpenMP] Update the bitcode library install and search path (#136754)

2025-04-23 Thread via cfe-commits
Author: Joseph Huber Date: 2025-04-23T08:20:15-05:00 New Revision: 6d0d50f0ac0cb108a06558cb178a68fb78cfa06f URL: https://github.com/llvm/llvm-project/commit/6d0d50f0ac0cb108a06558cb178a68fb78cfa06f DIFF: https://github.com/llvm/llvm-project/commit/6d0d50f0ac0cb108a06558cb178a68fb78cfa06f.diff

[clang] [llvm] [RISCV] Add support for Ziccamoc (PR #136694)

2025-04-23 Thread Pengcheng Wang via cfe-commits
@@ -167,6 +167,7 @@ Changes to the RISC-V Backend * Adds assembler support for ``.option exact``, which disables automatic compression, and branch and linker relaxation. This can be disabled with ``.option noexact``, which is also the default. +* Support was added for the

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

2025-04-23 Thread Donát Nagy via cfe-commits
@@ -0,0 +1,198 @@ +// RUN: %clang_analyze_cc1 -analyzer-checker=core,debug.ExprInspection -verify=expected,default %s +// RUN: %clang_analyze_cc1 -analyzer-checker=core,debug.ExprInspection -analyzer-config legacy-inlining-prevention=false -verify=expected,disabled %s + +int get

[clang] [llvm] [MIPS] Add FeatureMSA to i6400 and i6500 cores (PR #134985)

2025-04-23 Thread Mallikarjuna Gouda via cfe-commits
@@ -0,0 +1,69 @@ +; Test the MSA intrinsics that are encoded with the SPECIAL instruction format. mgoudar wrote: I have enabled MSA feature from driver also when -mcpu i6500/i6400 is specified. Also I have added codegen test to verify MSA instructions when i650

[clang] [llvm] [openmp] [OpenMP] Change build of OpenMP device runtime to be a separate runtime (PR #136729)

2025-04-23 Thread Joseph Huber via cfe-commits
jhuber6 wrote: > I think using the LLVM_ENABLE_RUNTIMES-machanism is a great idea. Regarding > the move back to `openmp/device`, I don't really have an opinion. However, > there are some arguments to make: > > 1. The same arguments apply to `libomptarget` as well > > 2. Definitions su

[clang] [llvm] [MIPS] Add FeatureMSA to i6400 and i6500 cores (PR #134985)

2025-04-23 Thread Mallikarjuna Gouda via cfe-commits
@@ -0,0 +1,9 @@ +// Check target CPUs are correctly passed. + +// RUN: %clang --target=mips64 -### -c %s 2>&1 -mcpu=i6400 -mmsa | FileCheck -check-prefix=MCPU-I6400 %s +// MCPU-I6400: "-target-cpu" "i6400" mgoudar wrote: I modified test to verify abicalls featur

[clang] [llvm] [OpenMP] Update the bitcode library install and search path (PR #136754)

2025-04-23 Thread Joseph Huber via cfe-commits
https://github.com/jhuber6 closed https://github.com/llvm/llvm-project/pull/136754 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Control analysis-based diagnostics with #pragma (PR #136323)

2025-04-23 Thread Nikita Popov via cfe-commits
nikic wrote: FYI this introduces some overhead: https://llvm-compile-time-tracker.com/compare.php?from=2a9f77f6bd48d757b2d45aadcb6cf76ef4b4ef32&to=71ce9e26aec00e4af27a69ccfab8ca1773ed7018&stat=instructions:u About 0.3% on clang files. https://github.com/llvm/llvm-project/pull/136323 __

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

2025-04-23 Thread Qiongsi Wu via cfe-commits
https://github.com/qiongsiwu updated https://github.com/llvm/llvm-project/pull/136773 >From 7f39ebcc34fe3f40c2554ff7fa93baca5b4634a0 Mon Sep 17 00:00:00 2001 From: Qiongsi Wu Date: Tue, 22 Apr 2025 14:17:15 -0700 Subject: [PATCH 1/5] Adding CXStringSet *createSet that takes a vector of StringR

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

2025-04-23 Thread Qiongsi Wu via cfe-commits
@@ -107,15 +107,28 @@ CXString createCXString(CXStringBuf *buf) { return Str; } -CXStringSet *createSet(const std::vector &Strings) { +template +static CXStringSet *createSetImpl(ArrayRef Strings) { CXStringSet *Set = new CXStringSet; Set->Count = Strings.size(); S

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

2025-04-23 Thread Qiongsi Wu via cfe-commits
@@ -107,15 +107,28 @@ CXString createCXString(CXStringBuf *buf) { return Str; } -CXStringSet *createSet(const std::vector &Strings) { +template +static CXStringSet *createSetImpl(ArrayRef Strings) { qiongsiwu wrote: Ah yes this is good to keep in mind. I r

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

2025-04-23 Thread Oliver Stöneberg via cfe-commits
firewave wrote: There's also a check in UBSAN which detects assignment of invalid values during run-time. So there's logic is various other places regarding this. https://github.com/llvm/llvm-project/pull/136823 ___ cfe-commits mailing list cfe-commit

[clang] [llvm] [RISCV] Allow `Zicsr`/`Zifencei` to duplicate with `g` (PR #136842)

2025-04-23 Thread Luke Lau via cfe-commits
https://github.com/lukel97 edited https://github.com/llvm/llvm-project/pull/136842 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libclc] [libclc] Build for OpenCL 3.0 (PR #135733)

2025-04-23 Thread Wenju He via cfe-commits
@@ -429,7 +411,9 @@ foreach( t ${LIBCLC_TARGETS_TO_BUILD} ) set( LIBCLC_ARCH_OBJFILE_DIR "${LIBCLC_OBJFILE_DIR}/${arch_suffix}" ) file( MAKE_DIRECTORY ${LIBCLC_ARCH_OBJFILE_DIR} ) -list( APPEND build_flags -cl-std=${opencl_lang_std} ) +# Build for OpenCL 3.0 an

[libclc] [libclc] Build for OpenCL 3.0 (PR #135733)

2025-04-23 Thread Wenju He via cfe-commits
https://github.com/wenju-he edited https://github.com/llvm/llvm-project/pull/135733 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [AArch64] Update __gcsss intrinsic to match revised ACLE specification (PR #136850)

2025-04-23 Thread via cfe-commits
https://github.com/sivan-shani created https://github.com/llvm/llvm-project/pull/136850 The original __gcsss intrinsic was implemented based on: https://github.com/ARM-software/acle/pull/260 with the signature: const void *__gcsss(const void *) Per the updated specification in: https://github.

[clang] [AArch64] Update __gcsss intrinsic to match revised ACLE specification (PR #136850)

2025-04-23 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: SivanShani-Arm (sivan-shani) Changes The original __gcsss intrinsic was implemented based on: https://github.com/ARM-software/acle/pull/260 with the signature: const void *__gcsss(const void *) Per the updated specification in: https://gi

[clang] [AArch64] Update __gcsss intrinsic to match revised ACLE specification (PR #136850)

2025-04-23 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 h -- clang/lib/Headers/arm_acle.h `` View the d

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

2025-04-23 Thread Balázs Benics via cfe-commits
https://github.com/balazs-benics-sonarsource requested changes to this pull request. Thank you for investigating this. At Sonar, we have not yet started the upgrade to clang-20. I suppose, you already did then, thus found this regression on trunk. Maybe we should also reflect of the quality c

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

2025-04-23 Thread Balázs Benics via cfe-commits
@@ -0,0 +1,198 @@ +// RUN: %clang_analyze_cc1 -analyzer-checker=core,debug.ExprInspection -verify=expected,default %s +// RUN: %clang_analyze_cc1 -analyzer-checker=core,debug.ExprInspection -analyzer-config legacy-inlining-prevention=false -verify=expected,disabled %s + +int get

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

2025-04-23 Thread Balázs Benics via cfe-commits
@@ -0,0 +1,198 @@ +// RUN: %clang_analyze_cc1 -analyzer-checker=core,debug.ExprInspection -verify=expected,default %s +// RUN: %clang_analyze_cc1 -analyzer-checker=core,debug.ExprInspection -analyzer-config legacy-inlining-prevention=false -verify=expected,disabled %s + +int get

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

2025-04-23 Thread Balázs Benics via cfe-commits
@@ -2523,6 +2523,20 @@ bool ExprEngine::replayWithoutInlining(ExplodedNode *N, return true; } +/// Return the innermost location context which is inlined at `Node`, unless +/// it's the top-level (entry point) location context. +static const LocationContext *getInlinedLocati

[clang] [llvm] [RISCV] Allow `Zicsr`/`Zifencei` to duplicate with `g` (PR #136842)

2025-04-23 Thread Pengcheng Wang via cfe-commits
https://github.com/wangpc-pp created https://github.com/llvm/llvm-project/pull/136842 This matches GCC and we supported it in LLVM 17/18. Fixes #136803 >From e133a5fc0091ec045a0ea0114d553c72e8f33e51 Mon Sep 17 00:00:00 2001 From: Pengcheng Wang Date: Wed, 23 Apr 2025 18:19:41 +0800 Subject:

[clang] [llvm] [Clang][llvm] Implement fp8 FMOP4A intrinsics (PR #130127)

2025-04-23 Thread Virginia Cangelosi via cfe-commits
https://github.com/virginia-cangelosi updated https://github.com/llvm/llvm-project/pull/130127 >From f2a217606537b67a314f9e2b50d7edad5b6ca0cd Mon Sep 17 00:00:00 2001 From: Virginia Cangelosi Date: Thu, 6 Mar 2025 13:38:19 + Subject: [PATCH 1/4] [Clang][llvm] Implement fp8 FMOP4A intrinsics

[libclc] [libclc] Build for OpenCL 3.0 (PR #135733)

2025-04-23 Thread Fraser Cormack via cfe-commits
https://github.com/frasercrmck closed https://github.com/llvm/llvm-project/pull/135733 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [clang][OpenMP] New OpenMP 6.0 threadset clause (PR #135807)

2025-04-23 Thread via cfe-commits
@@ -3691,6 +3691,7 @@ CGOpenMPRuntime::emitTaskInit(CodeGenFunction &CGF, SourceLocation Loc, DestructorsFlag = 0x8, PriorityFlag = 0x20, DetachableFlag = 0x40, +PoolFlag = 0x80, Ritanya-B-Bharadwaj wrote: Not yet, I have not added support for

[clang] [llvm] [clang] [OpenMP] New OpenMP 6.0 self_maps clause - CodeGen (PR #134131)

2025-04-23 Thread via cfe-commits
https://github.com/Ritanya-B-Bharadwaj edited https://github.com/llvm/llvm-project/pull/134131 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [clang][OpenMP] New OpenMP 6.0 threadset clause (PR #135807)

2025-04-23 Thread via cfe-commits
https://github.com/Ritanya-B-Bharadwaj edited https://github.com/llvm/llvm-project/pull/135807 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [RISCV] Allow `Zicsr`/`Zifencei` to duplicate with `g` (PR #136842)

2025-04-23 Thread Craig Topper via cfe-commits
@@ -717,6 +716,16 @@ RISCVISAInfo::parseArchString(StringRef Arch, bool EnableExperimentalExtension, } while (!Ext.empty()); } + // We add Zicsr/Zifenci as final to allow duplicated "zicsr"/"zifencei" like + // "rv64g_zicsr_zifencei". + if (Baseline == 'g') { +fo

[clang] [AArch64] Update __gcsss intrinsic to match revised ACLE specification (PR #136850)

2025-04-23 Thread via cfe-commits
https://github.com/sivan-shani ready_for_review https://github.com/llvm/llvm-project/pull/136850 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

<    1   2   3   4   5   >