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
Commits
24faa1fc
Commit
24faa1fc
authored
Oct 28, 2022
by
aska-0096
Browse files
Add f32_16x16x16_bf16 unit test
parent
790e21ec
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
17 additions
and
1 deletion
+17
-1
test/wmma_op/wmma_op.cpp
test/wmma_op/wmma_op.cpp
+5
-1
test/wmma_op/wmma_op_util.hpp
test/wmma_op/wmma_op_util.hpp
+12
-0
No files found.
test/wmma_op/wmma_op.cpp
View file @
24faa1fc
...
@@ -55,10 +55,14 @@ int main(int, char*[])
...
@@ -55,10 +55,14 @@ int main(int, char*[])
bool
pass
=
true
;
bool
pass
=
true
;
// clang-format off
// clang-format off
// |SrcType |DstType |GPUAccType |CPUAccType |AccNum
// |SrcType |DstType |GPUAccType |CPUAccType |AccNum
pass
&=
run_test
<
ck
::
half_t
,
float
,
float
,
float
,
8
>
();
pass
&=
run_test
<
ck
::
half_t
,
ck
::
half_t
,
float
,
float
,
8
>
();
pass
&=
run_test
<
ck
::
bhalf_t
,
ck
::
bhalf_t
,
float
,
float
,
8
>
();
pass
&=
run_test
<
ck
::
half_t
,
ck
::
half_t
,
ck
::
half_t
,
ck
::
half_t
,
16
>
();
pass
&=
run_test
<
ck
::
half_t
,
ck
::
half_t
,
ck
::
half_t
,
ck
::
half_t
,
16
>
();
pass
&=
run_test
<
ck
::
bhalf_t
,
ck
::
bhalf_t
,
ck
::
bhalf_t
,
float
,
16
>
();
pass
&=
run_test
<
ck
::
bhalf_t
,
ck
::
bhalf_t
,
ck
::
bhalf_t
,
float
,
16
>
();
pass
&=
run_test
<
int8_t
,
int8_t
,
int32_t
,
int32_t
,
8
>
();
pass
&=
run_test
<
int8_t
,
int8_t
,
int32_t
,
int32_t
,
8
>
();
#ifdef CK_EXPERIMENTAL_BIT_INT_EXTENSION_INT4
pass
&=
run_test
<
int4_t
,
int4_t
,
int32_t
,
int32_t
,
8
>
();
#endif
// clang-format on
// clang-format on
std
::
cout
<<
"TestGemm ..... "
<<
(
pass
?
"SUCCESS"
:
"FAILURE"
)
<<
std
::
endl
;
std
::
cout
<<
"TestGemm ..... "
<<
(
pass
?
"SUCCESS"
:
"FAILURE"
)
<<
std
::
endl
;
...
...
test/wmma_op/wmma_op_util.hpp
View file @
24faa1fc
...
@@ -32,6 +32,18 @@ builtin_wmma_naive_selector<half16_t,
...
@@ -32,6 +32,18 @@ builtin_wmma_naive_selector<half16_t,
reg_a
,
reg_b
,
reg_c
.
GetVectorTypeReference
(
Number
<
0
>
{}));
reg_a
,
reg_b
,
reg_c
.
GetVectorTypeReference
(
Number
<
0
>
{}));
}
}
template
<
>
__device__
void
builtin_wmma_naive_selector
<
bhalf16_t
,
StaticBufferTupleOfVector
<
AddressSpaceEnum
::
Vgpr
,
float
,
1
,
8
,
true
>>
(
const
bhalf16_t
&
reg_a
,
const
bhalf16_t
&
reg_b
,
StaticBufferTupleOfVector
<
AddressSpaceEnum
::
Vgpr
,
float
,
1
,
8
,
true
>&
reg_c
)
{
intrin_wmma_f32_16x16x16_bf16_w32
<
16
,
16
>::
Run
(
reg_a
,
reg_b
,
reg_c
.
GetVectorTypeReference
(
Number
<
0
>
{}));
}
template
<
>
template
<
>
__device__
void
__device__
void
builtin_wmma_naive_selector
<
half16_t
,
builtin_wmma_naive_selector
<
half16_t
,
...
...
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