aboutsummaryrefslogtreecommitdiff
path: root/tests/validation/reference/GEMMLowp.cpp
diff options
context:
space:
mode:
authorMichalis Spyrou <michalis.spyrou@arm.com>2020-04-08 14:10:15 +0100
committerMichalis Spyrou <michalis.spyrou@arm.com>2020-04-17 14:20:01 +0000
commitd1d7722cfc5ee130115d8d195068a98b16102a21 (patch)
treef68f3ecca02ab4edde90189266fa186ec1a69474 /tests/validation/reference/GEMMLowp.cpp
parent4c6bd514a8d424a29b776754f1b3426fa3a8c339 (diff)
downloadComputeLibrary-d1d7722cfc5ee130115d8d195068a98b16102a21.tar.gz
COMPMID-3314: Enable OpenMP in the reference tests
Change-Id: I05b5fedb998317144e0dd13a6377a97207b27f46 Signed-off-by: Michalis Spyrou <michalis.spyrou@arm.com> Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/3024 Tested-by: Arm Jenkins <bsgcomp@arm.com> Reviewed-by: Michele Di Giorgio <michele.digiorgio@arm.com> Comments-Addressed: Arm Jenkins <bsgcomp@arm.com>
Diffstat (limited to 'tests/validation/reference/GEMMLowp.cpp')
-rw-r--r--tests/validation/reference/GEMMLowp.cpp9
1 files changed, 9 insertions, 0 deletions
diff --git a/tests/validation/reference/GEMMLowp.cpp b/tests/validation/reference/GEMMLowp.cpp
index 36d86d1532..85a98e4a76 100644
--- a/tests/validation/reference/GEMMLowp.cpp
+++ b/tests/validation/reference/GEMMLowp.cpp
@@ -69,6 +69,9 @@ void quantize_down_scale(const SimpleTensor<TIn> *in, const SimpleTensor<TIn> *b
const int cols_in = in->shape().x();
const bool is_per_channel = result_mult_int.size() > 1;
+#if defined(_OPENMP)
+ #pragma omp parallel for
+#endif /* _OPENMP */
for(int i = 0; i < in->num_elements(); ++i)
{
int32_t result = ((*in)[i] + result_offset);
@@ -100,6 +103,9 @@ void quantize_down_scale_by_fixedpoint(const SimpleTensor<TIn> *in, const Simple
const int cols_in = in->shape().x();
const bool is_per_channel = result_fixedpoint_multiplier.size() > 1;
+#if defined(_OPENMP)
+ #pragma omp parallel for
+#endif /* _OPENMP */
for(int i = 0; i < in->num_elements(); ++i)
{
TIn result = (*in)[i];
@@ -141,6 +147,9 @@ void quantize_down_scale_by_float(const SimpleTensor<TIn> *in, const SimpleTenso
const int cols_in = in->shape().x();
const bool is_per_channel = result_real_multiplier.size() > 1;
+#if defined(_OPENMP)
+ #pragma omp parallel for
+#endif /* _OPENMP */
for(int i = 0; i < in->num_elements(); ++i)
{
TIn result = (*in)[i];