From 6260e194b34842ac6d932dd5c96842c0d1214d70 Mon Sep 17 00:00:00 2001 From: Michalis Spyrou Date: Thu, 6 Jun 2019 13:47:38 +0100 Subject: COMPMID-2394: (Nightly) Clang-tidy errors Change-Id: Ie7ccf4e62cccca6057c0bc4521496267a05e4459 Signed-off-by: Michalis Spyrou Reviewed-on: https://review.mlplatform.org/c/1304 Tested-by: Arm Jenkins Comments-Addressed: Arm Jenkins Reviewed-by: Giuseppe Rossini --- tests/validation/reference/ChannelExtract.cpp | 4 ++-- tests/validation/reference/ColorConvertHelper.h | 8 ++++---- tests/validation/reference/PixelWiseMultiplication.cpp | 13 +++++++------ tests/validation/reference/PixelWiseMultiplication.h | 4 ++-- 4 files changed, 15 insertions(+), 14 deletions(-) (limited to 'tests') diff --git a/tests/validation/reference/ChannelExtract.cpp b/tests/validation/reference/ChannelExtract.cpp index 6f17fc06fe..fc7ae7d6cb 100644 --- a/tests/validation/reference/ChannelExtract.cpp +++ b/tests/validation/reference/ChannelExtract.cpp @@ -1,5 +1,5 @@ /* - * Copyright (c) 2017-2018 ARM Limited. + * Copyright (c) 2017-2019 ARM Limited. * * SPDX-License-Identifier: MIT * @@ -61,7 +61,7 @@ SimpleTensor channel_extract(const TensorShape &shape, const std::vecto const auto *src_pixel = reinterpret_cast(src(src_coord)); auto *dst_pixel = reinterpret_cast(dst(dst_coord)); - dst_pixel[0] = src_pixel[channel_idx]; + dst_pixel[0] = src_pixel[channel_idx]; // NOLINT } } diff --git a/tests/validation/reference/ColorConvertHelper.h b/tests/validation/reference/ColorConvertHelper.h index b2ae6f2f80..abd1f5d1fe 100644 --- a/tests/validation/reference/ColorConvertHelper.h +++ b/tests/validation/reference/ColorConvertHelper.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2017-2018 ARM Limited. + * Copyright (c) 2017-2019 ARM Limited. * * SPDX-License-Identifier: MIT * @@ -9,14 +9,14 @@ * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or * sell copies of the Software, and to permit persons to whom the Software is * furnished to do so, subject to the following conditions: - *asymm_int_mult + * * The above copyright notice and this permission notice shall be included in all * copies or substantial portions of the Software. * * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, asymm_int_multDAMAGES OR OTHER + * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE * SOFTWARE. @@ -70,7 +70,7 @@ inline void store_rgb_from_src(const SimpleTensor src, SimpleTensor &rvec, auto *gvec_pixel = reinterpret_cast(gvec(vec_coord)); auto *bvec_pixel = reinterpret_cast(bvec(vec_coord)); - rvec_pixel[0] = src_pixel[0]; + rvec_pixel[0] = src_pixel[0]; // NOLINT gvec_pixel[0] = src_pixel[1]; bvec_pixel[0] = src_pixel[2]; } diff --git a/tests/validation/reference/PixelWiseMultiplication.cpp b/tests/validation/reference/PixelWiseMultiplication.cpp index ea058ecdba..7dc32d08a7 100644 --- a/tests/validation/reference/PixelWiseMultiplication.cpp +++ b/tests/validation/reference/PixelWiseMultiplication.cpp @@ -128,7 +128,8 @@ struct BroadcastUnroll<0> } // namespace template -SimpleTensor pixel_wise_multiplication(const SimpleTensor &src1, const SimpleTensor &src2, float scale, ConvertPolicy convert_policy, RoundingPolicy rounding_policy, QuantizationInfo qout) +SimpleTensor pixel_wise_multiplication(const SimpleTensor &src1, const SimpleTensor &src2, float scale, ConvertPolicy convert_policy, RoundingPolicy rounding_policy, + const QuantizationInfo &qout) { ARM_COMPUTE_UNUSED(qout); @@ -150,7 +151,7 @@ SimpleTensor pixel_wise_multiplication(const SimpleTensor &src1, const S template <> SimpleTensor pixel_wise_multiplication(const SimpleTensor &src1, const SimpleTensor &src2, float scale, ConvertPolicy convert_policy, RoundingPolicy rounding_policy, - QuantizationInfo qout) + const QuantizationInfo &qout) { SimpleTensor dst(TensorShape::broadcast_shape(src1.shape(), src2.shape()), src2.data_type(), 1, qout); @@ -177,10 +178,10 @@ SimpleTensor pixel_wise_multiplication(const SimpleTensor &src } // *INDENT-OFF* // clang-format off -template SimpleTensor pixel_wise_multiplication(const SimpleTensor &src1, const SimpleTensor &src2, float scale, ConvertPolicy convert_policy, RoundingPolicy rounding_policy, QuantizationInfo qout); -template SimpleTensor pixel_wise_multiplication(const SimpleTensor &src1, const SimpleTensor &src2, float scale, ConvertPolicy convert_policy, RoundingPolicy rounding_policy, QuantizationInfo qout); -template SimpleTensor pixel_wise_multiplication(const SimpleTensor &src1, const SimpleTensor &src2, float scale, ConvertPolicy convert_policy, RoundingPolicy rounding_policy, QuantizationInfo qout); -template SimpleTensor pixel_wise_multiplication(const SimpleTensor &src1, const SimpleTensor &src2, float scale, ConvertPolicy convert_policy, RoundingPolicy rounding_policy, QuantizationInfo qout); +template SimpleTensor pixel_wise_multiplication(const SimpleTensor &src1, const SimpleTensor &src2, float scale, ConvertPolicy convert_policy, RoundingPolicy rounding_policy, const QuantizationInfo &qout); +template SimpleTensor pixel_wise_multiplication(const SimpleTensor &src1, const SimpleTensor &src2, float scale, ConvertPolicy convert_policy, RoundingPolicy rounding_policy, const QuantizationInfo &qout); +template SimpleTensor pixel_wise_multiplication(const SimpleTensor &src1, const SimpleTensor &src2, float scale, ConvertPolicy convert_policy, RoundingPolicy rounding_policy, const QuantizationInfo &qout); +template SimpleTensor pixel_wise_multiplication(const SimpleTensor &src1, const SimpleTensor &src2, float scale, ConvertPolicy convert_policy, RoundingPolicy rounding_policy, const QuantizationInfo &qout); // clang-format on // *INDENT-ON* } // namespace reference diff --git a/tests/validation/reference/PixelWiseMultiplication.h b/tests/validation/reference/PixelWiseMultiplication.h index 787a7b23e2..39d2bc794c 100644 --- a/tests/validation/reference/PixelWiseMultiplication.h +++ b/tests/validation/reference/PixelWiseMultiplication.h @@ -1,5 +1,5 @@ /* - * Copyright (c) 2017-2018 ARM Limited. + * Copyright (c) 2017-2019 ARM Limited. * * SPDX-License-Identifier: MIT * @@ -36,7 +36,7 @@ namespace reference { template SimpleTensor pixel_wise_multiplication(const SimpleTensor &src1, const SimpleTensor &src2, float scale, - ConvertPolicy convert_policy, RoundingPolicy rounding_policy, QuantizationInfo qout = QuantizationInfo()); + ConvertPolicy convert_policy, RoundingPolicy rounding_policy, const QuantizationInfo &qout = QuantizationInfo()); } // namespace reference } // namespace validation } // namespace test -- cgit v1.2.1