Related Illnesses

 < Day Day Up > 



Premature Optimization is the first major illness presented because it is the most prevalent reason for so many mistakes. Many of the other illnesses given later often have Premature Optimization as their starting point, including one of the other major illnesses: Not Invented Here (NIH) NIH Syndrome is caused by the belief that only you can possibly write code correctly, including code that performs to the level necessary. This belief stems from the incorrect assumption of Premature Optimization that everything must be optimal. Although there are other reasons for NIH Syndrome, understanding Premature Optimization eliminates a major reason and puts you well on your way to preventing NIH Syndrome.

Another illness often driven by Premature Optimization is Complexification. As mentioned earlier, early optimization can be motivated by the desire to find a more interesting algorithm to work with rather than be bored with the simple algorithm. Avoiding Premature Optimization removes one more chance for Complexification to happen. Similar reasoning can apply to Hardcode, although that illness is often motivated by simple laziness.

Premature Optimization is often the cause of Brittle Bones, or fragile software architecture, as the dependencies and intertwined code can lead to an extremely fragile code base. The more optimizations that are made early in development, the more brittle the code becomes. This will soon build up and lead to major problems, usually at just the wrong time. Although avoiding Premature Optimization is only one step to preventing Brittle Bones, it is a very important step. Another causal relationship exists between source code optimization and i, or poor variable naming. Source code optimization is the primary cause of i.

On the reverse side, Myopia or shortsightedness is one of the causes of Premature Optimization. Short-term individual optimizations often get in the way of long-term design and full module optimizations. Remember to always take into account the long-term goals of the project, including performance goals, and consider how short-term decision might cause problems for the longer term.



 < Day Day Up > 



Preventative Programming Techniques. Avoid and Correct Common Mistakes
Preventative Programming Techniques: Avoid and Correct Common Mistakes (Charles River Media Programming)
ISBN: 1584502576
EAN: 2147483647
Year: 2002
Pages: 121
Authors: Brian Hawkins

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net