Classes | Namespaces | Macros | Functions | Variables
packetmath_test_shared.h File Reference
#include "main.h"
#include <typeinfo>
Include dependency graph for packetmath_test_shared.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Classes

struct  Eigen::internal::bit_andnot
 
struct  Eigen::test::packet_helper< Cond, Packet >
 
struct  Eigen::test::packet_helper< false, Packet >
 
struct  Eigen::test::runall< Scalar, PacketType, IsComplex, IsInteger >
 
struct  Eigen::test::runner< Scalar, PacketType, Vectorized, HasHalf >
 
struct  Eigen::test::runner< Scalar, PacketType, false, false >
 
struct  Eigen::test::runner< Scalar, PacketType, true, false >
 
struct  Eigen::test::runner< Scalar, PacketType, true, true >
 

Namespaces

 Eigen
 Namespace containing all symbols from the Eigen library.
 
 Eigen::internal
 
 Eigen::test
 

Macros

#define CHECK_CWISE1(REFOP, POP)
 
#define CHECK_CWISE1_BYREF1_IF(COND, REFOP, POP)
 
#define CHECK_CWISE1_EXACT_IF(COND, REFOP, POP)
 
#define CHECK_CWISE1_IF(COND, REFOP, POP)
 
#define CHECK_CWISE1_N(REFOP, POP, N)
 
#define CHECK_CWISE2_IF(COND, REFOP, POP)
 
#define CHECK_CWISE3_IF(COND, REFOP, POP)
 
#define EIGEN_TEST_MAKE_BITWISE(OP, FUNC)
 
#define EIGEN_TEST_MAKE_BITWISE2(OP, FUNC, T)
 

Functions

template<typename T , typename Bits , typename Func >
T Eigen::internal::apply_bit_op (Bits a, Bits b, Func f)
 
template<typename Scalar >
bool Eigen::test::areApprox (const Scalar *a, const Scalar *b, int size)
 
template<typename Scalar >
bool Eigen::test::areApproxAbs (const Scalar *a, const Scalar *b, int size, const typename NumTraits< Scalar >::Real &refvalue)
 
template<typename Scalar >
bool Eigen::test::areEqual (const Scalar *a, const Scalar *b, int size)
 
template<typename T >
bool Eigen::internal::biteq (T a, T b)
 
template<typename T >
Map< const Array< unsigned char, sizeof(T), 1 > > Eigen::internal::bits (const T &x)
 
template<typename Scalar >
EIGEN_DONT_INLINE bool Eigen::test::isApproxAbs (const Scalar &a, const Scalar &b, const typename NumTraits< Scalar >::Real &refvalue)
 
template<typename T >
T Eigen::internal::negate (const T &x)
 
template<typename Scalar >
void Eigen::test::print_mismatch (const Scalar *ref, const Scalar *vec, int size)
 

Variables

bool g_first_pass = true
 

Macro Definition Documentation

◆ CHECK_CWISE1

