mirror of
https://github.com/ROCm/composable_kernel.git
synced 2026-05-12 09:16:52 +00:00
* Squashed 'src/composable_kernel/' content from commitf6edda611git-subtree-dir: src/composable_kernel git-subtree-split:f6edda6119* add solver ConvIgemmFwdV6r1DlopsNchwKcyxNkhw; rename static ck source files * Squashed 'src/composable_kernel/' changes from f6edda611..5781adf5c5781adf5cUpdate develop (#5) (#6)97e6d514fMerge pull request #4 from ROCmSoftwarePlatform/separate_online_compile7b1ec41e5refactor49c33aaearefactor54b3e73d1rename git-subtree-dir: src/composable_kernel git-subtree-split:5781adf5cf* fix * refactor * remove online compilation from CK * refactor * fix * add ctest * add c-style pointer cast * vector/scalar pointer cast use c-style pointer cast instead of reinterpret_cast * fix clang warning suppression * tidy * suppress cppcheck * fix enum issue * revert chagnes to hip build * fix kernel filename * update CK build script * rename * rename * make innner product compatiable on gfx900 * Update src/include/miopen/solver/ck_utility_common.hpp Co-authored-by: JD <Jehandad.Khan@amd.com> * compiler parameter use stream * use int instead of index_t in kernel wrapper * DynamicBuffer, StaticBuffer, amd_buffer_load support customized value for invalid element * refactor * refactor * change cmakelist * change ck common utility * fix Co-authored-by: JD <Jehandad.Khan@amd.com>
82 lines
2.3 KiB
C++
82 lines
2.3 KiB
C++
#ifndef CONVOLUTION_PROBLEM_DESCRIPTOR
|
|
#define CONVOLUTION_PROBLEM_DESCRIPTOR
|
|
|
|
namespace ck {
|
|
namespace driver {
|
|
|
|
struct ConvolutionProblemDescriptor
|
|
{
|
|
ConvolutionProblemDescriptor() = default;
|
|
|
|
ConvolutionProblemDescriptor(int N_,
|
|
int K_,
|
|
int C_,
|
|
int Y_,
|
|
int X_,
|
|
int Hi_,
|
|
int Wi_,
|
|
int Ho_,
|
|
int Wo_,
|
|
int ConvStrideH_,
|
|
int ConvStrideW_,
|
|
int ConvDilationH_,
|
|
int ConvDilationW_,
|
|
int InLeftPadH_,
|
|
int InLeftPadW_,
|
|
int InRightPadH_,
|
|
int InRightPadW_,
|
|
ck::DataTypeEnum_t InDataTypeEnum_,
|
|
ck::DataTypeEnum_t WeiDataTypeEnum_,
|
|
ck::DataTypeEnum_t OutDataTypeEnum_)
|
|
: N{N_},
|
|
K{K_},
|
|
C{C_},
|
|
Y{Y_},
|
|
X{X_},
|
|
Hi{Hi_},
|
|
Wi{Wi_},
|
|
Ho{Ho_},
|
|
Wo{Wo_},
|
|
ConvStrideH{ConvStrideH_},
|
|
ConvStrideW{ConvStrideW_},
|
|
ConvDilationH{ConvDilationH_},
|
|
ConvDilationW{ConvDilationW_},
|
|
InLeftPadH{InLeftPadH_},
|
|
InLeftPadW{InLeftPadW_},
|
|
InRightPadH{InRightPadH_},
|
|
InRightPadW{InRightPadW_},
|
|
InDataTypeEnum{InDataTypeEnum_},
|
|
WeiDataTypeEnum{WeiDataTypeEnum_},
|
|
OutDataTypeEnum{OutDataTypeEnum_}
|
|
{
|
|
}
|
|
|
|
int N;
|
|
int K;
|
|
int C;
|
|
int Y;
|
|
int X;
|
|
int Hi;
|
|
int Wi;
|
|
int Ho;
|
|
int Wo;
|
|
int ConvStrideH;
|
|
int ConvStrideW;
|
|
int ConvDilationH;
|
|
int ConvDilationW;
|
|
int InLeftPadH;
|
|
int InLeftPadW;
|
|
int InRightPadH;
|
|
int InRightPadW;
|
|
|
|
ck::DataTypeEnum_t InDataTypeEnum;
|
|
ck::DataTypeEnum_t WeiDataTypeEnum;
|
|
ck::DataTypeEnum_t OutDataTypeEnum;
|
|
|
|
std::size_t CalculateFlop() const { return 2L * N * K * C * Y * X * Ho * Wo; }
|
|
};
|
|
|
|
} // namespace driver
|
|
} // namespace ck
|
|
#endif
|