Registered Member
|
I define EIGEN_DONT_ALIGN to make Eigen compile with C++/CLI without erroring but there is a miss in Eigen-3.0.2:
1>c:\tools\matrixlib\eigen-eigen-3.0.2\eigen\src\core\products\generalmatrixvector.h(554): error C2472: 'Eigen::internal::general_matrix_vector_product<int,double,1,0,double,0>::run' cannot be generated in managed code: 'Aligned data types not supported in managed code'; compile with /clr to generate a mixed image I am not sure how to fix this issue atm., but there is probably a simple workaround. Also, when specifying EIGEN_DONT_ALIGN shouldn't EIGEN_CPUID remain undefined as it is part of the aligned_allocator class? EIGEN_CPUID is however being set and prevents compilation on C++/CLI. Again, I workaround this by changing: # if (_MSC_VER > 1500) to # if (_MSC_VER > 1600) (my _MSC_VER is 1600). NOTE: The above workaround is of course wrong but was the simplest possible change I could get away with. If I allow unmanaged code (compiletime switch), EIGEN_CPUID may remain defined. |
Registered users: Bing [Bot], Google [Bot], Yahoo [Bot]