Commit Graph

7971 Commits

Author SHA1 Message Date
Jason Merrill
cc999d0300 linkage.m4 (GLIBCXX_CHECK_STDLIB_DECL_AND_LINKAGE): New.
* linkage.m4 (GLIBCXX_CHECK_STDLIB_DECL_AND_LINKAGE): New.
	(GLIBCXX_CHECK_STDLIB_SUPPORT): Check for atexit and at_quick_exit.
	* include/c_std/cstdlib: Add atexit and at_quick_exit.
	* include/c_global/cstdlib: Add atexit and at_quick_exit.
	* testsuite/18_support/quick_exit/quick_exit.cc: New.

From-SVN: r195948
2013-02-11 12:50:13 -05:00
Paolo Carlini
3b424b30be re PR libstdc++/56282 (std::basic_ios<char> broken with -std=c++11 (undefined reference))
2013-02-11  Paolo Carlini  <paolo.carlini@oracle.com>

	PR libstdc++/56282
	Revert:
	2013-02-06  Edward Smith-Rowland  <3dw4rd@verizon.net>

	PR libstdc++/56193
	* include/bits/basic_ios.h: Replace operator void*() const
	with explicit operator bool() const in C++11 and greater.
	* testsuite/27_io/basic_ios/pr56193.cc: New file.

From-SVN: r195939
2013-02-11 10:30:43 +00:00
François Dumont
adb1c4d1e0 containers.xml: Add section on unordered containers.
2013-02-10  François Dumont  <fdumont@gcc.gnu.org>
	    Jonathan Wakely  <jwakely.gcc@gmail.com>

	* doc/xml/manual/containers.xml: Add section on unordered containers.
	* doc/xml/manual/using.xml: Fix incomplete sentence.

Co-Authored-By: Jonathan Wakely <jwakely.gcc@gmail.com>

From-SVN: r195937
2013-02-11 00:19:41 +00:00
Jonathan Wakely
dfed5434f3 re PR libstdc++/56267 (unordered containers require Assignable hash function)
PR libstdc++/56267
	* include/bits/hashtable.h (__cache_default): Check if hash function
	is copy assignable.
	* testsuite/23_containers/unordered_set/56267.cc: New.
	* testsuite/23_containers/unordered_set/instantiation_neg.cc: Adjust
	dg-error line number.
	* testsuite/23_containers/unordered_set/
	not_default_constructible_hash_neg.cc: Likewise.

From-SVN: r195936
2013-02-11 00:19:29 +00:00
Jonathan Wakely
a9b68b8289 re PR libstdc++/56278 (unordered containers fail static assertion)
PR libstdc++/56278
	* include/bits/hashtable_policy.h (_Hash_code_base): Make default
	constructor public.
	* testsuite/23_containers/unordered_set/56278.cc: New.

From-SVN: r195935
2013-02-11 00:19:14 +00:00
François Dumont
0112ed6089 bessel_function.tcc (__cyl_bessel_ij_series): Code simplification.
2013-02-09  François Dumont  <fdumont@gcc.gnu.org>

	* include/tr1/bessel_function.tcc (__cyl_bessel_ij_series): Code
	simplification.

From-SVN: r195925
2013-02-09 20:55:12 +00:00
Edward Smith-Rowland
be59c9322a re PR libstdc++/56216 (TR1 bessel functions bomb at x == 0!)
PR libstdc++/56216

From-SVN: r195886
2013-02-08 14:10:48 +00:00
Paolo Carlini
54353978a4 pr56193.cc: Tweak.
2013-02-07  Paolo Carlini  <paolo.carlini@oracle.com>

	* testsuite/27_io/basic_ios/pr56193.cc: Tweak.

From-SVN: r195852
2013-02-07 15:20:58 +00:00
Edward Smith-Rowland
b31317e44f Add the full Copyright blurb on the PR56193 test.
From-SVN: r195851
2013-02-07 15:11:11 +00:00
Edward Smith-Rowland
fcf0430bda PR56193 - Wrong test operator for basic_ios in C++11.
From-SVN: r195849
2013-02-07 14:27:45 +00:00
Dodji Seketeli
c8ab2cfaff Add missing explicit instantiation for std::lower_bound template
Since commit r195676[1], it looks like
libstdc++-v3/src/c++11/hashtable_c++0x.cc is missing an explicit
instantiation for std::lower_bound.  This leads to libstdc++.so having
the symbol for that (missing) instantiation be undefined, thus
preventing executables from being linked with libstdc++.

The patchlet below seems to fixed the issue for me.

Boostrapped and tested on x86_64-unknown-linux-gnu.

[1]:

    commit bc36b44c7cb0e5e97ac807b8fb17507e0fb09008
    Author: fdumont <fdumont@138bc75d-0d04-0410-961f-82ee72b054a4>
    Date:   Fri Feb 1 20:44:41 2013 +0000

	2013-02-01  François Dumont  <fdumont@gcc.gnu.org>

	    * include/bits/hashtable_policy.h
	    (_Prime_rehash_policy::_M_next_bkt)
	    (_Prime_rehash_policy::_M_need_rehash): Move definition...
	    * src/c++11/hashtable_c++0x.cc: ... here.
	    * src/shared/hashtable-aux.cc: Remove c++config.h include.
	    * config/abi/gnu.ver (GLIBCXX_3.4.18): Export _Prime_rehash_policy
	    symbols.

	git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@195676 138bc75d-0d04-0410-961f-82ee72b054a4

libstdc++-v3/ChangeLog

	* libstdc++-v3/src/c++11/hashtable_c++0x.cc (namespace std): Add
	missing instantiation for std::lower_bound template.

From-SVN: r195783
2013-02-06 09:18:26 +01:00
François Dumont
4df047dd34 functional_hash.h (std::__is_fast_hash<>): New.
2013-02-04  François Dumont  <fdumont@gcc.gnu.org>

	* include/bits/functional_hash.h (std::__is_fast_hash<>): New.
	* include/bits/basic_string.h: Specialize previous to mark
	std::hash for string types as slow.
	* include/bits/hashtable.h (__cache_default): Replace is_integral
	with __is_fast_hash.
	* src/c++11/hash_c++0x.cc: Add type_traits include.
	* testsuite/23_containers/unordered_set/instantiation_neg.cc:
	Adapt dg-error line number.
	* testsuite/23_containers/unordered_set/
	not_default_constructible_hash_neg.cc: Likewise.

From-SVN: r195738
2013-02-04 21:14:07 +00:00
Manuel López-Ibáñez
9ea146e6da PR libstdc++/56202 (again)
2013-02-04  Manuel López-Ibáñez  <manu@gcc.gnu.org>
	    Paolo Carlini  <paolo.carlini@oracle.com>

	PR libstdc++/56202 (again)
	* include/bits/random.tcc (binomial_distribution<>::
	_M_waiting(_UniformRandomNumberGenerator&, _IntType)): Fix thinko
	in previous commit.

	* include/bits/random.h: Fix comment typo.

Co-Authored-By: Paolo Carlini <paolo.carlini@oracle.com>

From-SVN: r195732
2013-02-04 19:28:40 +00:00
Manuel López-Ibáñez
85018f40ae re PR libstdc++/56202 (SIGFPE (division by zero) in std::binomial_distribution)
2013-02-04  Manuel López-Ibáñez  <manu@gcc.gnu.org>
	    Paolo Carlini  <paolo.carlini@oracle.com>

	PR libstdc++/56202
	* include/bits/random.tcc (binomial_distribution<>::
	_M_waiting(_UniformRandomNumberGenerator&, _IntType)): Avoid
	division by zero.

Co-Authored-By: Paolo Carlini <paolo.carlini@oracle.com>

From-SVN: r195722
2013-02-04 17:10:59 +00:00
Richard Sandiford
405feeb871 Update copyright in libstdc++-v3.
From-SVN: r195701
2013-02-03 17:54:05 +00:00
Richard Sandiford
5031121c43 ctype_inline.h: Fix copyright typo.
libstdc++-v3/
	* config/os/mingw32/ctype_inline.h: Fix copyright typo.

From-SVN: r195691
2013-02-03 10:42:29 +00:00
François Dumont
6e14794657 2013-02-01 François Dumont <fdumont@gcc.gnu.org>
* include/bits/hashtable_policy.h
	(_Prime_rehash_policy::_M_next_bkt)
	(_Prime_rehash_policy::_M_need_rehash): Move definition...
	* src/c++11/hashtable_c++0x.cc: ... here.
	* src/shared/hashtable-aux.cc: Remove c++config.h include.
	* config/abi/gnu.ver (GLIBCXX_3.4.18): Export _Prime_rehash_policy
	symbols.

From-SVN: r195676
2013-02-01 20:44:41 +00:00
Jason Merrill
2ee8a2d5ce re PR libstdc++/54314 (undefined references to 'construction vtable for std::ostream-in-std::basic_ostringstream<char, std::char_traits<char>, std::allocator<char> >')
PR libstdc++/54314
gcc/
	* varasm.c (default_assemble_visibility): Don't warn about
	visibility on artificial decls.
gcc/cp/
	* class.c (build_ctor_vtbl_group): Give construction vtables
	hidden visibility.
libstdc++-v3/
	* config/abi/pre/gnu.ver: Don't export construction vtables.
	* config/abi/pre/gnu-versioned-namespace.ver: Likewise.

From-SVN: r195550
2013-01-29 12:24:51 -05:00
Jonathan Wakely
0addb273c5 re PR libstdc++/56112 (cannot create unordered_map from range of types convertible to value_type)
PR libstdc++/56112
	* include/bits/hashtable_policy.h (insert(_Pair&&)): Use _M_emplace
	to construct value_type explicitly before trying to extract the key.
	* testsuite/23_containers/unordered_map/cons/56112.cc: New.

From-SVN: r195520
2013-01-28 23:07:35 +00:00
François Dumont
5b3be7cf99 hashtable_policy.h (_Local_iterator_base): Use _Hashtable_ebo_helper to embed functors into the local_iterator when necessary.
2013-01-28  François Dumont  <fdumont@gcc.gnu.org>

	* include/bits/hashtable_policy.h (_Local_iterator_base): Use
	_Hashtable_ebo_helper to embed functors into the local_iterator
	when necessary. Pass information about functors involved in hash
	code by copy.
	* include/bits/hashtable.h (__cache_default): Do not cache for
	builtin integral types unless the hash functor is not noexcept
	qualified or is not default constructible. Adapt static assertions
	and local iterator instantiations.
	* include/debug/unordered_set
	(std::__debug::unordered_set<>::erase): Detect local iterators to
	invalidate using contained node rather than generating a dummy
	local_iterator instance.
	(std::__debug::unordered_multiset<>::erase): Likewise.
	* include/debug/unordered_map
	(std::__debug::unordered_map<>::erase): Likewise.
	(std::__debug::unordered_multimap<>::erase): Likewise.
	* testsuite/performance/23_containers/insert_erase/41975.cc: Test
	std::tr1 and std versions of unordered_set regardless of any
	macro. Add test on default cache behavior.
	* testsuite/performance/23_containers/insert/54075.cc: Likewise.
	* testsuite/23_containers/unordered_set/instantiation_neg.cc:
	Adapt line number.
	* testsuite/23_containers/unordered_set/
	not_default_constructible_hash_neg.cc: New.
	* testsuite/23_containers/unordered_set/buckets/swap.cc: New.

From-SVN: r195517
2013-01-28 20:52:13 +00:00
Paolo Carlini
91f4a9e332 re PR libstdc++/56085 (Unsafe negation in C++03 pow(complex,int))
2013-01-24  Paolo Carlini  <paolo.carlini@oracle.com>

	PR libstdc++/56085
	* include/std/complex (pow(const complex<>&, int)): Avoid __n
	signed overflow.

From-SVN: r195421
2013-01-24 12:20:57 +00:00
Jakub Jelinek
0a18c815f9 explicit-hle.cc: Tightten scan-assembler-times regexps...
* testsuite/29_atomics/atomic_flag/test_and_set/explicit-hle.cc:
	Tightten scan-assembler-times regexps, add dg-additional-options for
	ia32, add -g0 -fno-exceptions -fno-asynchronous-unwind-tables to
	dg-options.

From-SVN: r195383
2013-01-22 18:15:47 +01:00
Andi Kleen
318c94c0d5 Fix PR number in ChangeLog
From-SVN: r195330
2013-01-21 01:24:10 +00:00
Andi Kleen
d76b6ea417 libstdc++: Add mem_order_hle_acquire/release to atomic.h v2
The underlying compiler supports additional __ATOMIC_HLE_ACQUIRE/RELEASE
memmodel flags for TSX, but this was not exposed to the C++ wrapper.
Handle it there.

These are additional flags, so some of assert checks need to mask
off the flags before checking the memory model type.

libstdc++-v3/:
2013-01-12  Andi Kleen  <ak@linux.intel.com>
	    Jonathan Wakely  <jwakely.gcc@gmail.com>

        PR libstdc++/55223
	* include/bits/atomic_base.h (__memory_order_modifier): Add
	__memory_order_mask, __memory_order_modifier_mask,
	__memory_order_hle_acquire, __memory_order_hle_release.
	(operator|,operator&): Add.
	(__cmpexch_failure_order):  Rename to __cmpexch_failure_order2.
	(__cmpexch_failure_order): Add.
	(clear, store, load, compare_exchange_weak, compare_exchange_strong):
	Handle flags.
	* testsuite/29_atomics/atomic_flag/test_and_set/explicit-hle.cc:
	Add.

Co-Authored-By: Jonathan Wakely <jwakely.gcc@gmail.com>

From-SVN: r195321
2013-01-20 19:03:22 +00:00
Jonathan Wakely
c93fa3ca7e re PR libstdc++/55861 ([C++11] `std::shared_future::get' is not const-qualified)
PR libstdc++/55861
	* include/std/future (_State_base::_S_check(const shared_ptr<T>&)):
	Fix return type.
	(__basic_future::_M_get_result()): Const qualify.
	(shared_future::get()): Likewise.
	* testsuite/30_threads/shared_future/members/get.cc: Use const
	objects.

From-SVN: r195314
2013-01-19 23:42:55 +00:00
Jonathan Wakely
b7202baf14 PR libstdc++/55043 (again)
PR libstdc++/55043 (again)
	* include/bits/alloc_traits.h (allocator_traits::construct): Disable
	unless construction would be well-formed.
	(__allow_copy_cons, __check_copy_constructible): Define.
	* include/bits/unordered_map.h (__check_copy_constructible): Use as
	base class so copy constructor will be deleted if appropriate.
	(is_copy_constructible): Remove specialization.
	* include/bits/unordered_set.h: Likewise.
	* include/debug/unordered_map.h: Undo previous commit. Default copy
	and move constructors.
	* include/debug/unordered_set.h: Likewise.
	* include/profile/unordered_map.h: Undo previous commit.
	* include/profile/unordered_set.h: Likewise.
	* testsuite/23_containers/unordered_map/55043.cc: Fix test.
	* testsuite/23_containers/unordered_multimap/55043.cc: Likewise.
	* testsuite/23_containers/unordered_multiset/55043.cc: Likewise.
	* testsuite/23_containers/unordered_set/55043.cc: Likewise.
	* testsuite/23_containers/unordered_map/requirements/53339.cc: XFAIL,
	cannot support incomplete types.
	* testsuite/23_containers/unordered_multimap/requirements/53339.cc:
	Likewise.

From-SVN: r195253
2013-01-16 23:56:00 +00:00
Jonathan Wakely
8175e9866c re PR libstdc++/55043 (issue with nesting unordered_map containing unique_ptr into vector)
PR libstdc++/55043
	* include/std/unordered_map: Include alloc_traits.h
	* include/std/unordered_set: Likewise.
	* include/bits/alloc_traits.h: Define __is_copy_insertable.
	* include/bits/unordered_map.h: Use it.
	* include/bits/unordered_set.h: Likewise.
	* include/debug/unordered_map.h: Likewise.
	* include/debug/unordered_set.h: Likewise.
	* include/profile/unordered_map.h: Likewise.
	* include/profile/unordered_set.h: Likewise.
	* include/bits/hashtable.h: Fix comment typos.
	* testsuite/23_containers/unordered_map/55043.cc: New.
	* testsuite/23_containers/unordered_multimap/55043.cc: New.
	* testsuite/23_containers/unordered_multiset/55043.cc: New.
	* testsuite/23_containers/unordered_set/55043.cc: New.

From-SVN: r195231
2013-01-16 09:20:34 +00:00
Steve Ellcey
5a0727d990 vector.cc: Shrink memory usage under simulator.
2013-01-14  Steve Ellcey  <sellcey@mips.com>

	* testsuite/libstdc++-v3/testsuite/23_containers/vector/profile/vector.cc:
	Shrink memory usage under simulator.
	* testsuite/libstdc++-v3/testsuite/26_numerics/valarray/28277.cc: Ditto.
	* testsuite/libstdc++-v3/testsuite/27_io/basic_istream/extractors_character/wchar_t/4.cc:
	Ditto.
	* testsuite/libstdc++-v3/testsuite/27_io/basic_istream/getline/wchar_t/5.cc:
	Ditto.
	* testsuite/libstdc++-v3/testsuite/27_io/basic_istream/ignore/wchar_t/2.cc:
	Ditto.
	* testsuite/libstdc++-v3/testsuite/27_io/basic_ostream/inserters_character/wchar_t/28277-1.cc:
	Ditto.
	* testsuite/libstdc++-v3/testsuite/27_io/basic_ostream/inserters_character/wchar_t/28277-2.cc:
	Ditto.
	* testsuite/libstdc++-v3/testsuite/27_io/basic_stringbuf/overflow/wchar_t/1.cc:
	Ditto.
	* testsuite/libstdc++-v3/testsuite/27_io/basic_stringbuf/setbuf/wchar_t/4.cc:
	Ditto.

From-SVN: r195177
2013-01-14 20:57:58 +00:00
Janis Johnson
93b2c9a52e gdb-test.exp (gdb_batch_check): Catch error running gdb command.
* testsuite/lib/gdb-test.exp (gdb_batch_check): Catch error running
	gdb command.

From-SVN: r195115
2013-01-11 20:11:36 +00:00
Jonathan Wakely
965f0c572f * doc/xml/manual/status_cxx2011.xml: Document that N3189 is missing.
From-SVN: r195036
2013-01-08 21:29:20 +00:00
Jonathan Wakely
890e166507 re PR c++/55908 (Problem binding a const member function to a const object)
PR libstdc++/55908
	* include/std/functional (_Mem_fn::operator()): Fix constraints to
	avoid ambiguity.
	* testsuite/20_util/function_objects/mem_fn/55908.cc: New.
	* testsuite/20_util/bind/ref_neg.cc: Adjust dg-error line numbers.

From-SVN: r195035
2013-01-08 21:01:14 +00:00
Rainer Orth
1191c46b4b Restrict -Wa,-nH use to Solaris (PR libstdc++/55594)
PR libstdc++/55594
	* acinclude.m4 (GLIBCXX_CHECK_ASSEMBLER_HWCAP): Restrict test to
	Solaris targets.
	* configure: Regenerate.

From-SVN: r195009
2013-01-08 09:47:55 +00:00
Jonathan Wakely
78aff33680 re PR libstdc++/55847 (mistake bad_weak_ptr::what() message)
PR libstdc++/55847
	* src/c++11/shared_ptr.cc (bad_weak_ptr::what()): Correct string.
	* testsuite/20_util/shared_ptr/cons/weak_ptr_expired.cc: Verify
	string.

	PR libstdc++/55728
	* include/std/functional (bad_function_call::what()): Declare.
	* src/c++11/functional.cc (bad_function_call::what()): Define.
	* config/abi/pre/gnu.ver (bad_function_call::what()): Export.
	* testsuite/20_util/bad_function_call/what.cc: New.

From-SVN: r194958
2013-01-07 00:50:16 +00:00
Jonathan Wakely
1c2620dd6a unordered_map.h: Fix typo in comments.
* include/bits/unordered_map.h: Fix typo in comments.
	* doc/xml/manual/status_cxx2011.xml: Add implementation-defined bucket
	counts for unordered associative containers.

From-SVN: r194954
2013-01-06 21:58:18 +00:00
Jonathan Wakely
ac43ff42f2 * doc/xml/manual/abi.xml: Update library and symbol versions.
From-SVN: r194950
2013-01-06 21:19:39 +00:00
Richard Sandiford
adf8bb4f07 insert_fn_imps.hpp: Fix typo in copyright years.
libstdc++-v3/
	* include/ext/pb_ds/detail/splay_tree_/insert_fn_imps.hpp: Fix typo
	in copyright years.
	* testsuite/22_locale/time_get/get_weekday/wchar_t/3.cc: Likewise.

From-SVN: r194941
2013-01-06 11:53:01 +00:00
Jakub Jelinek
90d04a445c Update Copyright years for files modified in 2011 and/or 2012.
From-SVN: r194903
2013-01-04 13:49:55 +01:00
Jakub Jelinek
86a2db336a ChangeLog rotation.
From-SVN: r194840
2013-01-03 10:47:48 +01:00
Kai Tietz
3cc6dd4dce os_defines.h (_GLIBCXX_LLP64): Define if llp64 abi is used.
* config/os/mingw32/os_defines.h (_GLIBCXX_LLP64): Define if llp64
	abi is used.
	* config/os/mingw32-w64/os_defines.h: Likewise.
	* libsupc++/cxxabi.h (__base_class_type_info): Adjust
	type of __offset_flags for llp64.
	* libsupc++/eh_alloc.cc (EMERGENCY_OBJ_SIZE): Define proper
	for llp64 abi.
	(EMERGENCY_OBJ_COUNT): Likewise.
	(bitmask_type): Likewise.
	* libsupc++/hash_bytes.cc (_Hash_bytes): Handle llp64.

From-SVN: r194658
2012-12-21 11:12:48 +01:00
Jonathan Wakely
23df853421 functional (_Require): Move to ...
* include/std/functional (_Require): Move to ...
	* include/std/type_traits (_Require): ... here.
	* include/bits/shared_ptr_base.h (__shared_count::_S_create_from_up):
	Handle unique_ptr for arrays or with custom pointer types.
	(__shared_ptr::__shared_ptr(unique_ptr<_Tp1, _Del>&&): Likewise.
	* include/bits/unique_ptr.h (unique_ptr<_Tp[], _Dp>): Use
	_Dp::pointer if defined. Implement proposed resolution of LWG 2118.
	* testsuite/20_util/shared_ptr/cons/unique_ptr_array.cc: New.
	* testsuite/20_util/unique_ptr/assign/cv_qual.cc: New.
	* testsuite/20_util/unique_ptr/cons/array_convertible_neg.cc: New.
	* testsuite/20_util/unique_ptr/cons/convertible_neg.cc: New.
	* testsuite/20_util/unique_ptr/cons/cv_qual.cc: New.
	* testsuite/20_util/unique_ptr/modifiers/cv_qual.cc: New.
	* testsuite/20_util/unique_ptr/requirements/pointer_type_array.cc: New.
	* testsuite/20_util/shared_ptr/cons/unique_ptr.cc: Adjust comments.
	* testsuite/20_util/unique_ptr/cons/pointer_array_convertible_neg.cc:
	Likewise.
	* testsuite/20_util/unique_ptr/requirements/pointer_type.cc: Likewise.
	* testsuite/20_util/bind/ref_neg.cc: Adjust dg-error line number.
	* testsuite/20_util/declval/requirements/1_neg.cc: Likewise.
	* testsuite/20_util/default_delete/48631_neg.cc: Likewise.
	* testsuite/20_util/shared_ptr/cons/43820_neg.cc: Likewise.
	* testsuite/20_util/unique_ptr/assign/48635_neg.cc: Likewise.
	* testsuite/20_util/unique_ptr/modifiers/reset_neg.cc: Adjust
	dg-error text.
	* testsuite/20_util/unique_ptr/cons/ptr_deleter_neg.cc: Use
	different instantiations so static_assert fails for each.

From-SVN: r194651
2012-12-20 21:02:33 +00:00
Jonathan Wakely
8ed812cc4b re PR libstdc++/55741 (bootstrap fails in libstdc++-v3/src/c++11/thread.cc)
PR libstdc++/55741
	* acinclude.m4 (GLIBCXX_ENABLE_LIBSTDCXX_TIME): Check for Sleep.
	* config.h.in: Regenerate.
	* configure: Regenerate.
	* src/c++11/thread.cc (__sleep_for): Use Sleep if available.

From-SVN: r194635
2012-12-20 14:36:56 +00:00
Jonathan Wakely
898be2f38d abi.xml: Update URLs for C++ ABI.
* doc/xml/manual/abi.xml: Update URLs for C++ ABI.
	* doc/xml/manual/policy_data_structures_biblio.xml: Add xmlns
	attribute.
	* doc/xml/manual/debug_mode.xml: Give filenames to chunks.
	* doc/xml/manual/diagnostics.xml: Likewise.
	* doc/xml/manual/extensions.xml: Likewise.
	* doc/xml/manual/bitmap_allocator.xml: Likewise.
	* doc/xml/manual/mt_allocator.xml: Likewise.
	* doc/xml/manual/policy_data_structures.xml: Likewise.
	* doc/xml/manual/parallel_mode.xml: Likewise.
	* doc/xml/manual/profile_mode.xml: Likewise.
	* doc/xml/manual/spine.xml: Likewise. Update copyright years.
	* doc/html/*: Regenerate.

From-SVN: r194576
2012-12-18 11:08:33 +00:00
Jonathan Wakely
92b8bccecb * include/std/future (__async_sfinae_helper): Remove.
From-SVN: r194567
2012-12-17 21:30:51 +00:00
Jonathan Wakely
5f2862cf63 thread.cc (execute_native_thread_routine): Do not swallow __forced_unwind exceptions.
* src/c++11/thread.cc (execute_native_thread_routine): Do not swallow
	__forced_unwind exceptions.
	* testsuite/30_threads/thread/native_handle/cancel.cc: New.

From-SVN: r194539
2012-12-16 20:52:47 +00:00
Steve Ellcey
2993114da5 3.cc: Shrink memory usage under simulator.
2012-12-14  Steve Ellcey  <sellcey@mips.com>

	* testsuite/21_strings/basic_string/append/wchar_t/3.cc: Shrink
	memory usage under simulator.
	* testsuite/21_strings/basic_string/cons/wchar_t/6.cc: Ditto.
	* testsuite/21_strings/basic_string/inserters_extractors/wchar_t/10.cc:
	Ditto.
	* testsuite/21_strings/basic_string/inserters_extractors/wchar_t/11.cc:
	Ditto.

From-SVN: r194510
2012-12-14 22:03:40 +00:00
Steve Ellcey
01f4c82194 18654.cc: Shrink memory usage under simulator.
2012-12-13  Steve Ellcey  <sellcey@mips.com>

	* testsuite/21_strings/basic_string/capacity/char/18654.cc: Shrink
	memory usage under simulator.
	* testsuite/21_strings/basic_string/capacity/wchar_t/18654.cc: Ditto.
	* testsuite/22_locale/collate/transform/char/28277.cc: Ditto.
	* testsuite/22_locale/collate/transform/wchar_t/28277.cc: Ditto.

From-SVN: r194488
2012-12-13 19:55:13 +00:00
Benjamin Kosnik
f52f03c86c documentation_hacking.xml: Fix validation issue.
2012-12-12  Benjamin Kosnik  <bkoz@redhat.com>

	* doc/xml/manual/documentation_hacking.xml: Fix validation issue.

From-SVN: r194455
2012-12-12 22:15:30 +00:00
Jonathan Wakely
3c523cf8a8 re PR libstdc++/55631 (Several ext/ headers can not be #included on their own)
PR libstdc++/55631
	* include/ext/alloc_traits.h: Include missing header.
	* include/ext/pointer.h: Likewise.
	* include/ext/string_conversions.h: Require C++11.
	* libsupc++/initializer_list: Reindent.

From-SVN: r194429
2012-12-11 22:28:01 +00:00
Benjamin Kosnik
74080cba9b Makefile.am (xml_sources_manual): Add policy_data_structures_biblio.xml.
2012-12-10  Benjamin Kosnik  <bkoz@redhat.com>

	* doc/Makefile.am (xml_sources_manual): Add
	policy_data_structures_biblio.xml.
	(${docbook_outdir}/latex): Add.
	(doc-xml-validate-docbook): Split into..
	(doc-xml-validate-dtd-db):... this for DTD.
	(doc-xml-validate-rng-db):... this for Relax NG.
	(doc-pdf-docbook-dirs): Add.
	(doc-pdf-docbook-pre): Add.
	* doc/xml/manual/build_hacking.xml: Add literal markup.
	* doc/xml/manual/documentation_hacking.xml: Clean whitespace in
	<filename> markup. Add notes about debugging the generation process.
	* doc/xml/manual/policy_data_structures.xml: Split biblio into...
	* doc/xml/manual/policy_data_structures_biblio.xml: ... this. New.
	* doc/xml/manual/test_policy_data_structures.xml: Fixup <filename>
	markup.

From-SVN: r194379
2012-12-11 01:52:14 +00:00
Matthias Klose
d392c399e5 Makefile.am (libstdc++-symbols.ver): Use CONFIG_HEADER.
2012-12-10  Matthias Klose  <doko@ubuntu.com>

        * src/Makefile.am (libstdc++-symbols.ver): Use CONFIG_HEADER.
        * src/Makefile.in: Regenerate.

From-SVN: r194346
2012-12-10 09:08:12 +00:00
Andreas Schwab
9ddad47136 libstdc++.exp (dg-test): Unset testname_with_flags after running the test.
* testsuite/lib/libstdc++.exp (dg-test): Unset testname_with_flags
after running the test.

From-SVN: r194330
2012-12-09 14:31:27 +00:00
Andreas Schwab
b788b99833 Makefile.am (${host_builddir}/c++config.h): Replace [<space><tab>] by [<tab><space>].
* include/Makefile.am (${host_builddir}/c++config.h): Replace
[<space><tab>] by [<tab><space>].
* include/Makefile.in: Regenerate.

From-SVN: r194169
2012-12-04 22:40:24 +00:00
Steven Bosscher
1b5be39ffc Makefile.am: Fix regexp broken by previous commit.
* include/Makefile.am: Fix regexp broken by previous commit.
	* include/Makefile.in: Likewise.

From-SVN: r194152
2012-12-04 15:52:52 +00:00
Benjamin Kosnik
cef1bc586c standard_policies.hpp: Remove.
2012-12-03  Benjamin Kosnik  <bkoz@redhat.com>

	* include/ext/pb_ds/detail/cc_hash_table_map_/standard_policies.hpp:
	Remove.
	* include/ext/pb_ds/detail/gp_hash_table_map_/standard_policies.hpp:
	Remove.
 	* include/Makefile.am (pb_headers): Remove include files.
	* include/Makefile.in: Regenerated.

From-SVN: r194107
2012-12-03 23:23:52 +00:00
John David Anglin
27ba7cea69 re PR libstdc++/55503 (FAIL: 30_threads/condition_variable/members/53841.cc (test for excess errors))
PR libstdc++/55503
	* testsuite/30_threads/condition_variable/members/53841.cc: Add
	hppa*-hp-hpux11* to -pthread dg-options.

From-SVN: r194021
2012-12-01 18:25:11 +00:00
Kai Tietz
02f9e21a26 re PR target/55445 (Always defined __SEH__ when build from trunk)
PR target/55445
        * libsupc++/eh_personaltity.cc (__SEH__): Additional check
        for not being SjLj.

From-SVN: r193929
2012-11-29 10:39:49 +01:00
Andrew Pinski
5d99894e65 re PR other/54279 (first stage build with g++ fails with "." as the first component of $PATH)
2012-11-28  Andrew Pinski  <apinski@cavium.com>

        PR bootstrap/54279
        * configure.ac (CXX_FOR_TARGET): Change over to use xg++.
        * configure: Regenerate.
        * Makefile.tpl (POSTSTAGE1_CXX_EXPORT): Change over to use xg++.
        * Makefile.in: Regenerate.

2012-11-28  Andrew Pinski  <apinski@cavium.com>

        PR bootstrap/54279
        * Makefile.in (${QMTEST_DIR}/context): Use xg++ instead of g++.

2012-11-28  Andrew Pinski  <apinski@cavium.com>

        PR bootstrap/54279
        * Make-lang.in (g++$(exeext)): Rename to
        (xg++$(exeext)): This.
        (g++-cross$(exeext)): Use xg++$(exeext) instead of g++$(exeext).
        (c++.start.encap): Likewise.
        (c++.install-common): Likewise.

2012-11-28  Andrew Pinski  <apinski@cavium.com>

        PR bootstrap/54279
        * lib/g++.exp (g++_init): Search for xg++ instead of g++ in the build
        directories.
        * lib/obj-c++.exp (obj-c++_init): Likewise.

2012-11-28  Andrew Pinski  <apinski@cavium.com>

        PR bootstrap/54279
        * scripts/testsuite_flags.in (--build-cxx): Use xg++ instead of g++.
        * testsuite/lib/libstdc++.exp (libstdc++_init): Likewise.

From-SVN: r193910
2012-11-28 14:11:29 -08:00
Jonathan Wakely
b1c2b51b66 functional (_Mem_fn): Constrain function call operators to avoid ambiguities.
* include/std/functional (_Mem_fn): Constrain function call operators
	to avoid ambiguities. Use perfect forwarding.
	* testsuite/20_util/function_objects/mem_fn/55463.cc: Additional
	tests.
	* testsuite/20_util/function_objects/mem_fn/forward.cc: New.
	* testsuite/20_util/bind/ref_neg.cc: Adjust dg-error line numbers.

From-SVN: r193879
2012-11-28 01:42:25 +00:00
Ollie Wild
29f696491c Fix incorrect @headername Doxygen macro invocation.
Format is @headername{hdr1,hdr2} not @headername{hdr1 or hdr2}.

2012-11-27  Ollie Wild  <aaw@google.com>

	* include/bits/stl_tree.h (@headername): Fix incorrect Doxygen macro
	invocation.

From-SVN: r193869
2012-11-27 20:52:02 +00:00
Jonathan Wakely
5895a897b5 functional (__is_socketlike): Change from class template to alias template.
* include/std/functional (__is_socketlike): Change from class
	template to alias template.

From-SVN: r193832
2012-11-26 23:53:36 +00:00
Jonathan Wakely
5127244e4b re PR libstdc++/55463 (Result of std::mem_fn doesn't accept rvalues)
PR libstdc++/55463
	* include/std/functional (_Mem_fn): Handle rvalue objects. Add
	noexcept-specifications.
	* testsuite/20_util/function_objects/mem_fn/55463.cc: New.
	* testsuite/20_util/bind/ref_neg.cc: Adjust dg-error line numbers.

From-SVN: r193831
2012-11-26 23:53:29 +00:00
Jonathan Wakely
aa66b299c8 re PR libstdc++/52680 (std::this_thread::sleep_for #ifdef'd out by _GLIBCXX_USE_NANOSLEEP)
PR libstdc++/52680
	* acinclude.m4 (GLIBCXX_ENABLE_LIBSTDCXX_TIME): Check for usleep and
	sleep if nanosleep is not available. Bump libtool revision.
	* config.h.in: Regenerate.
	* configure: Likewise.
	* config/abi/pre/gnu.ver (GLIBCXX_3.4.18): Add __sleep_for.
	* include/std/thread (this_thread::__sleep_for): Add.
	(this_thread::yield, this_thread::sleep_until, this_thread::sleep_for):
	Declare unconditionally.
	* src/c++11/thread.cc (this_thread::__sleep_for): Define.
	* testsuite/lib/libstdc++.exp (check_v3_target_nanosleep): Rename to
	check_v3_target_sleep.
	* testsuite/lib/dg-options.exp (dg-require-nanosleep): Rename to
	dg-require-sleep.
	* testsuite/30_threads/condition_variable_any/53830.cc: Update.
	* testsuite/30_threads/this_thread/2.cc: Likewise.
	* testsuite/30_threads/this_thread/3.cc: Likewise.
	* testsuite/30_threads/this_thread/4.cc: Likewise.
	* testsuite/30_threads/async/54297.cc: Likewise.

From-SVN: r193769
2012-11-23 22:11:23 +00:00
Paolo Carlini
25caa91e99 re PR libstdc++/55413 ([LTO] hashtable.h:1648 '__bbegin_bkt' may be used uninitialized in this function [-Werror=maybe-uninitialized])
2012-11-20  Paolo Carlini  <paolo.carlini@oracle.com>

	PR libstdc++/55413
	* include/bits/hashtable.h (_Hashtable<>::_M_rehash_aux): Initialize
	__bbegin_bkt and __prev_bkt to avoid uninitialized warnings.
	* testsuite/23_containers/unordered_set/instantiation_neg.cc: Adjust
	dg-error line number.

From-SVN: r193663
2012-11-20 14:54:11 +00:00
Matthias Klose
3263c9a3a7 2012-11-20 Matthias Klose <doko@ubuntu.com>
* doc/doxygen/user.cfg.in (ALIASES). Escape sharp braces.
        * include/bits/allocator.h: Escape sharp braces in comment.
        * include/profile/impl/profiler_algos.h: Likewise.

From-SVN: r193662
2012-11-20 13:48:28 +00:00
Jonathan Wakely
6b1328eb3c array_allocator.h: Replace uses of __GXX_EXPERIMENTAL_CXX0X__ with __cplusplus.
* include/ext/array_allocator.h: Replace uses of
	__GXX_EXPERIMENTAL_CXX0X__ with __cplusplus.

From-SVN: r193644
2012-11-20 00:24:18 +00:00
Jonathan Wakely
0e8330d91d typedefs.cc: Check rebind and improve propagate_on_container_move_assignment check.
* testsuite/20_util/allocator/requirements/typedefs.cc: Check rebind
	and improve propagate_on_container_move_assignment check.

From-SVN: r193639
2012-11-19 22:35:11 +00:00
Jonathan Wakely
1b5dc776ca stl_algo.h (reverse_copy): Update comment per DR 2074.
* include/bits/stl_algo.h (reverse_copy): Update comment per DR 2074.
	* include/bits/unordered_map.h: Apply DR 2005 resolution.
	* doc/xml/manual/status_cxx2011.xml: Update per DR 2048.
	* include/bits/allocator.h (allocator): Apply DR 2103 resolution.
	* include/ext/array_allocator.h: Likewise.
	* include/ext/bitmap_allocator.h: Likewise.
	* include/ext/malloc_allocator.h: Likewise.
	* include/ext/mt_allocator.h: Likewise.
	* include/ext/new_allocator.h: Likewise.
	* include/ext/pool_allocator.h: Likewise.
	* include/ext/throw_allocator.h: Likewise.
	* include/ext/alloc_traits.h (__allocator_always_compares_equal): Add
	additional specializations.
	* include/std/functional: Add comment about DR resolution.
	* include/std/future: Likewise.
	* include/std/scoped_allocator: Likewise.
	* include/std/thread: Likewise.
	* testsuite/20_util/allocator/requirements/typedefs.cc: New.
	* testsuite/20_util/bind/ref_neg.cc: Adjust dg-error line numbers.

From-SVN: r193638
2012-11-19 22:28:00 +00:00
Jonathan Wakely
207585a63d hashtable.h: Improve comments.
* include/bits/hashtable.h: Improve comments.
	* include/bits/hashtable_policy.h: Likewise.

From-SVN: r193636
2012-11-19 21:33:52 +00:00
Paolo Carlini
741aacafff re PR libstdc++/55363 (tuple_size is not a class template)
2012-11-17  Paolo Carlini  <paolo.carlini@oracle.com>

	PR libstdc++/55363
	* include/std/array (tuple_size, tuple_element): Move out
	NAMESPACE_CONTAINER.
	* testsuite/23_containers/array/tuple_interface/get_neg.cc: Adjust
	dg-error line numbers.
	* testsuite/23_containers/array/tuple_interface/tuple_element_neg.cc:
	Likewise.

From-SVN: r193584
2012-11-17 12:09:58 +00:00
François Dumont
d4a7f7a15c hashtable_policy.h (_Prime_rehash_policy): Remove automatic shrink.
2012-11-16  François Dumont  <fdumont@gcc.gnu.org>

	* include/bits/hashtable_policy.h (_Prime_rehash_policy): Remove
	automatic shrink.
	(_Prime_rehash_policy::_M_bkt_for_elements): Do not call
	_M_next_bkt anymore.
	(_Prime_rehash_policy::_M_next_bkt): Move usage of
	_S_growth_factor ...
	(_Prime_rehash_policy::_M_need_rehash): ... here.
	* include/bits/hashtable.h (_Hashtable<>): Adapt.
	* testsuite/performance/23_containers/insert_erase/41975.cc: Add
	_USE_TR1 to force build using std::tr1 container.
	* testsuite/performance/23_containers/insert/unordered_set.cc:
	Likewise.
	* testsuite/performance/23_containers/insert/54075.cc: New.

From-SVN: r193576
2012-11-16 21:28:44 +00:00
Tom Tromey
50605a7f19 whatis.cc: New file.
* testsuite/libstdc++-prettyprinters/whatis.cc: New file.
	* testsuite/lib/gdb-test.exp (whatis-test): New proc.
	(gdb-test): Handle 'whatis' tests.
	(gdb_batch_check): New proc.
	(gdb_version_check): Rewrite to use gdb_batch_check.
	* python/libstdcxx/v6/printers.py: Import gdb.types.
	(FilteringTypePrinter): New class.
	(add_one_type_printer, register_type_printers): New functions.
	(register_libstdcxx_printers): Call register_type_printers.

From-SVN: r193573
2012-11-16 18:17:25 +00:00
Jason Merrill
4fce678f8a re PR c++/55275 (abi_tag attribute doesn't work on explicit specializations of class templates)
PR c++/55275
	* pt.c (maybe_process_partial_specialization): Update
	DECL_SOURCE_LOCATION for new specializations.

From-SVN: r193524
2012-11-14 20:53:23 -05:00
Jonathan Wakely
c25639b1a3 re PR libstdc++/53841 ([C++11] condition_variable::wait_until() fails with high resolution clocks)
PR libstdc++/53841
	* include/std/condition_variable (condition_variable::wait_until):
	Handle clocks with higher resolution than __clock_t.
	(condition_variable::__wait_until_impl): Remove unnecessary _Clock
	parameter.
	* testsuite/30_threads/condition_variable/members/53841.cc: New.

From-SVN: r193523
2012-11-15 01:38:17 +00:00
Jonathan Wakely
99ace34a31 re PR libstdc++/55320 (Invalid delete with throwing copy-c'tor passed to std::function)
PR libstdc++/55320
	* include/std/functional (function::function(F)): Set _M_manager after
	operations that could throw.
	(_Function_base::_Ref_manager::_M_init_functor): Use addressof.
	* include/tr1/functional
	(_Function_base::_Ref_manager::_M_init_functor): Use addressof.
	(_Function_base::_Base_manager::_M_get_pointer): Likewise.
	* testsuite/20_util/function/cons/55320.cc: New.
	* testsuite/20_util/function/cons/addressof.cc: New.
	* testsuite/20_util/function/cons/callable.cc: Remove header.
	* testsuite/20_util/bind/ref_neg.cc: Adjust dg-error line numbers.
	* testsuite/tr1/3_function_objects/function/10.cc: New.

From-SVN: r193514
2012-11-14 23:33:01 +00:00
Uros Bizjak
0c9afb50c4 abi_tag.cc: Adjust expected demangling for 128bit long-double targets.
* testsuite/26_numerics/complex/abi_tag.cc: Adjust expected
	demangling for 128bit long-double targets.

From-SVN: r193509
2012-11-14 23:23:51 +01:00
Jonathan Wakely
0ad9f93083 future (atomic_future): Remove declaration of non-standard name.
* include/std/future (atomic_future): Remove declaration of
	non-standard name.

From-SVN: r193457
2012-11-12 23:00:41 +00:00
Jason Merrill
7a3a9e6821 * include/std/complex (real, imag): Add ABI tag in C++11 mode.
From-SVN: r193445
2012-11-12 12:51:26 -05:00
Andreas Schwab
92eba4000d chapter.txml: Remove whitespace inside <keyword>.
* doc/xml/chapter.txml: Remove whitespace inside <keyword>.
* doc/xml/class.txml: Likewise.
* doc/xml/manual/abi.xml: Likewise.
* doc/xml/manual/algorithms.xml: Likewise.
* doc/xml/manual/allocator.xml: Likewise.
* doc/xml/manual/appendix_contributing.xml: Likewise.
* doc/xml/manual/appendix_free.xml: Likewise.
* doc/xml/manual/appendix_porting.xml: Likewise.
* doc/xml/manual/atomics.xml: Likewise.
* doc/xml/manual/auto_ptr.xml: Likewise.
* doc/xml/manual/backwards_compatibility.xml: Likewise.
* doc/xml/manual/bitmap_allocator.xml: Likewise.
* doc/xml/manual/build_hacking.xml: Likewise.
* doc/xml/manual/codecvt.xml: Likewise.
* doc/xml/manual/concurrency.xml: Likewise.
* doc/xml/manual/concurrency_extensions.xml: Likewise.
* doc/xml/manual/configure.xml: Likewise.
* doc/xml/manual/containers.xml: Likewise.
* doc/xml/manual/ctype.xml: Likewise.
* doc/xml/manual/debug.xml: Likewise.
* doc/xml/manual/debug_mode.xml: Likewise.
* doc/xml/manual/diagnostics.xml: Likewise.
* doc/xml/manual/extensions.xml: Likewise.
* doc/xml/manual/internals.xml: Likewise.
* doc/xml/manual/intro.xml: Likewise.
* doc/xml/manual/io.xml: Likewise.
* doc/xml/manual/iterators.xml: Likewise.
* doc/xml/manual/locale.xml: Likewise.
* doc/xml/manual/localization.xml: Likewise.
* doc/xml/manual/messages.xml: Likewise.
* doc/xml/manual/mt_allocator.xml: Likewise.
* doc/xml/manual/numerics.xml: Likewise.
* doc/xml/manual/parallel_mode.xml: Likewise.
* doc/xml/manual/policy_data_structures.xml: Likewise.
* doc/xml/manual/prerequisites.xml: Likewise.
* doc/xml/manual/profile_mode.xml: Likewise.
* doc/xml/manual/shared_ptr.xml: Likewise.
* doc/xml/manual/status_cxx1998.xml: Likewise.
* doc/xml/manual/status_cxx2011.xml: Likewise.
* doc/xml/manual/status_cxxtr1.xml: Likewise.
* doc/xml/manual/status_cxxtr24733.xml: Likewise.
* doc/xml/manual/strings.xml: Likewise.
* doc/xml/manual/support.xml: Likewise.
* doc/xml/manual/test.xml: Likewise.
* doc/xml/manual/using_exceptions.xml: Likewise.
* doc/xml/manual/utilities.xml: Likewise.
* doc/xml/spine.xml: Likewise.

From-SVN: r193414
2012-11-11 21:17:43 +00:00
Andreas Schwab
919bbe6e1e acinclude.m4 (GLIBCXX_CONFIGURE_DOCBOOK): Also check for /usr/share/xml/docbook/stylesheet/nwalsh5/current.
* acinclude.m4 (GLIBCXX_CONFIGURE_DOCBOOK): Also check for
/usr/share/xml/docbook/stylesheet/nwalsh5/current.
* configure: Regenerate.

From-SVN: r193413
2012-11-11 21:01:01 +00:00
Gerald Pfeifer
6e7e4ca2e8 policy_data_structures.xml: Update reference for select.
* doc/xml/manual/policy_data_structures.xml: Update reference
	for select.

From-SVN: r193405
2012-11-11 09:57:14 +00:00
Jason Merrill
734f50238f * many: Replace uses of __GXX_EXPERIMENTAL_CXX0X__ with __cplusplus.
From-SVN: r193392
2012-11-10 12:27:22 -05:00
François Dumont
ecf07a67d0 re PR libstdc++/54075 ([4.7.1] unordered_map insert still slower than 4.6.2)
2012-11-08  François Dumont  <fdumont@gcc.gnu.org>

	PR libstdc++/54075
	* include/bits/hashtable.h (_Hashtable<>::rehash): Reset hash
	policy state if no rehash.
	* testsuite/23_containers/unordered_set/modifiers/reserve.cc
	(test02): New.

From-SVN: r193339
2012-11-08 20:16:04 +00:00
Paolo Carlini
271a8a1651 55028-debug.cc: Don't pass -D_GLIBCXX_DEBUG by hand (check-debug does).
2012-11-08  Paolo Carlini  <paolo.carlini@oracle.com>

	* testsuite/23_containers/unordered_multimap/insert/55028-debug.cc:
	Don't pass -D_GLIBCXX_DEBUG by hand (check-debug does).

From-SVN: r193327
2012-11-08 13:40:53 +00:00
Florian Weimer
6aaa880639 cxa_vec.C: Fix typo in comment.
* g++.old-deja/g++.abi/cxa_vec.C: Fix typo in comment.

	* testsuite/18_support/cxa_vec.cc: Fix typo in comment.

From-SVN: r193326
2012-11-08 10:54:04 +01:00
Jonathan Wakely
800ac749de iterator_tracker.h (operator++): Fix returning dangling reference.
* include/profile/iterator_tracker.h (operator++): Fix returning
	dangling reference.
	(operator--): Likewise.

From-SVN: r193323
2012-11-08 09:15:43 +00:00
Paolo Carlini
54ba39f599 array (_GLIBCXX_THROW_OR_ABORT): Move...
2012-11-07  Paolo Carlini  <paolo.carlini@oracle.com>

	* include/debug/array (_GLIBCXX_THROW_OR_ABORT): Move...
	* include/bits/c++config: ... here.
	* include/bits/shared_ptr_base.h (__throw_bad_weak_ptr): Use it.
	* include/ext/pb_ds/exception.hpp: Likewise.
	* include/ext/throw_allocator.h (__throw_forced_error): Likewise.
	* include/ext/concurrence.h (__throw_concurrence_lock_error,
	__throw_concurrence_unlock_error, __throw_concurrence_broadcast_error,
	__throw_concurrence_wait_error): Likewise.
	* include/tr1/shared_ptr.h (__throw_bad_weak_ptr): Likewise.
	* include/tr1/functional (function<_Res(_ArgTypes...)>::operator()
	(_ArgTypes...)): Likewise.
	* libsupc++/eh_aux_runtime.cc (__cxxabiv1::__cxa_bad_cast,
	__cxxabiv1::__cxa_bad_typeid): Likewise.
	* libsupc++/vec.cc (compute_size): Likewise.
	* libsupc++/new_op.cc (operator new (std::size_t)): Likewise.
	* src/c++11/functexcept.cc: Likewise.
	* testsuite/util/io/illegal_input_error.hpp
	(__throw_illegal_input_error): Likewise.
	* libsupc++/eh_personality.cc: Avoid warning with -fno-exceptions.
	* testsuite/ext/profile/mutex_extensions_neg.cc: Adjust dg-error line
	numbers.
	* testsuite/tr1/2_general_utilities/shared_ptr/cons/43820_neg.cc:
	Likewise.
	* testsuite/23_containers/array/tuple_interface/
	tuple_element_debug_neg.cc: Likewise.
	* testsuite/23_containers/array/tuple_interface/get_debug_neg.cc:
	Likewise.
	* testsuite/20_util/shared_ptr/cons/43820_neg.cc: Likewise.

From-SVN: r193295
2012-11-07 13:20:33 +00:00
Jonathan Wakely
d720a22b6e stl_vector.h (vector(size_type)): Add missing allocator parameter.
* include/bits/stl_vector.h (vector(size_type)): Add missing allocator
	parameter.
	* include/bits/stl_bvector.h: Likewise.
	* include/debug/vector (vector(size_type)): Likewise.
	* include/profile/vector (vector(size_type)): Likewise. Pass allocator
	to base constructor.
	* testsuite/23_containers/vector/requirements/dr438/assign_neg.cc:
	Adjust dg-error line numbers.
	* testsuite/23_containers/vector/requirements/dr438/
	constructor_1_neg.cc: Likewise.
	* testsuite/23_containers/vector/requirements/dr438/
	constructor_2_neg.cc: Likewise.
	* testsuite/23_containers/vector/requirements/dr438/insert_neg.cc:
	Likewise.

From-SVN: r193284
2012-11-07 09:17:42 +00:00
Paolo Carlini
0611ce440a re PR libstdc++/51850 (debug mode for std::array and tr1::array)
2012-11-06  Paolo Carlini  <paolo.carlini@oracle.com>

	PR libstdc++/51850
	* include/debug/array: New, debug-mode implementation.
	* include/profile/array: New.
	* include/std/array: Adjust.
	* include/std/tuple: Just include <array>.
	* include/Makefile.am: Add.
	* include/Makefile.in: Regenerate.
	* testsuite/23_containers/array/debug/front1_neg.cc: New.
	* testsuite/23_containers/array/debug/
	square_brackets_operator1_neg.cc: Likewise.
	* testsuite/23_containers/array/debug/front2_neg.cc: Likewise.
	* testsuite/23_containers/array/debug/
	square_brackets_operator2_neg.cc: Likewise.
	* testsuite/23_containers/array/debug/back1_neg.cc: Likewise.
	* testsuite/23_containers/array/debug/back2_neg.cc: Likewise.
	* testsuite/23_containers/array/tuple_interface/get_neg.cc: Tweak
	to run only in normal-mode.
	* testsuite/23_containers/array/tuple_interface/tuple_element_neg.cc:
	Likewise.
	* testsuite/23_containers/array/tuple_interface/get_debug_neg.cc: New.
	* testsuite/23_containers/array/tuple_interface/
	tuple_element_debug_neg.cc: Likewise.

From-SVN: r193278
2012-11-07 00:42:19 +00:00
Jonathan Wakely
b142d8a2b5 55123.cc: Remove duplicate include.
* testsuite/20_util/shared_ptr/cons/55123.cc: Remove duplicate
	include.

From-SVN: r193263
2012-11-06 22:53:16 +00:00
Paolo Carlini
c4ae987730 atomic_base.h: Don't include <cstddef>, use nullptr.
2012-11-06  Paolo Carlini  <paolo.carlini@oracle.com>
  
	* include/bits/atomic_base.h: Don't include <cstddef>, use nullptr.
	* include/std/atomic: Likewise.
	* include/tr2/dynamic_bitset: Likewise.

	* libsupc++/vec.cc (compute_size(std::size_t, std::size_t,
	std::size_t)): Fix for -fno-exceptions.

From-SVN: r193232
2012-11-06 11:03:45 +00:00
Jonathan Wakely
31828bd36a * include/profile/map.h (map::emplace_hint): Add missing return.
From-SVN: r193202
2012-11-06 00:19:57 +00:00
Jonathan Wakely
3c7d8b035a deque: Constrain InputIterator parameters.
* include/profile/deque: Constrain InputIterator parameters.
	* include/profile/forward_list: Likewise.
	* include/profile/list: Likewise.
	* include/profile/map.h: Likewise.
	* include/profile/multimap.h: Likewise.
	* include/profile/set.h: Likewise.
	* include/profile/multiset.h: Likewise.
	* include/profile/vector: Likewise.

From-SVN: r193196
2012-11-06 00:06:42 +00:00
Jonathan Wakely
e77c9aedcd forward_list: Update to meet allocator-aware requirements.
* include/profile/forward_list: Update to meet allocator-aware
	requirements.
	* include/debug/forward_list: Likewise.
	* include/debug/vector: Verify allocators are swapped or equal.
	* include/debug/macros.h (__glibcxx_check_equal_allocs): Define.
	* include/debug/formatter.h: Add new debug message.
	* src/c++11/debug.cc: Likewise.
	* testsuite/23_containers/forward_list/allocator/swap.cc: Do not
	swap containers with non-propagating, non-equal allocators.
	* testsuite/23_containers/vector/allocator/swap.cc: Likewise.

From-SVN: r193186
2012-11-05 21:10:27 +00:00
Benjamin Kosnik
684592672f re PR libstdc++/55028 (_GLIBCXX_DEBUG is broken when using v7 namespace)
2012-11-05  Benjamin Kosnik  <bkoz@redhat.com>
            Oleg Smolsky  <oleg@smolsky.net>

	PR libstdc++/55028
	*  config/abi/pre/gnu-versioned-namespace.ver: Add symbols.
	* testsuite/23_containers/unordered_multimap/insert/55028-debug.cc: New.

Co-Authored-By: Oleg Smolsky <oleg@smolsky.net>

From-SVN: r193185
2012-11-05 21:01:08 +00:00
François Dumont
51bf1e805e throw_allocator.h (__throw_value_base): Add move semantic, not throwing.
2012-10-05  François Dumont  <fdumont@gcc.gnu.org>

	* include/ext/throw_allocator.h (__throw_value_base): Add move
	semantic, not throwing.
	(__throw_value_limit): Likewise.
	(__throw_value_random): Likewise.
	* testsuite/util/exception/safety.h: Add validation of C++11
	methods emplace/emplace_front/emplace_back/emplace_hint.
	* testsuite/util/testsuite_container_traits.h: Signal emplace
	support on deque, forward_list, list and vector.
	* testsuite/23_containers/deque/requirements/exception/
	propagation_consistent.cc: Remove dg-do run fail.

From-SVN: r193184
2012-11-05 20:58:35 +00:00
Paolo Carlini
935ec36fdd re PR libstdc++/55215 (Constructor seeding is broken for Mersenne twister)
2012-11-05  Paolo Carlini  <paolo.carlini@oracle.com>

	PR libstdc++/55215
	* include/bits/random.tcc (mersenne_twister_engine<>::seed(_Sseq&)):
	Assign state_size to _M_p.
	* testsuite/26_numerics/random/mersenne_twister_engine/cons/55215.cc:
	New.
	* testsuite/26_numerics/random/independent_bits_engine/cons/55215.cc:
	Likewise.
	* testsuite/26_numerics/random/shuffle_order_engine/cons/55215.cc:
	Likewise.
	* testsuite/26_numerics/random/subtract_with_carry_engine/cons/
	55215.cc: Likewise.
	* testsuite/26_numerics/random/discard_block_engine/cons/55215.cc:
	Likewise.
	* testsuite/26_numerics/random/linear_congruential_engine/cons/
	55215.cc: Likewise.

From-SVN: r193181
2012-11-05 19:25:20 +00:00
Florian Weimer
6d0ae0359c Detect overflow in size calculations in __cxa_vec_new{2,3}
2012-11-03  Florian Weimer  <fweimer@redhat.com>

	* libsupc++/vec.cc (compute_size): New.
	(__cxa_vec_new2, __cxa_vec_new3): Use it.
	* testsuite/18_support/cxa_vec.cc: New.

From-SVN: r193174
2012-11-05 18:48:46 +01:00
Robert Mason
2588b26e0e final patch for enabling VxWorks
From-SVN: r193124
2012-11-03 15:53:28 +00:00
Jonathan Wakely
41ee74878a * doc/html/*: Regenerate.
From-SVN: r193116
2012-11-03 00:22:18 +00:00
Gerald Pfeifer
1a34066e2e configure.xml: Adjust GNU libc link.
* doc/xml/manual/configure.xml: Adjust GNU libc link.

	* doc/xml/manual/debug.xml: Adjust GDB documentation link.
	Use GCC instead of gcc.

	* doc/xml/manual/prerequisites.xml: Remove detailed reference
	to binutils downloads.

From-SVN: r193109
2012-11-02 21:59:43 +00:00
Paolo Carlini
5bcb3b4d80 re PR libstdc++/55169 (std::discrete_distribution::operator(generator&) makes unnecessary copy of parameter vector)
2012-11-02  Paolo Carlini  <paolo.carlini@oracle.com>

	PR libstdc++/55169
	* include/bits/random.h: Remove all uses of param().
	(chi_squared_distribution<>::__generate_impl(_ForwardIterator,
	_ForwardIterator, _UniformRandomNumberGenerator&): Declare
	* include/bits/random.tcc: ... define.
	* include/ext/random: Remove all uses of param().

From-SVN: r193092
2012-11-02 10:45:25 +00:00
Gerald Pfeifer
e570b479ae allocator.xml: Update reference to Hoard.
* doc/xml/manual/allocator.xml: Update reference to Hoard.
	Update reference to Berger's OOPSLA 2002 paper.

From-SVN: r193091
2012-11-02 08:57:18 +00:00
Jonathan Wakely
073deae695 printers.py (Tr1HashtableIterator): Update.
* python/libstdcxx/v6/printers.py (Tr1HashtableIterator): Update.
	(StdForwardListPrinter): Likewise.

From-SVN: r193087
2012-11-02 01:47:17 +00:00
Jonathan Wakely
50799846a5 forward_list.h (forward_list(size_type)): Add missing allocator parameter.
* include/bits/forward_list.h (forward_list(size_type)): Add missing
	allocator parameter.
	(_Fwd_list_node_base): Use NSDMI and define constructor as defaulted.
	(_Fwd_list_node::_M_value): Replace with uninitialized storage.
	(_Fwd_list_node::_M_valptr()): Define functions to access storage.
	(_Fwd_list_iterator, _Fwd_list_const_iterator): Use _M_valptr.
	(_Fwd_list_base::_M_create_node): Only use allocator to construct the
	element not the node.
	* include/bits/forward_list.tcc (_Fwd_list_base::_M_erase_after): Only
	use allocator to destroy the element not the node.
	* testsuite/23_containers/forward_list/cons/11.cc: Remove unused
	headers.
	* testsuite/23_containers/forward_list/cons/12.cc: Likewise.
	* testsuite/23_containers/forward_list/cons/13.cc: New.
	* testsuite/23_containers/forward_list/cons/14.cc: New.

From-SVN: r193086
2012-11-02 01:29:00 +00:00
Gerald Pfeifer
7ce3b11540 codecvt.xml: Fix reference to Austin Common Standards Revision Group.
* doc/xml/manual/codecvt.xml: Fix reference to Austin Common
	Standards Revision Group.
	* doc/xml/manual/messages.xml: Ditto.
	* doc/xml/manual/using_exceptions.xml: Ditto.

	* doc/xml/manual/messages.xml: Fix reference to GNU gettext.

	* doc/xml/manual/policy_data_structures.xml: Fix reference to
	STL at SGI.
	Update reference to COM at Microsoft.
	Update reference to Worst-case efficient priority queues at ACM.

From-SVN: r193084
2012-11-02 00:25:46 +00:00
Jonathan Wakely
2328b1de5e range_access.cc: Fix copying permission statement.
* testsuite/18_support/initializer_list/range_access.cc: Fix copying
	permission statement.
	* testsuite/20_util/specialized_algorithms/uninitialized_copy/
	808590.cc: Likewise.
	* testsuite/20_util/specialized_algorithms/uninitialized_copy/
	move_iterators/1.cc: Likewise.
	* testsuite/20_util/specialized_algorithms/uninitialized_copy_n/
	move_iterators/1.cc: Likewise.
	* testsuite/21_strings/basic_string/capacity/char/shrink_to_fit.cc:
	Likewise.
	* testsuite/21_strings/basic_string/capacity/wchar_t/shrink_to_fit.cc:
	Likewise.
	* testsuite/21_strings/basic_string/range_access/char/1.cc: Likewise.
	* testsuite/21_strings/basic_string/range_access/wchar_t/1.cc:
	Likewise.
	* testsuite/23_containers/array/element_access/at_neg.cc: Likewise.
	* testsuite/23_containers/array/range_access.cc: Likewise.
	* testsuite/23_containers/deque/capacity/29134-2.cc: Likewise.
	* testsuite/23_containers/deque/capacity/29134.cc: Likewise.
	* testsuite/23_containers/deque/capacity/shrink_to_fit.cc: Likewise.
	* testsuite/23_containers/deque/range_access.cc: Likewise.
	* testsuite/23_containers/deque/requirements/do_the_right_thing.cc:
	Likewise.
	* testsuite/23_containers/forward_list/capacity/1.cc: Likewise.
	* testsuite/23_containers/forward_list/cons/1.cc: Likewise.
	* testsuite/23_containers/forward_list/cons/10.cc: Likewise.
	* testsuite/23_containers/forward_list/cons/11.cc: Likewise.
	* testsuite/23_containers/forward_list/cons/12.cc: Likewise.
	* testsuite/23_containers/forward_list/cons/2.cc: Likewise.
	* testsuite/23_containers/forward_list/cons/3.cc: Likewise.
	* testsuite/23_containers/forward_list/cons/4.cc: Likewise.
	* testsuite/23_containers/forward_list/cons/5.cc: Likewise.
	* testsuite/23_containers/forward_list/cons/6.cc: Likewise.
	* testsuite/23_containers/forward_list/cons/7.cc: Likewise.
	* testsuite/23_containers/forward_list/cons/8.cc: Likewise.
	* testsuite/23_containers/forward_list/cons/9.cc: Likewise.
	* testsuite/23_containers/forward_list/debug/clear.cc: Likewise.
	* testsuite/23_containers/forward_list/debug/erase_after1_neg.cc:
	Likewise.
	* testsuite/23_containers/forward_list/debug/erase_after2_neg.cc:
	Likewise.
	* testsuite/23_containers/forward_list/debug/erase_after3_neg.cc:
	Likewise.
	* testsuite/23_containers/forward_list/debug/erase_after4_neg.cc:
	Likewise.
	* testsuite/23_containers/forward_list/debug/erase_after5_neg.cc:
	Likewise.
	* testsuite/23_containers/forward_list/debug/erase_after6_neg.cc:
	Likewise.
	* testsuite/23_containers/forward_list/debug/erase_after7_neg.cc:
	Likewise.
	* testsuite/23_containers/forward_list/debug/erase_after8_neg.cc:
	Likewise.
	* testsuite/23_containers/forward_list/debug/erase_after9_neg.cc:
	Likewise.
	* testsuite/23_containers/forward_list/debug/insert_after1_neg.cc:
	Likewise.
	* testsuite/23_containers/forward_list/debug/insert_after2_neg.cc:
	Likewise.
	* testsuite/23_containers/forward_list/debug/insert_after3_neg.cc:
	Likewise.
	* testsuite/23_containers/forward_list/debug/move_constructor.cc:
	Likewise.
	* testsuite/23_containers/forward_list/debug/splice_after.cc: Likewise.
	* testsuite/23_containers/forward_list/debug/splice_after1_neg.cc:
	Likewise.
	* testsuite/23_containers/forward_list/debug/splice_after2_neg.cc:
	Likewise.
	* testsuite/23_containers/forward_list/debug/splice_after3_neg.cc:
	Likewise.
	* testsuite/23_containers/forward_list/debug/splice_after4_neg.cc:
	Likewise.
	* testsuite/23_containers/forward_list/debug/splice_after5_neg.cc:
	Likewise.
	* testsuite/23_containers/forward_list/debug/splice_after6_neg.cc:
	Likewise.
	* testsuite/23_containers/forward_list/debug/splice_after7_neg.cc:
	Likewise.
	* testsuite/23_containers/forward_list/debug/swap.cc: Likewise.
	* testsuite/23_containers/forward_list/modifiers/1.cc: Likewise.
	* testsuite/23_containers/forward_list/modifiers/2.cc: Likewise.
	* testsuite/23_containers/forward_list/modifiers/3.cc: Likewise.
	* testsuite/23_containers/forward_list/modifiers/4.cc: Likewise.
	* testsuite/23_containers/forward_list/modifiers/5.cc: Likewise.
	* testsuite/23_containers/forward_list/modifiers/6.cc: Likewise.
	* testsuite/23_containers/forward_list/operations/1.cc: Likewise.
	* testsuite/23_containers/forward_list/operations/2.cc: Likewise.
	* testsuite/23_containers/forward_list/operations/3.cc: Likewise.
	* testsuite/23_containers/forward_list/operations/4.cc: Likewise.
	* testsuite/23_containers/forward_list/operations/5.cc: Likewise.
	* testsuite/23_containers/forward_list/operations/6.cc: Likewise.
	* testsuite/23_containers/forward_list/operations/7.cc: Likewise.
	* testsuite/23_containers/forward_list/range_access.cc: Likewise.
	* testsuite/23_containers/forward_list/requirements/
	do_the_right_thing.cc: Likewise.
	* testsuite/23_containers/list/capacity/1.cc: Likewise.
	* testsuite/23_containers/list/capacity/1.h: Likewise.
	* testsuite/23_containers/list/capacity/29134.cc: Likewise.
	* testsuite/23_containers/list/modifiers/1.cc: Likewise.
	* testsuite/23_containers/list/modifiers/1.h: Likewise.
	* testsuite/23_containers/list/modifiers/1_c++0x.cc: Likewise.
	* testsuite/23_containers/list/modifiers/2.cc: Likewise.
	* testsuite/23_containers/list/modifiers/2.h: Likewise.
	* testsuite/23_containers/list/modifiers/3.cc: Likewise.
	* testsuite/23_containers/list/modifiers/3.h: Likewise.
	* testsuite/23_containers/list/modifiers/insert/25288.cc: Likewise.
	* testsuite/23_containers/list/modifiers/insert/25288.h: Likewise.
	* testsuite/23_containers/list/operations/1.cc: Likewise.
	* testsuite/23_containers/list/operations/1.h: Likewise.
	* testsuite/23_containers/list/operations/2.cc: Likewise.
	* testsuite/23_containers/list/operations/2.h: Likewise.
	* testsuite/23_containers/list/operations/2_c++0x.cc: Likewise.
	* testsuite/23_containers/list/operations/3.cc: Likewise.
	* testsuite/23_containers/list/operations/3.h: Likewise.
	* testsuite/23_containers/list/operations/3_c++0x.cc: Likewise.
	* testsuite/23_containers/list/operations/4.cc: Likewise.
	* testsuite/23_containers/list/operations/4.h: Likewise.
	* testsuite/23_containers/list/operations/42352.cc: Likewise.
	* testsuite/23_containers/list/operations/5.cc: Likewise.
	* testsuite/23_containers/list/operations/5.h: Likewise.
	* testsuite/23_containers/list/range_access.cc: Likewise.
	* testsuite/23_containers/list/requirements/do_the_right_thing.cc:
	Likewise.
	* testsuite/23_containers/map/capacity/29134.cc: Likewise.
	* testsuite/23_containers/map/range_access.cc: Likewise.
	* testsuite/23_containers/multimap/capacity/29134.cc: Likewise.
	* testsuite/23_containers/multimap/range_access.cc: Likewise.
	* testsuite/23_containers/multiset/capacity/29134.cc: Likewise.
	* testsuite/23_containers/multiset/range_access.cc: Likewise.
	* testsuite/23_containers/set/capacity/29134.cc: Likewise.
	* testsuite/23_containers/set/range_access.cc: Likewise.
	* testsuite/23_containers/unordered_map/final_hash.cc: Likewise.
	* testsuite/23_containers/unordered_map/observers.cc: Likewise.
	* testsuite/23_containers/unordered_map/range_access.cc: Likewise.
	* testsuite/23_containers/unordered_map/requirements/52942.cc:
	Likewise.
	* testsuite/23_containers/unordered_map/requirements/53067.cc:
	Likewise.
	* testsuite/23_containers/unordered_map/requirements/53339.cc:
	Likewise.
	* testsuite/23_containers/unordered_multimap/final_hash.cc: Likewise.
	* testsuite/23_containers/unordered_multimap/observers.cc: Likewise.
	* testsuite/23_containers/unordered_multimap/range_access.cc: Likewise.
	* testsuite/23_containers/unordered_multimap/requirements/53339.cc:
	Likewise.
	* testsuite/23_containers/unordered_multiset/final_hash.cc: Likewise.
	* testsuite/23_containers/unordered_multiset/observers.cc: Likewise.
	* testsuite/23_containers/unordered_multiset/range_access.cc: Likewise.
	* testsuite/23_containers/unordered_set/final_hash.cc: Likewise.
	* testsuite/23_containers/unordered_set/instantiation_neg.cc: Likewise.
	* testsuite/23_containers/unordered_set/observers.cc: Likewise.
	* testsuite/23_containers/unordered_set/range_access.cc: Likewise.
	* testsuite/23_containers/unordered_set/requirements/52942.cc:
	Likewise.
	* testsuite/23_containers/unordered_set/requirements/53067.cc:
	Likewise.
	* testsuite/23_containers/vector/bool/capacity/29134.cc: Likewise.
	* testsuite/23_containers/vector/bool/modifiers/insert/31370.cc:
	Likewise.
	* testsuite/23_containers/vector/capacity/29134-2.cc: Likewise.
	* testsuite/23_containers/vector/capacity/29134.cc: Likewise.
	* testsuite/23_containers/vector/capacity/shrink_to_fit.cc: Likewise.
	* testsuite/23_containers/vector/capacity/shrink_to_fit2.cc: Likewise.
	* testsuite/23_containers/vector/range_access.cc: Likewise.
	* testsuite/23_containers/vector/requirements/do_the_right_thing.cc:
	Likewise.
	* testsuite/24_iterators/range_access.cc: Likewise.
	* testsuite/25_algorithms/copy/1.cc: Likewise.
	* testsuite/25_algorithms/copy/2.cc: Likewise.
	* testsuite/25_algorithms/copy/3.cc: Likewise.
	* testsuite/25_algorithms/copy/34595.cc: Likewise.
	* testsuite/25_algorithms/copy/4.cc: Likewise.
	* testsuite/25_algorithms/copy/deque_iterators/1.cc: Likewise.
	* testsuite/25_algorithms/copy/move_iterators/1.cc: Likewise.
	* testsuite/25_algorithms/copy/streambuf_iterators/char/1.cc: Likewise.
	* testsuite/25_algorithms/copy/streambuf_iterators/char/2.cc: Likewise.
	* testsuite/25_algorithms/copy/streambuf_iterators/char/3.cc: Likewise.
	* testsuite/25_algorithms/copy/streambuf_iterators/char/4.cc: Likewise.
	* testsuite/25_algorithms/copy/streambuf_iterators/wchar_t/1.cc:
	Likewise.
	* testsuite/25_algorithms/copy/streambuf_iterators/wchar_t/2.cc:
	Likewise.
	* testsuite/25_algorithms/copy/streambuf_iterators/wchar_t/3.cc:
	Likewise.
	* testsuite/25_algorithms/copy/streambuf_iterators/wchar_t/4.cc:
	Likewise.
	* testsuite/25_algorithms/copy_backward/deque_iterators/1.cc: Likewise.
	* testsuite/25_algorithms/copy_backward/move_iterators/1.cc: Likewise.
	* testsuite/25_algorithms/copy_n/1.cc: Likewise.
	* testsuite/25_algorithms/copy_n/2.cc: Likewise.
	* testsuite/25_algorithms/copy_n/3.cc: Likewise.
	* testsuite/25_algorithms/copy_n/4.cc: Likewise.
	* testsuite/25_algorithms/copy_n/50119.cc: Likewise.
	* testsuite/25_algorithms/copy_n/move_iterators/1.cc: Likewise.
	* testsuite/25_algorithms/fill/4.cc: Likewise.
	* testsuite/25_algorithms/fill_n/1.cc: Likewise.
	* testsuite/25_algorithms/find/istreambuf_iterators/char/1.cc:
	Likewise.
	* testsuite/25_algorithms/find/istreambuf_iterators/char/2.cc:
	Likewise.
	* testsuite/25_algorithms/find/istreambuf_iterators/wchar_t/1.cc:
	Likewise.
	* testsuite/25_algorithms/find/istreambuf_iterators/wchar_t/2.cc:
	Likewise.
	* testsuite/25_algorithms/heap/1.cc: Likewise.
	* testsuite/25_algorithms/heap/moveable.cc: Likewise.
	* testsuite/25_algorithms/heap/moveable2.cc: Likewise.
	* testsuite/25_algorithms/is_heap/1.cc: Likewise.
	* testsuite/25_algorithms/is_heap_until/1.cc: Likewise.
	* testsuite/25_algorithms/is_sorted/1.cc: Likewise.
	* testsuite/25_algorithms/is_sorted_until/1.cc: Likewise.
	* testsuite/25_algorithms/move/1.cc: Likewise.
	* testsuite/25_algorithms/move/deque_iterators/1.cc: Likewise.
	* testsuite/25_algorithms/move_backward/1.cc: Likewise.
	* testsuite/25_algorithms/move_backward/deque_iterators/1.cc: Likewise.
	* testsuite/25_algorithms/partition/1.cc: Likewise.
	* testsuite/25_algorithms/partition/moveable.cc: Likewise.
	* testsuite/25_algorithms/pop_heap/empty2_neg.cc: Likewise.
	* testsuite/25_algorithms/pop_heap/empty_neg.cc: Likewise.
	* testsuite/25_algorithms/stable_partition/1.cc: Likewise.
	* testsuite/25_algorithms/stable_partition/moveable.cc: Likewise.
	* testsuite/25_algorithms/stable_partition/pr52822.cc: Likewise.
	* testsuite/26_numerics/valarray/range_access.cc: Likewise.
	* testsuite/28_regex/range_access.cc: Likewise.
	* testsuite/ext/vstring/capacity/29134.cc: Likewise.
	* testsuite/ext/vstring/capacity/shrink_to_fit.cc: Likewise.
	* testsuite/ext/vstring/hash/char/1.cc: Likewise.
	* testsuite/ext/vstring/hash/wchar_t/1.cc: Likewise.
	* testsuite/ext/vstring/range_access.cc: Likewise.
	* testsuite/ext/vstring/requirements/do_the_right_thing.cc: Likewise.
	* testsuite/performance/25_algorithms/copy_backward_deque_iterators.cc:
	Likewise.
	* testsuite/performance/25_algorithms/copy_deque_iterators.cc:
	Likewise.
	* testsuite/tr1/6_containers/unordered_map/capacity/29134-map.cc:
	Likewise.
	* testsuite/tr1/6_containers/unordered_multimap/capacity/
	29134-multimap.cc: Likewise.
	* testsuite/tr1/6_containers/unordered_multiset/capacity/
	29134-multiset.cc: Likewise.
	* testsuite/tr1/6_containers/unordered_set/capacity/29134-set.cc:
	Likewise.

From-SVN: r193076
2012-11-01 23:20:37 +00:00
François Dumont
0dd4969120 hashtable_policy.h (__details::_Before_begin<>): New, combine a base node instance and an allocator.
2012-11-01  François Dumont  <fdumont@gcc.gnu.org>

	* include/bits/hashtable_policy.h (__details::_Before_begin<>):
	New, combine a base node instance and an allocator.
	* include/bits/hashtable.h (_Hashtable<>::_M_node_allocator): Remove.
	(_Hashtable<>::_M_before_begin): Rename into _M_bbegin and type
	modified to __detail::_Before_begin<>.
	(_Hashtable<>::_M_node_allocator()): New, get the node allocator
	part of _M_bbegin.
	(_Hashtable<>::_M_before_begin()): New, get the before begin node
	part of _M_bbegin.
	(_Hashtable<>): Adapt to use latter.

From-SVN: r193068
2012-11-01 20:55:51 +00:00
Jonathan Wakely
362261e71f forward_list.h (forward_list::assign): Dispatch to new functions based on assignability of elements.
* include/bits/forward_list.h (forward_list::assign): Dispatch to new
	functions based on assignability of elements.
	(forward_list::_M_assign): Add overloaded functions for assigning
	via assignment or via clearing and insertion.
	(forward_list::_M_assign_val): Likewise.
	(forward_list::_M_move_assign(forward_list&&, false_type)): Do not
	erase elements that are not moved.
	* include/bits/forward_list.tcc (forward_list::operator=): Call
	assign() to copy elements.
	* testsuite/23_containers/forward_list/cons/10.cc: New.
	* testsuite/23_containers/forward_list/cons/11.cc: New.
	* testsuite/23_containers/forward_list/cons/12.cc: New.

From-SVN: r193057
2012-11-01 01:30:34 +00:00
Jonathan Yong
261f93e075 os_defines.h: Do not define anymore _GLIBCXX_HAVE_BROKEN_VSWPRINTF.
2012-10-31  Jonathan Yong  <jon_y@users.sourceforge.net>

	* config/os/mingw32-w64/os_defines.h: Do not define anymore
	_GLIBCXX_HAVE_BROKEN_VSWPRINTF.

From-SVN: r193033
2012-10-31 11:36:45 +00:00
Jonathan Yong
e3b744420b os_defines.h: Do not define anymore _GLIBCXX_HAVE_BROKEN_VSWPRINTF.
2012-10-31  Jonathan Yong  <jon_y@users.sourceforge.net>

	* config/os/mingw32-w64/os_defines.h: Do not define anymore
	_GLIBCXX_HAVE_BROKEN_VSWPRINTF.

From-SVN: r193032
2012-10-31 11:34:27 +00:00
Jonathan Wakely
b0b4a25308 forward_list.h (forward_list): Adjust comments.
* include/bits/forward_list.h (forward_list): Adjust comments.
	(forward_list(const forward_list&, const _Alloc&)): Use
	_M_range_initialize to copy elements.
	(forward_list(forward_list&&, const _Alloc&)): Add exception
	specification.
	(_Fwd_list_base(const _Fwd_list_base&, const _Node_alloc_type&)):
	Remove.
	* include/bits/forward_list.tcc (_Fwd_list_base(const _Fwd_list_base&,
	const _Node_alloc_type&)): Remove.
	(_Fwd_list_base(_Fwd_list_base&&, const _Node_alloc_type&)): Fix
	memory leak when allocators are not equal.

From-SVN: r193009
2012-10-31 01:09:59 +00:00
Jonathan Wakely
1ea58d3499 re PR libstdc++/55123 ([C++11] Construction of shared_ptr<const T> from unique_ptr<const T> fails)
PR libstdc++/55123
	* include/bits/shared_ptr_base.h (__shared_count::_S_create_from_up):
	Do not instantiate allocator with element_type.
	* testsuite/20_util/shared_ptr/cons/55123.cc: New.

From-SVN: r192964
2012-10-29 21:49:19 +00:00
Jonathan Wakely
937b190d75 re PR libstdc++/55041 (prettyprinting/shared_ptr & cxx11 fails on some platforms)
PR libstdc++/55041
	* python/libstdcxx/v6/printers.py (Tr1UnorderedMapPrinter): Update
	to handle hashtable as member of unordered_map not base class.
	(Tr1UnorderedSetPrinter): Likewise.

From-SVN: r192894
2012-10-28 13:20:31 +00:00
François Dumont
099e644e2d unordered_map.h (unordered_map<>): Prefer aggregation to inheritance with _Hashtable.
2012-10-27  François Dumont  <fdumont@gcc.gnu.org>

	* include/bits/unordered_map.h (unordered_map<>): Prefer
	aggregation to inheritance with _Hashtable.
	(unordered_multimap<>): Likewise.
	* include/bits/unordered_set.h
	(unordered_set<>(const unordered_set&)):  Use default
	implementation.
	(unordered_set<>(unordered_set&&)): Likewise.
	(unordered_set<>::operator=(const unordered_set&)): Likewise.
	(unordered_set<>::operator=(unordered_set&&)): Likewise.
	(unordered_multiset<>(const unordered_multiset&)): Likewise.
	(unordered_multiset<>(unordered_multiset&&)): Likewise.
	(unordered_multiset<>::operator=(const unordered_multiset&)):
	Likewise.
	(unordered_multiset<>::operator=(unordered_multiset&&)): Likewise.
	* include/debug/unordered_map (operator==): Adapt.
	* include/profile/unordered_map (operator==): Adapt.

From-SVN: r192876
2012-10-27 12:20:18 +00:00
Daniel Kruegler
6c5173c05f type_traits (common_type): Implement LWG 2141.
2012-10-24  Daniel Krugler  <daniel.kruegler@gmail.com>

	* include/std/type_traits (common_type): Implement LWG 2141.
	* testsuite/20_util/duration/requirements/sfinae_friendly_1.cc:
	Update.
	* testsuite/20_util/common_type/requirements/typedefs-1.cc: Likewise.
	* testsuite/20_util/common_type/requirements/sfinae_friendly_1.cc:
	Likewise.
	* testsuite/20_util/common_type/requirements/sfinae_friendly_2.cc:
	Likewise.
	* testsuite/20_util/common_type/requirements/typedefs-2.cc: Likewise.

From-SVN: r192780
2012-10-24 20:37:05 +00:00
Haakan Younes
c2d9083df2 re PR libstdc++/55047 (operator() in std::exponential_distribution may call log(0))
2012-10-24   Haakan Younes  <hyounes@google.com>
	     Paolo Carlini  <paolo.carlini@oracle.com>

	PR libstdc++/55047
	* include/bits/random.h (exponential_distribution<>::operator):
	Fix formula to std::log(result_type(1) - __aurng()).
	* include/bits/random.tcc: Likewise, everywhere.

Co-Authored-By: Paolo Carlini <paolo.carlini@oracle.com>

From-SVN: r192762
2012-10-24 12:20:19 +00:00
Yufeng Zhang
597ee90168 AArch64 [10/10]
2012-10-23  Yufeng Zhang  <yufeng.zhang@arm.com>

	* config/cpu/aarch64/cxxabi_tweaks.h: New file.
	* configure.host: Enable aarch64.

From-SVN: r192731
2012-10-23 17:30:49 +00:00
François Dumont
637fd8b3be unordered_set.h (unordered_set<>): Prefer aggregation to inheritance with _Hashtable.
2012-10-22  François Dumont  <fdumont@gcc.gnu.org>

	* include/bits/unordered_set.h (unordered_set<>): Prefer
	aggregation to inheritance with _Hashtable.
	(unordered_multiset<>): Likewise.
	* include/debug/unordered_set (operator==): Adapt.
	* include/profile/unordered_set (operator==): Adapt.

From-SVN: r192695
2012-10-22 19:53:38 +00:00
Yufeng Zhang
e3b0260052 configure.xml (--enable-clocale): Document the 'newlib' and 'darwin' options.
2012-10-22  Yufeng Zhang  <yufeng.zhang@arm.com>
	    Jonathan Wakely  <jwakely.gcc@gmail.com>

	* doc/xml/manual/configure.xml (--enable-clocale): Document the
	'newlib' and 'darwin' options. Minor stylistic improvements.

Co-Authored-By: Jonathan Wakely <jwakely.gcc@gmail.com>

From-SVN: r192661
2012-10-22 00:42:17 +01:00
François Dumont
0a011b17ee map.h (map::emplace_hint): Remove invalid parenthesis.
2012-10-21  François Dumont  <fdumont@gcc.gnu.org>

	* include/profile/map.h (map::emplace_hint): Remove invalid
	parenthesis.

From-SVN: r192656
2012-10-21 19:06:47 +00:00
Hans-Peter Nilsson
836e938574 45713.cc: Skip for mmix-*-*.
* testsuite/23_containers/bitset/45713.cc: Skip for mmix-*-*.
	Tweak sizetype-related comment.

From-SVN: r192647
2012-10-21 04:52:54 +00:00
Jonathan Wakely
ae40b500d2 * include/std/scoped_allocator: Avoid badname.
From-SVN: r192629
2012-10-20 03:08:37 +01:00
Jonathan Wakely
db2415a9a1 * doc/xml/manual/status_cxx2011.xml: Update.
From-SVN: r192616
2012-10-19 17:53:32 +01:00
Jonathan Wakely
644b2e4c0d scoped_allocator (__outermost_alloc_traits): Define.
* include/std/scoped_allocator (__outermost_alloc_traits): Define.
	(scoped_allocator_adaptor::destroy): Use it.
	(scoped_allocator_adaptor::construct): Likewise. Overload for
	piecewise construction of std::pair objects.
	* testsuite/20_util/scoped_allocator/2.cc: New.
	* doc/xml/manual/status_cxx2011.xml: Update.

From-SVN: r192613
2012-10-19 17:16:11 +01:00
Jonathan Wakely
7aad1ae2b2 forward_list.h: Add C++11 allocator support.
* include/bits/forward_list.h: Add C++11 allocator support.
	* include/bits/forward_list.tcc: Likewise.
	* doc/xml/manual/status_cxx2011.xml: Update.
	* testsuite/23_containers/forward_list/allocator/copy.cc: New.
	* testsuite/23_containers/forward_list/allocator/copy_assign.cc: New.
	* testsuite/23_containers/forward_list/allocator/minimal.cc: New.
	* testsuite/23_containers/forward_list/allocator/move_assign.cc: New.
	* testsuite/23_containers/forward_list/allocator/noexcept.cc: New.
	* testsuite/23_containers/forward_list/allocator/swap.cc: New.

From-SVN: r192588
2012-10-18 22:06:21 +01:00
François Dumont
14cbb5d84c formatter.h (_Debug_msg_id): Add __msg_valid_load_factor.
2012-10-18  François Dumont  <fdumont@gcc.gnu.org>

	* include/debug/formatter.h (_Debug_msg_id): Add
	__msg_valid_load_factor.
	* include/debug/macros.h (__glibcxx_check_max_load_factor): New.
	* include/debug/unordered_set
	(unordered_set<>::max_load_factor(float)): Check max load factor
	is positive.
	(unordered_multiset<>::max_load_factor(float)): Likewise.
	* include/debug/unordered_map
	(unordered_map<>::max_load_factor(float)): Likewise.
	(unordered_multimap<>::max_load_factor(float)): Likewise.
	* testsuite/23_containers/unordered_map/debug/max_load_factor_neg.cc:
	New.
	* testsuite/23_containers/unordered_multimap/debug/
	max_load_factor_neg.cc: New.
	* testsuite/23_containers/unordered_set/debug/max_load_factor_neg.cc:
	New.
	* testsuite/23_containers/unordered_multiset/debug/
	max_load_factor_neg.cc: New.

From-SVN: r192575
2012-10-18 19:50:37 +00:00
Benjamin Kosnik
a9ba8ba56c move.h (move_if_noexcept): Mark constexpr.
2012-10-17  Benjamin Kosnik  <bkoz@redhat.com>

	* include/bits/move.h (move_if_noexcept): Mark constexpr.
	* include/std/array (front, back): Same.
	* include/std/chrono: Add comment.
	* include/std/tuple (__tuple_compare): Mark __eq, __less constexpr.
	(operator ==, <, >, !=, <=, >=): Same.
	* testsuite/20_util/forward/c_neg.cc: Adjust line numbers.
	* testsuite/20_util/forward/f_neg.cc: Same.
	* testsuite/20_util/move_if_noexcept/constexpr.cc: New.
	* testsuite/20_util/tuple/comparison_operators/constexpr.cc: New.
	* testsuite/20_util/tuple/creation_functions/constexpr.cc: Add.
	* testsuite/23_containers/array/element_access/
	constexpr_element_access.cc: Same.
	* testsuite/23_containers/array/tuple_interface/get_neg.cc: Adjust
	line numbers.
	* testsuite/23_containers/array/tuple_interface/tuple_element_neg.cc:
	Same.

	* testsuite/20_util/tuple/comparison_operators/35480_neg.cc:
          Temporarily add dg-excess-errors.

From-SVN: r192556
2012-10-18 08:36:06 +00:00
François Dumont
7181e991b5 formatter.h (_Debug_msg_id): Add __msg_bucket_index_oob.
2012-10-16  François Dumont  <fdumont@gcc.gnu.org>

	* include/debug/formatter.h (_Debug_msg_id): Add
	__msg_bucket_index_oob.
	* include/debug/macros.h (__glibcxx_check_bucket_index): New.
	* include/debug/unordered_set (unordered_set<>::begin(size_type)):
	Add check on bucket index.
	(unordered_set<>::begin(size_type) const): Likewise.
	(unordered_set<>::cbegin(size_type) const): Likewise.
	(unordered_set<>::end(size_type)): Likewise.
	(unordered_set<>::end(size_type) const): Likewise.
	(unordered_set<>::cend(size_type) const): Likewise.
	(unordered_set<>::bucket_size(size_type)): Likewise.
	(unordered_multiset<>::begin(size_type)): Likewise.
	(unordered_multiset<>::begin(size_type) const): Likewise.
	(unordered_multiset<>::cbegin(size_type) const): Likewise.
	(unordered_multiset<>::end(size_type)): Likewise.
	(unordered_multiset<>::end(size_type) const): Likewise.
	(unordered_multiset<>::cend(size_type) const): Likewise.
	(unordered_multiset<>::bucket_size(size_type)): Likewise.
	* include/debug/unordered_map (unordered_map<>::begin(size_type)):
	Likewise.
	(unordered_map<>::begin(size_type) const): Likewise.
	(unordered_map<>::cbegin(size_type) const): Likewise.
	(unordered_map<>::end(size_type)): Likewise.
	(unordered_map<>::end(size_type) const): Likewise.
	(unordered_map<>::cend(size_type) const): Likewise.
	(unordered_map<>::bucket_size(size_type)): Likewise.
	(unordered_multimap<>::begin(size_type)): Likewise.
	(unordered_multimap<>::begin(size_type) const): Likewise.
	(unordered_multimap<>::cbegin(size_type) const): Likewise.
	(unordered_multimap<>::end(size_type)): Likewise.
	(unordered_multimap<>::end(size_type) const): Likewise.
	(unordered_multimap<>::cend(size_type) const): Likewise.
	(unordered_multimap<>::bucket_size(size_type)): Likewise.
	* testsuite/23_containers/unordered_map/debug/bucket_size_neg.cc:
	New.
	* testsuite/23_containers/unordered_map/debug/begin1_neg.cc: New.
	* testsuite/23_containers/unordered_map/debug/begin2_neg.cc: New.
	* testsuite/23_containers/unordered_map/debug/cbegin_neg.cc: New.
	* testsuite/23_containers/unordered_map/debug/end1_neg.cc: New.
	* testsuite/23_containers/unordered_map/debug/end2_neg.cc: New.
	* testsuite/23_containers/unordered_map/debug/cend_neg.cc: New.
	* testsuite/23_containers/unordered_multimap/debug/bucket_size_neg.cc:
	New.
	* testsuite/23_containers/unordered_multimap/debug/begin1_neg.cc: New.
	* testsuite/23_containers/unordered_multimap/debug/begin2_neg.cc: New.
	* testsuite/23_containers/unordered_multimap/debug/cbegin_neg.cc: New.
	* testsuite/23_containers/unordered_multimap/debug/end1_neg.cc: New.
	* testsuite/23_containers/unordered_multimap/debug/end2_neg.cc: New.
	* testsuite/23_containers/unordered_multimap/debug/cend_neg.cc: New.
	* testsuite/23_containers/unordered_set/debug/bucket_size_neg.cc:
	New.
	* testsuite/23_containers/unordered_set/debug/begin1_neg.cc: New.
	* testsuite/23_containers/unordered_set/debug/begin2_neg.cc: New.
	* testsuite/23_containers/unordered_set/debug/cbegin_neg.cc: New.
	* testsuite/23_containers/unordered_set/debug/end1_neg.cc: New.
	* testsuite/23_containers/unordered_set/debug/end2_neg.cc: New.
	* testsuite/23_containers/unordered_set/debug/cend_neg.cc: New.
	* testsuite/23_containers/unordered_multiset/debug/bucket_size_neg.cc:
	New.
	* testsuite/23_containers/unordered_multiset/debug/begin1_neg.cc: New.
	* testsuite/23_containers/unordered_multiset/debug/begin2_neg.cc: New.
	* testsuite/23_containers/unordered_multiset/debug/cbegin_neg.cc: New.
	* testsuite/23_containers/unordered_multiset/debug/end1_neg.cc: New.
	* testsuite/23_containers/unordered_multiset/debug/end2_neg.cc: New.
	* testsuite/23_containers/unordered_multiset/debug/cend_neg.cc: New.

From-SVN: r192512
2012-10-16 19:57:03 +00:00
Matthias Klose
9945a87681 config.gcc: Match arm*-*-linux-* for ARM Linux/GNU.
gcc/
2012-10-15  Matthias Klose  <doko@ubuntu.com>

        * config.gcc: Match arm*-*-linux-* for ARM Linux/GNU.
        * doc/install.texi: Use arm-*-*linux-* instead of arm-*-*linux-gnueabi.

gcc/testsuite/
2012-10-15  Matthias Klose  <doko@ubuntu.com>

        * lib/target-supports.exp (check_profiling_available): Match
        arm*-*-linux-* for ARM Linux/GNU.
        * g++.dg/torture/predcom-1.C: Match arm*-*-linux-* for ARM Linux/GNU.
        * gfortran.dg/enum_10.f90: Likewise.
        * gfortran.dg/enum_9.f90: Likewise.
        * gcc.target/arm/synchronize.c: Likewise.
        * g++.old-deja/g++.jason/enum6.C: Likewise.
        * g++.old-deja/g++.other/enum4.C: Likewise.
        * g++.old-deja/g++.law/enum9.C: Likewise.

gcc/ada/
2012-10-15  Matthias Klose  <doko@ubuntu.com>

        * gcc-interface/Makefile.in: Match arm*-*-linux-*eabi* for
        ARM Linux/GNU.

libgcc/
2012-10-15  Matthias Klose  <doko@ubuntu.com>

        * config.host: Match arm*-*-linux-* for ARM Linux/GNU.

libstdc++-v3/
2012-10-15  Matthias Klose  <doko@ubuntu.com>

        * configure.host: Match arm*-*-linux-* for ARM Linux/GNU.
        * testsuite/20_util/make_signed/requirements/typedefs-2.cc: Likewise.
        * testsuite/20_util/make_unsigned/requirements/typedefs-2.cc: Likewise.

libjava/
2012-10-15  Matthias Klose  <doko@ubuntu.com>

        * configure.ac: Match arm*-*-linux-* for ARM Linux/GNU.
        * configure: Regenerate.

From-SVN: r192475
2012-10-15 21:12:23 +00:00
Pavel Chupin
1183dc2cd8 gthr.m4: New.
* config/gthr.m4: New. Define GCC_AC_THREAD_HEADER.
	    * libgcc/configure: Regenerate.
	    * libgcc/configure.ac: Replace code with GCC_AC_THREAD_HEADER use.
	    * libstdc++-v3/Makefile.in: Regenerate.
	    * libstdc++-v3/acinclude.m4: Replace code with GCC_AC_THREAD_HEADER use.
	    * libstdc++-v3/configure: Regenerate.
	    * libstdc++-v3/doc/Makefile.in: Regenerate.
	    * libstdc++-v3/include/Makefile.am: Regenerate.
	    * libstdc++-v3/include/Makefile.in: Rename variable.
	    * libstdc++-v3/libsupc++/Makefile.in: Regenerate.
	    * libstdc++-v3/po/Makefile.in: Regenerate.
	    * libstdc++-v3/python/Makefile.in: Regenerate.
	    * libstdc++-v3/src/Makefile.in: Regenerate.
	    * libstdc++-v3/src/c++11/Makefile.in: Regenerate.
	    * libstdc++-v3/src/c++98/Makefile.in: Regenerate.
	    * libstdc++-v3/testsuite/Makefile.in: Regenerate.

From-SVN: r192458
2012-10-15 13:10:30 +00:00
Jason Merrill
fe0f6df424 re PR target/54908 (misc regressions on emutls targets remain from dynamic initialization of non-function-local TLS variables)
PR target/54908
	* libsupc++/atexit_thread.cc: Rewrite to keep the cleanup list
	with get/setspecific.  Destroy the key on dlclose.

From-SVN: r192449
2012-10-15 03:32:13 -04:00
Edward Smith-Rowland
b09e6a7074 Forgot the CL entry for the Hoyt and arcsine distributions.
From-SVN: r192404
2012-10-12 15:16:29 +00:00
Edward Smith-Rowland
500602220a dd the Hoyt and the arcsine distributions as extensions.
From-SVN: r192403
2012-10-12 15:15:21 +00:00
Kirill Yukhin
3b06f98418 Revert r192297.
From-SVN: r192394
2012-10-12 10:57:06 +00:00
Paolo Carlini
a13ab2bcf7 hashtable_policy.h: Revert libstdc++/53067 quick hacks thanks to the resolution of c++/51213.
2012-10-12  Paolo Carlini  <paolo.carlini@oracle.com>

	* include/bits/hashtable_policy.h: Revert libstdc++/53067 quick
	hacks thanks to the resolution of c++/51213.

From-SVN: r192380
2012-10-11 22:18:27 +00:00
Paolo Carlini
69b5686085 45713.cc: Tweak.
2012-10-11  Paolo Carlini  <paolo.carlini@oracle.com>

	* testsuite/23_containers/bitset/45713.cc: Tweak.

From-SVN: r192358
2012-10-11 13:24:11 +00:00
Paolo Carlini
56355dc970 45713.cc: Tweak.
2012-10-11  Paolo Carlini  <paolo.carlini@oracle.com>

	* testsuite/23_containers/bitset/45713.cc: Tweak.

From-SVN: r192357
2012-10-11 13:23:33 +00:00
Daniel Krugler
970293de57 sfinae_friendly_1.cc: Update / extend.
2012-10-11  Daniel Krugler  <daniel.kruegler@googlemail.com>

	* testsuite/20_util/common_type/requirements/sfinae_friendly_1.cc:
	Update / extend.
	* testsuite/20_util/common_type/requirements/sfinae_friendly_2.cc:
	Likewise.
	* testsuite/20_util/duration/requirements/sfinae_friendly_1.cc:
	Likewise.

From-SVN: r192356
2012-10-11 11:45:35 +00:00
Hans-Peter Nilsson
1e2a71c8bf re PR testsuite/54897 (23_containers/bitset/45713.cc (test for excess errors))
PR testsuite/54897
	* testsuite/23_containers/bitset/45713.cc: Skip for avr*-*-*
	cris*-*-* h8300*-*-* mcore*-*-* moxie*-*-*.

From-SVN: r192354
2012-10-11 11:36:39 +00:00
Daniel Krugler
770e9be943 sfinae_friendly_1.cc: Update / extend.
2012-10-11  Daniel Krugler  <daniel.kruegler@googlemail.com>

	* testsuite/20_util/common_type/requirements/sfinae_friendly_1.cc:
	Update / extend.
	* testsuite/20_util/common_type/requirements/sfinae_friendly_2.cc:
	Likewise.
	* testsuite/20_util/duration/requirements/sfinae_friendly_1.cc:
	Likewise.

From-SVN: r192352
2012-10-11 10:27:45 +00:00
Rainer Orth
92257853d0 Fix Solaris symbol versioning (PR libstdc++/54872)
PR libstdc++/54872
	* config/abi/pre/gnu.ver (GLIBCXX_3.4.11) [!__sun__ && !__svr4__]:
	Don't export _ZNSt12system_errorC*.

From-SVN: r192349
2012-10-11 08:38:28 +00:00
Jonathan Wakely
ce23073501 Add PR to previous ChangeLog entry.
From-SVN: r192336
2012-10-11 00:12:23 +01:00
Jack Howarth
0d184995c4 os_defines.h: Define _GLIBCXX_USE_NANOSLEEP and _GLIBCXX_USE_SCHED_YIELD.
2012-10-10  Jack Howarth  <howarth@bromo.med.uc.edu>
	    Jonathan Wakely  <jwakely.gcc@gmail.com>

	* config/os/bsd/darwin/os_defines.h: Define _GLIBCXX_USE_NANOSLEEP
	and _GLIBCXX_USE_SCHED_YIELD.
	* acinclude.m4 (GLIBCXX_ENABLE_LIBSTDCXX_TIME): Add comment.

Co-Authored-By: Jonathan Wakely <jwakely.gcc@gmail.com>

From-SVN: r192335
2012-10-11 00:12:10 +01:00
Mark Kettenis
1f726ff876 2012-10-10 Mark Kettenis <kettenis@openbsd.org>
* configure.host (*-*-openbsd*) Set cpu_include_dir.
	* config/os/bsd/openbsd/ctype_base.h: New file.
	* config/os/bsd/openbsd/ctype_configure_char.cc: New file.
	* config/os/bsd/openbsd/ctype_inline.h: New file.
	* config/os/bsd/openbsd/os_defines.h: New file.
	* acinclude.m4 (GLIBCXX_ENABLE_CLOCALE): Use newlib locale model
	for OpenBSD.
	* configure: Regenerated.

From-SVN: r192334
2012-10-11 00:11:54 +01:00
Paolo Carlini
fe4e4e3bf4 type_traits (__do_common_type_impl): Revert for now LWG 2141-related change.
2012-10-10  Paolo Carlini  <paolo.carlini@oracle.com>

	* include/std/type_traits (__do_common_type_impl): Revert for now
	LWG 2141-related change.
	* testsuite/20_util/common_type/requirements/typedefs-1.cc: Likewise.
	* testsuite/20_util/common_type/requirements/sfinae_friendly_1.cc:
	Adjust.

From-SVN: r192308
2012-10-10 12:02:05 +00:00
Pavel Chupin
e80f7f1767 Fix missing gthr-default.h issue on separate libstdc++ configure
Fix missing gthr-default.h issue on separate libstdc++ configure
        * libstdc++-v3/acinclude.m4: Define glibcxx_thread_h.
        * libstdc++-v3/include/Makefile.am: Use glibcxx_thread_h.
        * libstdc++-v3/Makefile.in: Regenerate.
        * libstdc++-v3/configure: Regenerate.
        * libstdc++-v3/doc/Makefile.in: Regenerate.
        * libstdc++-v3/include/Makefile.in: Regenerate.
        * libstdc++-v3/libsupc++/Makefile.in: Regenerate.
        * libstdc++-v3/po/Makefile.in: Regenerate.
        * libstdc++-v3/python/Makefile.in: Regenerate.
        * libstdc++-v3/src/Makefile.in: Regenerate.
        * libstdc++-v3/src/c++11/Makefile.in: Regenerate.
        * libstdc++-v3/src/c++98/Makefile.in: Regenerate.
        * libstdc++-v3/testsuite/Makefile.in: Regenerate.

From-SVN: r192297
2012-10-10 10:02:44 +00:00
Daniel Krugler
b3618b7167 type_traits (common_time): Provide "SFINAE-friendly" implementation.
2012-10-09  Daniel Krugler  <daniel.kruegler@googlemail.com>

	* include/std/type_traits (common_time): Provide "SFINAE-friendly"
	implementation.
	(__success_type, __failure_type): Fix.
	* include/std/chrono (common_type): Likewise for the chrono::time_point
	specialization.
	* testsuite/20_util/common_type/requirements/sfinae_friendly_1.cc: New.
	* testsuite/20_util/common_type/requirements/sfinae_friendly_2.cc:
	Likewise.
	* testsuite/20_util/duration/requirements/sfinae_friendly_1.cc:
	Likewise.
	* testsuite/20_util/common_type/requirements/typedefs-1.cc: Adjust wrt
	LWG 2141.
	* testsuite/20_util/duration/requirements/typedefs_neg1.cc: Adjust
	dg-error line numbers.
	* testsuite/20_util/duration/requirements/typedefs_neg2.cc: Likewise.
	* testsuite/20_util/duration/requirements/typedefs_neg3.cc: Likewise.
	* testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Likewise.
	* testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc:
	Likewise.
	* testsuite/20_util/declval/requirements/1_neg.cc: Likewise.

	* testsuite/20_util/result_of/sfinae_friendly_1.cc: Trivial stylistic
	tweaks.
	* testsuite/20_util/result_of/sfinae_friendly_2.cc: Likewise.

From-SVN: r192276
2012-10-09 22:31:44 +00:00
Andrew MacLeod
3cedb9108b re PR libstdc++/54861 (std::atomic_signal_fence(std::memory_order_seq_cst) issues unnecessary mfence)
2012-10-09  Andrew MacLeod  <amacleod@redhat.com>

	PR libstdc++/54861
	* include/bits/atomic_base.h (atomic_signal_fence): Call
	__atomic_signal_fence instead of __atomic_thread_fence.

From-SVN: r192268
2012-10-09 18:40:02 +00:00
Benjamin Kosnik
1a61077e0e 808590.cc: Fix constant value.
2012-10-09  Benjamin Kosnik  <bkoz@redhat.com>

	* testsuite/20_util/specialized_algorithms/uninitialized_copy/808590.cc:
	Fix constant value.

From-SVN: r192265
2012-10-09 16:21:27 +00:00
Paolo Carlini
eeeef8f4f9 re PR libstdc++/54869 (ext/random/simd_fast_mersenne_twister_engine/cons/default.cc FAILs)
2012-10-09  Paolo Carlini  <paolo.carlini@oracle.com>

	PR libstdc++/54869
	* include/ext/random (simd_fast_mersenne_twister_engine): Provide
	only for little endian targets.
	* include/ext/random.tcc: Likewise.
	* config/cpu/i486/opt/ext/opt_random.h: Likewise.
	* testsuite/lib/libstdc++.exp (check_v3_target_little_endian): Add.
	* testsuite/lib/dg-options.exp (dg-require-little-endian): Add.
	* testsuite/ext/random/simd_fast_mersenne_twister_engine/
	operators/equal.cc: Use the latter.
	* testsuite/ext/random/simd_fast_mersenne_twister_engine/
	operators/serialize.cc: Likewise.
	* testsuite/ext/random/simd_fast_mersenne_twister_engine/
	operators/inequal.cc: Likewise.
	* testsuite/ext/random/simd_fast_mersenne_twister_engine/
	cons/copy.cc: Likewise.
	* testsuite/ext/random/simd_fast_mersenne_twister_engine/
	cons/seed1.cc: Likewise.
	* testsuite/ext/random/simd_fast_mersenne_twister_engine/
	cons/seed2.cc: Likewise.
	* testsuite/ext/random/simd_fast_mersenne_twister_engine/
	cons/default.cc: Likewise.
	* testsuite/ext/random/simd_fast_mersenne_twister_engine/
	cons/seed_seq.cc: Likewise.

From-SVN: r192256
2012-10-09 14:50:19 +00:00
Jonathan Wakely
8024199176 re PR libstdc++/54754 ([parallel mode] 'make check-parallel' only works on x86-64)
PR libstdc++/54754
	* include/parallel/compatibility.h: Use atomic built-ins when they are
	lock-free.

From-SVN: r192240
2012-10-09 09:16:13 +01:00
Uros Bizjak
f5220359f4 testsuite_abi.cc (check_version): Add CXXABI_1.3.7.
* testsuite/util/testsuite_abi.cc (check_version): Add CXXABI_1.3.7.

From-SVN: r192237
2012-10-09 08:15:15 +02:00
Jason Merrill
5b031b9b56 Support C++11 thread_local destructors.
gcc/cp/
	* decl.c (get_thread_atexit_node): New.
	(register_dtor_fn): Use it for TLS.
libstdc++-v3/
	* libsupc++/cxxabi.h: Declare __cxa_thread_atexit.
	* libsupc++/atexit_thread.cc: New.
	* libsupc++/Makefile.am (nested_exception.lo): Add it.
	* config/abi/pre/gnu.ver: Add __cxa_thread_atexit.

From-SVN: r192210
2012-10-08 10:45:24 -04:00
Matthias Klose
d39e4c0c0b basic: Remove empty directory.
2012-10-07  Matthias Klose  <doko@ubuntu.com>

        * testsuite/28_regex/algorithms/match/basic: Remove empty directory.
        * testsuite/28_regex/algorithms/match/extended: Likewise.
        * testsuite/28_regex/algorithms/match: Likewise.

From-SVN: r192180
2012-10-07 09:59:02 +00:00
Paolo Carlini
a2ca8577e6 re PR c++/52764 (Including <cstdint> after <stdint.h> fails to define limit macros)
2012-10-06  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/52764
	* ginclude/stdint-wrap.h: In C++11 if __STDC_HOSTED__ define
	__STDC_LIMIT_MACROS and __STDC_CONSTANT_MACROS.
	* ginclude/stdint-gcc.h: In C++11 unconditionally define
	limit and constant macros.

/testsuite
2012-10-06  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/52764
	* g++.dg/cpp0x/stdint.C: New.

/libstdc++-v3
2012-10-06  Paolo Carlini  <paolo.carlini@oracle.com>

	PR c++/52764
	* include/c_global/cstdint: Remove __STDC_LIMIT_MACROS and
	__STDC_CONSTANT_MACROS related macros.

From-SVN: r192174
2012-10-06 23:06:04 +00:00
Joe Seymour
d6a5e81d74 dynamic_bitset: Fix cxxabi_forced.h include path.
2012-10-06  Joe Seymour  <jseymour@codesourcery.com>

	* include/tr2/dynamic_bitset: Fix cxxabi_forced.h include path.

From-SVN: r192154
2012-10-06 08:39:13 +00:00
Benjamin Kosnik
d2edfb151d match: Rename to...
2012-10-05  Benjamin Kosnik  <bkoz@redhat.com>

	* testsuite/28_regex/algorithms/match: Rename to...
	* testsuite/28_regex/algorithms/regex_match: ...this.
	* testsuite/28_regex/basic_regex/regex.cc: Rename to...
	* testsuite/28_regex/basic_regex/ctors/basic/default.cc: ...this.
	* testsuite/util/testsuite_regex.h: New.
	* testsuite/28_regex/basic_regex/ctors/basic/raw_string.cc: New.

From-SVN: r192146
2012-10-05 21:18:54 +00:00
Jakub Jelinek
0d23cf7a4f cp-tree.h (SIZEOF_EXPR_TYPE_P): Define.
cp/
	* cp-tree.h (SIZEOF_EXPR_TYPE_P): Define.
	* tree.c (cp_tree_equal): Handle SIZEOF_EXPR with
	SIZEOF_EXPR_TYPE_P.
	* mangle.c (write_expression): Likewise.
	* cxx-pretty-print.c (pp_cxx_unary_expression): Likewise.
	* error.c (dump_expr): Likewise.
	* parser.c (cp_parser_unary_expression): For sizeof call
	cxx_sizeof_or_alignof_{type,expr} just for diagnostics and
	return SIZEOF_EXPR with the operand.
	* pt.c (tsubst_copy, tsubst_copy_and_build): For SIZEOF_EXPR,
	call cxx_sizeof_or_alignof_{type,expr} for diagnostics, but
	return SIZEOF_EXPR with tsubsted operand.
	(value_dependent_expression_p): Handle SIZEOF_EXPR with
	SIZEOF_EXPR_TYPE_P.
	(instantiation_dependent_r): Likewise.
	* call.c (null_ptr_cst_p): Call maybe_constant_value for C++98.
	* semantics.c (finish_call_expr): Call
	sizeof_pointer_memaccess_warning if needed.
	(cxx_eval_constant_expression): Handle SIZEOF_EXPR.
	(potential_constant_expression_1): Remove early exit for
	C++98.  Handle PROPERTY_REF.
	* decl.c (duplicate_decls): When redeclaring a builtin function,
	keep the merged decl builtin also if newdecl is a gnu_inline
	inline definition.
	(fold_sizeof_expr_r): New function.
	(compute_array_index_type): Fold SIZEOF_EXPRs in itype.
	* cp-gimplify.c (cp_genericize_r): Fold SIZEOF_EXPR.
	* typeck.c (cp_build_binary_op): For warn_for_sign_compare
	try harder using maybe_constant_value to get INTEGER_CSTs.

	* decl.c (stabilize_vla_size): Call pointer_set_destroy
	at the end.
testsuite/
	* g++.dg/torture/Wsizeof-pointer-memaccess1.C: New test.
	* g++.dg/torture/Wsizeof-pointer-memaccess2.C: New test.
	* g++.dg/warn/Wsign-compare-5.C: New test.
	* g++.dg/warn/Wsizeof-pointer-memaccess-1.C: New test.
	* g++.dg/warn/Wnull-conversion-1.C: For c++11 add dg-error.
	* g++.dg/ext/builtin30.C: New test.
	* g++.dg/ext/vla12.C: New test.
	* gcc.dg/builtins-85.c: New test.
libstdc++-v3/
	* testsuite/20_util/shared_ptr/cons/43820_neg.cc: Adjust line
	numbers.

From-SVN: r192141
2012-10-05 21:30:39 +02:00
Marc Glisse
3b1cd14dd0 re PR target/54686 (std::abs (long long) resorts to std::abs (double) if llabs is absent)
2012-10-05  Marc Glisse  <marc.glisse@inria.fr>

	PR libstdc++/54686
	* include/c_global/cstdlib (abs(long long)): Define with
	__builtin_llabs when we have long long.
	(abs(long)): Use __builtin_labs.
	(abs(__int128)): Define when we have __int128.

From-SVN: r192138
2012-10-05 19:10:22 +00:00
Paolo Carlini
67dd8d5938 cstdlib: Remove redundant pasto code protected by __GXX_EXPERIMENTAL_CXX0X__.
2012-10-05  Paolo Carlini  <paolo.carlini@oracle.com>

	* include/c_global/cstdlib: Remove redundant pasto code protected
	by __GXX_EXPERIMENTAL_CXX0X__.
	* include/c_global/cwctype: Likewise.
	* include/c_global/ccomplex: Remove uses of obsolete macro
	_GLIBCXX_INCLUDE_AS_TR1.
	* include/c_global/cfloat: Likewise.

From-SVN: r192137
2012-10-05 17:39:32 +00:00
Marc Glisse
8f2b580aeb re PR target/54686 (std::abs (long long) resorts to std::abs (double) if llabs is absent)
2012-10-05  Marc Glisse  <marc.glisse@inria.fr>

	PR libstdc++/54686
	* include/c_std/cstdlib (abs(long long)): Define with
	__builtin_llabs when we have long long.
	(abs(long)): Use __builtin_labs.
	(abs(__int128)): Define when we have __int128.
	* testsuite/26_numerics/headers/cstdlib/54686.c: New file.

From-SVN: r192132
2012-10-05 16:20:44 +00:00
Paolo Carlini
90f9c94e02 re PR libstdc++/53248 (std::array<T,0> doesn't work when T is not default-constructible)
2012-10-03  Paolo Carlini  <paolo.carlini@oracle.com>

	PR libstdc++/53248
	* include/std/array (__array_traits<>): Add.
	(array<>): Allow for zero-size arrays of non default-constructible
	elements.
	* testsuite/23_containers/array/requirements/
	non_default_constructible.cc: New.
	* testsuite/23_containers/array/requirements/zero_sized_arrays.cc:
	Adjust.
	* testsuite/23_containers/array/tuple_interface/get_neg.cc: Adjust
	dg-error line numbers.
	* testsuite/23_containers/array/tuple_interface/tuple_element_neg.cc:
	Likewise.

From-SVN: r192056
2012-10-04 00:02:29 +00:00
Jonathan Wakely
1504e3e1c4 re PR other/53889 (Gthreads doesn't support destroying recursive mutexes)
libgcc:

	PR other/53889
	* gthr.h (__gthread_recursive_mutex_destroy): Document new required
	function.
	* gthr-posix.h (__gthread_recursive_mutex_destroy): Define.
	* gthr-single.h (__gthread_recursive_mutex_destroy): Likewise.
	* config/gthr-rtems.h (__gthread_recursive_mutex_destroy): Likewise.
	* config/gthr-vxworks.h (__gthread_recursive_mutex_destroy): Likewise.
	* config/i386/gthr-win32.h (__gthread_recursive_mutex_destroy):
	Likewise.
	* config/mips/gthr-mipssde.h (__gthread_recursive_mutex_destroy):
	Likewise.
	* config/pa/gthr-dce.h (__gthread_recursive_mutex_destroy): Likewise.
	* config/s390/gthr-tpf.h (__gthread_recursive_mutex_destroy): Likewise.

libstdc++-v3:

	PR other/53889
	* include/std/mutex (__recursive_mutex_base::~__recursive_mutex_base):
	Use __gthread_recursive_mutex_destroy.
	(__recursive_mutex_base::_S_destroy): Remove.
	(__recursive_mutex_base::_S_destroy_win32): Likewise.
	* include/ext/concurrence.h (__recursive_mutex::~__recursive_mutex):
	Use __gthread_recursive_mutex_destroy.
	(__recursive_mutex::_S_destroy): Remove.
	(__recursive_mutex::_S_destroy_win32): Likewise.

From-SVN: r192002
2012-10-02 21:22:32 +01:00
Benjamin Kosnik
e0372a2f31 gnu-versioned-namespace.ver: Add more typeinfo/vtable exports.
2012-10-01  Benjamin Kosnik  <bkoz@redhat.com>

	* config/abi/pre/gnu-versioned-namespace.ver: Add more
	typeinfo/vtable exports.

From-SVN: r191949
2012-10-01 23:58:37 +00:00
Paolo Carlini
decf0e27a0 re PR libstdc++/54757 (FAIL: ext/random/beta_distribution/cons/default.cc (test for excess errors))
2012-10-01  Paolo Carlini  <paolo.carlini@oracle.com>

	PR libstdc++/54757
	* include/ext/random (rice_distribution<>::operator()): Use std::hypot
	only if _GLIBCXX_USE_C99_MATH_TR1.
	* include/ext/random.tcc (rice_distribution<>::__generate_impl):
	Likewise.

From-SVN: r191944
2012-10-01 23:10:02 +00:00
Daniel Krugler
83ddb39f04 type_traits (result_of): Provide "SFINAE-friendly" (see N3436) implementation.
2012-10-01  Daniel Krugler  <daniel.kruegler@googlemail.com>

	* include/std/type_traits (result_of): Provide "SFINAE-friendly"
	(see N3436) implementation.
	* testsuite/20_util/result_of/sfinae_friendly_1.cc: New.
	* testsuite/20_util/result_of/sfinae_friendly_2.cc: Likewise.
	* testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Tweak
	dg-error line numbers.
	* testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc:
	Likewise.
	* testsuite/20_util/declval/requirements/1_neg.cc: Likewise.

From-SVN: r191930
2012-10-01 16:02:57 +00:00
Benjamin Kosnik
321168c3e6 user.cfg.in: Update to doxygen 1.8.2.
2012-09-30  Benjamin Kosnik  <bkoz@redhat.com>

	* doc/doxygen/user.cfg.in: Update to doxygen 1.8.2.

From-SVN: r191876
2012-09-30 17:56:49 +00:00
Jonathan Wakely
b4ca0e1a10 ropeimpl.h (__uninitialized_fill_n_a): Fix using declaration.
* include/ext/ropeimpl.h (__uninitialized_fill_n_a): Fix using
	declaration.
	* testsuite/ext/rope/5.cc: New.

From-SVN: r191869
2012-09-30 16:36:18 +01:00
Jonathan Wakely
e8031ec516 re PR libstdc++/54577 (deque<T>::erase() still takes iterator instead of const_iterator)
PR libstdc++/54577
	* doc/xml/manual/status_cxx2011.xml: N2350 changes are missing from
	sequence containers.
	* doc/html/*: Regenerate.

From-SVN: r191866
2012-09-30 12:40:06 +01:00
Jonathan Wakely
4e57a5c302 Fix ChangeLog date
From-SVN: r191857
2012-09-29 19:00:54 +01:00
Jonathan Wakely
693ac783d9 re PR libstdc++/34106 ([parallel mode] Atomic operations compatibility layer needs cleanup)
PR libstdc++/34106
	* include/parallel/compatibility.h: Remove non-GCC code.

From-SVN: r191856
2012-09-29 18:58:34 +01:00
Benjamin Kosnik
b1d6986c94 fragment.am (CONFIG_CXXFLAGS): Remove EXTRA_CXX_FLAGS.
2012-09-28  Benjamin Kosnik  <bkoz@redhat.com>

	* fragment.am (CONFIG_CXXFLAGS): Remove EXTRA_CXX_FLAGS.
	* libsupc++/Makefile.am (LTCXXCOMPILE): Add EXTRA_CXX_FLAGS here.
	* src/Makefile.am: Same.
	* src/c++98/Makefile.am: Same.
	* src/c++11/Makefile.am: Same.
	* Makefile.in: Regenerated.
	* src/Makefile.am: Same.
	* src/c++11/Makefile.in: Same.
	* src/c++98/Makefile.in: Same.
	* include/Makefile.in: Same.
	* po/Makefile.in: Same.
	* python/Makefile.in: Same.
	* testsuite/Makefile.in: Same.

2012-09-28  Benjamin Kosnik  <bkoz@redhat.com>

	* src/c++98/Makefile.am: Fixup PARALLEL_FLAGS.

From-SVN: r191847
2012-09-29 04:08:17 +00:00
Benjamin Kosnik
495de4f4cb acinclude.m4 (GLIBCXX_ENABLE_PARALLEL): Remove ENABLE_PARALLEL.
2012-09-28  Benjamin Kosnik  <bkoz@redhat.com>

	* acinclude.m4 (GLIBCXX_ENABLE_PARALLEL): Remove ENABLE_PARALLEL.
	* include/Makefile.am: Same.
	* src/c++98/Makefile.am: Same.
	* src/Makefile.am: Same.
	* Makefile.in: Regenerated.
	* aclocal.m4: Same.
	* configure: Same.
	* doc/Makefile.in: Same.
	* include/Makefile.in: Same.
	* libsupc++/Makefile.in: Same.
	* po/Makefile.in: Same.
	* python/Makefile.in: Same.
	* src/Makefile.in: Same.
	* testsuite/Makefile.in: Same.
	* src/c++11/Makefile.in: Same.
	* src/c++98/Makefile.in: Same.

	* src/c++98/compatibility-debug_list-2.cc: Update comments.
	* src/c++98/compatibility-debug_list.cc: Same.
	* src/c++98/compatibility-list-2.cc: Renamed to src/c++98/list-aux-2.cc
	* src/c++98/compatibility-list.cc: Renamed to src/c++98/list-aux.cc
	* src/c++98/compatibility-parallel_list-2.cc: Renamed to
	src/c++98/list_associated-2.cc.
	* src/c++98/compatibility-parallel_list.cc: Renamed to
	src/c++98/list_associated.cc.

From-SVN: r191837
2012-09-28 19:48:27 +00:00
Paolo Carlini
fb95b3dfae re PR libstdc++/54727 (error: declaration of ‘UINT64_C’ must be available)
2012-09-27  Paolo Carlini  <paolo.carlini@oracle.com>

	PR libstdc++/54727
	* config/cpu/i486/opt/bits/opt_random.h: Avoid UINT64_C.

From-SVN: r191806
2012-09-27 12:53:46 +00:00
Paolo Carlini
8054b82ee5 random: Add include checks for c++11 and <cstdint>.
2012-09-26  Paolo Carlini  <paolo.carlini@oracle.com>

	* include/ext/random: Add include checks for c++11 and <cstdint>.

From-SVN: r191792
2012-09-27 01:04:30 +00:00
Benjamin Kosnik
957ea7ba30 re PR libstdc++/54314 (undefined references to 'construction vtable for std::ostream-in-std::basic_ostringstream<char, std::char_traits<char>, std::allocator<char> >')
2012-09-26  Benjamin Kosnik  <bkoz@redhat.com>

       PR libstdc++/54314
       * config/abi/pre/gnu.ver: Add vtable exports.
       * config/abi/pre/gnu-versioned-namespace.ver: Same.

From-SVN: r191788
2012-09-27 00:05:03 +00:00
Benjamin Kosnik
3b7f9f50be Correct truncation on last checkin.
From-SVN: r191787
2012-09-27 00:00:46 +00:00
Akira Takahashi
e80d3fda8e re PR libstdc++/53515 (InputIterator version std::advance needs negative check)
2012-09-26  Akira Takahashi  <faithandbrave@gmail.com>

	PR libstdc++/53515
	* include/bits/stl_iterator_base_funcs.h (__advance(_InputIterator&,
	_Distance, input_iterator_tag)): Add _GLIBCXX_DEBUG_ASSERT(__n >= 0).

From-SVN: r191784
2012-09-26 23:56:39 +00:00
Ulrich Drepper
48c7b524c1 Optimize bulk mode for normal_distribution<double> for SSE3.
2012-09-26  Ulrich Drepper  <drepper@gmail.com>

	Optimize bulk mode for normal_distribution<double> for SSE3.
	* configure.host: Define cpu_opt_bits_random.
	* configure.ac: Substitute CPU_OPT_BITS_RANDOM.
	* include/Makefile.am (bits_headers): Add ${bits_host_headers}.
	(bits_host_headers): Define.
	* include/bits/random.tcc: Move __details::_Power_of_2 to...
	* include/bits/random.h: ...here.
	* include/std/random: Include <bits/opt_random.h>.
	* config/cpu/i486/opt/bits/opt_random.h: New file.
	* config/cpu/generic/opt/bits/opt_random.h: New file.
	* configure: Regenerated.
	* Makefile.in: Regenerated.
	* aclocal.m4: Regenerated.
	* doc/Makefile.in: Regenerated.
	* include/Makefile.in: Regenerated.
	* libsupc++/Makefile.in: Regenerated.
	* po/Makefile.in: Regenerated.
	* python/Makefile.in: Regenerated.
	* src/Makefile.in: Regenerated.
	* src/c++11/Makefile.in: Regenerated.
	* src/c++98/Makefile.in: Regenerated.
	* testsuite/Makefile.in: Regenerated.

	* config/cpu/generic/opt/ext/opt_random.h: Fix comment.

From-SVN: r191758
2012-09-26 13:10:26 +00:00
Paolo Carlini
222b68463b re PR libstdc++/44436 ([C++0x] Implement emplace* in associative containers)
2012-09-25  Paolo Carlini  <paolo.carlini@oracle.com>

	* doc/xml/manual/status_cxx2011.xml: Update vs PR 44436.

From-SVN: r191695
2012-09-25 08:43:38 +00:00
Edward Smith-Rowland
21a8ccc02f Implement the K-distribution as an extension.
From-SVN: r191688
2012-09-25 03:26:36 +00:00
François Dumont
55826ab6d1 re PR libstdc++/44436 ([C++0x] Implement emplace* in associative containers)
2012-09-24  François Dumont  <fdumont@gcc.gnu.org>

	PR libstdc++/44436
	* include/bits/stl_tree.h
	(_Rb_tree<>::_M_insert_): Take _Base_ptr rather than
	_Const_Base_ptr.
	(_Rb_tree<>::_M_insert_node): New.
	(_Rb_tree<>::_M_get_insert_unique_pos): New, search code of
	_M_insert_unique method.
	(_Rb_tree<>::_M_insert_unique): Use latter.
	(_Rb_tree<>::_M_emplace_unique): New, likewise.
	(_Rb_tree<>::_M_get_insert_equal_pos): New, search code of
	_M_insert_equal method.
	(_Rb_tree<>::_M_insert_equal): Use latter.
	(_Rb_tree<>::_M_emplace_equal): New, likewise.
	(_Rb_tree<>::_M_get_insert_hint_unique_pos): New, search code of
	_M_insert_unique_ method.
	(_Rb_tree<>::_M_insert_unique_): Use latter.
	(_Rb_tree<>::_M_emplace_hint_unique): New, likewise.
	(_Rb_tree<>::_M_get_insert_hint_equal_pos): New, search code of
	_M_insert_equal_ method.
	(_Rb_tree<>::_M_insert_equal_): Use latter.
	(_Rb_tree<>::_M_emplace_hint_equal): New, likewise.
	(_Rb_tree<>::_M_insert_lower): Remove first _Base_ptr parameter,
	useless as always null.
	* include/bits/stl_map.h: Include <tuple> in C++11.
	(map<>::operator[](const key_type&)): Use
	_Rb_tree<>::_M_emplace_hint_unique in C++11.
	(map<>::operator[](key_type&&)): Likewise.
	(map<>::emplace): New.
	(map<>::emplace_hint): New.
	* include/bits/stl_multimap.h (multimap<>::emplace): New.
	(multimap<>::emplace_hint): New.
	* include/bits/stl_set.h (set<>::emplace): New.
	(set<>::emplace_hint): New.
	* include/bits/stl_multiset.h (multiset<>::emplace): New.
	(multiset<>::emplace_hint): New.
	* include/debug/map.h (std::__debug::map<>::emplace): New.
	(std::__debug::map<>::emplace_hint): New.
	* include/debug/multimap.h (std::__debug::multimap<>::emplace):
	New.
	(std::__debug::multimap<>::emplace_hint): New.
	* include/debug/set.h (std::__debug::set<>::emplace): New.
	(std::__debug::set<>::emplace_hint): New.
	* include/debug/multiset.h (std::__debug::multiset<>::emplace):
	New.
	(std::__debug::multiset<>::emplace_hint): New.
	* include/profile/map.h (std::__profile::map<>::emplace): New.
	(std::__profile::map<>::emplace_hint): New.
	* include/profile/multimap.h (std::__profile::multimap<>::emplace):
	New.
	(std::__profile::multimap<>::emplace_hint): New.
	* include/profile/set.h (std::__profile::set<>::emplace): New.
	(std::__profile::set<>::emplace_hint): New.
	* include/profile/multiset.h (std::__profile::multiset<>::emplace):
	New.
	(std::__profile::multiset<>::emplace_hint): New.
	* testsuite/util/testsuite_container_traits.h: Signal that emplace
	and emplace_hint are available on std::map, std::multimap,
	std::set and std::multiset in C++11.
	* testsuite/23_containers/map/operators/2.cc: New.
	* testsuite/23_containers/map/modifiers/emplace/1.cc: New.
	* testsuite/23_containers/multimap/modifiers/emplace/1.cc: New.
	* testsuite/23_containers/set/modifiers/emplace/1.cc: New.
	* testsuite/23_containers/multiset/modifiers/emplace/1.cc: New.

From-SVN: r191679
2012-09-24 19:53:36 +00:00
François Dumont
e6fa043b2d 41975.cc: Use __uset_hashtable rather than removed __unordered_set.
2012-09-24  François Dumont  <fdumont@gcc.gnu.org>

	* testsuite/performance/23_containers/insert_erase/41975.cc: Use
	__uset_hashtable rather than removed __unordered_set.

From-SVN: r191678
2012-09-24 19:48:06 +00:00
Paolo Carlini
4fd97a6380 revert: stl_algobase.h (max, min): Use conditional operator.
2012-09-23  Paolo Carlini  <paolo.carlini@oracle.com>

	Revert:
	2012-09-21  Paolo Carlini  <paolo.carlini@oracle.com>

	* include/bits/stl_algobase.h (max, min): Use conditional operator.

From-SVN: r191652
2012-09-23 19:58:16 +00:00
Uros Bizjak
37f1d5c9f9 re PR libstdc++/54675 (Many libstdc++ testsuite failures in ext/random)
PR libstdc++/54675
	* include/ext/random: Avoid the badname __alpha (and, for
	consistency, __mu, __nu, __sigma and __omega too).
	* include/bits/random.tcc: Likewise.

From-SVN: r191650
2012-09-23 13:24:46 +02:00
Edward Smith-Rowland
0c105b723d Implement the Pareto distribution as an extension.
From-SVN: r191612
2012-09-21 12:33:20 +00:00
Paolo Carlini
88a4c78be1 stl_algobase.h (max, min): Use conditional operator.
2012-09-21  Paolo Carlini  <paolo.carlini@oracle.com>

	* include/bits/stl_algobase.h (max, min): Use conditional operator.

From-SVN: r191608
2012-09-21 10:48:30 +00:00
Benjamin Kosnik
ac6d1200be re PR libstdc++/28811 (--with-pic vs static libraries and libstdc++)
2012-09-18  Benjamin Kosnik  <bkoz@redhat.com>

        PR libstdc++/28811
        PR libstdc++/54482
        * configure.ac (glibcxx_lt_pic_flag,
          glibcxx_compiler_pic_flag,
          glibcxx_compiler_shared_flag): New. Use them.
        (lt_prog_compiler_pic_CXX): Set via glibcxx_*_flag(s) above.
        (pic_mode): Set to default.
        (PIC_CXXFLAGS): Remove.
        * Makefile.am (PICFLAG, PICFLAG_FOR_TARGET): Remove. Comment.
        * libsupc++/Makefile.am: Use glibcxx_ld_pic_flag and
          glibcxx_compiler_shared_flag. Comment.
        * src/c++11/Makefile.am: Same.
        * src/c++98/Makefile.am: Same.
        * src/Makefile.am: Use glibcxx_compiler_pic_flag.

        * Makefile.in: Regenerated.
        * aclocal.m4: Same.
        * configure: Same.
        * doc/Makefile.in: Same.
        * include/Makefile.in: Same.
        * libsupc++/Makefile.in: Same.
        * po/Makefile.in: Same.
        * python/Makefile.in: Same.
        * src/Makefile.in: Same.
        * src/c++11/Makefile.in: Same.
        * src/c++98/Makefile.in: Same.
        * testsuite/Makefile.in: Same.

        * src/c++11/compatibility-atomic-c++0x.cc: Use
          _GLIBCXX_SHARED instead of PIC to designate shared-only
          code blocks.
        * src/c++11/compatibility-c++0x.cc: Same.
        * src/c++11/compatibility-thread-c++0x.cc: Same.
        * src/c++98/compatibility-list-2.cc: Same.
        * src/c++98/compatibility.cc: : Same.

        * testsuite/17_intro/shared_with_static_deps.cc: New.

        * doc/xml/manual/build_hacking.xml: Separate configure from
        make/build issues, add build details.

From-SVN: r191509
2012-09-20 02:10:22 +00:00
Edward Smith-Rowland
19ece7ec02 Implement the Nakagami statistical distribution as an extension.
From-SVN: r191434
2012-09-18 16:14:09 +00:00
Paolo Carlini
ecfce0b850 re PR libstdc++/54612 (Many failures in ext/random testsuite)
2012-09-18  Paolo Carlini  <paolo.carlini@oracle.com>

	PR libstdc++/54612
	* include/ext/random.tcc (operator==
	(const __gnu_cxx::simd_fast_mersenne_twister_engine<>&,
	const __gnu_cxx::simd_fast_mersenne_twister_engine<>&)): Fix
	state_size use.
	* config/cpu/i486/opt/ext/opt_random.h: Guard with __SSE2__.

From-SVN: r191424
2012-09-18 14:02:20 +00:00
Ulrich Drepper
9bf714c23f configure.ac: Substitute CPU_OPT_EXT_RANDOM.
* configure.ac: Substitute CPU_OPT_EXT_RANDOM.
	* configure.host: Define cpu_opt_ext_random to location of the
	optimized version of <ext/random>.
	* include/Makefile.am (ext_headers): Add ${ext_host_headers}.
	(ext_host_headers): Define.
	* include/ext/random (simd_fast_mersenne_twister_engine<>
	::operator==): Don't define function here.
	* include/ext/random.tcc (simd_fast_mersenne_twister_engine): Don't
	define code using SSE2 here.  Define generic code only if
	_GLIBCXX_OPT_HAVE_RANDOM_SFMT_GEN_READ is not defined.
	(simd_fast_mersenne_twister_engine<>
	::operator==): Define here if
	_GLIBCXX_OPT_HAVE_RANDOM_SFMT_OPERATOREQUAL is not defined.
	* config/cpu/generic/opt/ext/opt_random.h: New file.
	* config/cpu/i486/opt/ext/opt_random.h: New file.
	* libsupc++/Makefile.in: Regenerated.
	* testsuite/Makefile.in: Regenerated.
	* po/Makefile.in: Regenerated.
	* configure: Regenerated.
	* Makefile.in: Regenerated.
	* doc/Makefile.in: Regenerated.
	* aclocal.m4: Regenerated.
	* python/Makefile.in: Regenerated.
	* include/Makefile.in: Regenerated.
	* src/c++98/Makefile.in: Regenerated.
	* src/c++11/Makefile.in: Regenerated.
	* src/Makefile.in: Regenerated.

From-SVN: r191384
2012-09-17 13:02:39 +00:00
Edward Smith-Rowland
f0e1e86d22 Fix a paste-o in ext/random.tcc - declared an Adapted urng that was not used ot needed.
From-SVN: r191371
2012-09-17 03:46:40 +00:00
Paolo Carlini
d9d69f64b1 random (rice_distribution<>::operator==): Change inline friend definition to non-template.
2012-09-16  Paolo Carlini  <paolo.carlini@oracle.com>

	* include/ext/random (rice_distribution<>::operator==): Change
	inline friend definition to non-template.
	* testsuite/ext/random/rice_distribution/requirements/
	explicit_instantiation/1.cc: New.

	* testsuite/26_numerics/random/normal_mv_distribution: Move...
	* testsuite/ext/random/normal_mv_distribution: ... here.
	* testsuite/26_numerics/random/simd_fast_mersenne_twister_engine:
	Move...
	* testsuite/ext/random/simd_fast_mersenne_twister_engine: ... here.
	* testsuite/26_numerics/random/beta_distribution: Move...
	* testsuite/ext/random/beta_distribution: ... here.
	* testsuite/26_numerics/random/rice_distribution: Move...
	* testsuite/ext/random/rice_distribution: ... here.

From-SVN: r191367
2012-09-16 22:28:21 +00:00
Edward Smith-Rowland
283126182e Add the rice distribution as an extension.
From-SVN: r191362
2012-09-16 17:36:56 +00:00
David Edelsohn
f783a79952 * configure: Regenerated.
From-SVN: r191330
2012-09-14 19:41:36 -04:00
Paolo Carlini
02cbc6d6a7 2012-09-14 Paolo Carlini <paolo.carlini@oracle.com>
* Tweak last ChangeLog entry.

From-SVN: r191296
2012-09-14 12:23:12 +00:00
Jonathan Wakely
645708abf6 Check _GLIBCXX_USE_C99_STDINT_TR1 in random.cc
PR libstdc++/54576
	* libstdc++-v3/src/c++11/random.cc: Check if
	_GLIBCXX_USE_C99_STDINT_TR1 is defined.

Co-Authored-By: H.J. Lu <hongjiu.lu@intel.com>

From-SVN: r191294
2012-09-14 04:41:53 -07:00
Rainer Orth
9520425b6b Clear hardware capabilities on libstdc++.so with Sun as
* acinclude.m4 (GLIBCXX_CHECK_ASSEMBLER_HWCAP): Define.
	* configure.ac: Call GLIBCXX_CHECK_ASSEMBLER_HWCAP.
	* fragment.am (CONFIG_CXXFLAGS): Add $(HWCAP_FLAGS).
	* configure: Regenerate.
	* Makefile.in: Regenerate.
	* doc/Makefile.in: Regenerate.
	* include/Makefile.in: Regenerate.
	* libsupc++/Makefile.in: Regenerate.
	* po/Makefile.in: Regenerate.
	* python/Makefile.in: Regenerate.
	* src/Makefile.in: Regenerate.
	* src/c++11/Makefile.in: Regenerate.
	* src/c++98/Makefile.in: Regenerate.
	* testsuite/Makefile.in: Regenerate.

From-SVN: r191218
2012-09-12 12:38:15 +00:00
Jakub Jelinek
635442bfd8 re PR libstdc++/54172 (__cxa_guard_acquire thread-safety issue)
PR libstdc++/54172
	* libsupc++/guard.cc (__cxa_guard_acquire): Fix up the last
	argument of the first __atomic_compare_exchange_n.

From-SVN: r191190
2012-09-11 17:22:54 +02:00
Sebastian Huber
5a86d36fcc re PR libstdc++/43852 (Embedded systems friendly libstdc++)
2012-09-10  Sebastian Huber  <sebastian.huber@embedded-brains.de>
	    Jonathan Wakely  <jwakely.gcc@gmail.com>

	PR libstdc++/43852
	* acinclude.m4 (GLIBCXX_ENABLE_VERBOSE): Define.
	* configure.ac (GLIBCXX_ENABLE_VERBOSE): Use it.
	* config.h.in: Regenerate.
	* configure: Likewise.
	* libsupc++/eh_term_handler.cc (_GLIBCXX_VERBOSE): Check new macro.
	* libsupc++/pure.cc (_GLIBCXX_VERBOSE): Likewise.
	* doc/xml/manual/configure.xml (--disable-libstdcxx-verbose): Document.
	* doc/html/manual/configure.html: Regenerate.

Co-Authored-By: Jonathan Wakely <jwakely.gcc@gmail.com>

From-SVN: r191121
2012-09-10 00:08:48 +01:00