Re: [eigen] aliasing system |
[ Thread Index | Date Index | More lists.tuxfamily.org/eigen Archives ]
On Friday 07 September 2007 10:44:18 Andre Krause wrote: > >> The point of my example with rows was that if we want to determine if > >> rows/columns/blocks/minors overlap in memory, we're trying to do > >> something that can't be done at compile-time (because the arguments that > >> you pass to these functions is not necessary a compile-time constant). > >> Hence that will have a cost, and if you want to handle all cases it'll > >> be a big cost (you'll have to check for each entry in the matrix if > >> overlapping occurs at that entry). > BUT i still would insist to have that check in _DEBUG mode only at > runtime ! if it is possible without too much coding. it is very > important to be able to somehow know that my code does what i assume it > to do. and newbies and those who usually skip the FAQ and DOCs will be > faced with strange errors if they try what seems to be a naturally > equation: m=m*m. OK, seems like a good idea. I'll try to do it. > > but i have another idea: Umm, no. The expression templates are not just an optimization, they are the central building block and the API would not be possible without them. Without expression templates there is no way that we could allow adding one row into another one by doing matrix.xpr().row(0) += matrix.row(1). So it's not possible to add/remove Ets depending on an ifdef. Cheers, Benoit
Attachment:
signature.asc
Description: This is a digitally signed message part.
Mail converted by MHonArc 2.6.19+ | http://listengine.tuxfamily.org/ |