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
9e7cca9d
Commit
9e7cca9d
authored
Jun 15, 2023
by
rocking
Browse files
Add comment
parent
4726df77
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
0 deletions
+3
-0
example/49_maxpool2d_bwd/maxpool2d_bwd_common.hpp
example/49_maxpool2d_bwd/maxpool2d_bwd_common.hpp
+2
-0
include/ck/tensor_operation/gpu/device/impl/device_index_pool_bwd_impl.hpp
..._operation/gpu/device/impl/device_index_pool_bwd_impl.hpp
+1
-0
No files found.
example/49_maxpool2d_bwd/maxpool2d_bwd_common.hpp
View file @
9e7cca9d
...
@@ -163,6 +163,8 @@ bool maxpool_bwd_test(bool do_verification,
...
@@ -163,6 +163,8 @@ bool maxpool_bwd_test(bool do_verification,
size_t
pool_bwd_workspace_sz
=
pool_bwd
.
GetWorkSpaceSize
(
pool_bwd_argument_ptr
.
get
());
size_t
pool_bwd_workspace_sz
=
pool_bwd
.
GetWorkSpaceSize
(
pool_bwd_argument_ptr
.
get
());
DeviceMem
pool_bwd_workspace_device_buf
(
pool_bwd_workspace_sz
);
DeviceMem
pool_bwd_workspace_device_buf
(
pool_bwd_workspace_sz
);
// similar to din_device_buf.SetZero()
// we need to set workspace to be zero
pool_bwd_workspace_device_buf
.
SetZero
();
pool_bwd_workspace_device_buf
.
SetZero
();
pool_bwd
.
SetWorkSpacePointer
(
pool_bwd_argument_ptr
.
get
(),
pool_bwd
.
SetWorkSpacePointer
(
pool_bwd_argument_ptr
.
get
(),
pool_bwd_workspace_device_buf
.
GetDeviceBuffer
());
pool_bwd_workspace_device_buf
.
GetDeviceBuffer
());
...
...
include/ck/tensor_operation/gpu/device/impl/device_index_pool_bwd_impl.hpp
View file @
9e7cca9d
...
@@ -244,6 +244,7 @@ struct DeviceIndexPoolBwdImpl : public DeviceIndexPoolBwd<DOutDataType, IndexDat
...
@@ -244,6 +244,7 @@ struct DeviceIndexPoolBwdImpl : public DeviceIndexPoolBwd<DOutDataType, IndexDat
}
}
};
};
// User need to set the value of workspace to zero
size_t
GetWorkSpaceSize
(
const
BaseArgument
*
pArg
)
const
override
size_t
GetWorkSpaceSize
(
const
BaseArgument
*
pArg
)
const
override
{
{
const
Argument
*
pArg_
=
dynamic_cast
<
const
Argument
*>
(
pArg
);
const
Argument
*
pArg_
=
dynamic_cast
<
const
Argument
*>
(
pArg
);
...
...
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