Our tech blog has moved!

More news, tips, and stories on our brand new Tech Blog!

Code

  • October 17, 2018

    .NET Threadpool starvation, and how queuing makes it worse

    There has been plenty of talk lately about threadpool starvation in .NET: https://blogs.msdn.microsoft.com/vancem/2018/10/16/diagnosing-net-core-threadpool-starvation-with-perfview-why-my-service-is-not-saturating-all-cores-or-seems-to-stall https://blogs.msdn.microsoft.com/vsoservice/?p=17665 or even on our own blog: https://labs.criteo.com/2018/09/monitor-finalizers-contention-and-threads-in-your-application/ What is it about? This is one of the numerous ways asynchronous code can break if you wait synchronously on a... Read More

  • May 22, 2018

    Extending the new WinDbg, Part 3 – Embedding a C# interpreter

    In part 1 and part 2, we’ve seen in detail how to customize the WinDBG UI as we see fit. This time, we’ll apply this knowledge to cover a very specific use-case: running C# code as script directly inside of... Read More

  • November 3, 2017

    ClrMD Part 8 – Spelunking inside the .NET Thread Pool

    This post of the series shows how to easily list pending tasks and work items managed by the .NET thread pool using DynaMD proxies. Part 1: Bootstrap ClrMD to load a dump. Part 2: Find duplicated strings with ClrMD heap... Read More

  • September 6, 2017

    Extending the new WinDbg, Part 1 – Buttons and commands

    This article is the first of a three-parts series on how to extend the new Windows 10 WinDbg app in order to make your .NET debugging easier and faster. In the first part of the series, you are going to... Read More

  • August 28, 2017

    ClrMD Part 7 – Manipulate nested structs using dynamic

    In the previous post of the ClrMD series, we’ve seen how to use dynamic to manipulate objects from a memory dump the same way as you would with actual objects. However, the code we wrote was limited to class instances.... Read More

  • August 1, 2017

    ClrMD Part 6 – Manipulate memory structures like real objects

    This sixth post of the ClrMD series details how to make object fields navigation simple with C# like syntax thanks to the dynamic infrastructure. The associated code is part of the DynaMD library and is available on GitHub and nuget.... Read More

  • June 29, 2017

    ClrMD Part 5 – How to use ClrMD to extend SOS in WinDBG

    This fifth post of the ClrMD series shows how to leverage this API inside a WinDBG extension. The associated code allows you to translate a task state into a human readable value. Part 1: Bootstrap ClrMD to load a dump. Part... Read More

  • May 31, 2017

    ClrMD Part 4 – What callbacks are called by my timers?

    This fourth post of the ClrMD series digs into the details of figuring out which method gets called when a timer triggers. The associated code lists all timers in a dump. Part 1: Bootstrapping ClrMD to load a dump. Part... Read More

  • May 3, 2017

    ClrMD Part 3 – Dealing with static and instance fields to list timers

    This third post of the ClrMD series focuses on how to retrieve value of static and instance fields by taking timers as an example. The next post will dig into the details of figuring out which method gets called when... Read More

  • April 6, 2017

    RyuJIT and the never-ending ThreadAbortException

    When you see this, you know for sure that something is wrong with a server: This chart counts the number of first-chance exceptions thrown by the server.  We have here an average of 840K exceptions thrown per minute, or 14K... Read More

  • March 24, 2017

    ClrMD Part 2 – From ClrRuntime to ClrHeap or how to traverse the managed heap

    This second post in the ClrMD series details the basics of parsing the CLR heaps. The associated code checks string duplicates as sample. Part 1: Bootstrapping ClrMD to load a dump. From ClrRuntime to ClrHeap or how to traverse the... Read More

  • February 21, 2017

    ClrMD Part 1 – Going beyond SOS

    A little bit of context Thousands of servers are closely monitored at Criteo and when inconsistent behaviors are detected, an investigation is started based on these deviant machines. The level of details provided by the monitoring is close to what... Read More