Beating the Compiler
In modern times, everyone knows that writing assembly is a fool's errand: compilers are the result of literal engineer-centuries of work, and they know the processor much better than you do.
The latest blog posts to take off on Hacker News. 6,945 posts.
In modern times, everyone knows that writing assembly is a fool's errand: compilers are the result of literal engineer-centuries of work, and they know the processor much better than you do.
“Print the sum of 50 million ASCII-encoded integers uniformly sampled from [0, 2³¹−1], separated by a single new line and sent to standard input.”
If we have a heuristic to guess some value cheaply, we can remove a data dependency in a tight loop using the branch predictor. This allows the CPU to run more instructions in parallel, increasing performance. If this explanation does not make much sense to you, keep reading to learn about some of the magic making…
FlashAttention-3 achieves up to 75% GPU utilization on H100s, making AI models up to 2x faster and enabling efficient processing of longer text inputs. It allows for faster training and inference of LLMs, supports lower precision operations for improved efficiency.
If you are of a certain vintage, this image is burned indelibly somewhere in your posterior parietal complex: Oh, my old friend. How it’s been a long time. Cultural Significance For the uninitiated, what are we looking at? Could it be the Moiré Error from Doom? Well, no. You are looking at (part of) the boot up screen…
If you’ve read my first post about assembly language, you might expect that this is another post on how to understand assembly language. I will write more about that at some point, but this post is not that. Instead, this post is going to talk about some of the weird things and random trivia I learned while writing an…
What are the fundamental limits of end-to-end congestion control in 5G networks?
Long thought impossible, helium has been one of the greatest breakthroughs for high-capacity HDDs. This is the story the science behind them.
Intel released the powerful Pentium processor in 1993, a chip to "separate the really power-hungry folks from ordinary mortals." The origin...
There's a fascinating Rust library, loom, which can be used to thoroughly test lock-free data structures. I always wanted to learn how it works. I still do! But recently I accidentally implemented a small toy which, I think, contains some of the loom's ideas, and it seems worthwhile to write about that. The goal here…
As projects get more complicated the tooling has to improve. Outgrowing the arduino-ide is easy on the Pi Pico with the excelent pico-sdk but what if things get even more complicated...
A detailed blog post on optimizing multi-threaded matrix multiplication for x86 processors to achieve OpenBLAS/MKL-like performance. Tags: High-performance GEMM on CPU, Fast GEMM on CPU, High-performance matrix multiplication on CPU, Fast Matrix Multiplication on CPU, Matrix multiplication in C, GEMM in C, Matrix…
The personal website of JT Archie. Includes a blog, work ethic, and projects they have worked on.
In a previous article, I explained how I set up a TFT LCD screen on my Raspberry Pi. Because I had been previously using my Pi as a headless server, I hadn’t installed a desktop environment. I wanted to add a lightweight heads-up display to the server, and I wanted a graphical application that could operate without X…
Competitiveness is a vice of mine. When I heard that a friend got Linux to boot off of NFS, I had to one-up her. I had to prove that I could create...
Within the LLVM project, MC is a library responsible for handling assembly, disassembly, and object file formats. Intro to the LLVM MC Project, which was written back in 2010, remains a good source to understand the high-level structures. In the latest release cycle, substantial effort has been dedicated to refining…
I am responsible for the reliability of the firmware updates on our devices and this work never gets boring. The thing about firmware updates is that by definition, every bug is caused by the updater because before installing the affected version, the bug was not present. You could say that updates are the cause and…
Calculations in Google Sheets were initially done on the server, then on the client in JavaScript, and now on the client in WebAssembly Garbage Collection. This case study explains how and why.
UC Santa Cruz researchers show that it is possible to eliminate the most computationally expensive element of running large language models, called matrix multiplication, while maintaining performance.
Update: I have created an awesome-minisforum-v3 GitHub repository to list information for Minisforum V3 users, including some workarounds for the issues mentioned in this review. Quest for the Ideal
Let me set the right expectations first. This bug I found is actually not that complicated, it's very straightforward once you see what's going on. But I still think the process it took me to uncover this bug could be interesting. It's also kind of interesting that a simple bug stayed undiscovered for so long. I will…
Media over QUIC: Rethink your approach. *Unless you're doing something dope.
A major caveat in tools like sudo and doas for that matter is that they rely on setuid binaries and privilege escalation in order to run commands as root.
Earlier this week, I did the keynote at TLA+ conf 2024 ( watch the video or check out the slides ). My message in the keynote was something I have believed to be true for a long time: formal methods are an important part of good software engineering practice. If you’re a software engineer, especially one working on…
Even though we often hear terms like L1, L2, cache block size, etc., most programmers have a limited understanding of what cache really is. This is a beginner-friendly primer on how cache works.