chromium/third_party/libaom/source/libaom/test/fwht4x4_test.cc

/*
 * Copyright (c) 2016, Alliance for Open Media. All rights reserved.
 *
 * This source code is subject to the terms of the BSD 2 Clause License and
 * the Alliance for Open Media Patent License 1.0. If the BSD 2 Clause License
 * was not distributed with this source code in the LICENSE file, you can
 * obtain it at www.aomedia.org/license/software. If the Alliance for Open
 * Media Patent License 1.0 was not distributed with this source code in the
 * PATENTS file, you can obtain it at www.aomedia.org/license/patent.
 */

#include <math.h>
#include <stdlib.h>
#include <string.h>
#include <tuple>

#include "aom_dsp/aom_dsp_common.h"
#include "gtest/gtest.h"

#include "config/av1_rtcd.h"
#include "config/aom_dsp_rtcd.h"
#include "test/acm_random.h"
#include "test/register_state_check.h"
#include "test/transform_test_base.h"
#include "test/util.h"
#include "av1/common/entropy.h"
#include "aom/aom_codec.h"
#include "aom/aom_integer.h"
#include "aom_ports/mem.h"

ACMRandom;

namespace {
FdctFunc;
IdctFunc;

FhtFunc;

Dct4x4Param;

void fwht4x4_ref(const int16_t *in, tran_low_t *out, int stride,
                 TxfmParam * /*txfm_param*/) {}

void iwht4x4_10_c(const tran_low_t *in, uint8_t *out, int stride) {}

void iwht4x4_12_c(const tran_low_t *in, uint8_t *out, int stride) {}

#if HAVE_SSE4_1

void iwht4x4_10_sse4_1(const tran_low_t *in, uint8_t *out, int stride) {}

void iwht4x4_12_sse4_1(const tran_low_t *in, uint8_t *out, int stride) {}

#endif

class Trans4x4WHT : public libaom_test::TransformTestBase<tran_low_t>,
                    public ::testing::TestWithParam<Dct4x4Param> {};

TEST_P(Trans4x4WHT, AccuracyCheck) {}

TEST_P(Trans4x4WHT, CoeffCheck) {}

TEST_P(Trans4x4WHT, MemCheck) {}

TEST_P(Trans4x4WHT, InvAccuracyCheck) {}

TEST_P(Trans4x4WHT, DISABLED_Speed) {}

make_tuple;

INSTANTIATE_TEST_SUITE_P();

#if HAVE_SSE4_1

INSTANTIATE_TEST_SUITE_P();

#endif  // HAVE_SSE4_1

#if HAVE_NEON

INSTANTIATE_TEST_SUITE_P(
    NEON, Trans4x4WHT,
    ::testing::Values(make_tuple(&av1_fwht4x4_neon, &iwht4x4_10_c, DCT_DCT,
                                 AOM_BITS_10, 16, &av1_fwht4x4_c),
                      make_tuple(&av1_fwht4x4_neon, &iwht4x4_12_c, DCT_DCT,
                                 AOM_BITS_12, 16, &av1_fwht4x4_c)));

#endif  // HAVE_NEON

}  // namespace