#define CHECK_CWISE1 (   REFOP,
  POP 
)
Value:
{ \
for (int i=0; i<PacketSize; ++i) \
ref[i] = REFOP(data1[i]); \
internal::pstore(data2, POP(internal::pload<Packet>(data1))); \
VERIFY(test::areApprox(ref, data2, PacketSize) && #POP); \
}
bool areApprox(const Scalar *a, const Scalar *b, int size)
Reference counting helper.
Definition: object.h:67
EIGEN_DEVICE_FUNC void pstore(Scalar *to, const Packet &from)

Definition at line 126 of file packetmath_test_shared.h.

◆ CHECK_CWISE1_BYREF1_IF

#define CHECK_CWISE1_BYREF1_IF (   COND,
  REFOP,
  POP 
)
Value:
if(COND) { \
test::packet_helper<COND,Packet> h; \
for (int i=0; i<PacketSize; ++i) \
ref[i] = Scalar(REFOP(data1[i], ref[i+PacketSize])); \
Packet pout; \
Scalar sout; \
h.store(data2, POP(h.load(data1), h.forward_reference(pout, sout))); \
h.store(data2+PacketSize, h.forward_reference(pout, sout)); \
VERIFY(test::areApprox(ref, data2, 2 * PacketSize) && #POP); \
}
SCALAR Scalar
Definition: bench_gemm.cpp:46
bool areApprox(const Scalar *a, const Scalar *b, int size)
Reference counting helper.
Definition: object.h:67
const double h

Definition at line 213 of file packetmath_test_shared.h.

◆ CHECK_CWISE1_EXACT_IF

#define CHECK_CWISE1_EXACT_IF (   COND,
  REFOP,
  POP 
)
Value:
if(COND) { \
test::packet_helper<COND,Packet> h; \
for (int i=0; i<PacketSize; ++i) \
ref[i] = Scalar(REFOP(data1[i])); \
h.store(data2, POP(h.load(data1))); \
VERIFY(test::areEqual(ref, data2, PacketSize) && #POP); \
}
SCALAR Scalar
Definition: bench_gemm.cpp:46
bool areEqual(const Scalar *a, const Scalar *b, int size)
Reference counting helper.
Definition: object.h:67
const double h

Definition at line 196 of file packetmath_test_shared.h.

◆ CHECK_CWISE1_IF

#define CHECK_CWISE1_IF (   COND,
  REFOP,
  POP 
)
Value:
if(COND) { \
test::packet_helper<COND,Packet> h; \
for (int i=0; i<PacketSize; ++i) \
ref[i] = Scalar(REFOP(data1[i])); \
h.store(data2, POP(h.load(data1))); \
VERIFY(test::areApprox(ref, data2, PacketSize) && #POP); \
}
SCALAR Scalar
Definition: bench_gemm.cpp:46
bool areApprox(const Scalar *a, const Scalar *b, int size)
Reference counting helper.
Definition: object.h:67
const double h

Definition at line 188 of file packetmath_test_shared.h.

◆ CHECK_CWISE1_N

#define CHECK_CWISE1_N (   REFOP,
  POP,
  N 
)
Value:
{ \
for (int i=0; i<N; ++i) \
ref[i] = REFOP(data1[i]); \
for (int j=0; j<N; j+=PacketSize) \
internal::pstore(data2 + j, POP(internal::pload<Packet>(data1 + j))); \
VERIFY(test::areApprox(ref, data2, N) && #POP); \
}
#define N
Definition: gksort.c:12
bool areApprox(const Scalar *a, const Scalar *b, int size)
Reference counting helper.
Definition: object.h:67
EIGEN_DEVICE_FUNC void pstore(Scalar *to, const Packet &from)
std::ptrdiff_t j

Definition at line 136 of file packetmath_test_shared.h.

◆ CHECK_CWISE2_IF

#define CHECK_CWISE2_IF (   COND,
  REFOP,
  POP 
)
Value:
if(COND) { \
test::packet_helper<COND,Packet> h; \
for (int i=0; i<PacketSize; ++i) \
ref[i] = Scalar(REFOP(data1[i], data1[i+PacketSize])); \
h.store(data2, POP(h.load(data1),h.load(data1+PacketSize))); \
VERIFY(test::areApprox(ref, data2, PacketSize) && #POP); \
}
SCALAR Scalar
Definition: bench_gemm.cpp:46
bool areApprox(const Scalar *a, const Scalar *b, int size)
Reference counting helper.
Definition: object.h:67
const double h

Definition at line 204 of file packetmath_test_shared.h.

◆ CHECK_CWISE3_IF

#define CHECK_CWISE3_IF (   COND,
  REFOP,
  POP 
)
Value:
if (COND) { \
test::packet_helper<COND, Packet> h; \
for (int i = 0; i < PacketSize; ++i) \
ref[i] = Scalar(REFOP(data1[i], data1[i + PacketSize], \
data1[i + 2 * PacketSize])); \
h.store(data2, POP(h.load(data1), h.load(data1 + PacketSize), \
h.load(data1 + 2 * PacketSize))); \
VERIFY(test::areApprox(ref, data2, PacketSize) && #POP); \
}
SCALAR Scalar
Definition: bench_gemm.cpp:46
bool areApprox(const Scalar *a, const Scalar *b, int size)
Reference counting helper.
Definition: object.h:67
const double h

Definition at line 224 of file packetmath_test_shared.h.

◆ EIGEN_TEST_MAKE_BITWISE

#define EIGEN_TEST_MAKE_BITWISE (   OP,
  FUNC 
)
Value:
EIGEN_TEST_MAKE_BITWISE2(OP,FUNC,double) \
EIGEN_TEST_MAKE_BITWISE2(OP,FUNC,half) \
EIGEN_TEST_MAKE_BITWISE2(OP,FUNC,bfloat16) \
EIGEN_TEST_MAKE_BITWISE2(OP,FUNC,std::complex<float>) \
EIGEN_TEST_MAKE_BITWISE2(OP,FUNC,std::complex<double>)
#define EIGEN_TEST_MAKE_BITWISE2(OP, FUNC, T)

Definition at line 49 of file packetmath_test_shared.h.

◆ EIGEN_TEST_MAKE_BITWISE2

#define EIGEN_TEST_MAKE_BITWISE2 (   OP,
  FUNC,
  T 
)
Value:
template<> T EIGEN_CAT(p,OP)(const T& a,const T& b) { \
return apply_bit_op<T>(bits(a),bits(b),FUNC); \
}
Scalar * b
Definition: benchVecAdd.cpp:17
#define EIGEN_CAT(a, b)
Definition: Macros.h:902
float * p
Map< const Array< unsigned char, sizeof(T), 1 > > bits(const T &x)

Definition at line 44 of file packetmath_test_shared.h.

Variable Documentation

◆ g_first_pass

bool g_first_pass = true

Definition at line 19 of file packetmath_test_shared.h.



gtsam
Author(s):
autogenerated on Tue Jul 4 2023 02:40:51