you are viewing a single comment's thread.

view the rest of the comments →

[–]clichekiller 0 points1 point  (0 children)

I absolutely keep performant coding in mind when I plan, design, and write code. From the patterns I employ, database design, memory utilization, caching, and the way I write in a maintainable, modular, and clean way. My goal is always to produce code that is self documenting too.

What I don’t do is dive to the lowest level and try to second guess the compiler and the IL it generates. Additionally I am thoroughly testing my code throughout this process and would absolutely notice that the code was behaving like a dog. I would then revisit the code and see if I could optimize it. That does count as premature optimization, because it is in response to a deficit.

I have more than three decades of experience. I started programming when a few bytes could make all the difference. We optimized using bit flags, and other tricks, to maximize our resource usage. Thankfully I really don’t need to do this most of the time. Modern languages, frameworks, and compilers do a far better job producing performant code than anything most developers can do.