Skip to content

Instantly share code, notes, and snippets.

View jmcph4's full-sized avatar

Jack McPherson jmcph4

View GitHub Profile

GC Benchmark Comparison: Copying vs. Mark-and-Sweep

Wall-clock timing of benchmarks/*.psh under --release, comparing the original Cheney-style copying collector (commit cc0c523) against the new in-place mark-and-sweep collector. Each benchmark was run once per build with a 240s timeout; both builds passed the full test suite.

Benchmark Original (copying GC) New (mark-and-sweep) Δ
alloc_objs.psh 42826ms 41224ms −3.7%
@jmcph4
jmcph4 / carp.sh
Last active August 6, 2026 17:34
talk to claude
#!/bin/bash
# usage
if [ "$#" -gt 1 ]; then
echo "[carp] usage: carp [prompt]"
exit
fi
CARPARKDIR=~/dev/tmp/carpark
#include <stdio.h>
#include <stdlib.h>
#include <sys/types.h>
#include "clob.h"
ssize_t level_insert(struct level* level, struct order order) {
if (level == NULL || level->price != order.price) return -1;
struct order* new_orders = realloc(level->orders, (level->num_orders + 1) * sizeof(struct order));
if (new_orders == NULL) return -1;
INIT Init
NEXT Next
INVARIANT TypeOK
https://www2.eecs.berkeley.edu/Pubs/TechRpts/2016/Archive/EECS-2016-143.pdf
https://www.nvidia.com/content/gtc-2010/pdfs/2238_gtc2010.pdf
https://bebop.cs.berkeley.edu/pubs/volkov2008-benchmarking.pdf
https://laurel.datsi.fi.upm.es/_media/proyectos/gopac/volkov10-pmaa.pdf
https://www.nvidia.com/docs/IO/116711/sc11-unrolling-parallel-loops.pdf
https://www.netlib.org/lapack/lawnspdf/lawn202.pdf
https://www2.eecs.berkeley.edu/Pubs/TechRpts/2016/Archive/EECS-2016-143.pdf
https://dl.acm.org/doi/10.1145/3178487.3178536
https://grothoff.org/christian/teaching/2008/4704/ParallelComputingExperienceswithCUDA.pdf
https://people.eecs.berkeley.edu/~kubitron/courses/cs258-S08/projects/reports/project6_report.pdf
https://x.com/bubbleboi/status/2048964901201215927
“Bushido is to enter a ‘death frenzy’ (shini-gurui). Even dozens of men cannot kill a man in a frenzied state already determined to die.” Lord Naoshige said this. One cannot accomplish great exploits in a normal frame of mind. Just become insane and desperate to die. In the Way of the warrior, contemplating matters too deeply will cause you to fall behind others. Don’t think of loyalty or filial piety, just enter a frenzy to perish in shidō. Loyalty and filial piety will manifest as a matter of course in the death frenzy.
@jmcph4
jmcph4 / bib.txt
Last active April 24, 2026 00:57
https://web.archive.org/web/20081219052953/zedshaw.com/rants/rails_is_a_ghetto.html
https://www.scattered-thoughts.net/writing/against-sql
https://www.youtube.com/watch?v=Jmi93AZf_z0
https://landley.net/history/mirror/cpm/history.html
https://groups.google.com/a/chromium.org/g/chromium-dev/c/EUqoIz2iFU4/m/kPZ5ZK0K3gEJ?pli=1
https://blog.railway.com/p/moving-railways-frontend-off-nextjs
https://www.youtube.com/watch?v=3tIQUFg4KQA