Re: [eigen] Calls to copyPacketByOuterInner: when do they happen?

[ Thread Index | Date Index | More Archives ]

On 25.11.2013 17:32, Christoph Hertzberg wrote:
> On 25.11.2013 16:25, Martin Felis wrote:

> Does it need 20% more time per call or is it called 20% more often?
> Neither of that would account for a performance decrease by 50%.

It's a bit tricky to say as it's a sampling based profiler, however I
have used 2 million function calls for each method (corresponding do
~2200/~3800 samples) so I guess it should correspond to the amount of
time spent in this function.

> I doubt that you want to "avoid" calling copyPacketByOuterInner, since
> it is usually the fastest method of copying/evaluating.
> I guess the problem is rather that you do some extra computations in
> some cases.

Okay, thanks!

> I don't really understand what's the purpose of
> #ifdef EIGEN_CORE_H
> in your code. This will always be true if you have Eigen included -- or
> does your code run with alternate matrix libraries? Do you need the
> .eval() where they are used? Unnecessary evals could account for some
> unnecessary copy operations.

You are referring to the function ForwardDynamics() that is slower, too,
but wanted to analyse the simpler InverseDynamics() first.

And yes I am using another library (SimpleMath) that is compatible to
Eigen for my use but compiles considerably faster. I mainly use it
during development. The profiling was however done using Eigen3 3.0.5
provided by Ubuntu 12.04.

Other than that the .eval() call is required. At least otherwise I get a
compile error.

> Could you link to a diff between the two versions which you profiled?
> Maybe something obvious pops out.

I have attached the profiling outputs. Any comments highly welcome.

> Finally, I'm sorry for asking the obvious question:
> Do you compile with optimization enabled (Release or RelWithDebug mode
> in cmake)? Otherwise Eigen spends a lot of time in methods that should
> be completely unrolled and inlined.

Absolutely a valid question! Everything is done in Release mode (-O3


mail  : martin.felis@xxxxxxxxxxxxxxxxxxxxx
phone : +49 6221 544983
office: IWR | Speyerer Str 6 | Room 319 | 69115 Heidelberg | Germany

Attachment: new_spherical_joint.pdf
Description: Adobe PDF document

Attachment: old_spherical_joint.pdf
Description: Adobe PDF document

Mail converted by MHonArc 2.6.19+