This forum has been archived. All content is frozen. Please use KDE Discuss instead.

Compiling default branch with MKL

Tags: None
(comma "," separated)
matthewlai
Registered Member
Posts
10
Karma
0

Compiling default branch with MKL

Tue May 05, 2015 11:31 pm
Hello!

I have just upgraded from 3.2.4 to Hg default for AVX support, and noticed that compiling with MKL no longer works (OSX 10.10, ICC 15.0.3). I don't actually need it anymore now that Eigen has AVX and has similar performance to MKL for my application ( ;D), so I'm only posting this in case it wasn't already known.

Code: Select all
#include <Eigen/Core>

int main() {}


Code: Select all
icc -DEIGEN_USE_MKL_ALL -g -std=c++11 -L/opt/intel/mkl/lib -I/opt/intel/mkl/include -I. -lpthread -fast test2.cpp -lm -mkl=sequential
In file included from ./Eigen/Core(298),
                 from test2.cpp(1):
./Eigen/src/Core/arch/AVX/MathFunctions.h(15): warning #47: incompatible redefinition of macro "_mm256_setr_m128" (declared at line 1558 of "/usr/bin/icc-15.0-base/compiler/include/immintrin.h")
  #define _mm256_setr_m128(lo, hi) \
          ^

In file included from ./Eigen/Core(416),
                 from test2.cpp(1):
./Eigen/src/Core/products/GeneralMatrixVector_MKL.h(51): error: constant "LhsStorageOrder" is not a type name
    general_matrix_vector_product<Index,LhsScalar,LhsStorageOrder,ConjugateLhs,RhsScalar,ConjugateRhs,BuiltIn> {};
                                                  ^

In file included from ./Eigen/Core(416),
                 from test2.cpp(1):
./Eigen/src/Core/products/GeneralMatrixVector_MKL.h(51): error: type name is not allowed
    general_matrix_vector_product<Index,LhsScalar,LhsStorageOrder,ConjugateLhs,RhsScalar,ConjugateRhs,BuiltIn> {};
                                                                               ^

In file included from ./Eigen/Core(416),
                 from test2.cpp(1):
./Eigen/src/Core/products/GeneralMatrixVector_MKL.h(51): error: constant "ConjugateRhs" is not a type name
    general_matrix_vector_product<Index,LhsScalar,LhsStorageOrder,ConjugateLhs,RhsScalar,ConjugateRhs,BuiltIn> {};
                                                                                         ^

In file included from ./Eigen/Core(416),
                 from test2.cpp(1):
./Eigen/src/Core/products/GeneralMatrixVector_MKL.h(51): error: constant "Eigen::BuiltIn" is not a type name
    general_matrix_vector_product<Index,LhsScalar,LhsStorageOrder,ConjugateLhs,RhsScalar,ConjugateRhs,BuiltIn> {};
                                                                                                      ^

In file included from ./Eigen/Core(416),
                 from test2.cpp(1):
./Eigen/src/Core/products/GeneralMatrixVector_MKL.h(51): error: too few arguments for class template "Eigen::internal::general_matrix_vector_product"
    general_matrix_vector_product<Index,LhsScalar,LhsStorageOrder,ConjugateLhs,RhsScalar,ConjugateRhs,BuiltIn> {};
                                                                                                             ^

In file included from ./Eigen/Core(416),
                 from test2.cpp(1):
./Eigen/src/Core/products/GeneralMatrixVector_MKL.h(51): error: not a class or struct name
    general_matrix_vector_product<Index,LhsScalar,LhsStorageOrder,ConjugateLhs,RhsScalar,ConjugateRhs,BuiltIn> {};
    ^

In file included from ./Eigen/Core(416),
                 from test2.cpp(1):
./Eigen/src/Core/products/GeneralMatrixVector_MKL.h(84): error: constant "Eigen::ColMajor" is not a type name
  EIGEN_MKL_GEMV_SPECIALIZE(double)
  ^

In file included from ./Eigen/Core(416),
                 from test2.cpp(1):
