Guillermo Adrián Molina writes:
Once everything is compiled I generate an assembler file for every class, for example ClassName.s. This could be a little confusing. I already compiled everything, why would I need to generate assembler files? Because assembler files are very handy to represent the image, take a look into a real method:
/* Test>>test Method bytecodes */ .global Test_Class_test_bytecodes Test_Class_test_bytecodes: .int ByteArray + 1 .int 154 /* Number: 77 */ .int 17888 /* Number: 8944 */ .global _Test_Class_test_bytecodes _Test_Class_test_bytecodes: .byte 85, 137, 229, 139, 69, 8, 80, 184 .int Test_Class_test_literals + 1 .byte 139, 64, 11, 232 .int getMethodIP - 4 - . .byte 255, 208, 129, 196, 4, 0, 0, 0, 139, 69, 8, 80, 184 .int Test_Class_test_literals + 1 .byte 139, 64, 15, 232 .int getMethodIP - 4 - . .byte 255, 208, 129, 196, 4, 0, 0, 0, 80, 184 .int Test_Class_test_literals + 1 .byte 139, 64, 19, 232 .int getMethodIP - 4 - . .byte 255, 208, 129, 196, 4, 0, 0, 0, 201, 195 .align 2
The first versions of Exupery generated gas assembly which I compiled then linked against C support code. Even after Exupery could compile inline I kept the code around to generate assembly instructions for several releases. It eventually got deleted as it wasn't adding any value.
If you're planning on continuing generating assembly then it might be worthwhile to try and find the code to produce assembly and update it to deal with the current instruction selector and the instructions that have been added since I stopped maintaining it.
Bryce