alloca is not necessarily alligned on windows

(grafted from 97965dde9bc079d042d3c4037e1927bee0df443f
)
This commit is contained in:
Gael Guennebaud 2014-02-14 00:04:38 +01:00
parent 9a09b75df3
commit fd96ff166d

View File

@ -578,7 +578,7 @@ template<typename T> class aligned_stack_memory_handler
*/ */
#ifdef EIGEN_ALLOCA #ifdef EIGEN_ALLOCA
#ifdef __arm__ #if defined(__arm__) || defined(_WIN32)
#define EIGEN_ALIGNED_ALLOCA(SIZE) reinterpret_cast<void*>((reinterpret_cast<size_t>(EIGEN_ALLOCA(SIZE+16)) & ~(size_t(15))) + 16) #define EIGEN_ALIGNED_ALLOCA(SIZE) reinterpret_cast<void*>((reinterpret_cast<size_t>(EIGEN_ALLOCA(SIZE+16)) & ~(size_t(15))) + 16)
#else #else
#define EIGEN_ALIGNED_ALLOCA EIGEN_ALLOCA #define EIGEN_ALIGNED_ALLOCA EIGEN_ALLOCA