From owner-cvs-all@FreeBSD.ORG Tue May 20 09:38:45 2008 Return-Path: Delivered-To: cvs-all@FreeBSD.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 71F921065671; Tue, 20 May 2008 09:38:45 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id 619178FC39; Tue, 20 May 2008 09:38:44 +0000 (UTC) (envelope-from kib@FreeBSD.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.1/8.14.1) with ESMTP id m4K9ci1q010232; Tue, 20 May 2008 09:38:44 GMT (envelope-from kib@repoman.freebsd.org) Received: (from kib@localhost) by repoman.freebsd.org (8.14.1/8.14.1/Submit) id m4K9cid3010231; Tue, 20 May 2008 09:38:44 GMT (envelope-from kib) Message-Id: <200805200938.m4K9cid3010231@repoman.freebsd.org> From: Konstantin Belousov Date: Tue, 20 May 2008 09:38:44 +0000 (UTC) To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org X-FreeBSD-CVS-Branch: RELENG_7 Cc: Subject: cvs commit: src/libexec/rtld-elf rtld.c rtld_lock.c rtld_lock.h X-BeenThere: cvs-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: CVS commit messages for the entire tree List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 20 May 2008 09:38:45 -0000 kib 2008-05-20 09:38:44 UTC FreeBSD src repository Modified files: (Branch: RELENG_7) libexec/rtld-elf rtld.c rtld_lock.c rtld_lock.h Log: MFC rev. 1.126 of libexec/rtld-elf/rtld.c rev. 1.5 of libexec/rtld-elf/rtld_lock.c rev. 1.3 of libexec/rtld-elf/rtld_lock.h Fix the problem with the C++ exception handling for the multithreaded programs. From the PR description: The gcc runtime's _Unwind_Find_FDE function, invoked during exception handling's stack unwinding, is not safe to execute from within multiple threads. FreeBSD' s dl_iterate_phdr() however permits multiple threads to pass through it though. The result is surprisingly reliable infinite looping of one or more threads if they just happen to be unwinding at the same time. Introduce the new lock that is write locked around the dl_iterate_pdr, thus providing required exclusion for the stack unwinders. PR: threads/123062 Submitted by: Andy Newman Reviewed by: kan Revision Changes Path 1.124.2.1 +5 -3 src/libexec/rtld-elf/rtld.c 1.4.2.1 +2 -1 src/libexec/rtld-elf/rtld_lock.c 1.2.20.1 +1 -0 src/libexec/rtld-elf/rtld_lock.h