The Syslog Hell
Syslog. You’ve probably heard about that, especially if you are into monitoring or security. Syslog is perceived to be the common, unified way that systems can send logs to otherContinue reading
Latches in C++20
Latches and barriers are coordination types that enable some threads to wait until a counter becomes zero. You can use a std::latch only once, but you can use a std::barrier more than once. Today, I have a closer look at latches.
Pine64 and Radxa's new Pi CM4-compatible boards
Since the Raspberry Pi was introduced, hundreds of clones have adopted the Pi's form factor (from the diminutive Zero to the 'full size' model B). Often they have better hardware specs, and yet they remain a more obscure also-ran in that generation of Single Board Computer (SBC). So when I saw Radxa's CM3 and Pine64's…
Tools to measure software energy consumption from your computer
Measuring the energy consumption of software is far from being a trivial task. This article provides essential details about energy consumption tools, their...
Monterey’s memory leak and how to avoid it
How this memory leak probably occurs, which apps it affects, and what you can do to avoid it completely.
A Dive into Ray Tracing Performance on the Apple M1
The Apple M1 available in the MacBook Air, MacBook Pro 13", and Mac Mini has been the focus of a ton of benchmarking writeups and blog posts about the new chip. The performance overall, and especially performance/watt, that Apple has achieved with the chip is very impressive. As a ray tracing person, what caught my…
Tracking down a segfault that suddenly started happening
I wanted to share a story of a segmentation fault I helped track down this weekend. I thought the final root cause of the segfault was interesting because of how unrelated it was to the code I was trying to debug.
Using NetBSD’s pkgsrc everywhere I can
And why you should too!
Where the top of the stack is on x86 (2011)
I've noticed more than once that some programmers are confused about the direction in which the stack grows on x86, and what "top of the stack" and "bottom of the stack" mean. It appears that this confusion is caused by a basic mismatch in the way people are used to thinking about stacks, and in the way the stack on…
Getting to the bottom of web map performance
mostly 1990s PC gaming
Big problems at the timezone database
The last time I wrote about the timezone database on this blog, the database was under threat from a lawsuit. Fortunately that lawsuit w...
Upgrading a motherboard’s BIOS/UEFI (the hard way)
A couple of weeks ago I found a really good deal on a Socket AM4 motherboard that supports the newest AMD Ryzen CPUs. The motherboard is an ASRock A520M/ac . It’s a very basic motherboard which doesn’t appear to be sold by any of the usual retailers anymore, but I couldn’t pass up on the deal, especially with the…
Bit Patterns of Float
I’ve spent too many hours repeatedly trying to find this information on the Web. Time to write it down.
Demystifying programs that create programs, part 1: A disassembler
People appear to enjoy the blog posts about me porting different compilers to OpenBSD . What I would like to do for the next couple of posts beginning with this one is to take a step back and de-complexify these programs. Both the D compiler and the GNU Modula-2 compiler are highly complex pieces of software. But at…
Performance Showdown: Rust vs Javascript (2020)
After spending some weeks playing with Rust, I felt ready to test my skills and try some programming challenges in the [Advent Of Code](https://adventofcode.com/). My approach to tackle some of those challenges was to solve them using Javascript (I use it in my day to day) first and then port the code to Rust. While…
Increase HTTP performance by fitting in the initial TCP slow start window
Did you know that if your site’s under ~12kb the first page will load significantly faster? Servers only send a few packets (typically 10) in the initial round-trip while TCP is warming up (referred to as TCP slow start). After sending the first set of packets, it needs to wait for the client to acknowledge it…
JVM Anatomy Quark #26: Identity Hash Code
"JVM Anatomy Quarks" is the on-going mini-post series, where every post is describing some elementary piece of knowledge about JVM. The name underlines the fact that the single post cannot be taken in isolation, and most pieces described here are going to readily interact with each other.
Reed-Solomon error recovery in RAID-6
A post describing a simple example how you can create your own manual error recovery solution based on what is used in RAID-6, in Python.
Cranelift, Part 3: Correctness in Register Allocation
This post is the last in a three-part series about Cranelift . In the first post , I covered overall context and the instruction-selection problem; in the second post , I took a deep dive into compiler performance via careful algorithmic design.
Allocgate: Restructuring how allocators work in Zig
Version 0.9 of the Zig programming language is planned to release in about a week. One of the major changes coming in this release is a restructuring of how allocators work, which has been termed Allocgate . This is a breaking change to the Allocator API provided by the standard library, so pretty much any code that…
When can glibc be built with Clang?
Updated in 2026: glibc 2.43 added experimental support for building with Clang. In September 2021, I wrote "So, dear glibc, will you be happy with my sending Clang patches?" in Build glibc with LLD 13. We have come to a turning point. In Linux Plumbers Conference 2021, at the glibc Birds of a Feather session, I asked…
Why Create a New Unix Shell?
This post explains the project's motivation from several perspectives. Unix shell is an old and successful technology, so there are many ways of looking at it.
Asynchronous Everything (2015)
Joe Duffy's Blog | Adventures in the high-tech underbelly