aboutsummaryrefslogtreecommitdiff
path: root/src/core/NEON/kernels/arm_conv/pooling/pooling_depthfirst.hpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/NEON/kernels/arm_conv/pooling/pooling_depthfirst.hpp')
-rw-r--r--src/core/NEON/kernels/arm_conv/pooling/pooling_depthfirst.hpp9
1 files changed, 5 insertions, 4 deletions
diff --git a/src/core/NEON/kernels/arm_conv/pooling/pooling_depthfirst.hpp b/src/core/NEON/kernels/arm_conv/pooling/pooling_depthfirst.hpp
index 8a6e63d993..1ca478513c 100644
--- a/src/core/NEON/kernels/arm_conv/pooling/pooling_depthfirst.hpp
+++ b/src/core/NEON/kernels/arm_conv/pooling/pooling_depthfirst.hpp
@@ -91,17 +91,17 @@ class PoolingDepthfirst : public DepthfirstDriver<TInput, TOutput>
protected:
/* Compute the amount of working space required for a single thread. */
- size_t get_working_size_per_thread(unsigned int n_channels) const override
+ size_t get_working_size_per_thread() const override
{
- return sizeof(WorkingSpace) + n_channels * (sizeof(TInput) + sizeof(TOutput));
+ return sizeof(WorkingSpace) + this->m_args.n_channels * (sizeof(TInput) + sizeof(TOutput));
}
/* Initialise the working space for a thread. */
- void initialise_working_space(void *raw_ws, unsigned int n_channels) const override
+ void initialise_working_space(void *raw_ws) const override
{
auto ws = reinterpret_cast<WorkingSpace *>(raw_ws);
ws->input_buffer = ws + 1;
- ws->output_buffer = reinterpret_cast<char *>(ws + 1) + sizeof(TInput) * n_channels;
+ ws->output_buffer = reinterpret_cast<char *>(ws + 1) + sizeof(TInput) * this->m_args.n_channels;
// Fill the input buffer with an appropriate value
TInput fill_val = 0;
@@ -119,6 +119,7 @@ class PoolingDepthfirst : public DepthfirstDriver<TInput, TOutput>
}
auto ptr = reinterpret_cast<TInput *>(ws->input_buffer);
+ auto n_channels = this->m_args.n_channels;
for (; n_channels; n_channels--)
{
*(ptr++) = fill_val;