./Eigen/src/Core/products/GeneralMatrixVector_MKL.h(84): error: type name is not allowed
  EIGEN_MKL_GEMV_SPECIALIZE(double)
  ^

In file included from ./Eigen/Core(416),
                 from test2.cpp(1):
./Eigen/src/Core/products/GeneralMatrixVector_MKL.h(84): error: too few arguments for class template "Eigen::internal::general_matrix_vector_product"
  EIGEN_MKL_GEMV_SPECIALIZE(double)
  ^

In file included from ./Eigen/Core(416),
                 from test2.cpp(1):
./Eigen/src/Core/products/GeneralMatrixVector_MKL.h(85): error: constant "Eigen::ColMajor" is not a type name
  EIGEN_MKL_GEMV_SPECIALIZE(float)
  ^

In file included from ./Eigen/Core(416),
                 from test2.cpp(1):
./Eigen/src/Core/products/GeneralMatrixVector_MKL.h(85): error: type name is not allowed
  EIGEN_MKL_GEMV_SPECIALIZE(float)
  ^

In file included from ./Eigen/Core(416),
                 from test2.cpp(1):
./Eigen/src/Core/products/GeneralMatrixVector_MKL.h(85): error: too few arguments for class template "Eigen::internal::general_matrix_vector_product"
  EIGEN_MKL_GEMV_SPECIALIZE(float)
  ^

In file included from ./Eigen/Core(416),
                 from test2.cpp(1):
./Eigen/src/Core/products/GeneralMatrixVector_MKL.h(86): error: constant "Eigen::ColMajor" is not a type name
  EIGEN_MKL_GEMV_SPECIALIZE(dcomplex)
  ^

In file included from ./Eigen/Core(416),
                 from test2.cpp(1):
./Eigen/src/Core/products/GeneralMatrixVector_MKL.h(86): error: type name is not allowed
  EIGEN_MKL_GEMV_SPECIALIZE(dcomplex)
  ^

In file included from ./Eigen/Core(416),
                 from test2.cpp(1):
./Eigen/src/Core/products/GeneralMatrixVector_MKL.h(86): error: too few arguments for class template "Eigen::internal::general_matrix_vector_product"
  EIGEN_MKL_GEMV_SPECIALIZE(dcomplex)
  ^

In file included from ./Eigen/Core(416),
                 from test2.cpp(1):
./Eigen/src/Core/products/GeneralMatrixVector_MKL.h(87): error: constant "Eigen::ColMajor" is not a type name
  EIGEN_MKL_GEMV_SPECIALIZE(scomplex)
  ^

In file included from ./Eigen/Core(416),
                 from test2.cpp(1):
./Eigen/src/Core/products/GeneralMatrixVector_MKL.h(87): error: type name is not allowed
  EIGEN_MKL_GEMV_SPECIALIZE(scomplex)
  ^

In file included from ./Eigen/Core(416),
                 from test2.cpp(1):
./Eigen/src/Core/products/GeneralMatrixVector_MKL.h(87): error: too few arguments for class template "Eigen::internal::general_matrix_vector_product"
  EIGEN_MKL_GEMV_SPECIALIZE(scomplex)
  ^

In file included from ./Eigen/Core(426),
                 from test2.cpp(1):
./Eigen/src/Core/Assign_MKL.h(79): error: assign_impl is not a template
    : assign_impl<Derived1, Eigen::CwiseUnaryOp<UnaryOp, Derived2>,Traversal,Unrolling,BuiltIn>
      ^

In file included from ./Eigen/Core(426),
                 from test2.cpp(1):
./Eigen/src/Core/Assign_MKL.h(79): error: not a class or struct name
    : assign_impl<Derived1, Eigen::CwiseUnaryOp<UnaryOp, Derived2>,Traversal,Unrolling,BuiltIn>
      ^

In file included from ./Eigen/Core(426),
                 from test2.cpp(1):
