I often look at my map files to get a feel for how large my code is, and have yet to have a problem with code size.
But... I think that my Makefile _should_ tell sdcc to check the code size for the processor, and the RAM size too. First, I found the linker options -I and -C and added this in Makefile: OVFL = "-Wl -I0x0800,-C0x4000" Now Makefile looks like this (trimmed): SDCC = sdcc -mstm8 -I../libs -L../libs -DSTM8103 OVFL = "-Wl -I0x0800,-C0x2000" LIBS = ... OBJS = ... .rel.ihx : $(SDCC) $(OVFL) $< $(LIBS) I then reduced the code size from 8K to 0x0a00 for code that is just over 0x0a00 in size. Here is the end of the map file: 00008A74 _clock_cal_get lib_clock 00008A97 _clock_cal_set lib_clock But sdcc and linker do not complain! Okay, I find the options --iram-size and --code-size and change my Makefile: OVFL = --iram-size 1024 --code-size 0x0a00 The result is: sdcc -mstm8 -I../libs -L../libs -DSTM8103 --iram-size 1024 --code-size 0x0a00 test_w1209.rel lib_stm8.lib With no complaint. I know I am missing something, but what is it? Thanks! -Richard _______________________________________________ Sdcc-user mailing list Sdcc-user@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/sdcc-user