A long time ago I had some grad students write a compiler infrastructure for TrueType bytecode. Maybe it's mostly bit-rotted, but if someone were interested in working on this, I could try to help.
When I get some time, I’d be happy to look into this. I’ve been doing some compiler-adjacent stuff recently (mostly type inference), and this seems like a very interesting application of those ideas. Regards, Brad