Expression templates: improving performance in evaluating expressions?
By the expression templates technique, a matrix expression like D = A*B+sin(C)+3.; is pretty much equivalent, in terms of computing performance, to a hand-written for loop. Now, suppose that I have the following two expressions D = A*B+sin(C)+3.; F = D*E; cout << F << "\n"; In a "classical" implementation by expression templates, the computing performance will be pretty much the same as that of two for loops in sequence. This is because the expressions are evaluated immediately after the = operators are encountered. My question is: is there any technique (for example, using placeholders?) to