Michael Pratt
prattmic.com
Michael Pratt
@prattmic.com
1.5K followers 190 following 180 posts
Hacking on the Go runtime and gVisor. 🏳️‍🌈
Posts Media Videos Starter Packs
For some added fun, also see go.dev/cl/715362, wherein I discover that VPCOMPRESSQ is horrifically slow on AMD Zen 4, but only with a memory destination.

And thanks to @lemire.bsky.social for writing about this, which made this much faster to track down!
Gerrit Code Review
go.dev
If you have an interest in understanding garbage collection better, or in how Go's new GC works under-the-hood, I highly recommend reading @michael.express's thorough guide through Go's current and Green Tea GC.
“The Green Tea Garbage Collector” by Michael Knyszek and Austin Clements — https://go.dev/blog/greenteagc

#golang
Reposted by Michael Pratt
Extremely happy to see Source Spotter, a Go Checksum Database monitor and Go toolchain reproducer by @agwa.name.

These use the transparency logs we built into the Go supply chain to keep the Google-operated services honest.
Source Spotter - Supply Chain Security for Go
Source Spotter is a sumdb auditor, module monitor, toolchain reproducer, and telemetry config tracker.
sourcespotter.com
Reposted by Michael Pratt
I got frustrated with how GitHub Actions lets workflows with read-only permissions poison the cache of read/write workflows (!!??!?), so yesterday night I put together an Action that runs commands in a gVisor sandbox.
GitHub - geomys/sandboxed-step: A GitHub Action that runs a command in a gVisor sandbox
A GitHub Action that runs a command in a gVisor sandbox - geomys/sandboxed-step
github.com
Reposted by Michael Pratt
As professional maintainers we can invest in making our projects safer and more reliable. To that end, here's a draft of the Geomys Standard of Care.

It covers general maintenance, stability & reliability, dependency management, account and CI security, vulnerability handling, licensing, and more.
The Geomys Standard of Care
Introducing the set of standards that Geomys maintainers strive to uphold in our professional activity as open source maintainers.
words.filippo.io
(Paraphrasing)

> instead of automatic dependency version bump tools, we (1) run govulncheck on a schedule and (2) run CI with the latest versions of our dependencies to ensure we’re alerted early of breakages

I love this, particularly testing with the latest versions even when not using them yet.
For the `reproducible = False` extension, it sounds like there is a general expectation that it is reproducible, but you get a warning if something changes.

Does that mean that every bazel command will refetch the toolchain to check? Or only when it happens to be missing from cache?
Wow, this is very cool. I haven’t been following the Bazel modules stuff, so I had no idea it could handle external dependencies now.
Is “control handoff is easily avoided by not doing it” oversimplified? Don’t give control to anyone, but even professional maintainers add new maintainers eventually. Things like two party review requirements help reduce risk by ensuring another human reviews changes even by other maintainers.
Reposted by Michael Pratt
To implement robust mitigations across Geomys, I did a survey of open source project compromises in 2024/2025.

Three root causes dominate: phishing, control handoff, and unsafe GitHub Actions triggers. All three can be systematically avoided.

words.filippo.io/compromise-s...
A Retrospective Survey of 2024/2025 Open Source Supply Chain Compromises
Project compromises have common root causes we can mitigate: phishing, control handoff, and unsafe GitHub Actions triggers.
words.filippo.io
Are you looking for slices.Collect or maps.Collect?

pkg.go.dev/slices#Collect
pkg.go.dev
In all seriousness, check out Birria-Landia if you find yourself nearby.
Reposted by Michael Pratt
Go @golang.org · 23d
🥳 Go 1.25.2 and 1.24.8 are released!

📢 Announcement: https://groups.google.com/g/golang-announce/c/4Emdl2iQ_bI/m/qZN5nc-mBgAJ

📦 Download: https://go.dev/dl/#go1.25.2

#golang
Time to go simplify my jj + Gerrit guide…
There is also nice set of resellers that I’ve learned when I see they are the only seller listed it just means the hotel is sold out.
I hate this so much. I’ve slowly grown heuristics for ignoring them, but it’s so annoying to have lovely map full of lies.
Reposted by Michael Pratt
We are thrilled to announce that our NEW Large Language Model will be released on 11.18.25.
No, I wouldn't reach for execution tracing first for memory usage issues. I suggest looking at a heap profile from runtime/pprof, as well as the breakdown of memory types in runtime/metrics (pkg.go.dev/runtime/metr...) /memory/classes/... metrics to verify that the leak is in Go memory.
metrics package - runtime/metrics - Go Packages
pkg.go.dev
Reposted by Michael Pratt
Fun little Go compiler CL merged today: go.dev/cl/706655

Uninlined generic functions have a "dict" arg, since Go generics are neither erased nor monomorphized, but instead instantiated for each "GC shape" (e.g. T=*int and T=*float64 get the same code, but T=int32 and T=int64 do not).
I'd love to hear from folks about your experiences. Do you use execution tracing often. If not, is it due to lack of need, lack of documentation, missing information, tooling issues, etc?