AVR ISR causes unexpected behavior
I hate myself for this. How I was compiling:

avr-gcc -o build/src/main.o -c -Wall -g -Os -mmcu=attiny2313 src/main.c 
avr-gcc -o build/main.elf build/src/main.o


How I should have been:

avr-gcc -o build/src/main.o -c -Wall -Os -mmcu=attiny2313 -std=c99 -ffunction-sections -fdata-sections src/main.c
avr-gcc -o build/main.elf -mmcu=attiny2313 build/src/main.o


The actual culprit was not passing the -mmcu flag to the linker, but adding -ffunction-sections and -fdata-sections also cured some weird problems I was having when using external header files.