Memory allocation is the root of all evil, part 2: Rust

A previous article illustrated how algorithms written in naïve C# can easily underperform due to being sloppy with memory allocations. It is a common assumption for engineers moving from the .NET world to the Rust world that this problem is automatically solved by Rust because "Rust is more efficient". Alas, this is not the case. … Continue reading Memory allocation is the root of all evil, part 2: Rust

You do not need multithreading to do more than one thing at a time

As hardware gets faster and more capable, software keeps getting slower. It is remarkable how inefficiently typical apps use the capabilities of modern processors! Often this means an app is doing only one thing at a time when it could do multiple things simultaneously, even on a single thread. This article explores a technique for … Continue reading You do not need multithreading to do more than one thing at a time

Does Rust have an advantage if memory-safety is not an advantage?

Rust is best known for its memory safety features. At the same time, most web services today are already built using memory-safe languages such as Java, Python, Go or C#. Are there still compelling reasons to use Rust when the competing language is equally memory-safe? Perhaps there is a performance difference? Let's test the hypothesis … Continue reading Does Rust have an advantage if memory-safety is not an advantage?

Memory allocation is the root of all evil

Most production code is written without its performance being a goal, using "typical" coding patterns for different languages. These patterns tend to be exemplified in articles, official documentation and tutorials. Typical code allows you to get things done rapidly by making use of powerful and flexible language features and APIs. However, typical code is not … Continue reading Memory allocation is the root of all evil