Topics /

Systems & Performance

The most popular blog posts about systems & performance on Hacker News. 4,390 posts.

Any year
4231

The terminal escape sequences ocean is deep and dark

A few months ago I got to debug and fix an interesting bug in the Csharp virtual terminal library VtNetCore . We use VtNetCore at BastionZero to extract terminal commands in realtime from user terminal sessions as they flow over the wire. This requires feeding the standard out and standard err of a terminal session…

4232

Plan9 from?

I have been saying for years that I am seeing the same phenomonon today that I saw thirty years ago when the microprocessor was first invented. At that time I argued a lot with all the computer scientists. They insisted that microprocessors were not really computers because they did not run the same software that…

4235

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…

4236

X86 Register Encoding

If you've ever look at the disassembly output for C or C++ code, you'll probably notice that there are a lot of push/pop instructions. And if you pay close enough attention, you'll notice that the compiler prefers to use certain registers over others. In particular, compilers will prefer pushing "old" registers like…

4238

File Locks on Linux

You're probably reading this page because you've attempted to access some part of my blog (Wandering Thoughts) or CSpace , the wiki thing it's part of. Unfortunately you're using a browser version that my anti-crawler precautions consider suspicious, most often because it's too old (most often this applies to versions…

4239

Systemd's DynamicUser feature is currently dangerous

You're probably reading this page because you've attempted to access some part of my blog (Wandering Thoughts) or CSpace , the wiki thing it's part of. Unfortunately you're using a browser version that my anti-crawler precautions consider suspicious, most often because it's too old (most often this applies to versions…

4245

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…

4246

Shrinking a Kotlin Binary by 99.2%

We'll get to the shrinking, but first let's motivate the binary in question. Three years ago I wrote the "Surfacing Hidden Change to Pull Requests" post which covered pushing important stats and diffs into PRs as a comment. This avoids surprises with changes that affect binary size, manifests, and dependency trees.

4247

Closures as Win32 Window Procedures

Back in 2017 I wrote about a technique for creating closures in C using JIT-compiled wrapper. It’s neat, though rarely necessary in real programs, so I don’t think about it often. I applied it to qsort , which sadly accepts no context pointer. More practical would be working around insufficient custom allocator…

4255

Reversing a MacOS Kernel Extension

In my last post I covered the basics of kernel debugging in macOS. In this post we will put some of that to use and work through the process of reversing a macOS kernel module. As I said in my last post, in macOS there is a kernel module named “Don’t Steal Mac OS X” (DSMOS) which registers a function with the Mach-O…

4260

PulseAudio Under the Hood (2017)

I’m working on the Roc Toolkit open-source project, a development kit for realtime audio streaming over the network. You can read more about the project in these two articles: 1, 2. We decided to implement a set of PulseAudio modules that will allow PulseAudio to use Roc as a network transport. Many Linux distros…