From b87b95e13cce28523e25d6a50af3147edfb43357 Mon Sep 17 00:00:00 2001 From: Gian Marco Iodice Date: Mon, 21 Jan 2019 17:14:31 +0000 Subject: COMPMID-1899: Fix NaN issue in CLGEMMMatrixMultiplyReshapedKernel Change-Id: Ide950b46c4d41de230c272c7044a03f4f9f237ed Reviewed-on: https://review.mlplatform.org/548 Reviewed-by: Georgios Pinitas Reviewed-by: Giuseppe Rossini Tested-by: Arm Jenkins --- tests/validation/fixtures/GEMMFixture.h | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'tests') diff --git a/tests/validation/fixtures/GEMMFixture.h b/tests/validation/fixtures/GEMMFixture.h index 24c9d96611..a6a3b67785 100644 --- a/tests/validation/fixtures/GEMMFixture.h +++ b/tests/validation/fixtures/GEMMFixture.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2017-2018 ARM Limited. + * Copyright (c) 2017-2019 ARM Limited. * * SPDX-License-Identifier: MIT * @@ -187,6 +187,10 @@ protected: { std::uniform_real_distribution<> distribution(-1.0f, 1.0f); library->fill(tensor, distribution, i); + + // Fill border with infinity in order to check the presence of NaN values (i.e. inf * 0) + std::uniform_real_distribution<> distribution_inf(std::numeric_limits::infinity(), std::numeric_limits::infinity()); + library->fill_borders_with_garbage(tensor, distribution_inf, i); } TensorType compute_target(const TensorShape &lhs_shape, const TensorShape &rhs_shape, const GEMMLHSMatrixInfo &lhs_info, const GEMMRHSMatrixInfo &rhs_info, DataType data_type, float alpha) -- cgit v1.2.1