Re: [eigen] matrix::linspace

[ Thread Index | Date Index | More Archives ]

2010/1/27 Hauke Heibel <hauke.heibel@xxxxxxxxxxxxxx>:
> On Tue, Jan 26, 2010 at 10:54 PM, Benoit Jacob <jacob.benoit.1@xxxxxxxxx> wrote:
>> Neither does my approach, once you take it as a partial unrolling. But
>> this approach will certainly decrease performance a lot, due to the
>> higher number of operations. I don't think that we're really in the
>> domain of application of this approach.
> But if I'ld use your approach of partial unrolling that would require
> a new assignment, right? I don't see how to easily incorporate that
> right now and probably you are right, I will skip this 'fancy'
> addition scheme...

Right, that's true, it requires setLinSpaced to have its own loop.
That wouldn't be a first, that doesn't mean adding anything to
Assign.h, you could instead completely decouple the implementation of
setLinSpaced from that of LinSpaced, e.g. forget about the template
parameter to the functor. The functor would be only for LinSpaced
while setLinSpaced would have its own for loop. But yes it's a bit
more code to have a separate loop for setLinSpaced. It's not too bad:
setLinSpaced is only for expressions that have LinearAccessBit, right?
So we're talking about a single for loop, and in the unrolled case, a
single loop unroller.


Mail converted by MHonArc 2.6.19+