From ded9bff79069a80cd41dc9aea4c02bed335cd52f Mon Sep 17 00:00:00 2001
From: Dmitri Naumov <github@naumov.de>
Date: Sun, 6 Aug 2017 23:18:45 +0200
Subject: [PATCH] [PL] Fix alignment of classes using Eigen::Matrix.

---
 ProcessLib/ComponentTransport/ComponentTransportFEM.h           | 2 ++
 ProcessLib/HT/HTFEM.h                                           | 2 ++
 ProcessLib/HydroMechanics/HydroMechanicsProcessData.h           | 2 ++
 .../BoundaryCondition/NeumannBoundaryConditionLocalAssembler.h  | 2 ++
 ProcessLib/LIE/HydroMechanics/HydroMechanicsProcessData.h       | 2 ++
 .../LocalAssembler/IntegrationPointDataFracture.h               | 2 ++
 .../HydroMechanics/LocalAssembler/IntegrationPointDataMatrix.h  | 2 ++
 .../LocalAssembler/IntegrationPointDataFracture.h               | 2 ++
 .../LocalAssembler/IntegrationPointDataMatrix.h                 | 2 ++
 ProcessLib/RichardsFlow/RichardsFlowFEM.h                       | 2 ++
 ProcessLib/SmallDeformation/SmallDeformationFEM.h               | 2 ++
 .../ThermalTwoPhaseFlowWithPPLocalAssembler.h                   | 2 ++
 ProcessLib/ThermoMechanics/ThermoMechanicsFEM.h                 | 2 ++
 ProcessLib/ThermoMechanics/ThermoMechanicsProcessData.h         | 2 ++
 .../TwoPhaseFlowWithPrho/TwoPhaseFlowWithPrhoLocalAssembler.h   | 2 ++
 15 files changed, 30 insertions(+)

diff --git a/ProcessLib/ComponentTransport/ComponentTransportFEM.h b/ProcessLib/ComponentTransport/ComponentTransportFEM.h
index 09ea5a4bc10..e8fa33311e5 100644
--- a/ProcessLib/ComponentTransport/ComponentTransportFEM.h
+++ b/ProcessLib/ComponentTransport/ComponentTransportFEM.h
@@ -40,6 +40,8 @@ struct IntegrationPointData final
     NodalRowVectorType const N;
     GlobalDimNodalMatrixType const dNdx;
     double const integration_weight;
+
+    EIGEN_MAKE_ALIGNED_OPERATOR_NEW;
 };
 
 const unsigned NUM_NODAL_DOF = 2;
diff --git a/ProcessLib/HT/HTFEM.h b/ProcessLib/HT/HTFEM.h
index bf928cb0a57..842d1579e55 100644
--- a/ProcessLib/HT/HTFEM.h
+++ b/ProcessLib/HT/HTFEM.h
@@ -42,6 +42,8 @@ struct IntegrationPointData final
     NodalRowVectorType const N;
     GlobalDimNodalMatrixType const dNdx;
     double const integration_weight;
+
+    EIGEN_MAKE_ALIGNED_OPERATOR_NEW;
 };
 
 const unsigned NUM_NODAL_DOF = 2;
diff --git a/ProcessLib/HydroMechanics/HydroMechanicsProcessData.h b/ProcessLib/HydroMechanics/HydroMechanicsProcessData.h
index ac5618a6b1d..3a29e06c484 100644
--- a/ProcessLib/HydroMechanics/HydroMechanicsProcessData.h
+++ b/ProcessLib/HydroMechanics/HydroMechanicsProcessData.h
@@ -99,6 +99,8 @@ struct HydroMechanicsProcessData
     Eigen::Matrix<double, DisplacementDim, 1> const specific_body_force;
     double dt = 0.0;
     double t = 0.0;
+
+    EIGEN_MAKE_ALIGNED_OPERATOR_NEW;
 };
 
 }  // namespace HydroMechanics
diff --git a/ProcessLib/LIE/BoundaryCondition/NeumannBoundaryConditionLocalAssembler.h b/ProcessLib/LIE/BoundaryCondition/NeumannBoundaryConditionLocalAssembler.h
index 3eff9000f02..6576819c333 100644
--- a/ProcessLib/LIE/BoundaryCondition/NeumannBoundaryConditionLocalAssembler.h
+++ b/ProcessLib/LIE/BoundaryCondition/NeumannBoundaryConditionLocalAssembler.h
@@ -83,6 +83,8 @@ public:
         b.add(indices, _local_rhs);
     }
 
