Storing an array

Nick.SIMON at Nick.SIMON at
Mon Jun 19 10:23:58 UTC 2000

> -----Original Message-----
> From: Jorge Andreu Garca [mailto:andreu at]
> Sent: 19 June 2000 09:11
> To: rtems
> Subject: Storing an array
> Hello:
> I want to use an array of  120.000 integersin a program that 
> should run
> on rtems, but I can't:
> When I store this in memory, the program stop when it read the
> declaration line of the array. 

If your program is executing a declaration it must be an automatic, i.e. on
the stack.  I doubt you have 480K bytes of stack space available!

> When I store it in heap (with a pointer
> in Ada) the computer reboot in the same line.

Putting it on the heap is probably the right thing - assuming you have
enough space in your heap.
If you have (or should have) it could be that your heap has become

The other valid way to store a large object is as a static or global, if
it's something thats needed continuously, or over & over again, in your

> Is there any function of rtems or any specification file where I can
> change the maximum size of the variables?

This is done in the BSP. Which are you using?  BTW do you really need 120
thousand integers? It does seem a lot.

> Any other ideas?
> Thanks:


-- Nick Simon 

More information about the users mailing list