main() mapped over several flash pages

cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

main() mapped over several flash pages

808 Views
Olitsch
Contributor I

Hi all !

 

I am using Codewarrior 4.5 with a MC9S12XDP512CAL.

 

I ran into a problem after my Main() went too big. I get the following error:

 

Link Error: L1102 Out of allocation space in segment PAGE_F7 at adress 0xF78229

 

I looked at the map file and the main() is indeed to big for a single segment. but there are more than enough free segments.

I allready tryed the "allocation over segment boundries" options of the linker, but the problem stays the same.

 

Is there anything else i have to adjust to allow the allocation over segment boundries?

Labels (1)
Tags (1)
0 Kudos
2 Replies

377 Views
Lundin
Senior Contributor IV

Err... if you wrote your program as a single, 16kb large function, this one is the least of your problems...

 

0 Kudos

377 Views
kef
Specialist I

You should split main() into two or more smaller functions and call them from main(). You can't allocate functions over page window boundaries, code won't run.

0 Kudos