Note: This is a first entry of a new series about Microsoft .NET CLR internals. I encourage you to ask – the most interesting questions will become a similar posts in the future! This one was inspired by Angelika Piątkowska.
How does Object.GetType() really work?
Extending this question: How an object knows what type it is? Is it the compiler or the runtime that knows that? How this is related to the CLR? As C# is statically and strongly typed, maybe the method call GetType() does not really exist, and the compiler can replace it with the appropriate result already at compile time?Continue reading
I don’t know if you have a driving license. Even if not, you will surely understand this sublime analogy presented by me. Sometimes, you drive a car and know traffic regulations. You can drive this manner successfully for the whole life. However, if you aim to be a professional driver, an old stager, it takes whole days in a car and sooner or later you get dirty with grease by working with an engine. This is how I see the .NET developer’s life. The vast majority may ride „very well”, knowing the syntax, design patterns, tricks of trade. They are professionals. Yet, there is a small group of geeks, nerds, old stagers, that are looking for something more. They want to understand CLR internals, know how does everything work, how to dig in into memory and how to use raw tools such as WinDbg. I consider this is plainly speaking a mind-absorbing occupation and can draws everybody’s attention, even for a while. The popularity of devWorkshops delivered in Poland by me and Sebastian Solnica confirms this presumption.Continue reading
If you do not have time, there is a little TL;DR for you:
Even if you do not answer and don’t ask questions – REGISTER YOURSELF – thanks to it you can upvote questions/answers, that you find helpful, appreciating time of people that helped you.
I have been active on StackOverflow around tags .NET/C# for some time. As I have reached over 10k points I have decided it’s a good occasion to write various thoughts about this gorgeous site. Here there are, in an order of the most general one to the most detailed. However, it’s hard to classify them precisely so just read and have fun! There are also my findings and pieces of advice how to gain some reputation.Continue reading
Today I would like to walk you through the process of compiling, running and debugging of .NET Core – that is the open source version of .NET environment. Let’s go to the answer to the simple question straight away…
In order to push the boat out. We got the source of .NET! Why do we need to compile it? In order to tamper, change, analyze, damage it – so that in the end up at Pull Request and record ourselves in Hall of Fame as our code will go to millions of computers all over the world!
Even if we don’t have such ambitious plans, isn’t it just fun to look inside .NET? Of course, it’s not the code of commercial .NET in one-to-one relation. However, the most of the inner part is the same, so there is plenty to play with. .NET foundation site states it plainly:Continue reading
Performance matters. Nowadays web performance matters even more – users will easily go and find another website if yours is responding too slowly. And this can be a matter of hundreds of milliseconds only. This directly translates to less money earned, and in fact can be your “be or not to be” on the market. Although performance is so important from a purely business point of view, it is also very interesting from its technical side. Performance is a fun. You have to understand things deeply, you must know specific technology tips and tricks, be aware of common pitfalls. This is all we, geeks, fans, developers, love to know, isn’t it? Have you ever heard about Mechanical Sympathy?Continue reading