For the code generation phase, it might be easier to bypass emitting a text-based assembly format and just use the ASM library directly. If you want something easier, I wrote a code generation library specifically for that purpose: https://github.com/cojen/Maker It also includes an example "Mini-C" language compiler.
Something else that could make your code generation for your JVM language easier: ProGuardCORE (https://github.com/Guardsquare/proguard-core). It can be used to read, generate and analyse Java bytecode.
What's the main difference compared to the ASM library? When I was still JVM stuff it was really on the right abstraction level for most things. (I was recently doing some .NET IL and gotta say that MS made it even easier to get started with DynamicMethod:s).
ProGuardCORE is very similar to ASM; they have a similar feature set and a similar visitor-based API. ProGuardCORE came about because ProGuard itself never used ASM when the project was started 20 years ago.
We split out ProGuardCORE from ProGuard 2 years ago, to provide as a library the core underlying bytecode manipulation & analysis tools that ProGuard and the Android security solution DexGuard both use.
Awesome! I started this for educational purposes too, but if it turns out to be useful then I'll be very happy! Hope it turns out that way (and let me know if there's anything else you need to make it useful! :) )
I have but Truffle was a bit further than I wanted to go for now. If I wanted to build a production ready language it would likely be my first choice though.
I have been toying with writing my own little JVM language (for education purposes) and this could go a long way to making that a bunch easier.
Thanks for sharing!