threads/76690: fork hang in child for (-lc_r & -lthr)
Farid Bavandpouri
fbavandpouri at amcc.com
Mon Oct 24 10:20:08 PDT 2005
Remove/unsubscribe mmontaseri at amcc.com
-----Original Message-----
From: owner-freebsd-threads at freebsd.org
[mailto:owner-freebsd-threads at freebsd.org] On Behalf Of Marc Olzheim
Sent: Monday, October 24, 2005 9:59 AM
To: Daniel Eischen
Cc: Marc Olzheim; freebsd-threads at freebsd.org; Marc Olzheim; David Xu;
Sven Berkvens-Matthijsse
Subject: Re: threads/76690: fork hang in child for (-lc_r & -lthr)
On Mon, Oct 24, 2005 at 12:41:01PM -0400, Daniel Eischen wrote:
> > But then the free() in the child process may be using an unstable
> > state of the malloc system (because if you don't acquire the lock
> > before the fork(), malloc() may be busy in the middle of the
fork()).
>
> I don't think that can happen because libc_r will not switch out a
> thread that is in a critical region (and libc locks are critical
> regions) until it leaves the region.
Well, that would be the idea, but GDB traces prove otherwise... :P And
that's why the patch prevents the test program in the PR from hanging.
Marc
--------------------------------------------------------
CONFIDENTIALITY NOTICE: This e-mail message, including any attachments, is for the sole use of the intended recipient(s) and contains information that is confidential and proprietary to Applied Micro Circuits Corporation or its subsidiaries. It is to be used solely for the purpose of furthering the parties' business relationship. All unauthorized review, use, disclosure or distribution is prohibited. If you are not the intended recipient, please contact the sender by reply e-mail and destroy all copies of the original message.
More information about the freebsd-threads
mailing list