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

Explicit vectorization in Eigen, why and how

Tags: None
(comma "," separated)
KlappStuhl
Registered Member
Posts
2
Karma
0
OS
Dear Eigen developers,

I am very impressed by eigens benchmark results posted on the website, congratulations :) !
I myself use blitz++ instead of eigen due to the multidimensionality of my academic simulation
code. Unfortunately blitz++ has fallen behind in performance compared to raw fortran code :'( ,
mainly because blitz++ does not support explicit vectorization like eigen does.
During discussions on blitz++ mailing list, some users claimed that vectorization should by automatically performed by newer intel or gcc versions. I checked the disassembled code of a
blitz++ example code and this is not the case. I guess the same will be true for the eigen code, and thus vectorization was added explicitely into eigen.
Is this the case or why was vectorization added explicitely into eigen ? Also, if somebody here is also familiar with blitz++ and eigen, could somebody give me a good starting point how to implement vectorization into blitz++ ? There are some plans ongoing to relicense blitz++ into LGPLv3+, so some code exchange would also be possible.

Thanks a lot, and keep up the good work,

Paul
User avatar
ggael
Moderator
Posts
3447
Karma
19
OS
Indeed, the compiler can only vectorize some simple specific cases but it will never be able to do it as good as we can because we have more information. Also explicit vectorization is not the only reason that makes Eigen fast, there is also explicit unrolling for small objects, optimized matrix product routines (regarding cache, etc.), etc.

In my opinion it would probably be simpler to build a multidimensional (or tensor) module on top of Eigen, than implementing explicit vectorization into Blitz++.
KlappStuhl
Registered Member
Posts
2
Karma
0
OS
OK, thanks a lot for your reply. I will have a closer look on these issues.


Bookmarks



Who is online

Registered users: bartoloni, Bing [Bot], Evergrowing, Google [Bot], ourcraft