Compiling C++ with the Clang API
This post describes how to compile a single C++ source file to an object file with the Clang API. Here is the code. It behaves like a simplified clang executable that handles -c and -S…
Every blog post that took off on Hacker News, ranked by the votes of its best submission. 14,546 posts.
This post describes how to compile a single C++ source file to an object file with the Clang API. Here is the code. It behaves like a simplified clang executable that handles -c and -S…
I’ve invested in a new odometer to help my car go faster. Accountability is important, and as a driver I believe the most important thing I can do is set measurable, achievable and inspiring goals for the people pushing my car down the road.
28 . That's the minimum number of AND or OR operators you need in order to write any Boolean function of five variables. Alex Healy and I computed that in April 2010. Until then, I believe no one had ever known that little fact. This post describes how we computed it and how we almost got scooped by Knuth's Volume 4A…
People appear to enjoy the blog posts about me porting different compilers to OpenBSD . What I would like to do for the next couple of posts beginning with this one is to take a step back and de-complexify these programs. Both the D compiler and the GNU Modula-2 compiler are highly complex pieces of software. But at…
The package version selection problem is to find a set of dependencies that can be used to build a top-level package P that is complete (all dependencies satisfied) and compatible (no two incompatible packages are selected). There may be no such set, because of the diamond dependency problem: perhaps A needs B and C…
Meta Title: Math, Sports Data & IPTV: A Portugal Guide Meta Description: Explore how math-minded sports fans use IPTV in Portugal to watch live football, Champi
Some updated tips for porting software to Python 3.
The little routine presented here is, with all due humbleness, hands down the best code I ever wrote. It is esoteric and might not appeal to the masses, and it certainly has no commercial value. But in terms of personal satisfaction at a job well done, this is about as good as it gets. Here's why:
Last week, I revisited Andrew Kensler's business card raytracer to make it run as fast as possible [1] . It was a lot of fun and I learned a lot in the process. I enjoyed it so much that I decided to revisit Andrew's follow up, the postcard sized pathtracer [2] . I spent a lot of time trying to make sense of that code…
Visualize binary protocols by building parsers in Elixir.
What happens when we get or set an attribute of a Python object? This question is not as simple as it may seem at first. It is true that any...
This post is based on the talk of the same name I gave at the Arrrrcamp conference in Ghent, Belgium on October 2nd, 2014. You can find the slides here and the video recording here .
Pathfinding is one of these topics that usualy baffles game developers. The A* algorithm in particular is poorly understood, and the general belief seems to be that it’s arcane magic.
Purpose Terminology Single-sided Standard double-sided Möbius double-sided Two-way double-sided Purpose The purpose of this page is to collect and summarize concise explanations of the pros and con…
An article series where I show you how to write a fully functional Python debugger.
All ambiguity is resolved by actions of practitioners at the sharp end of the system.Dr. Richard I. Cook, How Complex Systems Fail There’s a wonderful book by the late urban planning professo…
Rendering the wordle.org file as webpage and including in the docs as-is, because the Sphinx documentation generator doesn’t understand org-mode files, so we couldn’t render this page directly from Sphinx the usual way.
Posted to HN. Comments and discussion highly encouraged. Introduction This will be a short example-based guide to (a) awk (b) gnuplot and (c) using them in a script. I needed to graph some data based on the output of a command run a couple times. So what better way to solve that five minute task than to spend an hour…
Recently I was reverse-engineering an Android app [ a ] . The relevant details are as follows:
All the pieces have come together for widespread Wasm SIMD usage. The majority of browsers and Node 16 LTS support Wasm SIMD out of the box, and Rust recently learned how to compile Wasm intrinsics. Now I need to port a library from x86 SIMD to Wasm SIMD and distribute it in such a way that will fallback to a non-SIMD…
An overview of new features in pgvector 0.5.0, including HNSW, parallel index builds, and more!
A guide to bringing up the Linux Kernel and a userspace application on a new hardware (or in this case, a self-made emulator)
This post is aimed at readers who are familiar with Rust and want some insight into why it is great for machine learning.
Persistent PHP processes in Erlang/OTP. “It’s so easy, in fact, that I now use it to debug WordPress functions from within Erlang.”
.NET is a managed runtime, which means that it provides high-level features that ‘manage’ your program for you, from Introduction to the Common Language Runtime (CLR) (written in 2007):
Exporting graph data to text file and SVG with Datalog