Internal compiler error when using matrix multiplication (MSVC 2010)
Submitted by Tobias Jost
Assigned to Nobody
Link to original bugzilla bug (#1564)
Version: 3.3 (current stable)
Operating system: Windows
Created attachment 867
In a project using MSVC 2010 64bit I tried upgrading the previously used Eigen 3.2 installation to a more recent 3.3.1 and 3.3.4 version without much success due to an internal compiler error, citing “msc1.cpp” line 1420 as culprit.
I triaged this problem and simplified the code without a clear indication what goes wrong, but I observed:
- It is triggered by a multiplication of 2 Matrix2d objects.
- It is only triggered when using the overloaded ""-operator, using ".operator()"-syntax is a workaround.
- It is only triggered when initializing the object doing the multiplication as default argument of another function or constructor.
- It is only triggered when Initializing the parent object outside a function/class in global space
- It is only triggered when it is not the first declaration in global space
I attached a small demo. So far MSVC versions >= 2015 don’t seem to be affected but changing the toolchain isn’t an option for me. I went back to Eigen 3.2 for now.
If someone is interested in further examining this bug I’d be happy to provide further details.
Attachment 867, "Demo":