On Mon, 04 Jan 2010, Carlos O'Donell wrote: > On Mon, Jan 4, 2010 at 11:27 AM, Helge Deller <deller@xxxxxx> wrote: > This is wrong. Each thread should have 8MB of stack. If we only get ~ > 0x40 bytes then npt/nptl-init.c is setting __default_stacksize > incorrectly. The 0x40 bytes is the initial frame allocated for clone running in the child thread. The code is not running out of stack space. > Even PTHREAD_STACK_MIN should be 16kb? > > Could you verify that your assertion that only ~ 0x40 bytes of initial > room were allocated? > > > e) Thus the child either crashes, overwrites memory of the parent or does other things wrong. > > I agree with your analysis, but the error is that more stack should be > allocated. I don't follow that conclusion. The stack grows upward and the stack pointer isn't out of range. The fork operation is somehow corrupting the stack memory of the thread created by pthread_create. I would say the parent is corrupting its own memory. I doubt the forked child is affecting the parent. Fork would have to behave like vfork to do this. I have seen the pthread_create thread fail before the clone syscall of the following fork. Dave -- J. David Anglin dave.anglin@xxxxxxxxxxxxxx National Research Council of Canada (613) 990-0752 (FAX: 952-6602) -- To unsubscribe from this list: send the line "unsubscribe linux-parisc" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html