This is the mail archive of the binutils@sourceware.org mailing list for the binutils project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

relations between Linker and Map File


I'm using as to assemble for source code. This
requires a file called "filenam.link", : 

------------------------------------------------
    MEMORY
{
	/*The start up code in internal ROM*/
	introm  : o = 0x0000, l = 0x0c000 
	
	/*Initial dummy code in main code */
	zero_start : o = 0x10000, l = 0x00002

	/*Main code*/
	execcode  : o = 0x10002, l = 0x10000 
	
	/* The stack starts at the top of main ram.  */
	dram      : o = 0x20000 ,  l = 0x10000
	
	/* At the very top of the address space is the 8-bit
area.  */
	
	stack 	  : o = 0x9000  , l = 0xA000
        /* User stack area */	
 }
-----------------------------------------------------

I think this file is used to decides where the data an
code will be allocated in memory. 

But now I want to change it, I want the code area will
including many areas which are not continueous in
memory. I don't know if this is possible. 

And where in the binutils code that allocate exact
address for every variables  ? I want to look at this
code so that can understand more about the way GCC do.
Can you give me some hints ? 

Thank you very much. 


      


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]