From 8e15d99ddc77f8c2f7cd52c9ed080497fe610409 Mon Sep 17 00:00:00 2001 From: carlushuang Date: Mon, 7 Jul 2025 14:54:34 +0800 Subject: [PATCH] default skip y point to r (#2457) Co-authored-by: Thomas Ning [ROCm/composable_kernel commit: 0aecb5ab68a468f780bd16aea0471f59b11d4972] --- include/ck_tile/core/config.hpp | 6 ++++++ include/ck_tile/core/tensor/tile_distribution_encoding.hpp | 5 +++++ 2 files changed, 11 insertions(+) diff --git a/include/ck_tile/core/config.hpp b/include/ck_tile/core/config.hpp index 1ecc28fbeb..3a1ddd8abd 100644 --- a/include/ck_tile/core/config.hpp +++ b/include/ck_tile/core/config.hpp @@ -263,3 +263,9 @@ #ifndef CK_TILE_WA_ISSUE_2028 #define CK_TILE_WA_ISSUE_2028 0 #endif + +// Y pointed to R, we don't see a valuable use case. +// Will enforce encoding to check Y not pointed to R if set to zero +#ifndef CK_TILE_ENC_SUPPORT_Y_TO_R +#define CK_TILE_ENC_SUPPORT_Y_TO_R 0 +#endif diff --git a/include/ck_tile/core/tensor/tile_distribution_encoding.hpp b/include/ck_tile/core/tensor/tile_distribution_encoding.hpp index 30cd698595..52a16f32bd 100644 --- a/include/ck_tile/core/tensor/tile_distribution_encoding.hpp +++ b/include/ck_tile/core/tensor/tile_distribution_encoding.hpp @@ -47,6 +47,11 @@ struct tile_distribution_encoding static constexpr auto ys_to_rhs_major_ = Ys2RHsMajor{}; static constexpr auto ys_to_rhs_minor_ = Ys2RHsMinor{}; +#if !CK_TILE_ENC_SUPPORT_Y_TO_R + static_assert(container_find(ys_to_rhs_major_, 0) == NDimY, + "do not support Y dim pointed to R dim"); +#endif + // redundant but useful info // TODO: really bad code, should be over-hauled struct detail