Quote Originally Posted by wossname
...
Given the task specified ("make this faster"), I'd happily say that a few hours/days spent optimizing a custom algorithm is well worth the effort if the long-term effect is a significant saving in time.
I agree. However, if the requirement is "make this faster" and what is supplied "makes this better" which in turn makes it faster, then the original requirement is met, is easier to understand, and incorporates code reuse/inheritance, blah, blah.

We can go on all day about what will take more time, i.e. using a somewhat complete and generic framework versus writing the framework yourself, in a language this is designed for code reuse, no less. What about maintenance? Will the programmer that inherits this code from you know what your intent was, know how to port the code or maintain it, and will he trust that your algorithm is 0.00001 milliseconds faster than the supplied template? That's your call but you're defeating the purpose of the OOP paradigm and should be programming in C or ASM.