./Eigen/src/Core/Assign_MKL.h(123): error: a template argument list is not allowed in a declaration of a primary template
  EIGEN_MKL_VML_SPECIALIZE_ASSIGN(DefaultTraversal,NoUnrolling)
  ^

In file included from ./Eigen/Core(426),
                 from test2.cpp(1):
./Eigen/src/Core/Assign_MKL.h(124): error: a template argument list is not allowed in a declaration of a primary template
  EIGEN_MKL_VML_SPECIALIZE_ASSIGN(DefaultTraversal,CompleteUnrolling)
  ^

In file included from ./Eigen/Core(426),
                 from test2.cpp(1):
./Eigen/src/Core/Assign_MKL.h(125): error: a template argument list is not allowed in a declaration of a primary template
  EIGEN_MKL_VML_SPECIALIZE_ASSIGN(DefaultTraversal,InnerUnrolling)
  ^

In file included from ./Eigen/Core(426),
                 from test2.cpp(1):
./Eigen/src/Core/Assign_MKL.h(126): error: a template argument list is not allowed in a declaration of a primary template
  EIGEN_MKL_VML_SPECIALIZE_ASSIGN(LinearTraversal,NoUnrolling)
  ^

In file included from ./Eigen/Core(426),
                 from test2.cpp(1):
./Eigen/src/Core/Assign_MKL.h(127): error: a template argument list is not allowed in a declaration of a primary template
  EIGEN_MKL_VML_SPECIALIZE_ASSIGN(LinearTraversal,CompleteUnrolling)
  ^

In file included from ./Eigen/Core(426),
                 from test2.cpp(1):
./Eigen/src/Core/Assign_MKL.h(128): error: a template argument list is not allowed in a declaration of a primary template
  EIGEN_MKL_VML_SPECIALIZE_ASSIGN(InnerVectorizedTraversal,NoUnrolling)
  ^

In file included from ./Eigen/Core(426),
                 from test2.cpp(1):
./Eigen/src/Core/Assign_MKL.h(129): error: a template argument list is not allowed in a declaration of a primary template
  EIGEN_MKL_VML_SPECIALIZE_ASSIGN(InnerVectorizedTraversal,CompleteUnrolling)
  ^

In file included from ./Eigen/Core(426),
                 from test2.cpp(1):
./Eigen/src/Core/Assign_MKL.h(130): error: a template argument list is not allowed in a declaration of a primary template
  EIGEN_MKL_VML_SPECIALIZE_ASSIGN(InnerVectorizedTraversal,InnerUnrolling)
  ^

In file included from ./Eigen/Core(426),
                 from test2.cpp(1):
./Eigen/src/Core/Assign_MKL.h(131): error: a template argument list is not allowed in a declaration of a primary template
  EIGEN_MKL_VML_SPECIALIZE_ASSIGN(LinearVectorizedTraversal,CompleteUnrolling)
  ^

In file included from ./Eigen/Core(426),
                 from test2.cpp(1):
./Eigen/src/Core/Assign_MKL.h(132): error: a template argument list is not allowed in a declaration of a primary template
  EIGEN_MKL_VML_SPECIALIZE_ASSIGN(LinearVectorizedTraversal,NoUnrolling)
  ^

In file included from ./Eigen/Core(426),
                 from test2.cpp(1):
./Eigen/src/Core/Assign_MKL.h(133): error: a template argument list is not allowed in a declaration of a primary template
  EIGEN_MKL_VML_SPECIALIZE_ASSIGN(SliceVectorizedTraversal,NoUnrolling)
  ^

compilation aborted for test2.cpp (code 2)
make: *** [icc] Error 2

Thanks!
Matthew
User avatar
ggael
Moderator
Posts
3447
Karma
19
OS
Thank you for the feddback, yes we are aware that in the devel branch MKL support is completely broken, but we'll fix it only when the internal changes will be stabilised.
matthewlai
Registered Member
Posts
10
Karma
0
Awesome thanks!


Bookmarks



Who is online

Registered users: Bing [Bot], Google [Bot], Yahoo [Bot]