Monthly Archives: September 2018

Archive of posts published in the specified Month

Custom memory allocation in C# Part 11 — Benchmarking UnsafeList

This is the eleventh part of the Custom memory allocation series. For your convenience you can find other parts in the table of contents in Part 1 — Allocating object on a stack I presented some results suggesting that UnsafeList is faster than…

Custom memory allocation in C# Part 10 — Hijacking new in .NET Core

This is the tenth part of the Custom memory allocation series. For your convenience you can find other parts in the table of contents in Part 1 — Allocating object on a stack I had .NET Core 2.1.103 x64 installed and I wanted…

Custom memory allocation in C# Part 9 — Hijacking new in x64

This is the ninth part of the Custom memory allocation series. For your convenience you can find other parts in the table of contents in Part 1 — Allocating object on a stack We already hijacked new in C#. Last time we did…

Exception propagation in WinForms

Let’s start with the following code: using System; using System.Windows.Forms; class Program1 { [STAThread] static void Main() { var form = new Form(); form.Load += (sender, e) => throw new Exception(); try { Application.Run(form); } catch(Exception e) { MessageBox.Show(“This doesn’t execute”); } finally…

Random notes from crashing and hanging EMR Spark job

It sometimes happens that your EMR job crashes or hangs indefinitely with no meaningful log. You can try to capture memory dump but it is not very useful when your cluster machines have hundreds gigabytes of memory each. Below are “fixes” which worked…