
Joel Falcou wrote:
troy d. straszheim a écrit :
That's the point... you can't do that here. The elements behind A B and C are on the other end of a very slow bus.
That wasn't clear, sorry. What kind of slow bus ?
A bus that has an CUDA-capable video card on the other end. Transforms fire CUDA kernels that do the math. Before I started playing with a c++0x capable compiler, I dealt with by putting 'rvalueness' into the type system. This works with proto expression templates: template <typename T, typename IsRValue = mpl::false_> class array : public Expression<bp::terminal<array_impl<T, IsRValue> > > { // ... transforms return array_impl<T, mpl::true_>, and later transforms can tell that their arguments are reusable. It works fine, though it is arguably ugly, and as eric points out, this isn't what expression templates are 'for'. Anyhow, the other day I decided to see if I could make those extra template parameters go away via rvalue refs </chase_own_tail> -t