My Pernosco Workflow

Mozilla pays for Pernosco, and I get huge value from it. In fact, at this point, if Mozilla wasn’t paying for it, I would pay for it myself because it’s so fantastic.

Honestly, I upload traces of shell runs before trying local rr about 2/3rds of the time now, because Pernosco traces are just faster to solve; the power of instant jumps through time, data flow analysis, and the notebook are all incredible. Shell processing time is typically less than 5 minutes in my experience, so I just grab a snack / make a coffee after submitting.

Here’s my pernosco-submit workflow:

Step 1: Gather a Local Trace

UPDATE: The machines the process pernosco logs have been updated, so the below instructions have been too

To gather a local rr trace that’s compatible with Pernosco you need to disable incompatible CPU features. I have written a little script pernosco-record that I use to do that:

#!/bin/bash

rr record --disable-avx-512 "$@"

This works for jit-test like this:

./mach jit-test --debugger=pernosco-record testName

Or just ./mach run --debugger=pernosco-record foo.js

Step 2: Upload the trace

Find the trace you’re interested in ~/.local/share/rr/<trace>, and call pernosco-submit

pernosco-submit upload ~/.local/share/rr/<trace> <PATH TO CENTRAL>

You also will need to have set PERNOSCO_GROUP and PERNOSCO_USER in your environment. PERNOSCO_USER_SECRET_KEY cannot be in the environment of the recording, so I just always provided it on the command line.

Update: It turns out that these days, there's configuration files that can should be used instead of environment variables:

  • ~/.config/pernosco/user holds the email for Pernosco
  • ~/.config/pernosco/group holds the associate group for Pernosco. Mozilla has its own group, but if you're a regular Pernosco customer, check your account page for all this info.
  • ~/.config/pernosco/user_secret_key holds the secret key

Huge Thanks to Daniel Holbert for the tip!

Step 3: Wait for email

You'll get an email with the trace when it's done processing.