Learn the secrets of excellent .NET performance with insightful, detailed, and clear explanations. Do you want your .NET code to have the absolute best performance it can? With concision and clarity, this book demystifies the CLR, teaching you how and why to write code with optimum performance. Learn critical lessons from a person who helped design and build one of the largest high-performance .NET systems in the world.
This book does not just teach you how the CLR works—it teaches you exactly what you need to do now to obtain the best performance today. It will expertly guide you through the nuts and bolts of extreme performance optimization in .NET, complete with in-depth examinations of CLR functionality, free tool recommendations and tutorials, useful anecdotes, and step-by-step guides to measure and improve performance.
Among the topics you will learn are how to:
• Choose what to measure and why
• Use many amazing tools, freely available, to solve problems quickly
• Understand the .NET garbage collector and its effect on your application
• Use effective coding patterns that lead to optimal garbage collection performance
• Diagnose common GC-related issues
• Reduce costs of JITting
• Use multiple threads sanely and effectively, avoiding synchronization problems
• Know which .NET features and APIs to use and which to avoid
• Use code generation to avoid performance problems
• Measure everything and expose hidden performance issues
• Instrument your program with performance counters and ETW events
• Use the latest and greatest .NET features
• Ensure your code can run on mobile devices without problems
• Build a performance-minded team
…and much more.
About the Author
Ben Watson has been a software engineer at Microsoft since 2008. On the Bing platform team, he has built one of the world's leading .NET-based, high-performance server applications, handling high-volume, low-latency requests across thousands of machines for millions of customers. In his spare time, he enjoys geocaching, books of all kinds, classical music, and spending time with his family. He is also the author of the book C# 4.0 How-To, published by Sams.