mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-10-13 00:21:29 +08:00

* Introduce a new highly optimized matrix-matrix product for large matrices. The code is still highly experimental and it is activated only if you define EIGEN_WIP_PRODUCT at compile time. Currently the third dimension of the product must be a factor of the packet size (x4 for floats) and the right handed side matrix must be column major. Moreover, currently c = a*b; actually computes c += a*b !! Therefore, the code is provided for experimentation purpose only ! These limitations will be fixed soon or later to become the default product implementation.
77 lines
2.0 KiB
Plaintext
77 lines
2.0 KiB
Plaintext
#ifndef EIGEN_CORE_H
|
|
#define EIGEN_CORE_H
|
|
|
|
#ifndef EIGEN_DONT_VECTORIZE
|
|
#if ((defined __SSE2__) && ( (!defined __GNUC__) || (__GNUC__>=4 && __GNUC_MINOR__>=2)))
|
|
#define EIGEN_VECTORIZE
|
|
#define EIGEN_VECTORIZE_SSE
|
|
#include <emmintrin.h>
|
|
#include <xmmintrin.h>
|
|
#include <pmmintrin.h>
|
|
#endif
|
|
#ifdef __ALTIVEC__ // There are zero chances of both __SSE2__ AND __ALTIVEC__ been defined
|
|
#define EIGEN_VECTORIZE
|
|
#define EIGEN_VECTORIZE_ALTIVEC
|
|
#include <altivec.h>
|
|
// We _need_ to #undef bool as it's defined in <altivec.h> for some reason.
|
|
#undef bool
|
|
#endif
|
|
#endif
|
|
|
|
#include <cstdlib>
|
|
#include <cmath>
|
|
#include <complex>
|
|
#include <cassert>
|
|
#include <iostream>
|
|
|
|
#ifdef EIGEN_VECTORIZE
|
|
// it seems we cannot assume posix_memalign is defined in the stdlib header
|
|
extern "C" int posix_memalign (void **, size_t, size_t) throw ();
|
|
#endif
|
|
|
|
namespace Eigen {
|
|
|
|
#include "src/Core/util/Macros.h"
|
|
#include "src/Core/util/Constants.h"
|
|
#include "src/Core/util/ForwardDeclarations.h"
|
|
#include "src/Core/util/Meta.h"
|
|
|
|
#include "src/Core/NumTraits.h"
|
|
#include "src/Core/MathFunctions.h"
|
|
#include "src/Core/PacketMath.h"
|
|
#include "src/Core/Functors.h"
|
|
#include "src/Core/MatrixBase.h"
|
|
#include "src/Core/Coeffs.h"
|
|
#include "src/Core/Assign.h"
|
|
#include "src/Core/MatrixStorage.h"
|
|
#include "src/Core/Matrix.h"
|
|
#include "src/Core/Lazy.h"
|
|
#include "src/Core/Temporary.h"
|
|
#include "src/Core/CwiseBinaryOp.h"
|
|
#include "src/Core/CwiseUnaryOp.h"
|
|
#include "src/Core/CwiseNullaryOp.h"
|
|
#ifdef EIGEN_WIP_PRODUCT
|
|
#include "src/Core/ProductWIP.h"
|
|
#else
|
|
#include "src/Core/Product.h"
|
|
#endif
|
|
#include "src/Core/Block.h"
|
|
#include "src/Core/Minor.h"
|
|
#include "src/Core/Transpose.h"
|
|
#include "src/Core/Dot.h"
|
|
#include "src/Core/DiagonalMatrix.h"
|
|
#include "src/Core/DiagonalCoeffs.h"
|
|
#include "src/Core/Redux.h"
|
|
#include "src/Core/Visitor.h"
|
|
#include "src/Core/Fuzzy.h"
|
|
#include "src/Core/Map.h"
|
|
#include "src/Core/IO.h"
|
|
#include "src/Core/Swap.h"
|
|
#include "src/Core/CommaInitializer.h"
|
|
#include "src/Core/Triangular.h"
|
|
#include "src/Core/TriangularAssign.h"
|
|
|
|
} // namespace Eigen
|
|
|
|
#endif // EIGEN_CORE_H
|