+    EIGEN_MAKE_ALIGNED_OPERATOR_NEW;
+
 private:
     Parameter<double> const& _neumann_bc_parameter;
     typename Base::NodalVectorType _local_rhs;
diff --git a/ProcessLib/LIE/HydroMechanics/HydroMechanicsProcessData.h b/ProcessLib/LIE/HydroMechanics/HydroMechanicsProcessData.h
index e394ad56c2f..5906ac11a7a 100644
--- a/ProcessLib/LIE/HydroMechanics/HydroMechanicsProcessData.h
+++ b/ProcessLib/LIE/HydroMechanics/HydroMechanicsProcessData.h
@@ -150,6 +150,8 @@ struct HydroMechanicsProcessData
     MeshLib::PropertyVector<double>* mesh_prop_fracture_shear_failure = nullptr;
     MeshLib::PropertyVector<double>* mesh_prop_nodal_w = nullptr;
     MeshLib::PropertyVector<double>* mesh_prop_nodal_b = nullptr;
+
+    EIGEN_MAKE_ALIGNED_OPERATOR_NEW;
 };
 
 }  // namespace HydroMechanics
diff --git a/ProcessLib/LIE/HydroMechanics/LocalAssembler/IntegrationPointDataFracture.h b/ProcessLib/LIE/HydroMechanics/LocalAssembler/IntegrationPointDataFracture.h
index 9bab78f2790..b9ca64b5424 100644
--- a/ProcessLib/LIE/HydroMechanics/LocalAssembler/IntegrationPointDataFracture.h
+++ b/ProcessLib/LIE/HydroMechanics/LocalAssembler/IntegrationPointDataFracture.h
@@ -74,6 +74,8 @@ struct IntegrationPointDataFracture final
         w_prev = w;
         sigma_eff_prev = sigma_eff;
     }
+
+    EIGEN_MAKE_ALIGNED_OPERATOR_NEW;
 };
 
 }  // namespace HydroMechanics
diff --git a/ProcessLib/LIE/HydroMechanics/LocalAssembler/IntegrationPointDataMatrix.h b/ProcessLib/LIE/HydroMechanics/LocalAssembler/IntegrationPointDataMatrix.h
index e938893427c..b19854aaa2d 100644
--- a/ProcessLib/LIE/HydroMechanics/LocalAssembler/IntegrationPointDataMatrix.h
+++ b/ProcessLib/LIE/HydroMechanics/LocalAssembler/IntegrationPointDataMatrix.h
@@ -79,6 +79,8 @@ struct IntegrationPointDataMatrix final
         sigma_eff_prev = sigma_eff;
         material_state_variables->pushBackState();
     }
+
+    EIGEN_MAKE_ALIGNED_OPERATOR_NEW;
 };
 
 }  // namespace HydroMechanics
diff --git a/ProcessLib/LIE/SmallDeformation/LocalAssembler/IntegrationPointDataFracture.h b/ProcessLib/LIE/SmallDeformation/LocalAssembler/IntegrationPointDataFracture.h
index ce84d4edfc2..f9526910fb9 100644
--- a/ProcessLib/LIE/SmallDeformation/LocalAssembler/IntegrationPointDataFracture.h
+++ b/ProcessLib/LIE/SmallDeformation/LocalAssembler/IntegrationPointDataFracture.h
@@ -72,6 +72,8 @@ struct IntegrationPointDataFracture final
         _sigma_prev = _sigma;
         _aperture_prev = _aperture;
     }
+
+    EIGEN_MAKE_ALIGNED_OPERATOR_NEW;
 };
 
 }  // namespace SmallDeformation
diff --git a/ProcessLib/LIE/SmallDeformation/LocalAssembler/IntegrationPointDataMatrix.h b/ProcessLib/LIE/SmallDeformation/LocalAssembler/IntegrationPointDataMatrix.h
index f38184d4c6e..e6ea2febf71 100644
--- a/ProcessLib/LIE/SmallDeformation/LocalAssembler/IntegrationPointDataMatrix.h
+++ b/ProcessLib/LIE/SmallDeformation/LocalAssembler/IntegrationPointDataMatrix.h
@@ -53,6 +53,8 @@ struct IntegrationPointDataMatrix final
         _sigma_prev = _sigma;
         _material_state_variables->pushBackState();
     }
+
+    EIGEN_MAKE_ALIGNED_OPERATOR_NEW;
 };
 
 }  // namespace SmallDeformation
