From: Tobias Schwinger (tschwinger_at_[hidden])
Date: 2008-01-03 12:41:22
Larry Evans wrote:
> The attachment contains an alternative which uses no preprocessing.
> It uses more memory because of the static fun_vec in:
> However, it would probably use less code because of no preprocessor
> generated switch statements. OTOH, it would be slower because
> the function has to be looked up in the vector.
> Are there any other comparisons you can think of. It would be
> useful to outline the pro's and cons of alternative implementations
> you've considered.
We actually very much want a preprocessor-generated 'switch' statement
because it is a special hint for optimization and most compilers
generate very efficient code for it...
Boost list run by bdawes at acm.org, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk