Re: [eigen] Eigen "views" |
[ Thread Index |
Date Index
| More lists.tuxfamily.org/eigen Archives
]
- To: eigen@xxxxxxxxxxxxxxxxxxx
- Subject: Re: [eigen] Eigen "views"
- From: Benoit Jacob <jacob.benoit.1@xxxxxxxxx>
- Date: Tue, 16 Aug 2011 11:01:33 -0400
- Dkim-signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :content-type; bh=Ih2ueZalvFlYRX8HzQOBpUwcS20tInQTQ9bdyc3689Y=; b=AllMiQbxfOlyQUMOCMjrV2tfzg+cpIWppfpS0AdyhtF8YgBjEAoV0NkeIPlRJBDS/m JU85a2z/19kJxLWP1T0ggbQRdygOo9ClPU5DTLSZZeLiE5B1PXa1ZD9vRa3I6tUtch3i H4tPp3tuYNDbf9RenikKUnHEgKhWkDNo7TlbQ=
2011/8/16 Jose Luis Blanco <joseluisblancoc@xxxxxxxxx>:
> I would be also quite interesting in this feature, but... shouldn't it
> come at the cost of losing vectorization optimizations?
For sure, this feature would be tricky to vectorize. I'd not worry
about this at first and just do a non-vectorized version. Then, a
vectorized version could be made where the packet() method fetches the
4 (or 2) scalars independently and loads them into a xmm packet, but
it could be that the loss of memory locality when iterating over
packets offsets the benefits of vectorization. This would have to be
benchmarked.
Cheers,
Benoit
> Or are the inner workings of Eigen such smart that would dynamically
> build SSE "packets", etc.?
>
> Cheers,
> JL
>
> On Tue, Aug 16, 2011 at 3:10 PM, Christoph Hertzberg
> <chtz@xxxxxxxxxxxxxxxxxxxxxxxx> wrote:
>> On 16.08.2011 15:07, Christoph Hertzberg wrote:
>>>
>>> On 16.08.2011 08:48, Gael Guennebaud wrote:
>>>>
>>>> [...]
>>>>
>>>> m2 = m1(indices1,indices2);
>>>> m2 = m1(Eigen::All,indices2);
>>>> m2 = m1(indices1,Eigen::All);
>>>
>>> Yes, I think this looks as close as one can get to Matlab-syntax (not
>>> that this is a requirement, but it's definitely not a bad thing).
>>
>> You could even make m1(i, indices) return a row-vector etc ...
>>
>>>
>>> Christoph
>>>
>>
>>
>
> --
> ___________________________________________________________
>
> Dr. Jose-Luis Blanco-Claraco
> Dpt. Ing. Civil, Mat. y Fabric - Phone: +34 951 952435
> E.T.S.I. Industriales - Despacho 2.037
> Universidad de Malaga - Campus Universitario de Teatinos
> 29071 Malaga, Spain
> https://sites.google.com/site/jlblancosite/
> ___________________________________________________________
>
>
>