Why is std::function slower than a function pointer?
Nov 18, 2025
Introduction The other day I came across some code that passes a function to std::sort. Though sort will let you call it with a std::function, there was an admonishment to use the function pointer version of sort instead. Using std::function is almost 4x slower for a trivial float comparison. What’s...
Static analysis of the DeepSeek Android App
Feb 7, 2025
Introduction I conducted a static analysis of DeepSeek, a Chinese LLM chatbot, using version 1.8.0 from the Google Play Store. The goal was to identify potential security and privacy issues. I’ve written about DeepSeek previously here. Additional security and privacy concerns about DeepSeek have been raised. See also this analysis...
DeepSeek and the AI arms race
Jan 31, 2025
The release of the DeepSeek-r1 model by the Chinese AI lab DeepSeek, along with its availability on the App Store, marks a pivotal moment in the AI arms race between the US and China. This development underscores the intensifying competition in AI advancements between these two global powers. A lot...
The New York Times Test
May 25, 2024
One code of conduct professionals follow is “The New York Times Test”: you must never put anything in writing that you could be embarrassed to see printed on the front page of the New York Times. The risk is, if your company or business is ever in the news, and...
Binding C libraries in OCaml with the dune ctypes stanza
Feb 19, 2022
The OCaml ctypes library along with new support for ctypes stanzas in the dune build system make it a snap to bind C libraries. In this article, we will walk through how to prepare your project to use an external C library. But first, I’d like to try to convince...
Linux on the laptop, forever 10 years behind
Dec 7, 2021
It was the year 2003. I was sitting at the FTC office, with some other open source activists, testifying that Microsoft was in violation of its 1995 consent decree. Microsoft, through illegal monopolistic bundling deals, had been forcing laptop manufacturers to sell customers a license for Windows whether they wanted...
Mirage Minimum Viable GCE with valid TLS certificate!
Nov 13, 2021
In a previous installment we went over deploying a static TLS web-site to Google Compute Engine. It works but you have to click through the disconcerting certificate warning. Wouldn't it be nice if our all-OCaml unikernel application went ahead and obtained a trusted TLS certificate from Let's Encrypt all by...
Tutorial: minimum viable Mirage unikernel web server on GCE
Nov 10, 2021
If tens of millions of lines of C code in your application stack keeps you from sleeping easily at night, as it does me, you may be interested in changing your web services to all-OCaml based Mirage unikernels. The complete argument for considering this can be made elsewhere. What I'd...
Parler may still be hosted in the US
Jan 27, 2021
Parler was recently kicked off of Amazon AWS for TOS violations. Parler claims that the big tech cloud providers weren't willing to do business with them, and facing no place left to go, the site went offline. Recently the site came back online in limited form. Some have observed they're...
NYT threatens to out Slate Star Codex author
Jun 24, 2020
This is such terrible news. As seen on Slate Star Codex: NYT is Threatening my Safety by Revealing my Real Name so I am deleting the blog. I'm posting this mainly as a signal boost, and also to express sadness that if you want to publish ideas that are not...