New
The latest blog posts to take off on Hacker News. 14,541 posts.
The Enterprise Eats Software
Just now, Avdi had a miserable experience buying curtains. He went to pick up an order that he placed last night, but Lowe’s didn’t have it. The order was sent to the wrong store and it…
Asynchronous Everything (2015)
Joe Duffy's Blog | Adventures in the high-tech underbelly
My first Z80 assembly language program
I was 9 years old. A revision of the notebook containing my first Z80 assembly language program
SSH quoting
A while back there was a thread on one of our company mailing lists about SSH quoting, and I posted a long answer to it. Since then a few people have asked me questions that caused me to reach for it, so I thought it might be helpful if I …
How to average floating point numbers (2015)
When it comes to accuracy, how you add a series of arbitrary values together, and average them still matters.
Good and Bad Elixir
Words from Chris Keathley
I wrote a linker everyone can understand
When we wrote our assembler we made many design choices that helped us cut down on the complexity of the assembler itself. One of those decisions was to have the assembler directly output executables. That was a good choice in that it allowed us to quickly test as we were developing: once we implemented an opcode, we…
Real-world CSS vs. CSS-in-JS performance comparison
I took the real app and convert it from Styled Components to Linaria to compare the app performance of CSS-in-JS and normal CSS. Continue reading if you want to know how it went.
Engineering a Chess Match
This is the story of me trying to win a game of chess against my brother. A single freaking game. What’s so special about it? Am I good at chess? Not at all. Did I improve at my game in the process? Also no. Is it a story about “the journey rather than the destination”? Not really. Did I at least have fun in the…
The pedantic checklist for changing your data model in a web application
Let's say you have a web app with some database. In your database you have an Invoice model, where you store things you are charging your customers.
Design Issues in LLVM IR
On the whole, LLVM has a well-designed intermediate representation (IR), which is specified in the language reference . However, there are a number of areas where design mistakes have been made. And while the LLVM project is generally open to addressing such issues, mistakes in core IR design tend to be firmly…
Clever vs. Insightful Code
“Don’t write clever code.” Why not? “Because it’s hard to understand.” People who say this think of clever code such as Duff’s Device: Duff's Device send(to, from, count) registershort*to, *from; registercount; { registern =(count +7) /8; switch(count %8) { case0: do{ *to =*from++; case7: *to =*from++; case6: *to…
The case for continuous documentation
John Doe's personal website
The Repeated Deaths of OOP (2015)
Object Oriented Programming died several times already. This time might be the last.
How I Learned Symmetric-Key Cryptanalysis
personal web-log
Conway's Game of Life on FPGA
When learning a new programming language, I like having a well defined yet non-trivial problem to solve. Conway’s Game of Life (GoL) fits this definition. It has enough depth to uncover various tradeoffs. So naturally, when I picked up Chisel hardware description language (HDL), I wanted to build Game of Life in FPGA…
Pokegb: A gameboy emulator that only plays Pokémon Blue, in 68 lines of C++
POKEGB: A gameboy emulator that only plays Pokémon Blue, in 62 lines of c++. source: https://t.co/AGt7RUTr9H pic.twitter.com/o0BUUmzNOt
Implementing a LLVM Micro C compiler in Haskell
In this series, we will explore how to write a compiler for a small subset of C to LLVM in Haskell. Our language, Micro C, is basically a small subset of real C. We'll have basic numeric types, a real bool type, pointers, and structs. At the end of the series, we'll have a beautiful executable, mcc (Micro C…
Computing the number of digits of an integer even faster
I my previous blog post, I documented how one might proceed to compute the number of digits of an integer quickly. E.g., given the integer 999, you want 3 but given the integer 1000, you want 4. It is effectively the integer logarithm in base 10. On computers, you can quickly compute the integer logarithm … Continue…
Malloc broke Serenity's JPGLoader, or: how to win the lottery
I got the chance to investigate an interesting bug in SerenityOS this week. It was related to the decoding of JPG images in the operating system. For some reason, when a JPG image is viewed, it comes out like this: Lenna, showing up with incorrect colors. Weird, huh? Also seems like a simple confusion of RGB vs. BGR…
Leaky Abstractions
In the late 1990s, the Windows Shell and Internet Explorer teams introduced a bunch of brilliant and intricate designs that allowed extension of the shell and the browser to handle scenarios beyond…
Best practices around creating production ready web apps with Docker Compose
Here's a few patterns I've picked up based on using Docker since 2014. I've extracted these from doing a bunch of freelance work.
The most expensive number in engineering
How to put a price on the limits of knowledge
A Macro View of Nanite
After showing an impressive demo last year and unleashing recently with the UE5 preview, Nanite is all the rage these days. I just had to go in and have some fun trying to figure it out and explain…
PostGIS at 20, the Beginning
Twenty years ago today, the first email on the postgis users mailing list (at that time hosted on yahoogroups.com) was sent, announcing the first numbered release of PostGIS. The early history of PostGIS was tightly bound to a consulting company I had started a few years prior, Refractions Research. My first contracts…
You Don't Need to Rebuild Your Development Docker Image on Every Code Change
You can mount code from your development machine into a container and save yourself tedious waiting times during development.
“Computer science is not about computers”
Edsger W. Dijkstra? Alan Perlis? Jacques Arsac? George Johnson? Donald Knuth? Matthew Dennis Haines? Anonymous?
Finding CSV files that start with a BOM using ripgrep
For sqlite-utils issue 250 I needed to locate some test CSV files that start with a UTF-8 BOM.