Boost logo

Boost :

Subject: Re: [boost] different matrix library?
From: joel (joel.falcou_at_[hidden])
Date: 2009-08-14 13:32:39


DE wrote:
> looks smart and tricky but i don't see any advantages over computed
> indeces but only wasted spaces and time (for allocating additiona storage for pointers)
>
This si a trade-off. Beware that's only the allocating is slightly
slower as the malloc itslef takes more time than the small loop.
> at the same time dereferencing a pointer is like computing an index
Look at generated assembly and you'll see what happen.
At worst it's the same. At best, it replace all the idnex computation by
a single LEA on INTEL.
Also, it ease writing code that need to deal with multiple idnex.

Index computation with dim > 2 becomes impractical when you ned to do
thign like extarcting non rectangular area or doing tile blocking.

-- 
___________________________________________
Joel Falcou - Assistant Professor
PARALL Team - LRI - Universite Paris Sud XI
Tel : (+33)1 69 15 66 35

Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk