I'm an Infrastructure Engineer at Stripe and a fifth-year PhD candidate in the PLASMA Lab at UMass Amherst, advised by Emery Berger. My research interests span systems and programming languages, with a focus on making existing software more efficient, more secure, and usable in new contexts.

Weblog

Shared Anonymous Pages

Shared anonymous pages on Linux conflate two desirable types of sharing: aliasing memory within a process and aliasing memory between processes. Both of these types of sharing are useful, but it is not currently possible to choose only one or the the other on Linux today, AFAICT. Unfortunately, fixing this is hard.


Paper Review: µTune

µTune (OSDI 2018) presents a novel, adaptive threading model to minimize RPC latency regardless of current load in high-performance microservices. Traditional monolithic web applications have latency Service-level objectives (SLOs) in the range of 10s to 100s of milliseconds. Because responding to a user’s request in a microservice-based application may depend on many on sub-requests fanning out to dozens (or hundreds) of microservices, the latency budget for each internal request must be much shorter than that of the overall request, often on the order of single-digit milliseconds or less.


Understanding Kubernetes Ingress

I’ve become super excited about Kubernetes and its model of declarative configurations backed by controllers. You tell Kubernetes what you want, and the system (hopefully) eventually converges to your desired state. The docs, including books like the excellent Kubernetes Up And Running, do a great job explaining how to specify things like Pods and Deployments, and giving a high level intuition for how their controllers work (are there enough running pods for this deployment? If not, start a new one).

The concept that has taken me the longest to get a grasp on has been Ingress controllers.


2017 Year in Review

This has been a whirlwind year! I completed my final set of coursework towards my PhD and was admitted to PhD candidacy with distinction! Gwen and I celebrated our 1 year wedding anniversary, and had several other significant personal milestones. I presented several projects at regional and international academic conferences, and submitted my second publication on a super-cool new memory management technique. I interned on the Mobility and Networking team at Microsoft Research, and finally I am set to start as an Infrastructure Engineer at Stripe next week.


PLDI 2016

I just got back from the 2016 Programming Language Design and Implementation (PLDI) conference (my first PLDI!) in Santa Barbara, along with the Programming Language Mentoring Workshop (PLMW). I met a ton of great people in the PL community and even snuck in some good talks.


Notes on systemd Internals

systemd is the init system used by the current versions of most major Linux distributions, including Debian, Red Hat, Ubuntu and Arch. One of its key features is reliable dependency management, building a dependency graph of services, and sequencing of services where unrelated services can be started in parallel, but dependencies are sequenced correctly.

Let’s walk through how systemd implements this. Of note - if you’re interested in what a modern C codebase that doesn’t care about backwards compatibility can look like, systemd is especially interesting.


Tomato Garlic Dipping Sauce

This is a Syracuse-local recipe, scaled down from here. The goal is to match Cheeky Monkey’s sauce – I think we’re 80% of the way there but there is still some tweaking to do.


Notes on 'Practical FS Design'

I recently finished Practical File System Design by Dominic Giampaolo - a great read on filesystem implementation. Some aspects of the book are dated (initially published in 1999), but it does (lightly) discuss multithreading issues, which are absent from much of the classic UNIX literature. The three topic covered I felt were especially notable are journaling, indexing, and the comparison with other filesystems.


Optimizing real-world Go

This is about some fun I had while putting together a small Unix-y utility to measure RAM and swap usage - psm. I was able to decrease runtime by more than 65% during a 3-hour train ride with the help of some standard go tools.


Research

Mesh

Programs written in C/C++ can suffer from serious memory fragmentation, leading to low utilization of memory, degraded performance, and application failure due to memory exhaustion. Mesh is a plug-in replacement for malloc that, for the first time, eliminates fragmentation in unmodified C/C++ applications. Mesh combines novel randomized algorithms with widely-supported virtual memory operations to provably reduce fragmentation, breaking the classical Robson bounds with high probability. Mesh generally matches the runtime performance of state-of-the-art memory allocators while reducing memory consumption; in particular, it reduces the memory of consumption of Firefox by 16% and Redis by 39%.

Browsix

Programs written to run on conventional operating systems typically depend on OS abstractions like processes, pipes, signals, sockets, and a shared file system. Compiling programs into JavaScript, asm.js, or WebAssembly with tools like Emscripten or GopherJS isn't enough to successfully run many programs client-side, as browsers present a non-traditional runtime environment that lacks OS functionality. Porting these applications to the web currently requires extensive rewriting or paying to host significant portions of code in the cloud.

Browsix answers these challenges, with:

Processes: Unmodified C, C++, Go, and Node.js programs run as processes on Web Workers, executing in-parallel with the main browser thread – no need to worry about long-running computations blocking event-handling or page rendering.

Kernel + System Calls: By working at the lowest levels of abstraction, Browsix provides shared resources to multiple language runtimes, just as traditional operating systems enable running programs written in a host of languages.

Scalability: By enabling a large class of programs (including legacy codebases) to run in-browser, Browsix can free you from the chore of sandboxing and load-balancing programs server-side.

Projects

Systems

psm

Utility for fast, accurate RAM and swap reporting

slackfs

FUSE filesystem for Slack, and tmux-based UI

Web

seshcookie

HTTP sessions stored in encrypted cookies for Go

btscale

Reverse-engineered JavaScript API to the Acaia scale

System Dynamics

Simlin

Web-based System Dynamics model editor

boosd

Declarative language for object-oriented SD models, implemented in Go

Contributions

System Dynamics

System Dynamics is a methodology for debugging your mental models of the world. It does this by getting you to write down your assumptions as a model, simulate that model over time, compare the results to historical data, and project into the future. If the results based on your assumptions don't match the real data, you should consider changing your mental model! If the projection into the future doesn't look as you'd like, you are forced to be explicit with where and how your improved policies will influence the model. I wrote a thesis on object-oriented system dynamics as an approach to manage complexity and reuse models.

I'm slowly working on a web-based editor for SD models called Simlin, focused on simplicity and usability:


Go

I've authored a number of small changes, including a fix for a compiler crash. I found a nice little performance improvement in the time package. Previously, I've fixed issues in HTTP headers, JSON support, gob encoding, and the build system.

Linux kernel

I helped test and fixup the initial x32 pseudo-arch support in 00194b2e, ce5f7a99, and f044db4c. f75a8df3 and 10db4e1e address spurious and actual warnings emitted during kernel builds. More recently I've fixed an issue in the x86 FPU code with c88d4748.

Git

I found and fixed some issues with git diff --no-index in 176a3354 and f3999e03.

One Laptop Per Child

I was an intern and community member of OLPC. I diagnosed and fixed some bugs (like this one), worked on a System Dynamics activity named Model to enable students to do system dynamics modeling on the XOs, and rewrote the boot animation in C (from Python), cutting 12 seconds off the boot time for hundreds of thousands of laptops.