TRS80 zcc optimization
Posted: Thu Jun 03, 2021 4:26 am
I'm targeting a TRS80 (model 3). The code is compiling and running - now I'd like to explore optimization options. I understand zcc is a front-end that is doing a lot of things for me behind the scenes - but I'm little lost on what all that is (z88dk-z80asm.exe and zsdcc.exe?) and why I need -create-app
Here is what I'm using to compile:
zcc +trs80 -vn test.c utility.c core.c destiny_structs.c game_strings.c -create-app -subtype=disk -lndos -lm -o test
And it runs with the emulator like this:
trs80gp -m3 test.out -dx
-dx Disable floppy disk controller (boot into ROM BASIC)
Do I need -lndos? I tried passing optimize for speed, but I don't think it was working (probably not passed correctly). I think there are some TRS80 target examples, but they are all 1 single .c file.
In the cc65 world, I'd run cc65, ca65, then ld65 -- trying to clarify the equivalent aspects for z88dk.
Thanks!
Here is what I'm using to compile:
zcc +trs80 -vn test.c utility.c core.c destiny_structs.c game_strings.c -create-app -subtype=disk -lndos -lm -o test
And it runs with the emulator like this:
trs80gp -m3 test.out -dx
-dx Disable floppy disk controller (boot into ROM BASIC)
Do I need -lndos? I tried passing optimize for speed, but I don't think it was working (probably not passed correctly). I think there are some TRS80 target examples, but they are all 1 single .c file.
In the cc65 world, I'd run cc65, ca65, then ld65 -- trying to clarify the equivalent aspects for z88dk.
Thanks!