I don't. My primary focus is correctness first, then readability.
Reasons why I don't micro-optimize:
- It takes time, which I don't have a lot of.
- It most likely will negatively impact readability.
- I don't have time to baseline everything I write and then compare that to the optimized version. (If you don't do this, how will you know your code is optimized?) I like to push out optimization until after we have a substantial code base to profile where we can quantify the performance issues.
- Hardware is cheap, developer time is not. A lot of times a simple remedy to a performance issue is to add more nodes/HDs/resources.
- Sometimes performance optimization is not even needed.
- Sometimes the input size of an algorithm/procedure is small.
- For web based applications, the biggest bottleneck is the network I/O, so I would rather put my focus there.
- etc...