AnsweredAssumed Answered

Replacing ansif.lib by ansii.lib does not make code smaller--why not?

Question asked by Cab Jones on Jan 30, 2012
Latest reply on Jan 30, 2012 by Iulia Romaniuc

Using HC908JL12 with CW 6.3 and XP.  I see that ansif.lib is very much larger than ansii.lib, so I eliminated a few floating calculations and replaced ansif.lib by ansii.lib.  Yet it appears that my code is the same size regardless which library I use.  I do not know the structure of these libraries.  I imagine it is possible for the linker to only link in the required routines but that kind of precision would be surprising.  I am new to CW and may not be looking at the right numbers in the .map file.  It lists many NOT USED PROCEDURES (and they are different) which I expect is (different) wasted space in Flash.  In both .map files I have these identical sections:


Processor   : Freescale HC08
Memory Model: SMALL
File Format : ELF\DWARF 2.0
Linker      : SmartLinker V-5.0.37 Build 9279, Oct  7 2009

Summary of section sizes per section type:
READ_ONLY (R):         16FE (dec:     5886)
READ_WRITE (R/W):    AB (dec:      171)
NO_INIT (N/I):                  63 (dec:       99)


Isn't 5886 the majority of Flash?  I know there are a few other contributions, but nothing that would change when the library is changed.


Are your libraries and linker that brilliant, or what am I missing?