aboutsummaryrefslogtreecommitdiff
path: root/tests
diff options
context:
space:
mode:
authorOmar Al Khatib <omar.alkhatib@arm.com>2023-03-07 09:57:49 +0000
committerOmar Al Khatib <omar.alkhatib@arm.com>2023-03-07 14:47:24 +0000
commit3c7c1fa6c589f75fd8146a47fe71094c172fd56a (patch)
treef9f8aba8d3a22c4bb66b067d6a596d2404bcf56a /tests
parent47f177e679874dc901888973c5fc237b756b38cb (diff)
downloadComputeLibrary-3c7c1fa6c589f75fd8146a47fe71094c172fd56a.tar.gz
Resolve the presence of variables that are unused in release mode in Dynamic Fusion source files
Resloves: [COMPMID-5960] Signed-off-by: Omar Al Khatib <omar.alkhatib@arm.com> Change-Id: I1b11f01c51a029082ed05823717b4c4ae4897798 Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/9270 Tested-by: Arm Jenkins <bsgcomp@arm.com> Reviewed-by: Gunes Bayir <gunes.bayir@arm.com> Comments-Addressed: Arm Jenkins <bsgcomp@arm.com> Benchmark: Arm Jenkins <bsgcomp@arm.com>
Diffstat (limited to 'tests')
-rw-r--r--tests/validation/dynamic_fusion/gpu/cl/Add.cpp17
-rw-r--r--tests/validation/dynamic_fusion/gpu/cl/Reshape.cpp10
2 files changed, 12 insertions, 15 deletions
diff --git a/tests/validation/dynamic_fusion/gpu/cl/Add.cpp b/tests/validation/dynamic_fusion/gpu/cl/Add.cpp
index afe5ee4da1..0034b0f07f 100644
--- a/tests/validation/dynamic_fusion/gpu/cl/Add.cpp
+++ b/tests/validation/dynamic_fusion/gpu/cl/Add.cpp
@@ -100,8 +100,7 @@ DATA_TEST_CASE(Validate, framework::DatasetMode::ALL, zip(zip(
// clang-format on
// *INDENT-ON*
-constexpr AbsoluteTolerance<float> tolerance_f16(0.0001f); /**< Tolerance value for comparing reference's output against implementation's output for DataType::F16 */
-constexpr AbsoluteTolerance<float> tolerance_f32(0.0001f); /**< Tolerance value for comparing reference's output against implementation's output for DataType::F32 */
+constexpr AbsoluteTolerance<float> tolerance_f(0.0001f); /**< Tolerance value for comparing reference's output against implementation's output for DataType::F32 and DataType::F16 */
constexpr float tolerance_num = 0.0001f; /**< Tolerance number */
template <typename T>
@@ -123,7 +122,7 @@ FIXTURE_DATA_TEST_CASE(RunSmallOneOp,
framework::dataset::make("InPlace", { false })))
{
// Validate output
- validate(CLAccessor(_target), _reference, tolerance_f32);
+ validate(CLAccessor(_target), _reference, tolerance_f);
}
FIXTURE_DATA_TEST_CASE(RunLargeOneOp,
DynamicFusionCLAddFixture<float>,
@@ -134,7 +133,7 @@ FIXTURE_DATA_TEST_CASE(RunLargeOneOp,
framework::dataset::make("InPlace", { false })))
{
// Validate output
- validate(CLAccessor(_target), _reference, tolerance_f32);
+ validate(CLAccessor(_target), _reference, tolerance_f);
}
FIXTURE_DATA_TEST_CASE(RunSmallBroadcastOneOp,
DynamicFusionCLAddBroadcastFixture<float>,
@@ -145,7 +144,7 @@ FIXTURE_DATA_TEST_CASE(RunSmallBroadcastOneOp,
framework::dataset::make("InPlace", { false })))
{
// Validate output
- validate(CLAccessor(_target), _reference, tolerance_f32);
+ validate(CLAccessor(_target), _reference, tolerance_f);
}
FIXTURE_DATA_TEST_CASE(RunLargeBroadcastOneOp,
@@ -157,7 +156,7 @@ FIXTURE_DATA_TEST_CASE(RunLargeBroadcastOneOp,
framework::dataset::make("InPlace", { false })))
{
// Validate output
- validate(CLAccessor(_target), _reference, tolerance_f32);
+ validate(CLAccessor(_target), _reference, tolerance_f);
}
FIXTURE_DATA_TEST_CASE(RunSmallTwoOps,
DynamicFusionCLAddTwoOpsFixture<float>,
@@ -169,7 +168,7 @@ FIXTURE_DATA_TEST_CASE(RunSmallTwoOps,
framework::dataset::make("FuseTwoOps", { true })))
{
// Validate output
- validate(CLAccessor(_target), _reference, tolerance_f32);
+ validate(CLAccessor(_target), _reference, tolerance_f);
}
TEST_SUITE_END() // FP32
@@ -183,7 +182,7 @@ FIXTURE_DATA_TEST_CASE(RunSmallOneOp,
framework::dataset::make("InPlace", { false })))
{
// Validate output
- validate(CLAccessor(_target), _reference, tolerance_f32, tolerance_num);
+ validate(CLAccessor(_target), _reference, tolerance_f, tolerance_num);
}
FIXTURE_DATA_TEST_CASE(RunSmallBroadcastOneOp,
@@ -195,7 +194,7 @@ FIXTURE_DATA_TEST_CASE(RunSmallBroadcastOneOp,
framework::dataset::make("InPlace", { false })))
{
// Validate output
- validate(CLAccessor(_target), _reference, tolerance_f32, tolerance_num);
+ validate(CLAccessor(_target), _reference, tolerance_f, tolerance_num);
}
TEST_SUITE_END() // FP16
diff --git a/tests/validation/dynamic_fusion/gpu/cl/Reshape.cpp b/tests/validation/dynamic_fusion/gpu/cl/Reshape.cpp
index 51822b045a..6d88be448e 100644
--- a/tests/validation/dynamic_fusion/gpu/cl/Reshape.cpp
+++ b/tests/validation/dynamic_fusion/gpu/cl/Reshape.cpp
@@ -38,12 +38,9 @@ TEST_SUITE(CL)
TEST_SUITE(DYNAMIC_FUSION)
TEST_SUITE(RESHAPE)
-DATA_TEST_CASE(Validate, framework::DatasetMode::ALL, zip(zip(
- framework::dataset::make("InputInfo",
+DATA_TEST_CASE(Validate, framework::DatasetMode::ALL, zip(zip(framework::dataset::make("InputInfo",
{
- TensorInfo(TensorShape(9U, 5U, 7U, 3U), 1, DataType::F32),
- TensorInfo(TensorShape(8U, 4U, 6U, 4U), 1, DataType::F32),
- TensorInfo(TensorShape(8U, 4U, 6U, 4U), 1, DataType::F32), // mismatching dimensions
+ TensorInfo(TensorShape(9U, 5U, 7U, 3U), 1, DataType::F32), TensorInfo(TensorShape(8U, 4U, 6U, 4U), 1, DataType::F32), TensorInfo(TensorShape(8U, 4U, 6U, 4U), 1, DataType::F32) /*mismatching dimensions*/,
}),
framework::dataset::make("OutputShape",
{
@@ -61,7 +58,8 @@ input_info, output_shape, expected)
// Create sketch tensors
TensorShape input_shape = input_info.tensor_shape();
- TensorInfo src_info = sketch.create_tensor_info(input_info);
+ ARM_COMPUTE_UNUSED(input_shape);
+ TensorInfo src_info = sketch.create_tensor_info(input_info);
ReshapeAttributes attributes;
attributes.shape(output_shape);