commit a7b971b987afe0a37ac929cf3df81baca50ab986
parent 2e3c82cb7919077128b44907271f60facfe44f19
Author: Andrew Laack <andrew@laack.co>
Date: Sat, 10 Oct 2026 10:40:49 -0500
Continued work on profiling + software
Co-authored-by: Vim
Diffstat:
3 files changed, 112 insertions(+), 3 deletions(-)
diff --git a/posts/wip/basic-software-profiling-cpu-usage.md b/posts/wip/basic-software-profiling-cpu-usage.md
@@ -1,12 +1,12 @@
# Basic Software Profiling: CPU Usage
-This blog post is for former me. The me who was doing ML research, writing C++ code to make my software run faster, but didn't have an understanding of performance profiling. In retrospect, I wasted a lot of time, and CPU cycles, because I didn't know these tools existed. I spent lots of money on compute, which was only necessary because I didn't understand what I could do to make my software run faster.
+I have wasted many CPU cycles because I didn't understand software profiling.
-This post will not go in depth on how to speed up software, but it will discuss the process of identifying what parts of a program are taking the most time. I'll be focusing on compiled CPU-bound programs in this post, but many of these ideas generalize to interpreted programs that have other bottlenecks.
+By reading this blog post you will understand the process of identifying which parts of a program are taking the most CPU time. I'll be focusing on compiled CPU-bound programs in this post, but many of these ideas generalize to interpreted programs that have other bottlenecks.
## Tools
-[Perf](https://en.wikipedia.org/wiki/Perf_%28Linux%29) is the DevTools of Linux. Only one of the three most popular operating systems (Linux, OpenBSD, FreeBSD) supports perf, but there are sufficient analogs on FreeBSD, and if you're on OpenBSD good luck.
+[Perf](https://en.wikipedia.org/wiki/Perf_%28Linux%29) is the DevTools of Linux.
You might also want a visualization tool. I'll be showing [flamegraph](https://github.com/brendangregg/FlameGraph). Normally I just use perf because it is very powerful, but having pleasing visuals is useful for demonstrations (newer versions of `perf` can generate flamegraphs directly, but I prefer Brendan's implementation).
@@ -18,6 +18,7 @@ Let's start with something easy, how do you read a flamegraph? Take a look at th
<details>
<summary>Source code that generated this flamegraph</summary>
+
```cpp
uint32_t square(uint32_t input) {
return input * input;
@@ -57,6 +58,7 @@ int main() {
}
}
```
+
</details>
The amount of time spent with the `main` function on the stack is represented by the width of its bar.
diff --git a/posts/wip/constrained-software-revolution.md b/posts/wip/constrained-software-revolution.md
@@ -0,0 +1,70 @@
+# Constrained Software Revolution
+
+Software has been atrophying for some time now. Every release of Firefox is slower than the last, every release of Chromium is slower than the last, new websites from tech companies today are slower than they were last month, year, and decade.
+
+For all of the claims about caring about inclusion, people seem to not notice how exclusive they are being. When you make software that's slow, buggy, and complicated you're excluding people. People who have slower computers, who use different operating systems, who have disabilities, and who want to make their own standard compliant software. Slow down and consider this: Is you're click-jacking website harming or helping people? Is adding that ill considered feature to Firefox that only slows down startup time by 5ms (on your computer) really worth adding? Every choice in this process leads to the atrophying of software, and leads to the here and now.
+
+In some ways, software is better now than it's ever been before. My text editor, vim, is marginally better than it was 20 years ago, and if it wasn't, I'd just build that version instead, but when people treat their software like milk that spoils quickly, we don't have the luxury to go back in time and use what we had. Most people, misguidedly, interact with computing systems via the internet, a transient, spoiling, slow, inaccessible hellscape.
+
+It doesn't have to be like this.
+
+## Constrained Software
+
+Definition:
+
+1. Performs a small set of cohesive functions well
+2. Respects the user
+3. Simple
+
+This is the entire definition. Let's break these down.
+
+> Performs a small set of cohesive functions well
+
+A small set of cohesive functions. A few things that come to mind:
+
+1. Dillo
+2. Mpv
+
+Dillo is designed to browse the web, with plugins to browse alternative protocols too. This is cohesive. It is for browsing, and the additional features aid in this.
+
+Mpv is a useful tool for displaying many video formats, coming from many sources. This is not a small task as there are many video file formats, and it supports video streaming from sites as well.
+
+This small set of functions must be cohesive, it wouldn't make sense for your text editor to have an rss feed built into it, but conversely tools that are too small in scope become tedius to use directly.
+
+> Respects the user
+
+To respect the user, software must be accessible. This means it works across a variety of system configurations and is usable by people with many types of impairments. It must also not do things they don't want, like spy on them.
+
+> Simple
+
+Complicated software is what has led to the situation we have now. Complicated software entrenched a duopoly of browser engines,
+
+## So Suckless?
+
+Not quite.
+
+From their website:
+
+> Our project focuses on advanced and experienced computer users
+
+This is one distinction. There is an underserved niche of software for experienced users, but I don't believe constrained software should necessarily target this niche. Grandmas should be able to use constrained software; it's built to be intuitive and simple.
+
+Consider Dillo. There are advanced features, facilitated by its plugins system, but the base browser is exceptionally approachable. I'd argue it's more approachable than Chromium. I won't claim it would be preferred by many users in its present state, but slight improvements to the usage experience to keep up with modern standards (some stuff with settings and first pass rendering missing css sometimes) would certainly make it as usable or more usable.
+
+The problem right now is most sites people patronize don't work without J***S*****. I've accepted sites like that aren't made for me, but it requires widespread disdain to make it known people are sick and tired of this.
+
+---
+
+- constrained software
+ - this is a nice name, but it's not a unique enough word
+ - if I search suckless, I find suckless.
+- unflashy software
+- workhorse software
+- scopeful software
+ - software with a sensible scope
+- tractable software
+ - software that is doable for an individual
+- practical software
+- bloatless software
+ - software without the bloat
+- respectful software
diff --git a/posts/wip/so-fast-its-confusing.md b/posts/wip/so-fast-its-confusing.md
@@ -0,0 +1,37 @@
+# So Fast It's Confusing
+
+Dillo is so fast it's confusing.
+
+(modern hardware)
+
+Benchmarking:
+
+time to first paint:
+
+(frames at 60 fps)
+
+librewolf:
+
+10 frames
+10 frames
+10 frames
+9 frames
+8 frames
+10 frames
+9 frames
+
+chromium:
+
+23 frames
+23 frames
+23 frames
+23 frames
+
+dillo:
+
+6 frames
+7 frames
+6 frames
+
+
+The delta between fast and slow is somewhere around 5-7 frames for me (@60 fps)