Grok 12.0.1
Classes | Namespaces | Macros | Typedefs | Functions
test_util-inl.h File Reference
#include <stdio.h>
#include <string.h>
#include "hwy/aligned_allocator.h"
#include "hwy/base.h"
#include "hwy/detect_targets.h"
#include "hwy/per_target.h"
#include "hwy/targets.h"
#include "hwy/tests/hwy_gtest.h"
#include "hwy/tests/test_util.h"
#include "hwy/print-inl.h"

Go to the source code of this file.

Classes

struct  hwy::HWY_NAMESPACE::detail::ForeachCappedR< T, kMul, kMinArg, Test, kPow2 >
 
struct  hwy::HWY_NAMESPACE::detail::ForeachCappedR< T, 0, kMinArg, Test, kPow2 >
 
class  hwy::HWY_NAMESPACE::ForMaxPow2< Test >
 
class  hwy::HWY_NAMESPACE::ForExtendableVectors< Test, kPow2 >
 
class  hwy::HWY_NAMESPACE::ForShrinkableVectors< Test, kPow2 >
 
class  hwy::HWY_NAMESPACE::ForGEVectors< kMinBits, Test >
 
class  hwy::HWY_NAMESPACE::ForPromoteVectors< Test, kPow2 >
 
class  hwy::HWY_NAMESPACE::ForDemoteVectors< Test, kPow2 >
 
class  hwy::HWY_NAMESPACE::ForHalfVectors< Test, kPow2 >
 
class  hwy::HWY_NAMESPACE::ForPartialVectors< Test >
 

Namespaces

namespace  hwy
 
namespace  hwy::HWY_NAMESPACE
 
namespace  hwy::HWY_NAMESPACE::detail
 

Macros

#define HIGHWAY_HWY_TESTS_TEST_UTIL_INL_H_
 
#define HWY_ASSERT_EQ(expected, actual)
 
#define HWY_ASSERT_ARRAY_EQ(expected, actual, count)
 
#define HWY_ASSERT_STRING_EQ(expected, actual)
 
#define HWY_ASSERT_VEC_EQ(d, expected, actual)    AssertVecEqual(d, expected, actual, __FILE__, __LINE__)
 
#define HWY_ASSERT_MASK_EQ(d, expected, actual)    AssertMaskEqual(d, expected, actual, __FILE__, __LINE__)
 

Typedefs

template<class Test >
using hwy::HWY_NAMESPACE::ForGE128Vectors = ForGEVectors<128, Test>
 
template<class Test >
using hwy::HWY_NAMESPACE::ForPartialFixedOrFullScalableVectors
 

Functions

 HWY_BEFORE_NAMESPACE ()
 
template<class D , HWY_IF_FLOAT_D(D) >
HWY_INLINE Vec< D > hwy::HWY_NAMESPACE::PositiveIota (D d)
 
template<class D , typename First , HWY_IF_NOT_SPECIAL_FLOAT_D(D) >
VFromD< D > hwy::HWY_NAMESPACE::IotaForSpecial (D d, First first)
 
template<class D , typename First , HWY_IF_F16_D(D) , HWY_IF_LANES_GT_D(D, 1) , HWY_IF_POW2_GT_D(D, -1) >
VFromD< D > hwy::HWY_NAMESPACE::IotaForSpecial (D d, First first)
 
template<class D , typename First , HWY_IF_SPECIAL_FLOAT_D(D) , HWY_IF_LANES_D(D, 1) >
VFromD< D > hwy::HWY_NAMESPACE::IotaForSpecial (D d, First first)
 
template<class D , typename T = TFromD<D>>
HWY_INLINE void hwy::HWY_NAMESPACE::AssertVecEqual (D d, const T *expected, Vec< D > actual, const char *filename, const int line)
 
template<class D , typename T = TFromD<D>>
HWY_INLINE void hwy::HWY_NAMESPACE::AssertVecEqual (D d, Vec< D > expected, Vec< D > actual, const char *filename, int line)
 
template<class D >
HWY_NOINLINE void hwy::HWY_NAMESPACE::AssertMaskEqual (D d, VecArg< Mask< D > > a, VecArg< Mask< D > > b, const char *filename, int line)
 
template<class D >
HWY_INLINE Mask< D > hwy::HWY_NAMESPACE::MaskTrue (const D d)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForSignedTypes (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForUnsignedTypes (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForIntegerTypes (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForFloat16Types (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForFloat64Types (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForFloat16TypesDynamic (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForFloat64TypesDynamic (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForFloat3264Types (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForFloatTypes (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForFloatTypesDynamic (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForAllTypes (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForSpecialTypes (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForAllTypesAndSpecial (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForUI8 (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForUI16 (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForUIF16 (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForUI32 (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForUIF32 (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForUI64 (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForUIF64 (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForUI3264 (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForUIF3264 (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForU816 (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForI816 (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForU163264 (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForUI163264 (const Func &func)
 
template<class Func >
void hwy::HWY_NAMESPACE::ForUIF163264 (const Func &func)
 
constexpr size_t hwy::HWY_NAMESPACE::AdjustedReps (size_t max_reps)
 
constexpr size_t hwy::HWY_NAMESPACE::AdjustedLog2Reps (size_t max_pow2)
 
 HWY_AFTER_NAMESPACE ()
 

Macro Definition Documentation

◆ HIGHWAY_HWY_TESTS_TEST_UTIL_INL_H_

#define HIGHWAY_HWY_TESTS_TEST_UTIL_INL_H_

◆ HWY_ASSERT_ARRAY_EQ

#define HWY_ASSERT_ARRAY_EQ ( expected,
actual,
count )
Value:
hwy::AssertArrayEqual(expected, actual, count, hwy::TargetName(HWY_TARGET), \
__FILE__, __LINE__)
#define HWY_TARGET
Definition detect_targets.h:543
static HWY_MAYBE_UNUSED const char * TargetName(int64_t target)
Definition targets.h:85
HWY_INLINE void AssertArrayEqual(const T *expected, const T *actual, size_t count, const char *target_name, const char *filename, int line)
Definition test_util.h:206

◆ HWY_ASSERT_EQ

#define HWY_ASSERT_EQ ( expected,
actual )
Value:
hwy::AssertEqual(expected, actual, hwy::TargetName(HWY_TARGET), __FILE__, \
__LINE__)
HWY_INLINE void AssertEqual(const TExpected texpected, const TActual actual, const char *target_name, const char *filename, int line, size_t lane=0)
Definition test_util.h:194

◆ HWY_ASSERT_MASK_EQ

#define HWY_ASSERT_MASK_EQ ( d,
expected,
actual )    AssertMaskEqual(d, expected, actual, __FILE__, __LINE__)

◆ HWY_ASSERT_STRING_EQ

#define HWY_ASSERT_STRING_EQ ( expected,
actual )
Value:
__FILE__, __LINE__)
void AssertStringEqual(const char *expected, const char *actual, const char *target_name, const char *filename, int line)

◆ HWY_ASSERT_VEC_EQ

#define HWY_ASSERT_VEC_EQ ( d,
expected,
actual )    AssertVecEqual(d, expected, actual, __FILE__, __LINE__)

Function Documentation

◆ HWY_AFTER_NAMESPACE()

HWY_AFTER_NAMESPACE ( )

◆ HWY_BEFORE_NAMESPACE()

HWY_BEFORE_NAMESPACE ( )