Skip to content

Commit

Permalink
Fix the definition of global device constants
Browse files Browse the repository at this point in the history
  • Loading branch information
fwyzard committed Sep 21, 2023
1 parent fe7e6a8 commit 47f0a0f
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
4 changes: 2 additions & 2 deletions Eigen/src/Core/util/IntegralConstant.h
Original file line number Diff line number Diff line change
Expand Up @@ -184,8 +184,8 @@ template<int N, int DynamicKey> struct cleanup_index_type<std::integral_constant
#ifndef EIGEN_PARSED_BY_DOXYGEN

template<int N>
EIGEN_DEVICE_FUNC
constexpr internal::FixedInt<N> fix{};
EIGEN_CONSTEXPR EIGEN_DEVICE_CONST
internal::FixedInt<N> fix{};

#else // EIGEN_PARSED_BY_DOXYGEN

Expand Down
2 changes: 1 addition & 1 deletion Eigen/src/Core/util/Macros.h
Original file line number Diff line number Diff line change
Expand Up @@ -842,7 +842,7 @@

// Define compile-time constants for use by both the host and device functions
#if defined(EIGEN_CUDA_ARCH) || defined(EIGEN_HIP_DEVICE_COMPILE)
#define EIGEN_DEVICE_CONST __device__
#define EIGEN_DEVICE_CONST __constant__
#else
#define EIGEN_DEVICE_CONST
#endif
Expand Down

0 comments on commit 47f0a0f

Please sign in to comment.