From 3c512d6a4ffaa40169b9a2a2aa24ef27ef03a8a0 Mon Sep 17 00:00:00 2001 From: Frank Dellaert Date: Sat, 4 Feb 2023 23:38:25 -0800 Subject: [PATCH] Sidestep alignment issue by using 16 (default for Eigen). --- gtsam/nonlinear/internal/ExecutionTrace.h | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/gtsam/nonlinear/internal/ExecutionTrace.h b/gtsam/nonlinear/internal/ExecutionTrace.h index ccba89dda..d65c99880 100644 --- a/gtsam/nonlinear/internal/ExecutionTrace.h +++ b/gtsam/nonlinear/internal/ExecutionTrace.h @@ -18,11 +18,6 @@ #pragma once -// The MSVC compiler insists on knowing extended alignment is ok. -#ifdef _MSC_VER -#define _ENABLE_EXTENDED_ALIGNED_STORAGE -#endif - #include // Configuration from CMake #include #include @@ -42,7 +37,7 @@ template struct CallRecord; /// Storage type for the execution trace. /// It enforces the proper alignment in a portable way. /// Provide a traceSize() sized array of this type to traceExecution as traceStorage. -static const unsigned TraceAlignment = 32; +static const unsigned TraceAlignment = 16; // 16 bytes is the default alignment used by Eigen. typedef std::aligned_storage<1, TraceAlignment>::type ExecutionTraceStorage; template