github.com/johnnyeven/libtools@v0.0.0-20191126065708-61829c1adf46/third_party/eigen3/unsupported/Eigen/CXX11/FixedPoint (about)

     1  // This file is part of Eigen, a lightweight C++ template library
     2  // for linear algebra.
     3  //
     4  // Copyright (C) 2015 Benoit Steiner <benoit.steiner.goog@gmail.com>
     5  //
     6  // This Source Code Form is subject to the terms of the Mozilla
     7  // Public License v. 2.0. If a copy of the MPL was not distributed
     8  // with this file, You can obtain one at http://mozilla.org/MPL/2.0/.
     9  
    10  #ifndef EIGEN_CXX11_FIXED_POINT_MODULE
    11  #define EIGEN_CXX11_FIXED_POINT_MODULE
    12  
    13  #include <Eigen/Core>
    14  #include <stdint.h>
    15  
    16  /** \defgroup CXX11_FixedPoint_Module Fixed Point Module
    17    *
    18    * This module provides common core features for all modules that
    19    * explicitly depend on C++11. Currently, this is only the Tensor
    20    * module. Note that at this stage, you should not need to include
    21    * this module directly.
    22    *
    23    * It also provides a limited fallback for compilers that don't support
    24    * CXX11 yet, such as nvcc.
    25    *
    26    * \code
    27    * #include <Eigen/CXX11/FixedPoint>
    28    * \endcode
    29    */
    30  
    31  #include "src/FixedPoint/FixedPointTypes.h"
    32  
    33  // Use optimized implementations whenever available
    34  #if defined (EIGEN_VECTORIZE_AVX512DQ) || defined (EIGEN_VECTORIZE_AVX512BW)
    35  #include "src/FixedPoint/PacketMathAVX512.h"
    36  #include "src/FixedPoint/TypeCastingAVX512.h"
    37  
    38  #elif defined EIGEN_VECTORIZE_AVX2
    39  #define EIGEN_USE_OPTIMIZED_INT8_UINT8_MAT_MAT_PRODUCT
    40  #define EIGEN_USE_OPTIMIZED_INT16_INT16_MAT_MAT_PRODUCT
    41  #include "src/FixedPoint/PacketMathAVX2.h"
    42  #include "src/FixedPoint/MatMatProductAVX2.h"
    43  #include "src/FixedPoint/TypeCastingAVX2.h"
    44  
    45  #elif defined EIGEN_VECTORIZE_NEON
    46  #define EIGEN_USE_OPTIMIZED_INT8_UINT8_MAT_MAT_PRODUCT
    47  #include "src/FixedPoint/MatMatProductNEON.h"
    48  #endif
    49  
    50  // Use the default implementation when no optimized code is available
    51  #include "src/FixedPoint/MatMatProduct.h"
    52  #include "src/FixedPoint/MatVecProduct.h"
    53  
    54  
    55  #endif // EIGEN_CXX11_FIXED_POINT_MODULE