aboutsummaryrefslogtreecommitdiff
path: root/src/core/cpu/kernels/CpuElementwiseKernel.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/core/cpu/kernels/CpuElementwiseKernel.cpp')
-rw-r--r--src/core/cpu/kernels/CpuElementwiseKernel.cpp6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/core/cpu/kernels/CpuElementwiseKernel.cpp b/src/core/cpu/kernels/CpuElementwiseKernel.cpp
index ab915b9d72..1ac21acbc0 100644
--- a/src/core/cpu/kernels/CpuElementwiseKernel.cpp
+++ b/src/core/cpu/kernels/CpuElementwiseKernel.cpp
@@ -182,14 +182,12 @@ void CpuElementwiseKernel::configure_common(const ITensorInfo *input1, const ITe
ARM_COMPUTE_ERROR_ON_NULLPTR(input1, input2, output);
// Configure kernel window
- const std::pair<TensorShape, ValidRegion> broadcast_pair = ITensorInfo::broadcast_shape_and_valid_region(*input1, *input2);
- const TensorShape &out_shape = broadcast_pair.first;
- const ValidRegion &valid_region = broadcast_pair.second;
+ const TensorShape &out_shape = TensorShape::broadcast_shape(input1->tensor_shape(), input2->tensor_shape());
// Auto initialize output if not initialized
auto_init_if_empty(*output, out_shape, 1, input1->data_type());
- Window win = calculate_max_window(valid_region);
+ Window win = calculate_max_window(out_shape);
ICpuKernel::configure(win);
}