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

understanding generated code

Tags: None
(comma "," separated)
jpritikin
Registered Member
Posts
4
Karma
0

understanding generated code

Thu May 01, 2014 7:13 am
There are various disturbing warnings in the Eigen documentation about details that I barely understand like automatic temporaries, aliasing, and (lack of) optimization. How can I get a detailed understanding of the code generated by Eigen so I can be sure that I am not doing something stupid? Surely there is a better way than looking at the generated assembly output?
User avatar
ggael
Moderator
Posts
3447
Karma
19
OS

Re: understanding generated code

Thu May 01, 2014 7:36 am
To track memory allocation, you can compile with EIGEN_RUNTIME_NO_MALLOC and then put Eigen::set_is_malloc_allowed(false) before an expression for which you assume that there should not be any temps, but you're unsure. For small fixed size matrices, best is to look at the assembly. We cannot fully control what the compiler does.


Bookmarks



Who is online

Registered users: Baidu [Spider], Bing [Bot], Google [Bot], rblackwell