From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 8060 invoked by alias); 12 Sep 2005 04:49:41 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 8040 invoked by alias); 12 Sep 2005 04:49:36 -0000 Date: Mon, 12 Sep 2005 04:49:00 -0000 Message-ID: <20050912044936.8039.qmail@sourceware.org> From: "cvs-commit at gcc dot gnu dot org" To: gcc-bugs@gcc.gnu.org In-Reply-To: <20050705135434.22309.jakub@redhat.com> References: <20050705135434.22309.jakub@redhat.com> Reply-To: gcc-bugzilla@gcc.gnu.org Subject: [Bug libstdc++/22309] mt allocator doesn't pthread_key_delete it's keys X-Bugzilla-Reason: CC X-SW-Source: 2005-09/txt/msg01402.txt.bz2 List-Id: ------- Additional Comments From cvs-commit at gcc dot gnu dot org 2005-09-12 04:49 ------- Subject: Bug 22309 CVSROOT: /cvs/gcc Module name: gcc Changes by: bkoz@gcc.gnu.org 2005-09-12 04:49:11 Modified files: libstdc++-v3 : ChangeLog libstdc++-v3/config: linker-map.gnu libstdc++-v3/include/ext: mt_allocator.h libstdc++-v3/src: mt_allocator.cc libstdc++-v3/testsuite/lib: dg-options.exp libstdc++.exp Added files: libstdc++-v3/testsuite: testsuite_shared.cc libstdc++-v3/testsuite/ext/mt_allocator: 22309_thread.cc Log message: 2005-09-11 Benjamin Kosnik PR libstdc++/19265 PR libstdc++/22309 * include/ext/mt_allocator.h (__gnu_cxx::__create_handler): Remove. (__pool::_M_destroy_thread_key): Compatibility only. (__pool::_M_initialize(__destroy): Same. (__pool::_M_initialize): New. (__pool::_M_initialize_once): Nothing fancy. (__pool::_M_once): Remove. (__common_pool): New. (__common_pool_base): New. (__per_type_pool): New. (__per_type_pool_base): New. * src/mt_allocator.cc: Same. * config/linker-map.gnu (__pool::_M_initialize()): Add. 2005-09-11 Jakub Jelinek PR libstdc++/19265 PR libstdc++/22309 * src/mt_allocator.cc (__gnu_internal::freelist_mutex): Make static. (__gnu_internal::__freelist): New type. (__gnu_internal::freelist): New variable. (__gnu_internal::_M_destroy_thread_key): New function. (__gnu_cxx::__pool::_M_destroy): Don't delete _M_thread_freelist_initial. (__gnu_cxx::__pool::_M_initialize): Make argument nameless. Don't use _M_thread_freelist and _M_thread_freelist_initial __pool fields, instead use __gnu_internal::freelist fields, call gthread_key_create just once. Use __gnu_internal::_M_destroy_thread_key as key destructor. (__gnu_cxx::__pool::_M_get_thread_id): Store size_t id rather than _Thread_record* in the thread specific value. Don't use _M_thread_freelist __pool field, instead use __gnu_internal::freelist fields. (__gnu_cxx::__pool::_M_destroy_thread_key): Do nothing. 2005-09-11 Benjamin Kosnik Jakub Jelinek PR libstdc++/19265 PR libstdc++/22309 * testsuite/testsuite_shared.cc: New. * testsuite/lib/dg-options.exp (dg-require-sharedlib): New. * testsuite/lib/libstdc++.exp (libstdc++_init): Look for shared library, and set v3-sharedlib based on this. (check_v3_target_sharedlib): New. (proc v3-build_support): Build shared objects. * testsuite/ext/mt_allocator/22309_thread.cc: New, use above. Patches: http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libstdc++-v3/ChangeLog.diff?cvsroot=gcc&r1=1.3095&r2=1.3096 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libstdc++-v3/config/linker-map.gnu.diff?cvsroot=gcc&r1=1.84&r2=1.85 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libstdc++-v3/include/ext/mt_allocator.h.diff?cvsroot=gcc&r1=1.47&r2=1.48 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libstdc++-v3/src/mt_allocator.cc.diff?cvsroot=gcc&r1=1.12&r2=1.13 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libstdc++-v3/testsuite/testsuite_shared.cc.diff?cvsroot=gcc&r1=NONE&r2=1.1 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libstdc++-v3/testsuite/ext/mt_allocator/22309_thread.cc.diff?cvsroot=gcc&r1=NONE&r2=1.1 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libstdc++-v3/testsuite/lib/dg-options.exp.diff?cvsroot=gcc&r1=1.4&r2=1.5 http://gcc.gnu.org/cgi-bin/cvsweb.cgi/gcc/libstdc++-v3/testsuite/lib/libstdc++.exp.diff?cvsroot=gcc&r1=1.45&r2=1.46 -- http://gcc.gnu.org/bugzilla/show_bug.cgi?id=22309