

Konrad Kokosa
Mirosoft MVP, trainer, consultant
Warsaw, Poland
Actions
Author of the Pro .NET Memory Management book. Programming for over a dozen years, solving performance problems and architectural puzzles in the .NET world, speeding up web applications. Independent consultant, blogger, speaker and fan of Twitter. He also shares his passion as a trainer in the area of .NET, especially about application performance and diagnostics. Microsoft MVP in the Visual Studio and Development Tools category. Co-founder of https://dotnetos.org initiative.
Links
Area of Expertise
Topics
Deep dive into the .NET GC
This talks presents very deep dive into the internals of the .NET GC. After very short and concise introduction for the beginners, a lot of interesting facts will be presented describing internal workings of the GC with the level of details never presented so far. Those include allocations context, heap balancing, plugs and gaps, concurrent marking and sweeping, and so on, and so forth.
Make your custom .NET GC - "whys" and "hows"
Starting with .NET Core 2.1 a new feature called Local GC has been added. It allows you to do magic things - you can completely replace the default GC used by the runtime with your own, or you can use the default GC outside .NET environment. In the session we will look at this possibilities - how and why we can do it. We'll find out exactly where to start writing your own GC and whether it is difficult or not.
ETW to the rescue for .NET developer
We all know how often we need to diagnose our application. Unfortunately, quite often in the most difficult environment - on the production. I would like to present a powerful, though still somewhat underestimated Event Tracing for Windows mechanism, which provides a wealth of information about the operation of your computer, the system and - what is most interesting to us - our .NET applications. And all this completely for free!
Why managed memory is fooling us?
We all have been fooled! They told us that automatic memory management will solve all our problems. In managed worlds like .NET, JVM and others there is no memory leak, they said. You will never need to think about freeing memory manually. There is no need to think about memory management at all, they said. And they all lied!
Automatic memory management is just an abstraction. But like any other abstraction, it is convenient and nice and… it eventually leaks. In the most unpredictable and unpleasant way. No matter what platform or language you use, you are probably a victim of those lies. And while in many popular use cases they just work, I would like to show you some deeper insight.
In this talk, I would like to open your eyes on some low-level stuff that is going inside your computers and servers that execute your production code. Things that influence your code performance. And design patterns that will allow you to write more memory-aware code.
Takeaways:
* automatic memory management is not a silver-bullet - it has its own caveats that we should be aware of
* there are design patterns like Data-Oriented Design that try to leverage memory-awareness and they are perfectly usable in managed runtimes
* not so many people are even aware of how memory works (CPU caches, cache lines, DRAM) while it is really crucial in a performant code to know such details
Ref struct, ref readonly struct, ref returning, ref everything!
Managed pointers, in the form of ref variables, existed in .NET since the very beginning. But only recently they gained much bigger interest - there are such constructs like in parameters, local ref variables and readonly refs. Moreover, recently so-called ref structs were introduced and in the context of Span of T type one could hear of byref-like instance fields. We can hear about those "ref-something" things a lot, but should one really care?
I believe so, as all those changes perfectly fit into the ongoing process of speeding up .NET and its performance possibilities. There is a lot of ways to optimize your code with the conscious use of those constructs, although some caveats exist that we should be aware of. Let me introduce you to such "ref-world"!
High-performance code design patterns in C#
Description: More and more effort is being seen in .NET ecosystem put into the performance. Quite often we are seeing a new benchmark or blog post about memory allocations being reduced or overall throughput is increased. But how all this is achieved? Can any common code patterns be recognized, named and summarized in a modern C#, at the times of C# 8.0 and .NET Core 3.0? Can we provide a kind of Gang Of Four "design patterns" counterpart in the context of performance? As I believe so, in this talk a propose such a list of patterns, altogether with the rationale behind them and practical use cases. Please, feel invited to the world of common ways of using stackallocs, Span of T, pipelines, parallel processing and more.
The War Story - writing a thousand pages technical book
So you want to hear some war stories? Here's one - I was writing a Pro .NET Memory Management book for three years. Three years full of sacrifice, successes, failures, and mistakes. Yes, I've made probably all possible mistakes that can be done when writing your own book - starting from underestimating your possibilities. I've learned a lot about various approaches to organize your work, altogether with various technical less or more important technical details. This was a real war! A war that I like to see as I've won.
If you've ever considered writing your own book, come and listen to how it is. Maybe I'll even discourage you. If you have never considered writing it, please come and listen. Maybe I'll even encourage you! Nevertheless, I'd love to share my experience on this topic.
What’s New in .NET Core 3.0 and .NET 5.0 for Performance and Memory-Aware Folks?
The newest version of the runtime, as well as the C# language itself, brings some very interesting features that are helping in writing high performance, memory-aware code.
Some of those features are working out of the box, without a need to configure anything. Some must be used explicitly. Nevertheless, they all support the ongoing process of making the .NET ecosystem faster and faster. In this talk you will see what exactly those changes bring and how they can help you. For everyone's benefit!

Konrad Kokosa
Mirosoft MVP, trainer, consultant
Warsaw, Poland
Links
Actions
Please note that Sessionize is not responsible for the accuracy or validity of the data provided by speakers. If you suspect this profile to be fake or spam, please let us know.
Jump to top