Date: Tue, 6 May 2008 09:27:41 +0000 (UTC) From: Konstantin Belousov <kib@FreeBSD.org> To: src-committers@FreeBSD.org, cvs-src@FreeBSD.org, cvs-all@FreeBSD.org Subject: cvs commit: src/libexec/rtld-elf rtld.c rtld_lock.c rtld_lock.h Message-ID: <200805060927.m469Rfjr034972@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
kib 2008-05-06 09:27:41 UTC FreeBSD src repository Modified files: libexec/rtld-elf rtld.c rtld_lock.c rtld_lock.h Log: 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 <an at atrn org> Reviewed by: kan MFC after: 2 weeks Revision Changes Path 1.126 +5 -3 src/libexec/rtld-elf/rtld.c 1.5 +2 -1 src/libexec/rtld-elf/rtld_lock.c 1.3 +1 -0 src/libexec/rtld-elf/rtld_lock.h
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200805060927.m469Rfjr034972>