mirror of
https://github.com/ROCm/composable_kernel.git
synced 2026-05-01 20:21:23 +00:00
* solve compiler issue * solve the gfx950 mfma shuffle regression * refactor jenkinsfile to handle arch name better * [CK TILE] set divisor to count of thread along k dimension * fix the compiler error * solve degradation * Finish the multiplies fix * fix the scales * solve compilation error * solve the composes * solve the error of tile sweeper * fix the test and example * fix for gfx950 --------- Co-authored-by: Max Podkorytov <4273004+tenpercent@users.noreply.github.com> Co-authored-by: illsilin_amdeng <Illia.Silin@amd.com> Co-authored-by: Cong Ma <congma13@amd.com>
31 lines
977 B
C++
31 lines
977 B
C++
// Copyright (c) Advanced Micro Devices, Inc., or its affiliates.
|
|
// SPDX-License-Identifier: MIT
|
|
|
|
#pragma once
|
|
|
|
#include "ck_tile/core/utility/type_traits.hpp"
|
|
|
|
namespace ck_tile {
|
|
|
|
template <typename BlockWarps, typename BlockTile, typename WarpTile, typename ComputeDataType>
|
|
struct ElementWiseShape
|
|
{
|
|
static constexpr index_t kBlockM = BlockTile::at(number<0>{});
|
|
|
|
static constexpr index_t kWarpM = WarpTile::at(number<0>{});
|
|
|
|
static constexpr index_t kVectorM =
|
|
min(static_cast<index_t>(16 / sizeof(ComputeDataType)), kWarpM / get_warp_size());
|
|
|
|
static constexpr index_t kWarpPerBlockM = BlockWarps::at(number<0>{});
|
|
|
|
static constexpr index_t kThreadPerWarpM = get_warp_size();
|
|
|
|
static constexpr index_t kRepeatM = kBlockM / (kWarpPerBlockM * kVectorM * kThreadPerWarpM);
|
|
|
|
static constexpr index_t kBlockSize =
|
|
ck_tile::get_warp_size() * reduce_on_sequence(BlockWarps{}, multiplies<>{}, number<1>{});
|
|
};
|
|
|
|
} // namespace ck_tile
|