Skip to content

Bundled Eigen is broken for Darwin PowerPC: either update to a newer version or at least disable Altivec for Darwin #78

@barracuda156

Description

@barracuda156

Upstream eigen has merged a fix for Darwin PowerPC quite some time ago, AFAIK it should work, at least I use devel branch for building ports and nothing so far fails. However Boom uses, apparently, quite old eigen, which breaks the build, since unsupported VSX instructions are pulled in.

A quick-n-dirty fix will be disabling Altivec/VSX like this:

--- inst/include/Eigen/Core	2023-12-18 01:53:40.000000000 +0800
+++ inst/include/Eigen/Core	2023-12-19 02:58:58.000000000 +0800
@@ -206,7 +206,7 @@
   #include "src/Core/arch/SSE/TypeCasting.h"
   #include "src/Core/arch/SSE/MathFunctions.h"
   #include "src/Core/arch/SSE/Complex.h"
-#elif defined(EIGEN_VECTORIZE_ALTIVEC) || defined(EIGEN_VECTORIZE_VSX)
+#elif (defined(EIGEN_VECTORIZE_ALTIVEC) || defined(EIGEN_VECTORIZE_VSX)) && !defined(__APPLE__)
   #include "src/Core/arch/AltiVec/PacketMath.h"
   #include "src/Core/arch/AltiVec/MathFunctions.h"
   #include "src/Core/arch/AltiVec/Complex.h"
@@ -346,7 +346,7 @@
 #include "src/Core/CoreIterators.h"
 #include "src/Core/ConditionEstimator.h"
 
-#if defined(EIGEN_VECTORIZE_ALTIVEC) || defined(EIGEN_VECTORIZE_VSX)
+#if (defined(EIGEN_VECTORIZE_ALTIVEC) || defined(EIGEN_VECTORIZE_VSX)) && !defined(__APPLE__)
   #include "src/Core/arch/AltiVec/MatrixProduct.h"
 #elif defined EIGEN_VECTORIZE_NEON
   #include "src/Core/arch/NEON/GeneralBlockPanelKernel.h"

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions