aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid E. O'Brien <obrien@FreeBSD.org>2012-07-03 06:54:37 +0000
committerDavid E. O'Brien <obrien@FreeBSD.org>2012-07-03 06:54:37 +0000
commitd27994699127cfb0a68b75b378e706264c0441ec (patch)
tree92264ba3275e8085ec1b73ed44742739a3c0de49
parentfc6f4da7ef50661fa68ca8c1d4175122df331cf0 (diff)
downloadsrc-d27994699127cfb0a68b75b378e706264c0441ec.tar.gz
src-d27994699127cfb0a68b75b378e706264c0441ec.zip
Vendor import the latest GPLv2 libstdc++ sources.
It happens to be that while libstdc++ is a subset of gcc which was changed to GPLv3, libstdc++ was kept under LGPLv2 until the end of the 4.2 branch (gcc 4.2.4) (@ GRN 135556). Obtained from: svn://gcc.gnu.org/svn/gcc/branches/gcc-4_2-branch/libstdc++-v3 Requested by: pfg Reviewed by: pfg
Notes
Notes: svn path=/vendor/gcc/dist/; revision=238052
-rw-r--r--libstdc++/ChangeLog130
-rw-r--r--libstdc++/config/os/aix/os_defines.h7
-rw-r--r--libstdc++/include/bits/allocator.h10
-rw-r--r--libstdc++/include/bits/basic_string.h26
-rw-r--r--libstdc++/include/bits/fstream.tcc2
-rw-r--r--libstdc++/include/bits/locale_facets.tcc8
-rw-r--r--libstdc++/include/ext/atomicity.h2
-rw-r--r--libstdc++/include/ext/codecvt_specializations.h6
-rw-r--r--libstdc++/include/ext/concurrence.h2
-rw-r--r--libstdc++/include/ext/vstring.h26
-rw-r--r--libstdc++/include/tr1/boost_shared_ptr.h2
-rw-r--r--libstdc++/include/tr1/random9
-rw-r--r--libstdc++/libsupc++/eh_personality.cc4
-rw-r--r--libstdc++/libsupc++/typeinfo14
-rwxr-xr-xlibstdc++/scripts/check_compile57
-rw-r--r--libstdc++/src/valarray-inst.cc2
16 files changed, 258 insertions, 49 deletions
diff --git a/libstdc++/ChangeLog b/libstdc++/ChangeLog
index d915bcf66fbe..2236fe957842 100644
--- a/libstdc++/ChangeLog
+++ b/libstdc++/ChangeLog
@@ -1,3 +1,133 @@
+2008-05-19 Release Manager
+
+ * GCC 4.2.4 released.
+
+2008-03-13 David Edelsohn <edelsohn@gnu.org>
+
+ Backport from mainline:
+ 2008-01-26 David Edelsohn <edelsohn@gnu.org>
+
+ PR target/34794
+ * config/os/aix/os_defines.h: Define __COMPATMATH__.
+
+2008-02-14 Kaveh R. Ghazi <ghazi@caip.rutgers.edu>
+
+ * testsuite/27_io/fpos/14320-1.cc: Check for "long long" and
+ remove XFAIL.
+
+2008-02-01 Release Manager
+
+ * GCC 4.2.3 released.
+
+2008-01-06 Ted Phelps <phelps@gnusto.com>
+
+ PR c++/34152
+ * libsupc++/eh_personality.cc (PERSONALITY_FUNCTION): Check
+ _GLIBCXX_HAVE_GETIPINFO instead of HAVE_GETIPINFO.
+
+2008-01-05 Paolo Carlini <pcarlini@suse.de>
+
+ PR libstdc++/34680
+
+ Revert:
+ 2007-12-17 Jonathan Wakely <jwakely.gcc@gmail.com>
+ * include/bits/locale_facets.tcc (has_facet, use_facet): Simplify
+ RTTI checks.
+
+ 2007-12-14 Benjamin Kosnik <bkoz@redhat.com>
+
+ PR libstdc++/30127
+ PR libstdc++/34449
+ * include/bits/locale_facets.tcc (use_facet): Check facet hierarchy.
+ (has_facet): Same.
+ * testsuite/22_locale/global_templates/user_facet_hierarchies.cc: New.
+ * testsuite/22_locale/global_templates/
+ standard_facet_hierarchies.cc: New.
+
+2007-12-17 Jonathan Wakely <jwakely.gcc@gmail.com>
+
+ * include/bits/locale_facets.tcc (has_facet, use_facet): Simplify
+ RTTI checks.
+
+2007-12-17 Benjamin Kosnik <bkoz@redhat.com>
+
+ * testsuite/22_locale/global_templates/
+ standard_facet_hierarchies.cc: Fix for generic locale model.
+
+2007-12-14 Benjamin Kosnik <bkoz@redhat.com>
+
+ PR libstdc++/30127
+ PR libstdc++/34449
+ * include/bits/locale_facets.tcc (use_facet): Check facet hierarchy.
+ (has_facet): Same.
+ * testsuite/22_locale/global_templates/user_facet_hierarchies.cc: New.
+ * testsuite/22_locale/global_templates/
+ standard_facet_hierarchies.cc: New.
+
+2007-11-26 Paolo Carlini <pcarlini@suse.de>
+
+ * include/bits/locale_facets.tcc (num_put<>::_M_insert_int): When
+ ios_base::showpos and the type is signed and the value is zero,
+ prepend +.
+ * testsuite/22_locale/num_put/put/char/12.cc: New.
+ * testsuite/22_locale/num_put/put/wchar_t/12.cc: Likewise.
+
+2007-10-20 Paolo Carlini <pcarlini@suse.de>
+
+ * include/tr1/random
+ (uniform_int<>::_M_call(_UniformRandomNumberGenerator&, result_type,
+ result_type, true_type)): Fix small thinko.
+
+2007-10-19 Paolo Carlini <pcarlini@suse.de>
+
+ PR libstdc++/33815
+ * include/tr1/random
+ (uniform_int<>::_M_call(_UniformRandomNumberGenerator&, result_type,
+ result_type, true_type)): Avoid the modulo (which uses the low-order
+ bits).
+
+2007-10-18 Paolo Carlini <pcarlini@suse.de>
+
+ PR libstdc++/33807
+ * include/bits/allocator.h (operator==(const allocator<_Tp>&,
+ const allocator<_Tp>&), operator!=(const allocator<_Tp>&,
+ const allocator<_Tp>&)): Add.
+ * testsuite/20_util/memory/allocator/33807.cc: New.
+
+2007-10-14 Jonathan Wakely <jwakely.gcc@gmail.com>
+
+ * docs/html/Makefile: Follow up to libstdc++/14991, remove target.
+
+2007-10-14 Jonathan Wakely <jwakely.gcc@gmail.com>
+
+ * src/valarray-inst.cc, include/ext/atomicity.h,
+ include/ext/concurrence.h, include/bits/basic_string.h,
+ include/bits/fstream.tcc, include/ext/vstring.h: Fix comment typos.
+
+2007-10-14 Jonathan Wakely <jwakely.gcc@gmail.com>
+
+ * include/tr1_impl/boost_shared_ptr.h: (__weak_ptr::lock()): Add
+ missing template argument.
+ * testsuite/tr1/2_general_utilities/memory/shared_ptr/
+ explicit_instantiation/2.cc: New.
+ * testsuite/tr1/2_general_utilities/memory/weak_ptr/
+ explicit_instantiation/2.cc: New.
+
+2007-10-11 Paolo Carlini <pcarlini@suse.de>
+
+ PR libstdc++/33734
+ * include/ext/codecvt_specializations.h (encoding_state::good,
+ init, destroy): Use cast notation instead of reinterpret_cast.
+
+2007-10-07 Release Manager
+
+ * GCC 4.2.2 released.
+
+2007-10-06 Benjamin Kosnik <bkoz@redhat.com>
+
+ PR libstdc++/33678
+ * libsupc++/typeinfo (typeinfo): Revert ordering of virtual components.
+
2007-08-28 Paolo Carlini <pcarlini@suse.de>
PR libstdc++/33128
diff --git a/libstdc++/config/os/aix/os_defines.h b/libstdc++/config/os/aix/os_defines.h
index 8f1f8138ab65..2aa9f7fc2cb3 100644
--- a/libstdc++/config/os/aix/os_defines.h
+++ b/libstdc++/config/os/aix/os_defines.h
@@ -1,6 +1,6 @@
// Specific definitions for AIX -*- C++ -*-
-// Copyright (C) 2000, 2002, 2005 Free Software Foundation, Inc.
+// Copyright (C) 2000, 2002, 2005, 2008 Free Software Foundation, Inc.
//
// This file is part of the GNU ISO C++ Library. This library is free
// software; you can redistribute it and/or modify it under the
@@ -48,4 +48,9 @@
#define _ALL_SOURCE
#endif
+// C99 math
+#ifndef __COMPATMATH__
+#define __COMPATMATH__
+#endif
+
#endif
diff --git a/libstdc++/include/bits/allocator.h b/libstdc++/include/bits/allocator.h
index 43939c14fa76..4d62c0ae8f32 100644
--- a/libstdc++/include/bits/allocator.h
+++ b/libstdc++/include/bits/allocator.h
@@ -115,11 +115,21 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
operator==(const allocator<_T1>&, const allocator<_T2>&)
{ return true; }
+ template<typename _Tp>
+ inline bool
+ operator==(const allocator<_Tp>&, const allocator<_Tp>&)
+ { return true; }
+
template<typename _T1, typename _T2>
inline bool
operator!=(const allocator<_T1>&, const allocator<_T2>&)
{ return false; }
+ template<typename _Tp>
+ inline bool
+ operator!=(const allocator<_Tp>&, const allocator<_Tp>&)
+ { return false; }
+
// Inhibit implicit instantiations for required instantiations,
// which are defined via explicit instantiations elsewhere.
// NB: This syntax is a GNU extension.
diff --git a/libstdc++/include/bits/basic_string.h b/libstdc++/include/bits/basic_string.h
index e4b7a5b5fba3..dba1f566db50 100644
--- a/libstdc++/include/bits/basic_string.h
+++ b/libstdc++/include/bits/basic_string.h
@@ -1672,7 +1672,7 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
/**
* @brief Find position of a character of C substring.
* @param s String containing characters to locate.
- * @param pos Index of character to search from (default 0).
+ * @param pos Index of character to search from.
* @param n Number of characters from s to search for.
* @return Index of first occurrence.
*
@@ -1733,7 +1733,7 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
/**
* @brief Find last position of a character of C substring.
* @param s C string containing characters to locate.
- * @param pos Index of character to search back from (default end).
+ * @param pos Index of character to search back from.
* @param n Number of characters from s to search for.
* @return Index of last occurrence.
*
@@ -1764,7 +1764,7 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
/**
* @brief Find last position of a character.
* @param c Character to locate.
- * @param pos Index of character to search back from (default 0).
+ * @param pos Index of character to search back from (default end).
* @return Index of last occurrence.
*
* Starting from @a pos, searches backward for @a c within this string.
@@ -1794,7 +1794,7 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
/**
* @brief Find position of a character not in C substring.
* @param s C string containing characters to avoid.
- * @param pos Index of character to search from (default 0).
+ * @param pos Index of character to search from.
* @param n Number of characters from s to consider.
* @return Index of first occurrence.
*
@@ -1839,8 +1839,8 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
/**
* @brief Find last position of a character not in string.
* @param str String containing characters to avoid.
- * @param pos Index of character to search from (default 0).
- * @return Index of first occurrence.
+ * @param pos Index of character to search back from (default end).
+ * @return Index of last occurrence.
*
* Starting from @a pos, searches backward for a character not
* contained in @a str within this string. If found, returns the index
@@ -1853,9 +1853,9 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
/**
* @brief Find last position of a character not in C substring.
* @param s C string containing characters to avoid.
- * @param pos Index of character to search from (default 0).
+ * @param pos Index of character to search back from.
* @param n Number of characters from s to consider.
- * @return Index of first occurrence.
+ * @return Index of last occurrence.
*
* Starting from @a pos, searches backward for a character not
* contained in the first @a n characters of @a s within this string.
@@ -1866,10 +1866,10 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
find_last_not_of(const _CharT* __s, size_type __pos,
size_type __n) const;
/**
- * @brief Find position of a character not in C string.
+ * @brief Find last position of a character not in C string.
* @param s C string containing characters to avoid.
- * @param pos Index of character to search from (default 0).
- * @return Index of first occurrence.
+ * @param pos Index of character to search back from (default end).
+ * @return Index of last occurrence.
*
* Starting from @a pos, searches backward for a character not
* contained in @a s within this string. If found, returns the index
@@ -1885,8 +1885,8 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
/**
* @brief Find last position of a different character.
* @param c Character to avoid.
- * @param pos Index of character to search from (default 0).
- * @return Index of first occurrence.
+ * @param pos Index of character to search back from (default end).
+ * @return Index of last occurrence.
*
* Starting from @a pos, searches backward for a character other than
* @a c within this string. If found, returns the index where it was
diff --git a/libstdc++/include/bits/fstream.tcc b/libstdc++/include/bits/fstream.tcc
index 5520f9b61462..ea097c687106 100644
--- a/libstdc++/include/bits/fstream.tcc
+++ b/libstdc++/include/bits/fstream.tcc
@@ -194,7 +194,7 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
const bool __testin = _M_mode & ios_base::in;
if (__testin && !_M_writing)
{
- // Check for pback madness, and if so swich back to the
+ // Check for pback madness, and if so switch back to the
// normal buffers and jet outta here before expensive
// fileops happen...
_M_destroy_pback();
diff --git a/libstdc++/include/bits/locale_facets.tcc b/libstdc++/include/bits/locale_facets.tcc
index d3c47ff9b7f2..8f62e1904eaa 100644
--- a/libstdc++/include/bits/locale_facets.tcc
+++ b/libstdc++/include/bits/locale_facets.tcc
@@ -1,6 +1,7 @@
// Locale support -*- C++ -*-
-// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006
+// Copyright (C) 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005,
+// 2006, 2007, 2008
// Free Software Foundation, Inc.
//
// This file is part of the GNU ISO C++ Library. This library is free
@@ -117,6 +118,7 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
return static_cast<const _Facet&>(*__facets[__i]);
}
+
// Routine to access a cache for the facet. If the cache didn't
// exist before, it gets constructed on the fly.
template<typename _Facet>
@@ -1015,13 +1017,13 @@ _GLIBCXX_BEGIN_LDBL_NAMESPACE
if (__builtin_expect(__dec, true))
{
// Decimal.
- if (__v > 0)
+ if (__v >= 0)
{
if (__flags & ios_base::showpos
&& numeric_limits<_ValueT>::is_signed)
*--__cs = __lit[__num_base::_S_oplus], ++__len;
}
- else if (__v)
+ else
*--__cs = __lit[__num_base::_S_ominus], ++__len;
}
else if (__flags & ios_base::showbase && __v)
diff --git a/libstdc++/include/ext/atomicity.h b/libstdc++/include/ext/atomicity.h
index 975121e876b3..05bac1f46d40 100644
--- a/libstdc++/include/ext/atomicity.h
+++ b/libstdc++/include/ext/atomicity.h
@@ -42,7 +42,7 @@
_GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
// Functions for portable atomic access.
- // To abstract locking primatives across all thread policies, use:
+ // To abstract locking primitives across all thread policies, use:
// __exchange_and_add_dispatch
// __atomic_add_dispatch
#ifdef _GLIBCXX_ATOMIC_BUILTINS
diff --git a/libstdc++/include/ext/codecvt_specializations.h b/libstdc++/include/ext/codecvt_specializations.h
index f0a6bbed4d65..3973d3256d83 100644
--- a/libstdc++/include/ext/codecvt_specializations.h
+++ b/libstdc++/include/ext/codecvt_specializations.h
@@ -128,7 +128,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
bool
good() const throw()
{
- const descriptor_type __err = reinterpret_cast<iconv_t>(-1);
+ const descriptor_type __err = (iconv_t)(-1);
bool __test = _M_in_desc && _M_in_desc != __err;
__test &= _M_out_desc && _M_out_desc != __err;
return __test;
@@ -166,7 +166,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
void
init()
{
- const descriptor_type __err = reinterpret_cast<iconv_t>(-1);
+ const descriptor_type __err = (iconv_t)(-1);
const bool __have_encodings = _M_int_enc.size() && _M_ext_enc.size();
if (!_M_in_desc && __have_encodings)
{
@@ -199,7 +199,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
void
destroy() throw()
{
- const descriptor_type __err = reinterpret_cast<iconv_t>(-1);
+ const descriptor_type __err = (iconv_t)(-1);
if (_M_in_desc && _M_in_desc != __err)
{
iconv_close(_M_in_desc);
diff --git a/libstdc++/include/ext/concurrence.h b/libstdc++/include/ext/concurrence.h
index 56e07de91e0d..31c3ce681351 100644
--- a/libstdc++/include/ext/concurrence.h
+++ b/libstdc++/include/ext/concurrence.h
@@ -46,7 +46,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
// Available locking policies:
// _S_single single-threaded code that doesn't need to be locked.
// _S_mutex multi-threaded code that requires additional support
- // from gthr.h or abstraction layers in concurrance.h.
+ // from gthr.h or abstraction layers in concurrence.h.
// _S_atomic multi-threaded code using atomic operations.
enum _Lock_policy { _S_single, _S_mutex, _S_atomic };
diff --git a/libstdc++/include/ext/vstring.h b/libstdc++/include/ext/vstring.h
index 79265b9cc6db..38a2c9fd0712 100644
--- a/libstdc++/include/ext/vstring.h
+++ b/libstdc++/include/ext/vstring.h
@@ -1407,7 +1407,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
/**
* @brief Find position of a character of C substring.
* @param s String containing characters to locate.
- * @param pos Index of character to search from (default 0).
+ * @param pos Index of character to search from.
* @param n Number of characters from s to search for.
* @return Index of first occurrence.
*
@@ -1468,7 +1468,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
/**
* @brief Find last position of a character of C substring.
* @param s C string containing characters to locate.
- * @param pos Index of character to search back from (default end).
+ * @param pos Index of character to search back from.
* @param n Number of characters from s to search for.
* @return Index of last occurrence.
*
@@ -1499,7 +1499,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
/**
* @brief Find last position of a character.
* @param c Character to locate.
- * @param pos Index of character to search back from (default 0).
+ * @param pos Index of character to search back from (default end).
* @return Index of last occurrence.
*
* Starting from @a pos, searches backward for @a c within this string.
@@ -1529,7 +1529,7 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
/**
* @brief Find position of a character not in C substring.
* @param s C string containing characters to avoid.
- * @param pos Index of character to search from (default 0).
+ * @param pos Index of character to search from.
* @param n Number of characters from s to consider.
* @return Index of first occurrence.
*
@@ -1574,8 +1574,8 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
/**
* @brief Find last position of a character not in string.
* @param str String containing characters to avoid.
- * @param pos Index of character to search from (default 0).
- * @return Index of first occurrence.
+ * @param pos Index of character to search back from (default end).
+ * @return Index of last occurrence.
*
* Starting from @a pos, searches backward for a character not
* contained in @a str within this string. If found, returns the index
@@ -1589,9 +1589,9 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
/**
* @brief Find last position of a character not in C substring.
* @param s C string containing characters to avoid.
- * @param pos Index of character to search from (default 0).
+ * @param pos Index of character to search back from.
* @param n Number of characters from s to consider.
- * @return Index of first occurrence.
+ * @return Index of last occurrence.
*
* Starting from @a pos, searches backward for a character not
* contained in the first @a n characters of @a s within this string.
@@ -1602,10 +1602,10 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
find_last_not_of(const _CharT* __s, size_type __pos,
size_type __n) const;
/**
- * @brief Find position of a character not in C string.
+ * @brief Find last position of a character not in C string.
* @param s C string containing characters to avoid.
- * @param pos Index of character to search from (default 0).
- * @return Index of first occurrence.
+ * @param pos Index of character to search back from (default end).
+ * @return Index of last occurrence.
*
* Starting from @a pos, searches backward for a character not
* contained in @a s within this string. If found, returns the index
@@ -1621,8 +1621,8 @@ _GLIBCXX_BEGIN_NAMESPACE(__gnu_cxx)
/**
* @brief Find last position of a different character.
* @param c Character to avoid.
- * @param pos Index of character to search from (default 0).
- * @return Index of first occurrence.
+ * @param pos Index of character to search back from (default end).
+ * @return Index of last occurrence.
*
* Starting from @a pos, searches backward for a character other than
* @a c within this string. If found, returns the index where it was
diff --git a/libstdc++/include/tr1/boost_shared_ptr.h b/libstdc++/include/tr1/boost_shared_ptr.h
index fc79cfc70c23..d83bde692a61 100644
--- a/libstdc++/include/tr1/boost_shared_ptr.h
+++ b/libstdc++/include/tr1/boost_shared_ptr.h
@@ -857,7 +857,7 @@ _GLIBCXX_BEGIN_NAMESPACE(tr1)
// Q: How can we get here?
// A: Another thread may have invalidated r after the
// use_count test above.
- return __shared_ptr<element_type>();
+ return __shared_ptr<element_type, _Lp>();
}
#else
diff --git a/libstdc++/include/tr1/random b/libstdc++/include/tr1/random
index c97f16d2a2d7..492adfd5e74c 100644
--- a/libstdc++/include/tr1/random
+++ b/libstdc++/include/tr1/random
@@ -1618,10 +1618,15 @@ _GLIBCXX_BEGIN_NAMESPACE(tr1)
result_type
_M_call(_UniformRandomNumberGenerator& __urng,
result_type __min, result_type __max, true_type)
- {
+ {
+ // XXX Must be fixed to also work when __urng.max() - __urng.min()
+ // is smaller than __max - __min.
typedef typename __gnu_cxx::__add_unsigned<typename
_UniformRandomNumberGenerator::result_type>::__type __utype;
- return result_type(__utype(__urng()) % (__max - __min + 1)) + __min;
+ return result_type((__max - __min + 1.0L)
+ * (__utype(__urng()) - __utype(__urng.min()))
+ / (__utype(__urng.max())
+ - __utype(__urng.min()) + 1.0L)) + __min;
}
template<typename _UniformRandomNumberGenerator>
diff --git a/libstdc++/libsupc++/eh_personality.cc b/libstdc++/libsupc++/eh_personality.cc
index 5fd25f232d9d..12bba96b2b87 100644
--- a/libstdc++/libsupc++/eh_personality.cc
+++ b/libstdc++/libsupc++/eh_personality.cc
@@ -1,5 +1,5 @@
// -*- C++ -*- The GNU C++ exception personality routine.
-// Copyright (C) 2001, 2002, 2003, 2006 Free Software Foundation, Inc.
+// Copyright (C) 2001, 2002, 2003, 2006, 2008 Free Software Foundation, Inc.
//
// This file is part of GCC.
//
@@ -434,7 +434,7 @@ PERSONALITY_FUNCTION (int version,
// Parse the LSDA header.
p = parse_lsda_header (context, language_specific_data, &info);
info.ttype_base = base_of_encoded_value (info.ttype_encoding, context);
-#ifdef HAVE_GETIPINFO
+#ifdef _GLIBCXX_HAVE_GETIPINFO
ip = _Unwind_GetIPInfo (context, &ip_before_insn);
#else
ip = _Unwind_GetIP (context);
diff --git a/libstdc++/libsupc++/typeinfo b/libstdc++/libsupc++/typeinfo
index 90ac18a801f2..cddb65eda8f5 100644
--- a/libstdc++/libsupc++/typeinfo
+++ b/libstdc++/libsupc++/typeinfo
@@ -99,7 +99,13 @@ namespace std
#endif
bool operator!=(const type_info& __arg) const
{ return !operator==(__arg); }
-
+
+ // Return true if this is a pointer type of some kind
+ virtual bool __is_pointer_p() const;
+
+ // Return true if this is a function type
+ virtual bool __is_function_p() const;
+
// Try and catch a thrown type. Store an adjusted pointer to the
// caught type in THR_OBJ. If THR_TYPE is not a pointer type, then
// THR_OBJ points to the thrown object. If THR_TYPE is a pointer
@@ -113,12 +119,6 @@ namespace std
virtual bool __do_upcast(const __cxxabiv1::__class_type_info *__target,
void **__obj_ptr) const;
- // Return true if this is a pointer type of some kind
- virtual bool __is_pointer_p() const;
-
- // Return true if this is a function type
- virtual bool __is_function_p() const;
-
protected:
const char *__name;
diff --git a/libstdc++/scripts/check_compile b/libstdc++/scripts/check_compile
new file mode 100755
index 000000000000..c969f98c476e
--- /dev/null
+++ b/libstdc++/scripts/check_compile
@@ -0,0 +1,57 @@
+#!/usr/bin/env bash
+
+# Script to do performance testing.
+
+# Invocation
+# check_performance SRC_DIR BUILD_DIR
+
+# 1: variables
+#
+SRC_DIR=$1
+BUILD_DIR=$2
+
+# Now that we've successfully translated the numerical option into
+# a symbolic one, we can safely ignore it.
+shift
+
+# This has been true all along. Found out about it the hard way...
+case $BASH_VERSION in
+ 1*)
+ echo 'You need bash 2.x to run check_performance. Exiting.';
+ exit 1 ;;
+ *) ;;
+esac
+
+flags_script=$BUILD_DIR/scripts/testsuite_flags
+INCLUDES=`$flags_script --build-includes`
+PCH_FLAGS=`$flags_script --cxxpchflags`
+FLAGS=`$flags_script --cxxflags`
+TEST_FLAGS="-S"
+COMPILER=`$flags_script --build-cxx`
+CXX="$COMPILER $INCLUDES $PCH_FLAGS $FLAGS $TEST_FLAGS"
+
+echo "compile line is:"
+echo $CXX
+echo ""
+
+TESTS_FILE="testsuite_files"
+
+#mkdir binaries
+UNIQUE_ID=0
+
+for NAME in `cat $TESTS_FILE`
+do
+ if $RUN; then
+ echo $NAME
+ OUTPUT_NAME=$UNIQUE_ID
+ $CXX $SRC_DIR/testsuite/$NAME -o $OUTPUT_NAME
+ if [ -f $OUTPUT_NAME ]; then
+# mv $OUTPUT_NAME binaries
+ rm $OUTPUT_NAME
+ fi
+ echo ""
+ let UNIQUE_ID+=1
+ fi
+done
+
+exit 0
diff --git a/libstdc++/src/valarray-inst.cc b/libstdc++/src/valarray-inst.cc
index c13e1a2454bd..e63c52f229db 100644
--- a/libstdc++/src/valarray-inst.cc
+++ b/libstdc++/src/valarray-inst.cc
@@ -68,7 +68,7 @@ _GLIBCXX_BEGIN_NAMESPACE(std)
__gslice_to_index(size_t __o, const valarray<size_t>& __l,
const valarray<size_t>& __s, valarray<size_t>& __i)
{
- // There are as much as dimensions as there are strides.
+ // There are as many dimensions as there are strides.
size_t __n = __l.size();
// Get a buffer to hold current multi-index as we go through