Awhile back (http://listengine.tuxfamily.org/lists.tuxfamily.org/eigen/2009/09/msg00280.html)there was some discussion of automatically transforming a*b.transpose()*c into the equivalent (and faster) a*b.dot(c). A quick test 3.0.3 shows the latter expression being appreciably faster than the former at -O3 using the (admittedly lousy) benchmark Eigen::Vector3d a, b, c, d; for (unsigned long i = 0; i < 1000000; ++i) { grvy_timer_begin("Outer"); a.setRandom(); b.setRandom(); c.setRandom(); d = a*b.transpose()*c; grvy_timer_end("Outer"); grvy_timer_begin("Dot"); a.setRandom(); b.setRandom(); c.setRandom(); d = a*b.dot(c); grvy_timer_end("Dot"); } Very, very low priority. Just wanted to capture it as an issue. - Rhys
The expression evaluator (bug 99) should make this kind of optimizations possible.
-- GitLab Migration Automatic Message -- This bug has been migrated to gitlab.com's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.com/libeigen/eigen/issues/371.