From owner-svn-src-all@FreeBSD.ORG Sun Dec 7 02:32:50 2008 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 23599106564A; Sun, 7 Dec 2008 02:32:50 +0000 (UTC) (envelope-from peter@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 120338FC12; Sun, 7 Dec 2008 02:32:50 +0000 (UTC) (envelope-from peter@FreeBSD.org) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id mB72WnVP011585; Sun, 7 Dec 2008 02:32:49 GMT (envelope-from peter@svn.freebsd.org) Received: (from peter@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id mB72WnrR011584; Sun, 7 Dec 2008 02:32:49 GMT (envelope-from peter@svn.freebsd.org) Message-Id: <200812070232.mB72WnrR011584@svn.freebsd.org> From: Peter Wemm Date: Sun, 7 Dec 2008 02:32:49 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r185728 - head/lib/libthr/thread X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 07 Dec 2008 02:32:50 -0000 Author: peter Date: Sun Dec 7 02:32:49 2008 New Revision: 185728 URL: http://svn.freebsd.org/changeset/base/185728 Log: When libthr and rtld start up, there are a number of magic spells cast in order to get the symbol binding state "just so". This is to allow locking to be activated and not run into recursion problems later. However, one of the magic bits involves an explicit call to _umtx_op() to force symbol resolution. It does a wakeup operation on a fake, uninitialized (ie: random contents) umtx. Since libthr isn't active, this is harmless. Nothing can match the random wakeup. However, valgrind finds this and is not amused. Normally I'd just write a suppression record for it, but the idea of passing random args to syscalls (on purpose) just doesn't feel right. Modified: head/lib/libthr/thread/thr_rtld.c Modified: head/lib/libthr/thread/thr_rtld.c ============================================================================== --- head/lib/libthr/thread/thr_rtld.c Sun Dec 7 00:42:15 2008 (r185727) +++ head/lib/libthr/thread/thr_rtld.c Sun Dec 7 02:32:49 2008 (r185728) @@ -180,7 +180,7 @@ _thr_rtld_init(void) { struct RtldLockInfo li; struct pthread *curthread; - long dummy; + long dummy = -1; curthread = _get_curthread();