AnsweredAssumed Answered

Can _user_heap_stack be moved to m_data_20000000 section?

Question asked by Michael Economides on Mar 23, 2015
Latest reply on Sep 29, 2015 by David Tietz

I'm using MK22 with 128k of RAM.  As noted in the reference manual, the memory is split into two 64k sections, SRAM upper and SRAM lower, with middle boundary at 0x20000000.


I have  _user_heap_stack set to 32k... but it's too big to fit in the m_data section (SRAM lower).  So I would like it to move to m_data_20000000 (SRAM upper).


I don't see an option for this in Processor Expert's component inspector (CPU --> Build Options --> Generate Linker).  It only allows me to change the size of the heap, not which section in RAM.


Another option someone suggested, is to disable m_data_20000000 section entirely, and bump up the size of m_data to use the full 128k (instead of half).  But the reference manual says you cannot do burst reads across that boundary, and others have posted saying misaligned reads/writes don't work across the boundary either.  I don't know if this would cause problems for me, but I'd rather not risk it.


Any help would be appreciated,