Paul Khuong: some Lisp

https://pvk.ca/ (RSS)
visit blog
Fixing the hashing in "Hashing modulo α-equivalence"
29 Dec 2022 | original ↗

Per Vognsen sent me a link to Maziarz et al’s Hashing Modulo Alpha-Equivalence because its Lemma 6.6 claims to solve a thorny problem we have both encountered several times. Essentially, the lemma says that computing the natural recursive combination of hash values over \(2^b\) bits for two distinct trees (ADT instances) \(a\) and \(b\) yields a...

Plan B for UUIDs: double AES-128
12 Jul 2022 | original ↗

It looks like internauts are having another go at the “UUID as primary key” debate, where the fundamental problem is the tension between nicely structured primary keys that tend to improve spatial locality in the storage engine, and unique but otherwise opaque identifiers that avoid running into Hyrum’s law when communicating with external...

Hacking tips for Linux perf porcelain
2 Jun 2022 | original ↗

Sometimes you just want to abuse Linux perf to make it do a thing it’s not designed for, and a proper C program would represent an excessive amount of work. Here are two tricks I find helpful when jotting down hacky analysis scripts. Programmatically interacting with addr2line -i Perf can resolve symbols itself, but addr2line is a lot more...

Bounded dynamicism with cross-modifying code
20 Dec 2021 | original ↗

Originally posted on the Backtrace I/O tech blog. All long-lived programs are either implemented in dynamic languages,1 or eventually Greenspun themselves into subverting static programming languages to create a dynamic system (e.g., Unix process trees). The latter approach isn’t a bad idea, but it’s easy to introduce more flexibility than...

Slitter: a slab allocator that trusts, but verifies
1 Aug 2021 | original ↗

Originally posted on the Backtrace I/O tech blog. Slitter is Backtrace’s deliberately middle-of-the-road thread-caching slab allocator, with explicit allocation class tags (rather than derived from the object’s size class). It’s mostly written in Rust, and we use it in our C backend server. Slitter’s design is about as standard as it gets: we...

↑ these items are from RSS. Visit the blog itself at https://pvk.ca/ to find other articles and to appreciate the author's digital home.