mirror of
https://github.com/ROCm/composable_kernel.git
synced 2026-07-01 04:07:56 +00:00
We have a typed test suite of all the instance we want to create, and also we have simple test of the builder. Split those into two different test suites.
36 lines
1.0 KiB
C++
36 lines
1.0 KiB
C++
#include <gtest/gtest.h>
|
|
|
|
#include <ck_tile/builder/conv_builder.hpp>
|
|
|
|
namespace {
|
|
|
|
namespace ckb = ck_tile::builder;
|
|
|
|
struct FwdConvSignature
|
|
{
|
|
static constexpr int SPATIAL_DIM = 2;
|
|
static constexpr auto DIRECTION = ckb::ConvDirection::Forward;
|
|
static constexpr auto LAYOUT = ckb::GroupConvLayout::NHWGC_GKYXC_NHWGK;
|
|
static constexpr auto DATA_TYPE = ckb::DataType::FP16;
|
|
};
|
|
static_assert(ckb::ConvSignature<FwdConvSignature>);
|
|
|
|
struct DefaultFwdConvAlgorithm
|
|
{
|
|
};
|
|
static_assert(ckb::ConvAlgorithm<DefaultFwdConvAlgorithm>);
|
|
|
|
static constexpr char API_VERSION[] = "0.1.0";
|
|
|
|
TEST(ConvBuilderTest, TestDefaultInstance)
|
|
{
|
|
static constexpr DefaultFwdConvAlgorithm algorithm;
|
|
using Builder = ckb::ConvBuilder<FwdConvSignature, algorithm, API_VERSION>;
|
|
EXPECT_EQ(
|
|
Builder::Instance::TypeString(),
|
|
"DeviceGroupedConvFwdMultipleABD_Xdl_CShuffle_V3<256, 256, 256, 32, Default, 32, 32, 4, 4, "
|
|
"8, 8, 8, 1, 1, BlkGemmPipelineScheduler: Intrawave, BlkGemmPipelineVersion: v4>");
|
|
}
|
|
|
|
} // namespace
|