[LCP]Threads in Linux

Vincent Penquerc'h Vincent.Penquerch at artworks.co.uk
Mon Jun 24 22:38:05 UTC 2002


> I have a program in C++ in Linux which is using large arrays 
> (150000) inside a function, which called by a thread. After 
> compiling the same program in other platforms I am getting 
> weird run time errors, related to the stack and my 
> application crashes.
> 
> question: using large arrays in that way is a problem with 
> other platforms, like HP-UX or Solaris ?

automatic arrays go on the stack, which is limited on some
systems. Try adding a static (turning a stack auto array
into a global bss array).

-- 
Vincent Penquerc'h 
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.linux.org.au/pipermail/linuxcprogramming/attachments/20020624/e4f955ca/attachment.htm 


More information about the linuxCprogramming mailing list