diff options
author | Adnan AlSinan <adnan.alsinan@arm.com> | 2021-12-10 12:34:02 +0000 |
---|---|---|
committer | SiCong Li <sicong.li@arm.com> | 2021-12-23 17:01:14 +0000 |
commit | 3e155a52f19db046f83e30c25182460b00d108c7 (patch) | |
tree | f3ec747af21c8ee7b95d6dc88bf6ea4b4aa44659 /tests/validation | |
parent | f76a502a73ca628e2a2556abeaa60ed17bb68d97 (diff) | |
download | ComputeLibrary-3e155a52f19db046f83e30c25182460b00d108c7.tar.gz |
Rework gemm_reshape_lhs_ with new macros
Resolves COMPMID-4892
Signed-off-by: Adnan AlSinan <adnan.alsinan@arm.com>
Change-Id: I52f23ca293506fc693ae829daccc6e889a050752
Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/6833
Comments-Addressed: Arm Jenkins <bsgcomp@arm.com>
Reviewed-by: SiCong Li <sicong.li@arm.com>
Reviewed-by: Giorgio Arena <giorgio.arena@arm.com>
Tested-by: Arm Jenkins <bsgcomp@arm.com>
Diffstat (limited to 'tests/validation')
-rw-r--r-- | tests/validation/CL/GEMMReshapeLHSMatrix.cpp | 39 |
1 files changed, 37 insertions, 2 deletions
diff --git a/tests/validation/CL/GEMMReshapeLHSMatrix.cpp b/tests/validation/CL/GEMMReshapeLHSMatrix.cpp index 894b83701f..0dd9b811f6 100644 --- a/tests/validation/CL/GEMMReshapeLHSMatrix.cpp +++ b/tests/validation/CL/GEMMReshapeLHSMatrix.cpp @@ -66,8 +66,10 @@ const auto b_values = framework::dataset::make("batchsize", 1, 3); /** M0 values to test */ const auto m0_values_s32 = framework::dataset::make("M0", { 2, 3 }); -const auto m0_values_s16 = framework::dataset::make("M0", { 4, 5 }); -const auto m0_values_s8 = framework::dataset::make("M0", { 6, 7, 8 }); +const auto m0_values_s16 = framework::dataset::make("M0", { 4 }); +const auto m0_values_s16_nt = framework::dataset::make("M0", { 5 }); +const auto m0_values_s8_nt = framework::dataset::make("M0", { 6,7 }); +const auto m0_values_s8 = framework::dataset::make("M0", { 8 }); /** K0 values to test */ const auto k0_values_s32 = framework::dataset::make("K0", { 2, 3 }); @@ -101,6 +103,7 @@ FIXTURE_DATA_TEST_CASE(S32, CLGEMMReshapeLHSMatrixFixture<int>, framework::Datas // Validate output validate(CLAccessor(_target), _reference); } + FIXTURE_DATA_TEST_CASE(S16, CLGEMMReshapeLHSMatrixFixture<short>, framework::DatasetMode::ALL, combine(combine(combine(combine(combine(combine(combine(datasets::SmallGEMMReshape2DShapes(), b_values), @@ -114,6 +117,7 @@ FIXTURE_DATA_TEST_CASE(S16, CLGEMMReshapeLHSMatrixFixture<short>, framework::Dat // Validate output validate(CLAccessor(_target), _reference); } + FIXTURE_DATA_TEST_CASE(S8, CLGEMMReshapeLHSMatrixFixture<char>, framework::DatasetMode::ALL, combine(combine(combine(combine(combine(combine(combine(datasets::SmallGEMMReshape2DShapes(), b_values), @@ -128,6 +132,37 @@ FIXTURE_DATA_TEST_CASE(S8, CLGEMMReshapeLHSMatrixFixture<char>, framework::Datas validate(CLAccessor(_target), _reference); } +TEST_SUITE(NotTransposed) +FIXTURE_DATA_TEST_CASE(S16, CLGEMMReshapeLHSMatrixFixture<short>, framework::DatasetMode::ALL, + combine(combine(combine(combine(combine(combine(combine(datasets::SmallGEMMReshape2DShapes(), + b_values), + framework::dataset::make("DataType", DataType::S16)), + m0_values_s16_nt), + k0_values_s16), + v0_values), + i_values), + framework::dataset::make("transpose", { false }))) +{ + // Validate output + validate(CLAccessor(_target), _reference); +} + +FIXTURE_DATA_TEST_CASE(S8, CLGEMMReshapeLHSMatrixFixture<char>, framework::DatasetMode::ALL, + combine(combine(combine(combine(combine(combine(combine(datasets::SmallGEMMReshape2DShapes(), + b_values), + framework::dataset::make("DataType", DataType::S8)), + m0_values_s8_nt), + k0_values_s8), + v0_values), + i_values), + framework::dataset::make("transpose", { false }))) +{ + // Validate output + validate(CLAccessor(_target), _reference); +} + +TEST_SUITE_END() + TEST_SUITE(ReinterpretInputAs3D) FIXTURE_DATA_TEST_CASE(S32, CLGEMMReshapeLHSMatrix3DFixture<int>, framework::DatasetMode::ALL, combine(combine(combine(combine(combine(combine(combine(datasets::SmallGEMMReshape3DShapes(), |