From b14f34e97c6996c28efd336cc35e551332c7b221 Mon Sep 17 00:00:00 2001 From: Jan Patrick Lehr Date: Thu, 12 Feb 2026 23:11:53 +0100 Subject: [PATCH] [CK] Work around staging compiler lifetime warning (#4419) ## Motivation The staging compiler enables lifetime-safety warnings and we already worked around a few of them. This works around a few more instances that came up recently on gfx950 builds. The initial PR that resolved most issues: https://github.com/ROCm/composable_kernel/pull/3640 ## Technical Details This follows the pattern to locally ignore the newly added lifetime-safety warnings that were moved from experimental to production in upstream LLVM. As a result, CK turned them on and treats them as errors, which prevents the staging compiler from building CK. ## Test Plan ## Test Result ## Submission Checklist - [ ] Look over the contributing guidelines at https://github.com/ROCm/ROCm/blob/develop/CONTRIBUTING.md#pull-requests. Co-authored-by: Illia Silin <98187287+illsilin@users.noreply.github.com> --- include/ck/utility/functional2.hpp | 4 ++++ ..._wmma_multi_abd_gelu_bf16_i8_bf16_mk_kn_mn_v1_instance.cpp | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/include/ck/utility/functional2.hpp b/include/ck/utility/functional2.hpp index 888fedc0a9..c047e6181f 100644 --- a/include/ck/utility/functional2.hpp +++ b/include/ck/utility/functional2.hpp @@ -8,6 +8,9 @@ #include "ck/utility/tuple.hpp" #include "ck/utility/type.hpp" +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wlifetime-safety-intra-tu-suggestions" + namespace ck { namespace detail { @@ -113,3 +116,4 @@ struct identity }; } // namespace ck +#pragma clang diagnostic pop diff --git a/library/src/tensor_operation_instance/gpu/gemm_multi_abd/device_gemm_wmma_multi_abd_gelu_bf16_i8_bf16_mk_kn_mn_v1_instance.cpp b/library/src/tensor_operation_instance/gpu/gemm_multi_abd/device_gemm_wmma_multi_abd_gelu_bf16_i8_bf16_mk_kn_mn_v1_instance.cpp index 9176910cea..1bc05c16d4 100644 --- a/library/src/tensor_operation_instance/gpu/gemm_multi_abd/device_gemm_wmma_multi_abd_gelu_bf16_i8_bf16_mk_kn_mn_v1_instance.cpp +++ b/library/src/tensor_operation_instance/gpu/gemm_multi_abd/device_gemm_wmma_multi_abd_gelu_bf16_i8_bf16_mk_kn_mn_v1_instance.cpp @@ -12,6 +12,9 @@ #include "ck/library/tensor_operation_instance/add_device_operation_instance.hpp" +#pragma clang diagnostic push +#pragma clang diagnostic ignored "-Wlifetime-safety-intra-tu-suggestions" + namespace ck { namespace tensor_operation { namespace device { @@ -57,3 +60,4 @@ void add_device_gemm_wmma_multi_abd_bf16_i8_bf16_mk_kn_mn_gelu_v1_instances( } // namespace device } // namespace tensor_operation } // namespace ck +#pragma clang diagnostic pop