From owner-freebsd-threads@FreeBSD.ORG Wed Sep 21 18:50:08 2005 Return-Path: X-Original-To: freebsd-threads@hub.freebsd.org Delivered-To: freebsd-threads@hub.freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id 7CD3016A41F for ; Wed, 21 Sep 2005 18:50:08 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [216.136.204.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 48ED943D45 for ; Wed, 21 Sep 2005 18:50:08 +0000 (GMT) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (gnats@localhost [127.0.0.1]) by freefall.freebsd.org (8.13.3/8.13.3) with ESMTP id j8LIo8Nb057705 for ; Wed, 21 Sep 2005 18:50:08 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.13.3/8.13.1/Submit) id j8LIo8DN057704; Wed, 21 Sep 2005 18:50:08 GMT (envelope-from gnats) Date: Wed, 21 Sep 2005 18:50:08 GMT Message-Id: <200509211850.j8LIo8DN057704@freefall.freebsd.org> To: freebsd-threads@FreeBSD.org From: Christopher Sean Morrison Cc: Subject: Re: kern/86029: undefined reference to `_thread_dump_info' X-BeenThere: freebsd-threads@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: Christopher Sean Morrison List-Id: Threading on FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 21 Sep 2005 18:50:08 -0000 The following reply was made to PR kern/86029; it has been noted by GNATS. From: Christopher Sean Morrison To: Daniel Eischen Cc: David Xu , bug-followup@freebsd.org Subject: Re: kern/86029: undefined reference to `_thread_dump_info' Date: Wed, 21 Sep 2005 14:42:12 -0400 On Sep 21, 2005, at 1:28 PM, Daniel Eischen wrote: > That's what SIGINFO is for. Again, that's undocumented and > allowed to change, but it's better than calling a library > internal function. Again, this is really tangent to the whole point of the report, but it does raise ab additional question. If I raise a SIGINFO, is that going to give identical detail about the current threading states? I agree that it's better means to the end. The OpenBSD pthreads(3) manual page does document the signal but I have not had a motivation to change/test that bit of code until now. >> I've got no issue removing the call from our code, but it seems >> indicative of a larger change to what -pthread means. If -pthread no >> longer implies linking against c_r for whatever reason, that would be >> the fundamental difference here that we'll need to accommodate in our >> build. In that regard, what non-private routine will provide similar >> details when thread creation fails? > > -pthread means do whatever is necessary to link in the threads > library. In 5.x and subsequent, the threads library is libpthread, > not libc_r. Which has always been my understanding of -pthread as well. Does this mean then that the C library routines on an AMD64 FreeBSD 5.4 system are supposed to be re-entrant and thread safe? If that's the case, then I probably have another bug report to make. It also doesn't explain the inconsistency with the same rev of FreeBSD on IA32 systems where the same behavior is not exhibited. Cheers! Sean