diff --git a/ProcessLib/RichardsFlow/RichardsFlowFEM.h b/ProcessLib/RichardsFlow/RichardsFlowFEM.h
index 08c61797ef3..c21934444c9 100644
--- a/ProcessLib/RichardsFlow/RichardsFlowFEM.h
+++ b/ProcessLib/RichardsFlow/RichardsFlowFEM.h
@@ -47,6 +47,8 @@ struct IntegrationPointData final
     GlobalDimNodalMatrixType const dNdx;
     double const integration_weight;
     NodalMatrixType const mass_operator;
+
+    EIGEN_MAKE_ALIGNED_OPERATOR_NEW;
 };
 const unsigned NUM_NODAL_DOF = 1;
 
diff --git a/ProcessLib/SmallDeformation/SmallDeformationFEM.h b/ProcessLib/SmallDeformation/SmallDeformationFEM.h
index b89809c8e8e..801ee1756a8 100644
--- a/ProcessLib/SmallDeformation/SmallDeformationFEM.h
+++ b/ProcessLib/SmallDeformation/SmallDeformationFEM.h
@@ -61,6 +61,8 @@ struct IntegrationPointData final
         sigma_prev = sigma;
         material_state_variables->pushBackState();
     }
+
+    EIGEN_MAKE_ALIGNED_OPERATOR_NEW;
 };
 
 /// Used by for extrapolation of the integration point values. It is ordered
diff --git a/ProcessLib/ThermalTwoPhaseFlowWithPP/ThermalTwoPhaseFlowWithPPLocalAssembler.h b/ProcessLib/ThermalTwoPhaseFlowWithPP/ThermalTwoPhaseFlowWithPPLocalAssembler.h
index fe07bb3dbd5..8aba89166ed 100644
--- a/ProcessLib/ThermalTwoPhaseFlowWithPP/ThermalTwoPhaseFlowWithPPLocalAssembler.h
+++ b/ProcessLib/ThermalTwoPhaseFlowWithPP/ThermalTwoPhaseFlowWithPPLocalAssembler.h
@@ -50,6 +50,8 @@ struct IntegrationPointData final
     double const integration_weight;
     NodalMatrixType const mass_operator;
     NodalMatrixType const diffusion_operator;
+
+    EIGEN_MAKE_ALIGNED_OPERATOR_NEW;
 };
 const unsigned NUM_NODAL_DOF = 3;
 
diff --git a/ProcessLib/ThermoMechanics/ThermoMechanicsFEM.h b/ProcessLib/ThermoMechanics/ThermoMechanicsFEM.h
index dd85ee6c7a3..f01984566ec 100644
--- a/ProcessLib/ThermoMechanics/ThermoMechanicsFEM.h
+++ b/ProcessLib/ThermoMechanics/ThermoMechanicsFEM.h
@@ -87,6 +87,8 @@ struct IntegrationPointData final
 
         return C;
     }
+
+    EIGEN_MAKE_ALIGNED_OPERATOR_NEW;
 };
 
 /// Used by for extrapolation of the integration point values. It is ordered
diff --git a/ProcessLib/ThermoMechanics/ThermoMechanicsProcessData.h b/ProcessLib/ThermoMechanics/ThermoMechanicsProcessData.h
index 5729a546cf5..5ac1bb4210a 100644
--- a/ProcessLib/ThermoMechanics/ThermoMechanicsProcessData.h
+++ b/ProcessLib/ThermoMechanics/ThermoMechanicsProcessData.h
@@ -75,6 +75,8 @@ struct ThermoMechanicsProcessData
     Eigen::Matrix<double, DisplacementDim, 1> const specific_body_force;
     double dt;
     double t;
+
+    EIGEN_MAKE_ALIGNED_OPERATOR_NEW;
 };
 
 }  // namespace ThermoMechanics
diff --git a/ProcessLib/TwoPhaseFlowWithPrho/TwoPhaseFlowWithPrhoLocalAssembler.h b/ProcessLib/TwoPhaseFlowWithPrho/TwoPhaseFlowWithPrhoLocalAssembler.h
index b505b7721ed..2e9814c220b 100644
--- a/ProcessLib/TwoPhaseFlowWithPrho/TwoPhaseFlowWithPrhoLocalAssembler.h
+++ b/ProcessLib/TwoPhaseFlowWithPrho/TwoPhaseFlowWithPrhoLocalAssembler.h
@@ -52,6 +52,8 @@ struct IntegrationPointData final
     double integration_weight;
     NodalMatrixType massOperator;
     NodalMatrixType diffusionOperator;
+
+    EIGEN_MAKE_ALIGNED_OPERATOR_NEW;
 };
 const unsigned NUM_NODAL_DOF = 2;
 
-- 
GitLab