[clang] [clang][bytecode] Only implicitly start lifetime of trivially-default-constructible union members (PR #149835)

2025-07-22 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `sanitizer-x86_64-linux-bootstrap-asan` running on `sanitizer-buildbot2` while building `clang` at step 2 "annotate". Full details are available at: https://lab.llvm.org/buildbot/#/builders/52/builds/9882 Here is the relevan

[clang] [llvm] [SimplifyCFG] Extend jump-threading to allow live local defs (PR #135079)

2025-07-22 Thread via cfe-commits
@@ -3540,18 +3568,29 @@ foldCondBranchOnValueKnownInPredecessorImpl(BranchInst *BI, DomTreeUpdater *DTU, return false; // Now we know that this block has multiple preds and two succs. - // Check that the block is small enough and values defined in the block are - // n

[libclc] [libclc] Add generic native half implementation of __clc_normalize (PR #150165)

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

[clang] [clang-format] Change SpaceAfterLogicalNot to enumeration type (PR #150166)

2025-07-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang @llvm/pr-subscribers-clang-format Author: Owen Pan (owenca) Changes Replace true/false with SAN_Exclaim/SAN_Never and add SAN_Always. Closes #149971 --- Full diff: https://github.com/llvm/llvm-project/pull/150166.diff 6 Files Affected: - (modi

[clang] [clang-format] Change SpaceAfterLogicalNot to enumeration type (PR #150166)

2025-07-22 Thread Owen Pan via cfe-commits
https://github.com/owenca created https://github.com/llvm/llvm-project/pull/150166 Replace true/false with SAN_Exclaim/SAN_Never and add SAN_Always. Closes #149971 >From b5442f59d649b38086ccd91d40c7c291dd924cc8 Mon Sep 17 00:00:00 2001 From: Owen Pan Date: Tue, 22 Jul 2025 22:07:05 -0700 Subj

[libclc] [libclc] Add native half implementation of __clc_normalize (PR #150165)

2025-07-22 Thread Wenju He via cfe-commits
wenju-he wrote: llvm-diff amdgcn--amdhsa.bc.new amdgcn--amdhsa.bc.old ``` in function _Z9normalizeDh: in block %1 / %1: > %2 = fpext half %0 to float %2 = fcmp one half %0, 0xH > %4 = select i1 %3, float 1.00e+00, float 0.00e+00 > %5 = tail call noundef flo

[libclc] [libclc] Add native half implementation of __clc_normalize (PR #150165)

2025-07-22 Thread Wenju He via cfe-commits
https://github.com/wenju-he created https://github.com/llvm/llvm-project/pull/150165 This is ported from https://github.com/intel/llvm/blob/sycl/libclc/libspirv/lib/generic/geometric/normalize.cl and can pass a closed-source OpenCL CTS "test_geometrics geom_normalize --half CL_DEVICE_TYPE_GPU"

[clang] [clang][bytecode] Activate primitive fields before initializing them (PR #149963)

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

[clang] 23eef9a - [clang][bytecode] Activate primitive fields before initializing them (#149963)

2025-07-22 Thread via cfe-commits
Author: Timm Baeder Date: 2025-07-23T06:09:27+02:00 New Revision: 23eef9a7c40f15fcf3cd393e7dc18f48c516bf7e URL: https://github.com/llvm/llvm-project/commit/23eef9a7c40f15fcf3cd393e7dc18f48c516bf7e DIFF: https://github.com/llvm/llvm-project/commit/23eef9a7c40f15fcf3cd393e7dc18f48c516bf7e.diff L

[clang] [clang][ExprConst] Consider integer pointers of value 0 nullptr (PR #150164)

2025-07-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Timm Baeder (tbaederr) Changes When casting a 0 to a pointer type, the IsNullPtr flag was always set to false, leading to weird results like a pointer with value 0 that isn't a null pointer. This caused ```c++ struct B { const int *p;};

[clang] [clang][ExprConst] Consider integer pointers of value 0 nullptr (PR #150164)

2025-07-22 Thread Timm Baeder via cfe-commits
https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/150164 When casting a 0 to a pointer type, the IsNullPtr flag was always set to false, leading to weird results like a pointer with value 0 that isn't a null pointer. This caused ```c++ struct B { const int *p;}; te

[clang] Add necessary linker flags when -static-pie is enabled in BareMetal Toolchain (PR #147589)

2025-07-22 Thread Garvit Gupta via cfe-commits
https://github.com/quic-garvgupt milestoned https://github.com/llvm/llvm-project/pull/147589 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang][SYCL] Add sycl_external attribute and restrict emitting device code (PR #140282)

2025-07-22 Thread Tom Honermann via cfe-commits
@@ -12952,8 +12956,11 @@ bool ASTContext::DeclMustBeEmitted(const Decl *D) { if (LangOpts.SYCLIsDevice && FD->hasAttr()) return true; -// FIXME: Functions declared with SYCL_EXTERNAL are required during -// device compilation. +// Function definitions wit

[clang] [clang][timers][stats] Add a flag to enable timers in the stats file (PR #149946)

2025-07-22 Thread Alan Zhao via cfe-commits
https://github.com/alanzhao1 closed https://github.com/llvm/llvm-project/pull/149946 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 9285852 - [clang][timers][stats] Add a flag to enable timers in the stats file (#149946)

2025-07-22 Thread via cfe-commits
Author: Alan Zhao Date: 2025-07-22T18:50:45-07:00 New Revision: 92858528c2db534e4101b7ac6cd263ac7884764d URL: https://github.com/llvm/llvm-project/commit/92858528c2db534e4101b7ac6cd263ac7884764d DIFF: https://github.com/llvm/llvm-project/commit/92858528c2db534e4101b7ac6cd263ac7884764d.diff LOG

[clang] [clang] Fix potential constant expression checking with constexpr-unknown. (PR #149227)

2025-07-22 Thread A. Jiang via cfe-commits
frederick-vs-ja wrote: > Can you manually backport this patch? See #150131. This is being backported manually in #149402. https://github.com/llvm/llvm-project/pull/149227 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/c

[clang] [Clang] Rework creating offloading toolchains (PR #125556)

2025-07-22 Thread Jinsong Ji via cfe-commits
https://github.com/jsji edited https://github.com/llvm/llvm-project/pull/125556 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [Clang] Rework creating offloading toolchains (PR #125556)

2025-07-22 Thread Jinsong Ji via cfe-commits
@@ -950,221 +930,264 @@ static bool addSYCLDefaultTriple(Compilation &C, return true; } -void Driver::CreateOffloadingDeviceToolChains(Compilation &C, - InputList &Inputs) { - - // - // CUDA/HIP - // - // We need to generate a

[clang] efffa42 - [Clang] Add generated offloading Xarch args to synthesized args (#150142)

2025-07-22 Thread via cfe-commits
Author: Joseph Huber Date: 2025-07-22T20:20:13-05:00 New Revision: efffa42f593739ea7d80a5be301b6f235e44f35a URL: https://github.com/llvm/llvm-project/commit/efffa42f593739ea7d80a5be301b6f235e44f35a DIFF: https://github.com/llvm/llvm-project/commit/efffa42f593739ea7d80a5be301b6f235e44f35a.diff

[clang] [Clang] Add generated offloading Xarch args to synthesized args (PR #150142)

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

[clang] [Clang] Add generated offloading Xarch args to synthesized args (PR #150142)

2025-07-22 Thread Jinsong Ji via cfe-commits
https://github.com/jsji approved this pull request. LG, Thanks! https://github.com/llvm/llvm-project/pull/150142 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix potential constant expression checking with constexpr-unknown. (PR #149227)

2025-07-22 Thread Yanzuo Liu via cfe-commits
zwuis wrote: Can you manually backport this patch? See #150131. https://github.com/llvm/llvm-project/pull/149227 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[libclc] [libclc] Optimize generic CLC fmin/fmax (PR #128506)

2025-07-22 Thread Wenju He via cfe-commits
wenju-he wrote: > If the decision is the conformance test continues doing what it has been > doing, it should directly map to llvm.minimumnum/maximumnum. For now, @frasercrmck can we update this PR to use __builtin_elementwise_maximumnum/minimumnum so that OpenCL CTS can pass? https://github.

[clang] 471e59b - [clang] Set correct CXXABI for UEFI (#150115)

2025-07-22 Thread via cfe-commits
Author: Prabhu Rajasekaran Date: 2025-07-22T17:57:17-07:00 New Revision: 471e59b858b1d2ee844cb527522e60ed03a1a1dc URL: https://github.com/llvm/llvm-project/commit/471e59b858b1d2ee844cb527522e60ed03a1a1dc DIFF: https://github.com/llvm/llvm-project/commit/471e59b858b1d2ee844cb527522e60ed03a1a1dc.

[clang] [clang] Set correct CXXABI for UEFI (PR #150115)

2025-07-22 Thread Prabhu Rajasekaran via cfe-commits
https://github.com/Prabhuk closed https://github.com/llvm/llvm-project/pull/150115 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Set correct CXXABI for UEFI (PR #150115)

2025-07-22 Thread Prabhu Rajasekaran via cfe-commits
https://github.com/Prabhuk edited https://github.com/llvm/llvm-project/pull/150115 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] uefi_cxx_abi (PR #150115)

2025-07-22 Thread Prabhu Rajasekaran via cfe-commits
Prabhuk wrote: > looks ok to me. Or do you think it would make more sense to put this check in > `isKnownWindowsMSVCEnvironment()`? Thanks Amy! We want to make decisions for UEFI environment without MSVC/windows assumptions. It was one of the motivations for introducing the UEFI target triple

[clang] [API Notes] Attach API notes to forward declarations of tags (PR #149951)

2025-07-22 Thread Henrik G. Olsson via cfe-commits
https://github.com/hnrklssn closed https://github.com/llvm/llvm-project/pull/149951 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] 8c26858 - [API Notes] Attach API notes to forward declarations of tags (#149951)

2025-07-22 Thread via cfe-commits
Author: Doug Gregor Date: 2025-07-22T17:49:13-07:00 New Revision: 8c26858f1a8bc5796c493f4f720552edbcb09fb4 URL: https://github.com/llvm/llvm-project/commit/8c26858f1a8bc5796c493f4f720552edbcb09fb4 DIFF: https://github.com/llvm/llvm-project/commit/8c26858f1a8bc5796c493f4f720552edbcb09fb4.diff L

[clang] [Clang] Add elementwise maximumnum/minimumnum builtin functions (PR #149775)

2025-07-22 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/27377 Here is the relevant piece of the build lo

[clang] [Clang] Fix new driver device only compilation for `amdgcnspirv` target (PR #150110)

2025-07-22 Thread Matt Arsenault via cfe-commits
@@ -4886,6 +4886,10 @@ Action *Driver::BuildOffloadingActions(Compilation &C, // individually. for (Action *&A : DeviceActions) { if ((A->getType() != types::TY_Object && + !(A->getOffloadingToolChain() && + A->getOffloadingToolChain()->getTr

[clang] [Sanitize] fix crash in -fsanitize-annotate-debug-info (PR #149237)

2025-07-22 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik commented: Next time can you add more details to the summary, these are especially helpful for downstream folks but also for reviewers. Something along the lines of "Perform a null check in SanitizerAnnotateDebugInfo for the result of getCurrentDebugLocation". https:

[clang] [clang][deps] Add a release note for fixing crashes in `clang-scan-deps`. (PR #149857)

2025-07-22 Thread Volodymyr Sapsai via cfe-commits
https://github.com/vsapsai closed https://github.com/llvm/llvm-project/pull/149857 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] dbc41dd - [clang][deps] Add a release note for fixing crashes in `clang-scan-deps`. (#149857)

2025-07-22 Thread via cfe-commits
Author: Volodymyr Sapsai Date: 2025-07-22T20:15:54-04:00 New Revision: dbc41dd5d827a3e13625a66fd2bfa83a8a4dfe83 URL: https://github.com/llvm/llvm-project/commit/dbc41dd5d827a3e13625a66fd2bfa83a8a4dfe83 DIFF: https://github.com/llvm/llvm-project/commit/dbc41dd5d827a3e13625a66fd2bfa83a8a4dfe83.di

[clang] One more fix for P3144R2 implementation (PR #149406)

2025-07-22 Thread Harald van Dijk via cfe-commits
@@ -595,6 +595,10 @@ struct GH99278_2 { } f; }; GH99278_2 e; +void GH99278_3(int(*p)[]) { + delete p; + // expected-warning@-1 {{'delete' applied to a pointer-to-array type 'int (*)[]' treated as 'delete[]'}} +}; hvdijk wrote: I've changed the array tests

[clang] One more fix for P3144R2 implementation (PR #149406)

2025-07-22 Thread Harald van Dijk via cfe-commits
https://github.com/hvdijk updated https://github.com/llvm/llvm-project/pull/149406 >From 94e652bc0bd6a04ef61a9f9b703257d464c7b714 Mon Sep 17 00:00:00 2001 From: Harald van Dijk Date: Thu, 17 Jul 2025 21:47:30 +0100 Subject: [PATCH 1/7] More fixes for P3144R2 implementation P3144R2 made it ill-

[clang] One more fix for P3144R2 implementation (PR #149406)

2025-07-22 Thread Harald van Dijk via cfe-commits
https://github.com/hvdijk updated https://github.com/llvm/llvm-project/pull/149406 >From 94e652bc0bd6a04ef61a9f9b703257d464c7b714 Mon Sep 17 00:00:00 2001 From: Harald van Dijk Date: Thu, 17 Jul 2025 21:47:30 +0100 Subject: [PATCH 1/6] More fixes for P3144R2 implementation P3144R2 made it ill-

[clang] [clang-repl] Improve error message on failed undos (PR #149396)

2025-07-22 Thread Aaron Danen via cfe-commits
https://github.com/aadanen updated https://github.com/llvm/llvm-project/pull/149396 >From f3fbebdd6d940d36561ccf5177510095ba05077e Mon Sep 17 00:00:00 2001 From: Aaron Danen Date: Wed, 16 Jul 2025 19:44:58 -0700 Subject: [PATCH 1/5] clarified %undo error msg in clang-repl used grep -r "Too man

[clang] [llvm] [RISCV] Support XSfmm C intrinsics (PR #143070)

2025-07-22 Thread Craig Topper via cfe-commits
@@ -679,6 +685,50 @@ bool SemaRISCV::CheckBuiltinFunctionCall(const TargetInfo &TI, return CheckVSetVL(1, 2); case RISCVVector::BI__builtin_rvv_vsetvlimax: return CheckVSetVL(0, 1); + case RISCVVector::BI__builtin_rvv_sf_vsettnt: + case RISCVVector::BI__builtin_rvv

[clang] [clang][deps] Add a release note for fixing crashes in `clang-scan-deps`. (PR #149857)

2025-07-22 Thread Volodymyr Sapsai via cfe-commits
https://github.com/vsapsai updated https://github.com/llvm/llvm-project/pull/149857 >From afb15bdb129365564591b17986f45e63542da24e Mon Sep 17 00:00:00 2001 From: Volodymyr Sapsai Date: Mon, 21 Jul 2025 13:31:56 -0400 Subject: [PATCH] [clang][deps] Add a release note for fixing crashes in `clan

[clang] One more fix for P3144R2 implementation (PR #149406)

2025-07-22 Thread Harald van Dijk via cfe-commits
@@ -595,6 +595,10 @@ struct GH99278_2 { } f; }; GH99278_2 e; +void GH99278_3(int(*p)[]) { + delete p; + // expected-warning@-1 {{'delete' applied to a pointer-to-array type 'int (*)[]' treated as 'delete[]'}} +}; hvdijk wrote: > The general issue here is

[clang] uefi_cxx_abi (PR #150115)

2025-07-22 Thread Amy Huang via cfe-commits
amykhuang wrote: looks ok to me. Or do you think it would make more sense to put this check in `isKnownWindowsMSVCEnvironment()`? https://github.com/llvm/llvm-project/pull/150115 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.l

[clang] [clang-repl] Improve error message on failed undos (PR #149396)

2025-07-22 Thread Aaron Danen via cfe-commits
aadanen wrote: @DavidSpickett I applied clang-format and I think everything is looking good. Do I need to do anything else? Or is squashing the commits and merging up to someone with write permissions? Also, thanks a lot for the help. I plan to find a new issue to work on soon. Thanks for off

[clang] [clang-repl] Improve error message on failed undos (PR #149396)

2025-07-22 Thread Aaron Danen via cfe-commits
https://github.com/aadanen updated https://github.com/llvm/llvm-project/pull/149396 >From f3fbebdd6d940d36561ccf5177510095ba05077e Mon Sep 17 00:00:00 2001 From: Aaron Danen Date: Wed, 16 Jul 2025 19:44:58 -0700 Subject: [PATCH 1/5] clarified %undo error msg in clang-repl used grep -r "Too man

[clang] [clang][analyzer] Delay checking the model-path (PR #150133)

2025-07-22 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 -- clang/test/Analysis/model-file-missing.cpp clang/lib

[clang] [Clang] Fix new driver device only compilation for `amdgcnspirv` target (PR #150110)

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

[clang] [clang] Fix const eval of constexpr-unknown relational comparisons. (PR #150088)

2025-07-22 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik edited https://github.com/llvm/llvm-project/pull/150088 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Fix const eval of constexpr-unknown relational comparisons. (PR #150088)

2025-07-22 Thread Shafik Yaghmour via cfe-commits
@@ -14631,8 +14631,9 @@ EvaluateComparisonBinaryOperator(EvalInfo &Info, const BinaryOperator *E, // - Otherwise pointer comparisons are unspecified. if (!LHSDesignator.Invalid && !RHSDesignator.Invalid && IsRelational) { bool WasArrayIndex; - unsigned Misma

[clang] [clang] Fix const eval of constexpr-unknown relational comparisons. (PR #150088)

2025-07-22 Thread Shafik Yaghmour via cfe-commits
https://github.com/shafik approved this pull request. LGTM https://github.com/llvm/llvm-project/pull/150088 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Fix Windows EH IP2State tables (remove +1 bias) (PR #144745)

2025-07-22 Thread via cfe-commits
dyung wrote: @sivadeilra the tests are still failing at least on my MacOS bot after the fix in 9a7a6b24f8c88718ef1eea57bed07332e751c027. Can you take a look? https://lab.llvm.org/buildbot/#/builders/190/builds/23988 ``` TEST 'Clang :: CodeGenCXX/microsoft-abi-eh-disabled.c

[clang] [LifetimeSafety] Make the dataflow analysis generic (PR #148222)

2025-07-22 Thread Dhruva Chakrabarti via cfe-commits
dhruvachak wrote: @usx95 Build of https://github.com/ROCm/composable_kernel is failing with the same crash. -Weverything is used there as well. Can you please fix the problem or revert? https://github.com/llvm/llvm-project/pull/148222 ___ cfe-commits

[clang] [clang] Rename files that MacOS libtool warns about (NFC) (PR #150054)

2025-07-22 Thread Farzon Lotfi via cfe-commits
farzonl wrote: This change will absolutely fix the issue, I was advised on my few attempts that we want to be able to keep the same name and the fix should be in cmake and not a file rename. For example We have many `AMDGPU.cpp` - clang/lib/Basic/Targets/AMDGPU.cpp - clang/lib/CodeGen/Targets/

[clang] [llvm] [NFC][Clang][FMV] Make FMV priority data type future proof. (PR #150079)

2025-07-22 Thread Jon Roelofs via cfe-commits
https://github.com/jroelofs approved this pull request. https://github.com/llvm/llvm-project/pull/150079 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] [WebAssembly] Add support for nonnull_extern_ref type (PR #148935)

2025-07-22 Thread Jasmine Tang via cfe-commits
badumbatish wrote: thanks Paulo, will rebase this for a precommit test for clearer demonstration https://github.com/llvm/llvm-project/pull/148935 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cf

[clang] [llvm] [NFC][Clang][FMV] Make FMV priority data type future proof. (PR #150079)

2025-07-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-backend-risc-v Author: Alexandros Lamprineas (labrinea) Changes FMV priority is the returned value of a polymorphic function. On RISC-V and X86 targets a 32-bit value is enough. On AArch64 we currently need 64 bits and we will soon exceed that. APInt s

[clang] [llvm] [NFC][Clang][FMV] Make FMV priority data type future proof. (PR #150079)

2025-07-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: Alexandros Lamprineas (labrinea) Changes FMV priority is the returned value of a polymorphic function. On RISC-V and X86 targets a 32-bit value is enough. On AArch64 we currently need 64 bits and we will soon exceed that. APInt seems to b

[clang] [llvm] [NFC][Clang][FMV] Make FMV priority data type future proof. (PR #150079)

2025-07-22 Thread Alexandros Lamprineas via cfe-commits
https://github.com/labrinea created https://github.com/llvm/llvm-project/pull/150079 FMV priority is the returned value of a polymorphic function. On RISC-V and X86 targets a 32-bit value is enough. On AArch64 we currently need 64 bits and we will soon exceed that. APInt seems to be a suitable

[clang] [clang] Add a CodeGen option to ignore compilation directories (PR #149897)

2025-07-22 Thread Adrian Prantl via cfe-commits
https://github.com/adrian-prantl approved this pull request. https://github.com/llvm/llvm-project/pull/149897 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Add support for array constructors (PR #149142)

2025-07-22 Thread Andy Kaylor via cfe-commits
@@ -311,6 +312,115 @@ void CIRGenFunction::emitInitializerForField(FieldDecl *field, LValue lhs, assert(!cir::MissingFeatures::requiresCleanups()); } +/// Emit a loop to call a particular constructor for each of several members +/// of an array. +/// +/// \param ctor the co

[clang] [CIR] Add support for array constructors (PR #149142)

2025-07-22 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor edited https://github.com/llvm/llvm-project/pull/149142 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Add support for array constructors (PR #149142)

2025-07-22 Thread Andy Kaylor via cfe-commits
@@ -22,15 +24,97 @@ struct LoweringPreparePass : public LoweringPrepareBase { void runOnOperation() override; void runOnOp(Operation *op); + void lowerArrayCtor(ArrayCtor op); }; } // namespace -void LoweringPreparePass::runOnOp(Operation *op) {} +void LoweringPrep

[clang] [CIR] Add support for array constructors (PR #149142)

2025-07-22 Thread Andy Kaylor via cfe-commits
@@ -0,0 +1,93 @@ +// RUN: %clang_cc1 -triple x86_64-unknown-linux-gnu -Wno-unused-value -fclangir -emit-cir -mmlir --mlir-print-ir-before=cir-lowering-prepare %s -o - 2>&1 | FileCheck --check-prefixes=CIR-BEFORE-LPP %s +// RUN: %clang_cc1 -triple x86_64-unknown-linux-gnu -Wno-u

[clang] [CIR] Add support for array constructors (PR #149142)

2025-07-22 Thread Andy Kaylor via cfe-commits
@@ -0,0 +1,93 @@ +// RUN: %clang_cc1 -triple x86_64-unknown-linux-gnu -Wno-unused-value -fclangir -emit-cir -mmlir --mlir-print-ir-before=cir-lowering-prepare %s -o - 2>&1 | FileCheck --check-prefixes=CIR-BEFORE-LPP %s +// RUN: %clang_cc1 -triple x86_64-unknown-linux-gnu -Wno-u

[clang] [CIR] Add support for array constructors (PR #149142)

2025-07-22 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor approved this pull request. lgtm, with one nit remaining and a couple of test requests https://github.com/llvm/llvm-project/pull/149142 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin

[clang] [llvm] [llvm] Add CalleeTypeIds field to CallSiteInfo (PR #87574)

2025-07-22 Thread Prabhu Rajasekaran via cfe-commits
https://github.com/Prabhuk edited https://github.com/llvm/llvm-project/pull/87574 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] Fix switches for non-windows platforms, regression fix for #144745 (PR #150067)

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

[clang] [LifetimeSafety] Add language option for experimental lifetime safety (PR #149592)

2025-07-22 Thread Paul Osmialowski via cfe-commits
https://github.com/pawosm-arm approved this pull request. I've tried this commit, it makes gromacs buildable again! https://github.com/llvm/llvm-project/pull/149592 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/

[clang] [llvm] Fixes to unblock building LLVM and Clang as Arm64EC (PR #150068)

2025-07-22 Thread Daniel Paoliello via cfe-commits
https://github.com/dpaoliello updated https://github.com/llvm/llvm-project/pull/150068 >From 3c087665701751fb4733060551b04542c419cb46 Mon Sep 17 00:00:00 2001 From: Daniel Paoliello Date: Tue, 22 Jul 2025 10:17:02 -0700 Subject: [PATCH] Fixes to unblock building LLVM and Clang as Arm64EC ---

[clang] 9a7a6b2 - [clang][test] Fix failed tests on non-Windows platforms

2025-07-22 Thread Michael Liao via cfe-commits
Author: Michael Liao Date: 2025-07-22T13:36:04-04:00 New Revision: 9a7a6b24f8c88718ef1eea57bed07332e751c027 URL: https://github.com/llvm/llvm-project/commit/9a7a6b24f8c88718ef1eea57bed07332e751c027 DIFF: https://github.com/llvm/llvm-project/commit/9a7a6b24f8c88718ef1eea57bed07332e751c027.diff

[clang] [-Wunsafe-buffer-usage] Support safe patterns of "%.*s" in printf functions (PR #145862)

2025-07-22 Thread Aviral Goel via cfe-commits
@@ -743,28 +808,81 @@ static bool hasUnsafeFormatOrSArg(const CallExpr *Call, const Expr *&UnsafeArg, const CallExpr *Call; unsigned FmtArgIdx; const Expr *&UnsafeArg; +ASTContext &Ctx; + +// Returns an `Expr` representing the precision if specified, null +

[clang] [llvm] Fixes to unblock building LLVM and Clang as Arm64EC (PR #150068)

2025-07-22 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 -- llvm/lib/TargetParser/Host.cpp llvm/tools/llvm-exeges

[clang] [clang] Add a CodeGen option to ignore compilation directories (PR #149897)

2025-07-22 Thread Steven Wu via cfe-commits
cachemeifyoucan wrote: > & then for now, in your use case, you'd be using the cc1 flag via -Xclang, > etc? Our explicit module build comes from dependency scanner, where it can generate the cc1 arguments we want to achieve empty compilation directory if needed. https://github.com/llvm/llvm-p

[clang] [llvm] Fixes to unblock building LLVM and Clang as Arm64EC (PR #150068)

2025-07-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-platform-windows Author: Daniel Paoliello (dpaoliello) Changes These changes allow LLVM and Clang to be built with Clang targeting Arm64EC using the MSVC linker. Built with these options: ``` -DLLVM_ENABLE_PROJECTS="clang" -DLLVM_HOST_TRIPLE=arm64ec-pc

[clang] [llvm] [clang][DebugInfo] Add symbol for debugger with VTable information. (PR #130255)

2025-07-22 Thread via cfe-commits
jeremyd2019 wrote: This change seems to be causing a regression for MinGW and Cygwin targets, see #149639 https://github.com/llvm/llvm-project/pull/130255 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/l

[clang] [llvm] Fixes to unblock building LLVM and Clang as Arm64EC (PR #150068)

2025-07-22 Thread Daniel Paoliello via cfe-commits
https://github.com/dpaoliello created https://github.com/llvm/llvm-project/pull/150068 These changes allow LLVM and Clang to be built with Clang targeting Arm64EC using the MSVC linker. Built with these options: ``` -DLLVM_ENABLE_PROJECTS="clang" -DLLVM_HOST_TRIPLE=arm64ec-pc-windows-msvc -DCM

[clang] [clang] Add a CodeGen option to ignore compilation directories (PR #149897)

2025-07-22 Thread David Blaikie via cfe-commits
dwblaikie wrote: > Here is idea to not to add a new option. I am going to remove the fallback in > CodeGen but make sure clang-driver does the fallback computation and clang > cc1 will always respect that decision from clang-driver. In that case, it is > a behavior change for cc1 flag, but not

[clang] [clang] Add a CodeGen option to ignore compilation directories (PR #149897)

2025-07-22 Thread Steven Wu via cfe-commits
cachemeifyoucan wrote: Here is idea to not to add a new option. I am going to remove the fallback in CodeGen but make sure clang-driver does the fallback computation and clang cc1 will always respect that decision from clang-driver. In that case, it is a behavior change for cc1 flag, but not f

[clang] [clang][deps] Remove dependency on `tooling::ToolAction` (PR #149904)

2025-07-22 Thread Jan Svoboda via cfe-commits
https://github.com/jansvoboda11 closed https://github.com/llvm/llvm-project/pull/149904 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] aa1b416 - [clang][deps] Remove dependency on `tooling::ToolAction` (#149904)

2025-07-22 Thread via cfe-commits
Author: Jan Svoboda Date: 2025-07-22T10:10:39-07:00 New Revision: aa1b416065ec615e93c496bbb43c7c006a04553e URL: https://github.com/llvm/llvm-project/commit/aa1b416065ec615e93c496bbb43c7c006a04553e DIFF: https://github.com/llvm/llvm-project/commit/aa1b416065ec615e93c496bbb43c7c006a04553e.diff L

[clang] Fix switches for non-windows platforms, regression fix for #144745 (PR #150067)

2025-07-22 Thread via cfe-commits
llvmbot wrote: @llvm/pr-subscribers-clang Author: None (sivadeilra) Changes Fix `-` vs `/` paths for non-Windows platforms for integration tests in #144745 --- Full diff: https://github.com/llvm/llvm-project/pull/150067.diff 2 Files Affected: - (modified) clang/test/CodeGenCXX/microso

[clang] Fix switches for non-windows platforms, regression fix for #144745 (PR #150067)

2025-07-22 Thread via cfe-commits
https://github.com/sivadeilra created https://github.com/llvm/llvm-project/pull/150067 Fix `-` vs `/` paths for non-Windows platforms for integration tests in #144745 >From ac5b66f4069649cba72aca55c37eb609fa8eff3a Mon Sep 17 00:00:00 2001 From: Arlie Davis Date: Tue, 22 Jul 2025 10:08:23 -070

[clang] [clang] Add a CodeGen option to ignore compilation directories (PR #149897)

2025-07-22 Thread Steven Wu via cfe-commits
cachemeifyoucan wrote: I am not planning to merge yet until debug info people approves the direction. Like you said, I considered `-fdebug-compilation-dir=` option but it is actually altering the behavior if I want to achieve empty compilation directory. The underlying implementation can be tw

[clang] [CIR] Add support for array constructors (PR #149142)

2025-07-22 Thread Morris Hafner via cfe-commits
https://github.com/mmha updated https://github.com/llvm/llvm-project/pull/149142 >From 9814dc290952184c3a1080ea49ddd29b603ecdae Mon Sep 17 00:00:00 2001 From: Morris Hafner Date: Wed, 16 Jul 2025 18:48:52 +0200 Subject: [PATCH 1/5] [CIR] Add support for array constructors This patch upstreams s

[clang-tools-extra] [clang-doc] refactor JSON for better Mustache compatibility (PR #149588)

2025-07-22 Thread Erick Velez via cfe-commits
https://github.com/evelez7 updated https://github.com/llvm/llvm-project/pull/149588 >From a2851dd55f354bcdcb2e7b83b73dd16d039a3eda Mon Sep 17 00:00:00 2001 From: Erick Velez Date: Fri, 18 Jul 2025 13:58:14 -0700 Subject: [PATCH] [clang-doc] refactor JSON for better Mustache compatibility ---

[clang] [llvm] Fix Windows EH IP2State tables (remove +1 bias) (PR #144745)

2025-07-22 Thread via cfe-commits
sivadeilra wrote: @jansvoboda11 Can you verify that this change: ``` // RUN: %clang_cl -c --target=x86_64-windows-msvc /EHs-c- -O2 /GS- \ // RUN: -Xclang=-import-call-optimization \ // RUN: /clang:-S /clang:-o- -- %s 2>&1 \ // RUN: | FileCheck %s ``` (inserting `--` before `%s`) fixes the

[clang] [llvm] Fix Windows EH IP2State tables (remove +1 bias) (PR #144745)

2025-07-22 Thread via cfe-commits
dyung wrote: > This is causing failures on my macOS machine that uses paths starting with > "/Users": These test failures also appeared on my macOS bot: https://lab.llvm.org/buildbot/#/builders/190/builds/23983 https://github.com/llvm/llvm-project/pull/144745 _

[clang] [clang] Add a CodeGen option to ignore compilation directories (PR #149897)

2025-07-22 Thread David Blaikie via cfe-commits
dwblaikie wrote: I think at least with Bazel we use `-fdebug-compilation-dir=/proc/cwd` to create build-path-agnostic builds. Is that something you folks can use, rather than adding this new option? Or is there some other way we could make `-fdebug-compilation-dir` address this? (like differen

[clang] [llvm] Fix Windows EH IP2State tables (remove +1 bias) (PR #144745)

2025-07-22 Thread via cfe-commits
sivadeilra wrote: Looking at this now, along with a test failure on AArch64. https://github.com/llvm/llvm-project/pull/144745 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Fix Windows EH IP2State tables (remove +1 bias) (PR #144745)

2025-07-22 Thread Jan Svoboda via cfe-commits
jansvoboda11 wrote: This is causing failures on my macOS machine that uses paths starting with "/Users": ``` FAIL: Clang :: CodeGenCXX/microsoft-abi-eh-disabled.cpp (21998 of 22004) TEST 'Clang :: CodeGenCXX/microsoft-abi-eh-disabled.cpp' FAILED Exit Co

[clang] fix-149477-- Emit correct closure members for lambdas in CreateLimitedType (PR #149674)

2025-07-22 Thread David Blaikie via cfe-commits
dwblaikie wrote: > According to my understanding, this issue happens because when a standard > library header like uses a function-local lambda, the compiler generates a > closure type for that lambda sometimes this closure type gets added to the > debug info without including its captured var

[clang] [CIR] Upstream Cast kinds for ComplexType (PR #149717)

2025-07-22 Thread Andy Kaylor via cfe-commits
https://github.com/andykaylor approved this pull request. lgtm if @xlauko is satisfied. https://github.com/llvm/llvm-project/pull/149717 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Fix Windows EH IP2State tables (remove +1 bias) (PR #144745)

2025-07-22 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `clang-armv8-quick` running on `linaro-clang-armv8-quick` while building `clang,llvm` at step 5 "ninja check 1". Full details are available at: https://lab.llvm.org/buildbot/#/builders/154/builds/19094 Here is the relevant p

[clang] [llvm] Fix Windows EH IP2State tables (remove +1 bias) (PR #144745)

2025-07-22 Thread via cfe-commits
sivadeilra wrote: Created issue #150057 for follow-up improvements. https://github.com/llvm/llvm-project/pull/144745 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [llvm] Fix Windows EH IP2State tables (remove +1 bias) (PR #144745)

2025-07-22 Thread LLVM Continuous Integration via cfe-commits
llvm-ci wrote: LLVM Buildbot has detected a new failure on builder `clang-aarch64-quick` running on `linaro-clang-aarch64-quick` while building `clang,llvm` at step 5 "ninja check 1". Full details are available at: https://lab.llvm.org/buildbot/#/builders/65/builds/19986 Here is the relevan

[clang] [clang][deps] Remove dependency on `tooling::ToolAction` (PR #149904)

2025-07-22 Thread Ben Langmuir via cfe-commits
@@ -710,17 +704,25 @@ static bool forEachDriverJob( static bool createAndRunToolInvocation( std::vector CommandLine, DependencyScanningAction &Action, -FileManager &FM, +IntrusiveRefCntPtr FS, std::shared_ptr &PCHContainerOps, DiagnosticsEngine &Diags, De

[clang] [clang][deps] Remove dependency on `tooling::ToolAction` (PR #149904)

2025-07-22 Thread Ben Langmuir via cfe-commits
https://github.com/benlangmuir approved this pull request. https://github.com/llvm/llvm-project/pull/149904 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [CIR] Upstream Cast kinds for ComplexType (PR #149717)

2025-07-22 Thread Amr Hesham via cfe-commits
@@ -0,0 +1,310 @@ +// RUN: %clang_cc1 -triple x86_64-unknown-linux-gnu -fclangir -emit-cir -mmlir --mlir-print-ir-before=cir-canonicalize -o %t.cir %s 2>&1 | FileCheck --check-prefix=CIR-BEFORE %s +// RUN: %clang_cc1 -triple x86_64-unknown-linux-gnu -fclangir -emit-cir -mmlir -

[clang] [CIR] Upstream Cast kinds for ComplexType (PR #149717)

2025-07-22 Thread Amr Hesham via cfe-commits
https://github.com/AmrDeveloper updated https://github.com/llvm/llvm-project/pull/149717 >From 8a3e3e87ef31fd347eb70f853a112af5d3c11630 Mon Sep 17 00:00:00 2001 From: AmrDeveloper Date: Sun, 20 Jul 2025 16:58:13 +0200 Subject: [PATCH 1/7] [CIR] Upstream Cast kinds for ComplexType --- clang/in

[clang] [KeyInstr] Inline asm atoms (PR #149076)

2025-07-22 Thread via cfe-commits
llvmbot wrote: /pull-request llvm/llvm-project#150056 https://github.com/llvm/llvm-project/pull/149076 ___ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

[clang] [clang] Rename files that MacOS libtool warns about (NFC) (PR #150054)

2025-07-22 Thread via cfe-commits
github-actions[bot] wrote: :warning: undef deprecator found issues in your code. :warning: You can test this locally with the following command: ``bash git diff -U0 --pickaxe-regex -S '([^a-zA-Z0-9#_-]undef[^a-zA-Z0-9_-]|UndefValue::get)' 'HEAD~1' HEAD clang/lib/CodeGen/TargetBu

  1   2   3   4   >