Re: MPL compilation speed trade-offs...

My advice: use the MPL constructs and optimize later. When you're done you can measure the compilation speed difference when using mpl::plus, minus and divides vs. the ugly version at the bottom. I bet you dollars to donuts that it's not a significant hit. But if it is, you can make some informed choices.
Believe me, I'm better known for premature pessimization then premature optimization. It's no longer a matter of compilation times (I can live with that), but a matter of the compiler no longer being able to handle it (running out of memory, out of keys, etcetera). I've tried many other things first (/Zm, splitting up source files, etcetera), but I'm beginning to believe that meta-C++ is just not quite ready for the algorithmic complexity of some of my meta-code. I've started reaching for the preprocessor a lot lately, and I'm now writing a blend of template code and preprocessor code that is quite elegant, albeit completely unreadable ;). It does compile a lot faster fortunately. Thanks, Jaap Suter
participants (1)
-
Jaap Suter