* include/bits/locale_classes.h (locale::_Impl::_M_install_cache):
Move out of line.
* src/locale.cc: Define here, add mutex.
* configure.ac (libtool_VERSION): To 6:7:0.
* configure: Regenerate.
* testsuite/testsuite_abi.cc (check_version): Add GLIBCXX_3.4.7.
* config/linker-map.gnu: Export locale::_Impl::_M_install_cache.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@105221
138bc75d-0d04-0410-961f-
82ee72b054a4
+2005-10-10 Benjamin Kosnik <bkoz@redhat.com>
+
+ * configure.ac (libtool_VERSION): To 6:7:0.
+ * configure: Regenerate.
+ * testsuite/testsuite_abi.cc (check_version): Add GLIBCXX_3.4.7.
+ * config/linker-map.gnu: Export locale::_Impl::_M_install_cache.
+
+2005-10-10 Ian Lance Taylor <ian@airs.com>
+
+ PR libstdc++/13583
+ * include/bits/locale_classes.h (locale::_Impl::_M_install_cache):
+ Move out of line.
+ * src/locale.cc: Define here, add mutex.
+
2005-10-09 Paolo Carlini <pcarlini@suse.de>
PR libstdc++/24061 (issue 6.19)
std::locale::[A-Zj-z]*;
std::locale::_[A-Ha-z]*;
std::locale::_Impl::[A-Za-z]*;
- std::locale::_Impl::_M_[A-Za-z]*;
+# std::locale::_Impl::_M_[A-Za-z]*;
std::locale::_[J-Ra-z]*;
std::locale::_S_normalize_category*;
std::locale::_[T-Za-z]*;
_ZNSt19istreambuf_iteratorI[cw]St11char_traitsI[cw]EEppEv;
+ # std::locale::Impl _M_ members
+ _ZNSt6locale5_Impl16_M_install_facetEPKNS_2idEPKNS_5facetE;
+ _ZNSt6locale5_Impl16_M_replace_facetEPKS0_PKNS_2idE;
+ _ZNSt6locale5_Impl19_M_replace_categoryEPKS0_PKPKNS_2idE;
+ _ZNSt6locale5_Impl21_M_replace_categoriesEPKS0_i;
+
# DO NOT DELETE THIS LINE. Port-specific symbols, if any, will be here.
local:
_ZNKSt15basic_stringbufIwSt11char_traitsIwESaIwEE3strEv;
- _ZN9__gnu_cxx6__poolILb1EE13_M_initializeEv;
+ _ZN9__gnu_cxx6__poolILb1EE13_M_initializeEv;
} GLIBCXX_3.4.5;
+GLIBCXX_3.4.7 {
+
+ _ZNSt6locale5_Impl16_M_install_cacheEPKNS_5facetE[jm];
+
+} GLIBCXX_3.4.6;
+
# Symbols in the support library (libsupc++) have their own tag.
CXXABI_1.3 {
### am handles this now? ORIGINAL_LD_FOR_MULTILIBS=$LD
# For libtool versioning info, format is CURRENT:REVISION:AGE
-libtool_VERSION=6:6:0
+libtool_VERSION=6:7:0
# Find the rest of the source tree framework.
### am handles this now? ORIGINAL_LD_FOR_MULTILIBS=$LD
# For libtool versioning info, format is CURRENT:REVISION:AGE
-libtool_VERSION=6:6:0
+libtool_VERSION=6:7:0
AC_SUBST(libtool_VERSION)
# Find the rest of the source tree framework.
{ _M_install_facet(&_Facet::id, __facet); }
void
- _M_install_cache(const facet* __cache, size_t __index) throw()
- {
- __cache->_M_add_reference();
- _M_caches[__index] = __cache;
- }
+ _M_install_cache(const facet*, size_t);
};
template<typename _Facet>
#include <cwctype> // For towupper, etc.
#include <locale>
#include <bits/atomicity.h>
+#include <bits/concurrence.h>
+
+namespace __gnu_internal
+{
+ // Mutex object for cache access
+ static __glibcxx_mutex_define_initialized(locale_cache_mutex);
+}
namespace std
{
}
}
+ void
+ locale::_Impl::
+ _M_install_cache(const facet* __cache, size_t __index)
+ {
+ __gnu_cxx::lock sentry(__gnu_internal::locale_cache_mutex);
+ if (_M_caches[__index] != 0)
+ {
+ // Some other thread got in first.
+ delete __cache;
+ }
+ else
+ {
+ __cache->_M_add_reference();
+ _M_caches[__index] = __cache;
+ }
+ }
+
// locale::id
// Definitions for static const data members of locale::id
_Atomic_word locale::id::_S_refcount; // init'd to 0 by linker
known_versions.push_back("GLIBCXX_3.4.4");
known_versions.push_back("GLIBCXX_3.4.5");
known_versions.push_back("GLIBCXX_3.4.6");
+ known_versions.push_back("GLIBCXX_3.4.7");
known_versions.push_back("CXXABI_1.3");
known_versions.push_back("CXXABI_1.3.1");
}