Code was 28.8 KB of the ~32 KB a single 68k code resource can reach. visormesh.def declares section vmcode2; multigen generates the stub and linker script; build-prc takes the name, creator and backup bit from the .def. protocol.c and ui/text.c move there (segment 1 now 24.3 KB, segment 2 4.9 KB). Every function in them, static ones too, is declared VM_SECT2 so calls from segment 1 go through the __text__vmcode2 jump base, and their two static const tables became plain data, since const data stays in segment 1 where PC-relative code in segment 2 can't reach it. The rules are in src/sections.h. Checked in the objects: no .text left in the moved files, cross-segment calls go through the section bases.
3 lines
68 B
Modula-2
3 lines
68 B
Modula-2
application { "VisorMesh" VMsh backup }
|
|
multiple code { "vmcode2" }
|