Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
gaoqiong
composable_kernel_ROCM
Commits
e5c55c19
Commit
e5c55c19
authored
Oct 08, 2024
by
Mirza Halilcevic
Browse files
Minor refactor.
parent
23dd6a1f
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
7 additions
and
10 deletions
+7
-10
CMakeLists.txt
CMakeLists.txt
+1
-1
codegen/CMakeLists.txt
codegen/CMakeLists.txt
+2
-3
codegen/include/ck/host/device_batched_gemm_softmax_gemm/operation.hpp
...de/ck/host/device_batched_gemm_softmax_gemm/operation.hpp
+2
-0
codegen/src/device_batched_gemm_softmax_gemm_operation_xdl_cshuffle.cpp
...vice_batched_gemm_softmax_gemm_operation_xdl_cshuffle.cpp
+2
-6
No files found.
CMakeLists.txt
View file @
e5c55c19
...
@@ -654,4 +654,4 @@ rocm_create_package(
...
@@ -654,4 +654,4 @@ rocm_create_package(
MAINTAINER
"MIOpen Kernels Dev Team <dl.MIOpen@amd.com>"
MAINTAINER
"MIOpen Kernels Dev Team <dl.MIOpen@amd.com>"
LDCONFIG
LDCONFIG
HEADER_ONLY
HEADER_ONLY
)
)
\ No newline at end of file
codegen/CMakeLists.txt
View file @
e5c55c19
...
@@ -21,14 +21,14 @@ list(APPEND CMAKE_MODULE_PATH ${CK_ROOT}/cmake)
...
@@ -21,14 +21,14 @@ list(APPEND CMAKE_MODULE_PATH ${CK_ROOT}/cmake)
include
(
Embed
)
include
(
Embed
)
file
(
GLOB_RECURSE KERNEL_FILES CONFIGURE_DEPENDS
file
(
GLOB_RECURSE KERNEL_FILES CONFIGURE_DEPENDS
${
CK_ROOT
}
/include/ck/*.hpp
)
${
CK_ROOT
}
/include/ck/*.hpp
)
#printouts fo
t
debug purposes
#
printouts fo
r
debug purposes
#message(STATUS "KERNEL_FILES: ${KERNEL_FILES}")
#message(STATUS "KERNEL_FILES: ${KERNEL_FILES}")
#message(STATUS "RELATIVE: ${CK_ROOT}/include")
#message(STATUS "RELATIVE: ${CK_ROOT}/include")
add_embed_library
(
ck_headers
${
KERNEL_FILES
}
RELATIVE
${
CK_ROOT
}
/include
)
add_embed_library
(
ck_headers
${
KERNEL_FILES
}
RELATIVE
${
CK_ROOT
}
/include
)
file
(
GLOB SOURCES CONFIGURE_DEPENDS src/*.cpp
)
file
(
GLOB SOURCES CONFIGURE_DEPENDS src/*.cpp
)
#
#message(STATUS "SOURCE_FILES: ${SOURCES}")
#message(STATUS "SOURCE_FILES: ${SOURCES}")
# TODO: Use object library
# TODO: Use object library
add_library
(
ck_host STATIC
${
SOURCES
}
)
add_library
(
ck_host STATIC
${
SOURCES
}
)
add_library
(
composable_kernel::ck_host ALIAS ck_host
)
add_library
(
composable_kernel::ck_host ALIAS ck_host
)
...
@@ -39,7 +39,6 @@ set_target_properties(ck_host PROPERTIES
...
@@ -39,7 +39,6 @@ set_target_properties(ck_host PROPERTIES
target_include_directories
(
ck_host SYSTEM PRIVATE
target_include_directories
(
ck_host SYSTEM PRIVATE
$<BUILD_INTERFACE:
${
CMAKE_CURRENT_SOURCE_DIR
}
/include>
$<BUILD_INTERFACE:
${
CMAKE_CURRENT_SOURCE_DIR
}
/include>
# $<BUILD_INTERFACE:${PROJECT_SOURCE_DIR}/library/src/jit_library/solution_instances>
$<BUILD_INTERFACE:
${
CMAKE_CURRENT_BINARY_DIR
}
/solution_instances>
$<BUILD_INTERFACE:
${
CMAKE_CURRENT_BINARY_DIR
}
/solution_instances>
$<BUILD_INTERFACE:
${
CMAKE_CURRENT_BINARY_DIR
}
/embed/ck_headers/include>
$<BUILD_INTERFACE:
${
CMAKE_CURRENT_BINARY_DIR
}
/embed/ck_headers/include>
)
)
...
...
codegen/include/ck/host/device_batched_gemm_softmax_gemm/operation.hpp
View file @
e5c55c19
...
@@ -27,6 +27,8 @@ struct Operation_Xdl_CShuffle
...
@@ -27,6 +27,8 @@ struct Operation_Xdl_CShuffle
TensorDesc
B
{};
TensorDesc
B
{};
TensorDesc
B1
{};
TensorDesc
B1
{};
TensorDesc
C
{};
TensorDesc
C
{};
DataType
acc
=
DataType
::
Float
;
DataType
cs_type
=
DataType
::
Half
;
std
::
string
a_elem_op
=
PassThrough
;
std
::
string
a_elem_op
=
PassThrough
;
std
::
string
b_elem_op
=
PassThrough
;
std
::
string
b_elem_op
=
PassThrough
;
std
::
string
b1_elem_op
=
PassThrough
;
std
::
string
b1_elem_op
=
PassThrough
;
...
...
codegen/src/device_batched_gemm_softmax_gemm_operation_xdl_cshuffle.cpp
View file @
e5c55c19
...
@@ -41,8 +41,6 @@ void Operation_Xdl_CShuffle::update_prologue(const std::string& pro)
...
@@ -41,8 +41,6 @@ void Operation_Xdl_CShuffle::update_prologue(const std::string& pro)
if
(
!
prologue
.
empty
())
if
(
!
prologue
.
empty
())
{
{
this
->
prologue
=
pro
;
this
->
prologue
=
pro
;
// TODO
// this->cde_elem_op = "CDEElementOp";
}
}
else
else
{
{
...
@@ -55,8 +53,6 @@ void Operation_Xdl_CShuffle::update_epilogue(const std::string& epi)
...
@@ -55,8 +53,6 @@ void Operation_Xdl_CShuffle::update_epilogue(const std::string& epi)
if
(
!
epilogue
.
empty
())
if
(
!
epilogue
.
empty
())
{
{
this
->
epilogue
=
epi
;
this
->
epilogue
=
epi
;
// TODO
// this->cde_elem_op = "CDEElementOp";
}
}
else
else
{
{
...
@@ -336,8 +332,8 @@ Solution Operation_Xdl_CShuffle::ToSolution() const
...
@@ -336,8 +332,8 @@ Solution Operation_Xdl_CShuffle::ToSolution() const
{
"B0DataType"
,
ToString
(
this
->
B
.
element
)},
{
"B0DataType"
,
ToString
(
this
->
B
.
element
)},
{
"B1DataType"
,
ToString
(
this
->
B1
.
element
)},
{
"B1DataType"
,
ToString
(
this
->
B1
.
element
)},
{
"CDataType"
,
ToString
(
this
->
C
.
element
)},
{
"CDataType"
,
ToString
(
this
->
C
.
element
)},
{
"AccDataType"
,
ToString
(
DataType
::
Float
)},
{
"AccDataType"
,
ToString
(
this
->
acc
)},
{
"CShuffleDataType"
,
ToString
(
DataType
::
Half
)},
{
"CShuffleDataType"
,
ToString
(
this
->
cs_type
)},
{
"AElementwiseOperation"
,
this
->
a_elem_op
},
{
"AElementwiseOperation"
,
this
->
a_elem_op
},
{
"B0ElementwiseOperation"
,
this
->
b_elem_op
},
{
"B0ElementwiseOperation"
,
this
->
b_elem_op
},
{
"Acc0ElementwiseOperation"
,
this
->
acc_elem_op
},
{
"Acc0ElementwiseOperation"
,
this
->
acc_elem_op
},
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment