(Ah, “performant.” I used that word the other day while talking to my boss, and he wondered if I had made it up. It’s not actually a word, and most people talking about it on the Internet don’t seem to like it very much, but it works for me. I knew immediately what it was getting at – “having high performance,” basically. I wonder how long it will take to make it into the dictionary…)
Rico Mariani’s session was mostly about performance improvements to the .NET Framework 2.0. He talked about improvements to “ngen,” which should be good news for the startup time of client applications. He talked about “generic” collections – and warned against creating too many collection types that store less than 500 value type items. He talked about how “foreach” should now always be the optimal way to enumerate a collection. Garbage collection is faster, and it’s okay to call GC.Collect after the user does something that causes “mass extinction” of objects. Throwing exceptions is faster – though still discouraged for normal flow control. Security is faster, particularly for “full trust” applications. Reflection is faster – good news for users of custom attributes. Profiling is better. Delegates are faster. String hashing is faster. Et cetera. Basically, to “write performant managed code,” use the latest .NET Framework.