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
efd41464
Commit
efd41464
authored
Jan 10, 2024
by
Jakub Piasecki
Browse files
fix
parent
c7913947
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
43 additions
and
4 deletions
+43
-4
library/include/ck/library/tensor_operation_instance/gpu/gemm.hpp
...include/ck/library/tensor_operation_instance/gpu/gemm.hpp
+4
-3
library/src/tensor_operation_instance/gpu/gemm/device_gemm_xdl_c_shuffle_f16_int8_f16_mk_nk_mn_instance.cpp
...ice_gemm_xdl_c_shuffle_f16_int8_f16_mk_nk_mn_instance.cpp
+1
-1
test/gemm/CMakeLists.txt
test/gemm/CMakeLists.txt
+4
-0
test/gemm/gemm_fp16_int8.cpp
test/gemm/gemm_fp16_int8.cpp
+34
-0
No files found.
library/include/ck/library/tensor_operation_instance/gpu/gemm.hpp
View file @
efd41464
// SPDX-License-Identifier: MIT
// Copyright (c) 2018-202
3
, Advanced Micro Devices, Inc. All rights reserved.
// Copyright (c) 2018-202
4
, Advanced Micro Devices, Inc. All rights reserved.
#pragma once
...
...
@@ -375,7 +375,7 @@ void add_device_gemm_xdl_c_shuffle_f16_int8_f16_mk_kn_mn_instances(
void
add_device_gemm_xdl_c_shuffle_f16_int8_f16_mk_nk_mn_instances
(
std
::
vector
<
std
::
unique_ptr
<
DeviceGemm
<
Row
,
Row
,
Row
,
F16
,
I8
,
F16
,
PassThrough
,
PassThrough
,
PassThrough
>>>&
DeviceGemm
<
Row
,
Col
,
Row
,
F16
,
I8
,
F16
,
PassThrough
,
PassThrough
,
PassThrough
>>>&
instances
);
#endif
...
...
@@ -638,6 +638,7 @@ struct DeviceOperationInstanceFactory<
{
add_device_gemm_xdl_c_shuffle_f16_int8_f16_mk_nk_mn_instances
(
op_ptrs
);
}
}
#endif
return
op_ptrs
;
}
...
...
library/src/tensor_operation_instance/gpu/gemm/device_gemm_xdl_c_shuffle_f16_int8_f16_mk_nk_mn_instance.cpp
View file @
efd41464
...
...
@@ -16,7 +16,7 @@ namespace tensor_operation {
namespace
device
{
namespace
instance
{
using
I8
=
int8_t
using
I8
=
int8_t
;
using
F16
=
ck
::
half_t
;
using
F32
=
float
;
...
...
test/gemm/CMakeLists.txt
View file @
efd41464
...
...
@@ -26,3 +26,7 @@ add_test_executable(test_gemm_int8 gemm_int8.cpp)
if
(
result EQUAL 0
)
target_link_libraries
(
test_gemm_int8 PRIVATE utility device_gemm_instance
)
endif
()
add_test_executable
(
test_gemm_fp16_int8 gemm_fp16_int8.cpp
)
if
(
result EQUAL 0
)
target_link_libraries
(
test_gemm_fp16_int8 PRIVATE utility device_gemm_instance
)
endif
()
\ No newline at end of file
test/gemm/gemm_fp16_int8.cpp
0 → 100644
View file @
efd41464
// SPDX-License-Identifier: MIT
// Copyright (c) 2024, Advanced Micro Devices, Inc. All rights reserved.
#include <algorithm>
#include <cstdlib>
#include <iostream>
#include <numeric>
#include <tuple>
#include <vector>
#include "ck/ck.hpp"
#include "ck/tensor_operation/gpu/device/tensor_layout.hpp"
#include "ck/tensor_operation/gpu/device/gemm_specialization.hpp"
#include "ck/tensor_operation/gpu/device/device_gemm.hpp"
#include "ck/tensor_operation/gpu/element/element_wise_operation.hpp"
#include "ck/library/tensor_operation_instance/gpu/gemm.hpp"
#include "ck/library/utility/check_err.hpp"
#include "ck/library/utility/device_memory.hpp"
#include "ck/library/utility/host_tensor.hpp"
#include "ck/library/utility/host_tensor_generator.hpp"
#include "ck/library/reference_tensor_operation/cpu/reference_gemm.hpp"
#include "test/gemm/gemm_util.hpp"
using
ADataType
=
ck
::
half_t
;
using
BDataType
=
int8_t
;
using
CDataType
=
ck
::
half_t
;
using
AccDataType
=
float
;
#include "run_gemm_test.inc"
int
main
()
{
return
run_gemm_test
();
}
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