The Stargazer

Humans Need Not Apply

Humans Need Not Apply was a YouTube video by CGP Gray published in 2014. It talks about how technological advancements, especially making computers smarter and more able to think and make decisions, will increasingly make humans unnecessary. It was made in time where AI research was still in its …

Implementing order books in C++ and Rust - part 3/3

In the previous part we have started working on our Rust orderbook re-implementation of the C++ original, and defined the types Order and OrderKey<Side>, where Side is a type implementing the OrderbookSide trait: either Bid (for buy orders) or Ask (for sell orders). Defining OrderHandle …

Configuration knobs considered harmful (Abseil blog)

I found the recent Abseil article Performance Tip of the Week #52: Configuration knobs considered harmful to be insightful. Most people, developers included, would generally prefer more flexibility and configurability over less, but as the article points out, configuration options (flags) carry …

Graphs are hard

The Hunt for the Missing Data Type (discussion on Hacker News) is an article exploring why are graph implementations so rare while graph problems are so common: I see graphs everywhere and use them to analyze all sorts of systems. At the same time, I dread actually using graphs in my code. There is …

Implementing order books in C++ and Rust - part 2/3

In the previous part, we have sketched out the structure of implementing a simple order book in C++, supporting order insertion and efficient cancellation. (Implementing uncrossing, that is, trades when a buy order and a sell order agree on a price, is an exercise left to the reader, as is …

This is why we keep getting scammed and phished

In Thanks FedEx, This is Why We Keep Getting Phished (discussion on Hacker News) the author is playing the game we are probably all used to playing these days upon receiving a text or e-mail asking us to urgently do something or pay: scam or real. I highly recommend reading the article in full, as …

Implementing order books in C++ and Rust - part 1/3

A fairly standard programming problem in the world of trading is building an order book. In this article, I will be showing one particular interesting aspect of this problem, and how to solve it in C++. In the next two parts, we will be trying to implement the same solution in Rust. This is meant to …

Advice is disproportionately written by defective people

You don’t have polyamory, you hate people who write books makes some very good points, in particular highlighting how most people’s ideas (including mine) about polyamory comes from media, which distorts reality almost as a necessity. “They figured out their issues and lived happy …

Explaining politics with trauma

The Psychopolitics of Trauma by Scott Alexander is a very interesting essay to read. It talks about politics and today’s social and political climate in a way that was new to me and felt extremely reasonable. In fact, it posits an explanation for the feeling of aversion I have always felt …

Pastor runs crypto scam, blames God

As you know, I’m a sucker for hilarious finance news, and therefore for Matt Levine’s Money Stuff newsletter. More recently, this cracked me up: Pastor got his crypto scam audited. This has everything you could possibly desire in a finance story. […] a pastor named Eli Regalado …

Rust oddness: integer literal references?

I’m following Rust by Example to finally get into Rust properly, after several years spent as a primarily C++ developer. So far, most things have made sense to me, and I have been blown away by the compiler diagnostics: they are accurate and useful, which anybody with some C++ experience will …

AI sleeper agents

A fascinating summary of recent AI research: AI Sleeper Agents A sleeper agent is an AI that acts innocuous until it gets some trigger, then goes rogue. … So there’s been a dispute in the AI safety community - if for some reason you start with an AI sleeper agent, and you train it on normal …

Passing a struct of 3 or more words is slow on AMD64

I did not realize that the AMD64 ABI specifies a silly calling convention rule that forces structs with 3 or more word-sized (i.e. 8-byte) fields to be passed by pointer, even if you write your code expecting to have it be passed by value. I learned this from: Speed up your code: don’t pass …

Words and labels, on the powers of

Nobody has seasonal affective disorder describes that Seasonal Affective Disorder (SAD) is one of those medical-ish conditions that cannot be tested for, has no specific or clear symptoms, nor treatment. It could be generously called an umbrella term: The more I read about it, the more I get the …

C++ hack: explicitly hiding names

Sometimes you’ll encounter situations where a variable is still in scope, but cannot legally be accessed anymore. A typical example is if the variable has been moved from and we want to make sure we don’t accidentally reference it again, but there are other examples as well, for example …

Why chess bots are virtually unbeatable

A really interesting video with some details about how the Stockfish chess engine works and what makes it so good at chess: .embed-container { position: relative; padding-bottom: 56.25%; height: 0; overflow: hidden; max-width: 100%; } .embed-container iframe, .embed-container object, …

Good and evil genies: the AI alignment problem

I feel like that as much hype as AI has gotten, rightfully so, the people advocating for caution and restraint, such as the Effective Altruism movement, have not been very popular. Part of that is just being in the unenviable and intrinsically unpopular position of a naysayer, but I think a large …

Measuring work performance

In The value of your work I have talked about how in a job, work is useful for your individual career only if your manager deems it so, even though that is not always the same thing as what is valuable for your team or your organization. In fact, it is rather difficult to come up with a good, …

As usual, XKCD is dead right and manages to entertain at the same time: DateTime. I have had the misfortune of trying to implement sane date and time primitives at my last job, as well as dealing with measuring elapsed time with less overhead than clock_gettime(), and it is a nightmare. For a …

Genetically modified bacteria to end tooth decay?

This will be huge, if true: A genetically modified bacterium that outcompetes bacteria causing tooth decay (Hacker News discussion): Lantern Bioworks says they have a cure for tooth decay. Their product is a genetically modified bacterium which infects your mouth, outcompetes all the …

The frame pointers strike back

Interesting: Ubuntu 24.04 LTS will enable frame pointers by default, following Fedora which made the same change in version 38. In short: GCC will by default start emitting frame pointers again as if using -fno-omit-frame-pointer, which helps debugging and profiling tools a bit, at the cost of what …

The value of your work

2023-12-14 Work is valued if and only if it is something that management (or whoever evaluates your performance) cares about, which does not necessarily have to be in any way related to how much real value it provides. Have you fixed a bug or introduced a feature that helps every software developer …

How do all-you-can-eat restaurants stay profitable?

All-you-can-eat buffets are so not so widespread in Europe (as best as I can tell), but apparently they’re a thing in the USA. I’ve been in this kind of restaurant exactly once in my life, and I can’t say that I didn’t find the idea appealing: it instinctively seems like a …

Towards understanding AI models

As much hype and attention that the machine learning / artificial intelligence field gets, and in spite of some impressive results that have come out of it in the form of e.g. ChatGPT, overall we have very little understanding in exactly how do these models work. We can train them, and we can use …

Recovering from segmentation faults

This is brilliant: Cleanly recovering from Segfaults under Windows and Linux (32-bit, x86). I do not think I’d want to actually use this in production, for the same reason that the article itself points out: segmentation faults often indicate that something has gone horribly wrong inside the …