Move CUDA/Complex.h to GPU/Complex.h, remove TensorReductionCuda.h

The `Complex.h` file applies equally to HIP/CUDA, so placing under the
generic `GPU` folder.

The `TensorReductionCuda.h` has already been deprecated, now removing
for the next Eigen version.
This commit is contained in:
Antonio Sanchez 2021-10-08 11:36:27 -07:00
parent f2c9c2d2f7
commit d0d34524a1
3 changed files with 8 additions and 15 deletions

View File

@ -258,10 +258,9 @@ using std::ptrdiff_t;
#include "src/Core/functors/StlFunctors.h"
#include "src/Core/functors/AssignmentFunctors.h"
// Specialized functors to enable the processing of complex numbers
// on CUDA devices
#ifdef EIGEN_CUDACC
#include "src/Core/arch/CUDA/Complex.h"
// Specialized functors for GPU.
#ifdef EIGEN_GPUCC
#include "src/Core/arch/GPU/Complex.h"
#endif
#include "src/Core/util/IndexedViewHelper.h"

View File

@ -8,8 +8,8 @@
// Public License v. 2.0. If a copy of the MPL was not distributed
// with this file, You can obtain one at http://mozilla.org/MPL/2.0/.
#ifndef EIGEN_COMPLEX_CUDA_H
#define EIGEN_COMPLEX_CUDA_H
#ifndef EIGEN_COMPLEX_GPU_H
#define EIGEN_COMPLEX_GPU_H
// Many std::complex methods such as operator+, operator-, operator* and
// operator/ are not constexpr. Due to this, GCC and older versions of clang do
@ -30,7 +30,7 @@
// - Compiling with ICC requires defining _USE_COMPLEX_SPECIALIZATION_ prior
// to the first inclusion of <complex>.
#if defined(EIGEN_CUDACC) && defined(EIGEN_GPU_COMPILE_PHASE)
#if defined(EIGEN_GPUCC) && defined(EIGEN_GPU_COMPILE_PHASE)
// ICC already specializes std::complex<float> and std::complex<double>
// operators, preventing us from making them device functions here.
@ -266,6 +266,6 @@ EIGEN_USING_STD_COMPLEX_OPERATORS
#endif // !(EIGEN_COMP_ICC && _USE_COMPLEX_SPECIALIZATION_)
#endif // EIGEN_CUDACC && EIGEN_GPU_COMPILE_PHASE
#endif // EIGEN_GPUCC && EIGEN_GPU_COMPILE_PHASE
#endif // EIGEN_COMPLEX_CUDA_H
#endif // EIGEN_COMPLEX_GPU_H

View File

@ -1,6 +0,0 @@
#if defined(__clang__) || defined(__GNUC__)
#warning "Deprecated header file, please either include the main Eigen/CXX11/Tensor header or the respective TensorReductionGpu.h file"
#endif
#include "TensorReductionGpu.h"