|
Relocating library program segmentsNext Thread | Thread List | Previous Thread Start a Thread | Settings | Details | Message |
|---|
Read-Only Author David Fussell Posted 11-Apr-2003 13:49 GMT Toolset C51 |  Relocating library program segments David Fussell In an attempt to free some code space, I'm considering the wisdom of relocating some library program segments from the common code area into one of my two banks. I'm a bit reluctant to do this for library functions (PRINTF, etc), but I'm assuming that any directive relocating these program segments is detected at link time, so the appropriate bank switch code will be inserted around calls to these functions as necessary.
I appreciate the slight performance 'hit' resulting from this action, but needs must etc...
Is this a wise thing to consider? | | Read-Only Author Ric Watson Posted 9-Feb-2004 13:41 GMT Toolset C51 |  RE: Relocating library program segments Ric Watson I don't see why you shouldn't. As a matter of interest, do you mean Keil library program segments? If so, how do you go about relocating them? | | Read-Only Author Andrew Neil Posted 9-Feb-2004 13:48 GMT Toolset C51 |  RE: Relocating library program segments Andrew Neil Have you considered other options, like moving constants into XDATA? (assuming you have spare XDATA space...) | | Read-Only Author Tech Dept Posted 9-Feb-2004 13:51 GMT Toolset C51 |  RE: Relocating library program segments Tech Dept Hi Andrew, I want to locate Keil library functions in a place in ROM other than the lowest 1kB, which is where they seem to reside by default. Ric. | | Read-Only Author David Fussell Posted 9-Feb-2004 14:12 GMT Toolset C51 |  RE: Relocating library program segments David Fussell I'd look at the map file to obtain segment names etc, and use either the CODE directive to move them around in the 'common area', or alternatively, for banking, via the approprite 'BANK' directive. | |
Next Thread | Thread List | Previous Thread Start a Thread | Settings |
|