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
yangql
composable_kernel-1
Commits
9de63930
Commit
9de63930
authored
Jun 18, 2019
by
Chao Liu
Browse files
refactor
parent
23f633cd
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
10 additions
and
3 deletions
+10
-3
composable_kernel/include/kernel_algorithm/gridwise_convolution_implicit_gemm_v4_nchw_kcyx_nkhw_lds_double_buffer.hpp
...ion_implicit_gemm_v4_nchw_kcyx_nkhw_lds_double_buffer.hpp
+2
-3
composable_kernel/include/utility/utility.hpp
composable_kernel/include/utility/utility.hpp
+8
-0
No files found.
composable_kernel/include/kernel_algorithm/gridwise_convolution_implicit_gemm_v4_nchw_kcyx_nkhw_lds_double_buffer.hpp
View file @
9de63930
...
@@ -237,11 +237,10 @@ struct GridwiseConvolutionImplicitGemm_v4_nchw_kcyx_nkhw_lds_double_buffer
...
@@ -237,11 +237,10 @@ struct GridwiseConvolutionImplicitGemm_v4_nchw_kcyx_nkhw_lds_double_buffer
GemmDataPerReadB
);
GemmDataPerReadB
);
constexpr
index_t
in_block_space
=
constexpr
index_t
in_block_space
=
math
::
integer_divide_ceil
(
in_e_n1_b_n2_block_desc
.
GetElementSpace
(),
max_align
)
*
math
::
integer_least_multiple
(
in_e_n1_b_n2_block_desc
.
GetElementSpace
(),
max_align
);
max_align
;
constexpr
index_t
wei_block_space
=
constexpr
index_t
wei_block_space
=
math
::
integer_
divide_ceil
(
wei_e_k_block_desc
.
GetElementSpace
(),
max_align
)
*
max_align
;
math
::
integer_
least_multiple
(
wei_e_k_block_desc
.
GetElementSpace
(),
max_align
);
__shared__
Float
p_in_block_double
[
2
*
in_block_space
];
__shared__
Float
p_in_block_double
[
2
*
in_block_space
];
__shared__
Float
p_wei_block_double
[
2
*
wei_block_space
];
__shared__
Float
p_wei_block_double
[
2
*
wei_block_space
];
...
...
composable_kernel/include/utility/utility.hpp
View file @
9de63930
...
@@ -54,6 +54,14 @@ __host__ __device__ constexpr T integer_divide_ceil(T a, T b)
...
@@ -54,6 +54,14 @@ __host__ __device__ constexpr T integer_divide_ceil(T a, T b)
return
(
a
+
b
-
1
)
/
b
;
return
(
a
+
b
-
1
)
/
b
;
}
}
template
<
class
T
>
__host__
__device__
constexpr
T
integer_least_multiple
(
T
a
,
T
b
)
{
static_assert
(
is_same
<
T
,
index_t
>
{}
||
is_same
<
T
,
int
>
{},
"wrong type"
);
return
b
*
integer_divide_ceil
(
a
,
b
);
}
template
<
class
T
>
template
<
class
T
>
__host__
__device__
constexpr
T
max
(
T
x
)
__host__
__device__
constexpr
T
max
(
T
x
)
{
{
...
...
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