Java bytecode specification [closed]

2020-05-11 10:44发布

Is there a nice place for learning the JVM bytecode instruction set. The specification perhaps and maybe some tutorials?

I ask because I would like to design a toy language and a compiler for it that generates JVM bytecode.

Thanks for your knowledge and perhaps googling.

9条回答
我欲成王,谁敢阻挡
2楼-- · 2020-05-11 11:13

Also useful are the javap disassembler and bytecode manipulation frameworks like ASM and BCEL, even if all you want to do is verify your classes.

查看更多
走好不送
3楼-- · 2020-05-11 11:17

Perhaps check out Preon's example on how to parse a Java class file. It has a fairly complete representation of the bytecode in a Java object model.

查看更多
淡お忘
4楼-- · 2020-05-11 11:20

To start with, I suggest generating Java code from your language.

This will make reading and debugging much simpler.

查看更多
登录 后发表回答