Commit Graph

5604 Commits

Author SHA1 Message Date
Jonathan Wakely
207e08e0b5 C++STYLE: Fix typos.
2007-11-21  Jonathan Wakely  <jwakely.gcc@gmail.com>

	* docs/html/17_intro/C++STYLE: Fix typos.

From-SVN: r130336
2007-11-21 22:42:18 +00:00
Benjamin Kosnik
c60cd1dcf7 documentation.html: Validate.
2007-11-20  Benjamin Kosnik  <bkoz@redhat.com>

	* docs/html/documentation.html: Validate. Add links to index,
	correct broken links.
	* docs/html/17_intro/C++STYLE: Add bits.
	* docs/html/17_intro/configury.html: Correct, update.
	* docs/html/17_intro/api.html: Correct HTML.

	* include/bits/stl_algobase.h: Adjust comment.

From-SVN: r130331
2007-11-21 16:37:26 +00:00
Richard Sandiford
a7280feff6 variadic_construct.cc: Add dg-require-time.
libstdc++-v3/
	* testsuite/ext/throw_allocator/variadic_construct.cc: Add
	dg-require-time.

From-SVN: r130320
2007-11-20 20:58:38 +00:00
Paolo Carlini
f22aa574dc functional_hash.h: Do not include ext/numeric_traits.h.
2007-11-20  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/functional_hash.h: Do not include ext/numeric_traits.h.
	* include/tr1/functional_hash.h: Likewise.
	* include/std/functional: Include ext/type_traits.h.
	* include/tr1/functional: Likewise.

From-SVN: r130314
2007-11-20 14:06:53 +00:00
Paolo Carlini
a0ba4e53fd functional_hash.h (hash<long double>::operator()(long double)): Only declare.
2007-11-20  Paolo Carlini  <pcarlini@suse.de>

	* include/tr1_impl/functional_hash.h
	(hash<long double>::operator()(long double)): Only declare.
	* src/hash.cc: Define here.
	* config/abi/pre/gnu.ver: Adjust exports.
	* include/tr1/functional: Do not include <cmath>.
	* include/std/functional: Likewise.

	* include/std/functional: Include <new>.

From-SVN: r130312
2007-11-20 12:34:44 +00:00
Paolo Carlini
3c27955364 type_traits (_DEFINE_SPEC_BODY): Remove.
2007-11-18  Paolo Carlini  <pcarlini@suse.de>

	* include/tr1/type_traits (_DEFINE_SPEC_BODY): Remove.
	(_DEFINE_SPEC_0_HELPER): Rename to _DEFINE_SPEC_HELPER.
	(_DEFINE_SPEC): Simplify; adjust uses.

From-SVN: r130273
2007-11-18 18:55:27 +00:00
Paolo Carlini
90b81c3306 type_traits (is_reference, [...]): Declare.
2007-11-18  Paolo Carlini  <pcarlini@suse.de>

	* include/tr1_impl/type_traits (is_reference, is_function,
	remove_cv, is_member_pointer, remove_reference): Declare.
	* include/tr1_impl/type_traitsfwd.h: Remove.
	* include/Makefile.am: Adjust.
	* include/Makefile.in: Regenerate.

From-SVN: r130272
2007-11-18 18:05:42 +00:00
Jonathan Wakely
04901f81ae howto.html, [...]: Fix typos and anachronisms.
2007-11-17  Jonathan Wakely  <jwakely.gcc@gmail.com>

	* docs/html/17_intro/howto.html, docs/html/21_strings/howto.html,
	docs/html/22_locale/codecvt.html, docs/html/23_containers/howto.html,
	docs/html/27_io/howto.html, docs/html/ext/howto.html,
	docs/html/debug.html,  docs/html/install.html,
	docs/html/faq/index.html: Fix typos and anachronisms.

From-SVN: r130255
2007-11-17 01:11:43 +00:00
Paolo Carlini
478b2b9cb3 stl_algobase.h (struct __lexicographical_compare): Move to namespace std.
2007-11-16  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_algobase.h (struct __lexicographical_compare):
	Move to namespace std.
	(__lexicographical_compare_aux<>(_II1, _II1, _II2, _II2)): Add.
	(lexicographical_compare<>(_II1, _II1, _II2, _II2)): Call the latter.

From-SVN: r130254
2007-11-17 00:32:29 +00:00
Paolo Carlini
de03de6403 stl_algobase.h (struct __lexicographical_compare): Add.
2007-11-16  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_algobase.h (struct __lexicographical_compare): Add.
	(lexicographical_compare<>(_II1, _II1, _II2, _II2)): Use it.
	(lexicographical_compare(const unsigned char*, const unsigned char*,
	const unsigned char*, const unsigned char*),
	lexicographical_compare(const char*, const char*, const char*,
	const char*)): Remove.
	* include/ext/numeric_traits.h (__numeric_traits_floating<>::
	__is_signed): Add.

From-SVN: r130248
2007-11-16 23:41:55 +00:00
Paolo Carlini
f6dfe2fc46 locale_facets.cc: Fix typo in Copyright.
2007-11-16  Paolo Carlini  <pcarlini@suse.de>

	* src/locale_facets.cc: Fix typo in Copyright.

From-SVN: r130234
2007-11-16 17:50:50 +00:00
Paolo Carlini
c68e412864 locale_facets.tcc (__verify_grouping): Move...
2007-11-16  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/locale_facets.tcc (__verify_grouping): Move...
	* src/locale_facets.cc: ... here.
	* config/abi/pre/gnu.ver: Update exports.

From-SVN: r130233
2007-11-16 17:45:35 +00:00
Paolo Carlini
506af7a420 2007-11-16 Paolo Carlini <pcarlini@suse.de>
* Fix typo in ChangeLog entry.

From-SVN: r130212
2007-11-15 23:32:10 +00:00
Paolo Carlini
7f786096da istream.tcc (basic_istream<>::sentry:: sentry(basic_istream<>&, bool)): Explicitely convert to bool.
2007-11-15  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/istream.tcc (basic_istream<>::sentry::
	sentry(basic_istream<>&, bool)): Explicitely convert to bool.
	* include/bits/locale_facets.tcc (num_put<>::_M_insert_int(_OutIter,
	ios_base&, _CharT, _ValueT)): Likewise.
	* include/std/ostream (basic_ostream<>::sentry::~sentry): Likewise.

From-SVN: r130211
2007-11-15 22:59:12 +00:00
Paolo Carlini
4f39bf5c6b re PR libstdc++/34105 (Confusing error message with missing #include <algorithm>)
2007-11-15  Paolo Carlini  <pcarlini@suse.de>

	PR libstdc++/34105
	* include/bits/stl_algobase.h: Do not include <bits/algorithmfwd.h>.
	(lexicographical_compare(const unsigned char*, const unsigned char*,
	const unsigned char*, const unsigned char*),
	lexicographical_compare(const char*, const char*, const char*,
	const char*)): Move to namespace (std, _GLIBCXX_STD_P).
	* include/parallel/algobase.h: Do not include <bits/algorithmfwd.h>.
	(equal): Move after mismatch.
	* include/bits/stl_heap.h (is_heap, is_heap_until): Reorder.
	* include/bits/char_traits.h: Include <bits/stl_algobase.h> instead
	of <bits/algorithmfwd.h>.
	* include/bits/stl_algo.h: Include first <bits/algorithmfwd.h>.
	* include/bits/algorithmfwd.h (lexicographical_compare): Do not
	declare overloads.
	* include/parallel/partition.h: Include <parallel/random_number.h>.
	* testsuite/util/testsuite_abi.cc: Include <algorithm>.

From-SVN: r130207
2007-11-15 19:05:17 +00:00
Johannes Singler
d76575caa5 multiway_merge.h: More robust finding of an arbitrary existing element inside the input sequences.
2007-11-14  Johannes Singler  <singler@ira.uka.de>

      * include/parallel/multiway_merge.h: More robust finding of an
        arbitrary existing element inside the input sequences.
      * include/bits/stl_algo.h: Fix typo to actually call appropriate
        sequential version.

From-SVN: r130183
2007-11-14 17:37:38 +00:00
Benjamin Kosnik
4dd9d9db1d documentation.html: First pass at unified table of contents.
2007-11-13  Benjamin Kosnik  <bkoz@redhat.com>

	* docs/html/documentation.html: First pass at unified table of contents.
	* docs/html/abi.html: Move...
	* docs/html/17_intro/abi.html: ...here.
	* docs/html/17_intro/porting-howto.html: Update, edit, put
	resulting pieces into...
	* docs/html/17_intro/api.html: New.
	* docs/html/17_intro/c++0x_status.html: New.
	* docs/html/17_intro/CHECKLIST: Move to...
	* docs/html/17_intro/c++1998_status.html: ...here.
	* docs/html/ext/tr1.html: Move ...
	* docs/html/17_intro/tr1_status.html: ...here.
	* docs/html/debug_mode.html: Move...
	* docs/html/ext/debug_mode.html: ...here.
	* docs/html/parallel_mode.html: Move...
	* docs/html/ext/parallel_mode.html: ...here
	* docs/html/17_intro/BUGS: Remove.
	* docs/html/17_intro/concept_check.diff: Remove.
	* docs/html/17_intro/HEADER_POLICY: Remove.
	* docs/html/17_intro/headers_cc.txt: Remove.
	* docs/html/17_intro/PROBLEMS: Remove.
	* docs/html/17_intro/RELEASE-NOTES: Remove.
	* docs/html/explanations.html: Remove.
	* docs/html/makedoc.awk: Remove.
	* docs/html/faq/index.txt: Remove. HTML only.
	* /docs/html/Makefile: Remove.
	
	* docs/html/17_intro/configury.html: Editing, updating,
	consistency check with doxygen conventions. Change libstdc++-v3 to
	libstdc++.	
	* docs/html/17_intro/howto.html: Same.
	* docs/html/17_intro/license.html: Same.
	* docs/html/17_intro/porting.html: Same.
	* docs/html/18_support/howto.html: Same.
	* docs/html/19_diagnostics/howto.html: Same.
	* docs/html/20_util/allocator.html: Same.
	* docs/html/20_util/howto.html: Same.
	* docs/html/21_strings/howto.html: Same.
	* docs/html/22_locale/codecvt.html: Same.
	* docs/html/22_locale/ctype.html: Same.
	* docs/html/22_locale/howto.html: Same.
	* docs/html/22_locale/messages.html: Same.
	* docs/html/23_containers/howto.html: Same.
	* docs/html/24_iterators/howto.html: Same.
	* docs/html/25_algorithms/howto.html: Same.
	* docs/html/26_numerics/howto.html: Same.
	* docs/html/27_io/howto.html: Same.
	* docs/html/configopts.html: Same.
	* docs/html/debug.html: Same.
	* docs/html/ext/ballocator_doc.html: Same.
	* docs/html/ext/howto.html: Same.
	* docs/html/ext/mt_allocator.html: Same.
	* docs/html/ext/sgiexts.html: Same.
	* docs/html/faq/index.html: Same.
	* docs/html/install.html: Same.
	* docs/html/test.html: Same.
	
	* include/bits/c++config: Change _GLIBCXX_DEPRECATED to
	_GLIBCXX_DEPRECATED_ATTR, _GLIBCXX_VISIBILITY to
	_GLIBCXX_VISIBILITY_ATTR.	
	* include/backward/auto_ptr.h: Same.
	* include/backward/binders.h: Same.
	* include/bits/stl_function.h: Same.
	* include/std/memory: Same.
	* include/std/streambuf: Same.
	* include/tr1_impl/boost_shared_ptr.h: Same.
	* src/globals_io.cc: Same.
	* src/ios_init.cc: Same.

From-SVN: r130150
2007-11-13 17:43:57 +00:00
Paolo Carlini
b4d9ec93d6 deque.tcc (deque<>::_M_push_back_aux, [...]): Do not copy unnecessarily to __t_copy.
2007-11-13  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/deque.tcc (deque<>::_M_push_back_aux,
	_M_push_front_aux): Do not copy unnecessarily to __t_copy.

From-SVN: r130136
2007-11-13 11:35:56 +00:00
Chris Jefferson
7ffec97f9e stl_deque.h (deque<>::push_back<>(_Args...), [...]): Add.
2007-11-12  Chris Jefferson  <chris@bubblescope.net>
	    Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_deque.h (deque<>::push_back<>(_Args...),
	deque<>::push_front<>(_Args...), emplace<>(iterator, _Args...),
	insert(iterator, _Tp&&), _M_push_back_aux<>(_Args&&...),
	_M_push_front_aux<>(_Args&&...), _M_insert_aux<>(iterator,
	_Args&&...)): Add.
	* include/deque/deque.tcc (insert(iterator, value_type&&),
	emplace<>(iterator, _Args...), _M_push_back_aux<>(_Args&&...),
	_M_push_front_aux<>(_Args&&...), _M_insert_aux<>(iterator,
	_Args&&...)): Define.
	(_M_insert_aux(iterator, size_type, const value_type&),
	_M_insert_aux<>(iterator, _ForwardIterator, _ForwardIterator,
	size_type)): Use _GLIBCXX_MOVE3, _GLIBCXX_MOVE_BACKWARD3,
	__uninitialized_move*, __uninitialized_fill_move,
	__uninitialized_copy_move, when possible.
	* include/bits/stl_uninitialized.h (__uninitialized_copy_copy,
	__uninitialized_fill_copy, __uninitialized_copy_fill): Remove.
	(__uninitialized_copy_move, __uninitialized_move_copy,
	__uninitialized_move_fill, __uninitialized_fill_move): Add.
	* include/debug/deque (deque<>::push_back<>(_Args...),
	deque<>::push_front<>(_Args...), emplace<>(iterator, _Args...),
	insert(iterator, _Tp&&)): Add.
	* testsuite/23_containers/deque/modifiers/moveable.cc: Enable.
	* testsuite/23_containers/deque/capacity/moveable.cc: Likewise.
	* testsuite/23_containers/deque/cons/moveable.cc: Likewise.
	* testsuite/23_containers/deque/requirements/dr438/assign_neg.cc:
	Adjust dg-error line numbers.
	* testsuite/23_containers/deque/requirements/dr438/insert_neg.cc:
	Likewise.
	* testsuite/23_containers/deque/requirements/dr438/
	constructor_1_neg.cc: Likewise.
	* testsuite/23_containers/deque/requirements/dr438/
	constructor_2_neg.cc: Likewise.

	* include/debug/vector (vector<>::insert(iterator, _Tp&&)): Minor
	tweak, prefer std::move.

Co-Authored-By: Paolo Carlini <pcarlini@suse.de>

From-SVN: r130102
2007-11-12 16:01:09 +00:00
Howard Hinnant
c31ab059b6 stl_pair.h (pair<>::pair<>(_U1&&, _Arg0&&, _Args&&...)): Add.
2007-11-11  Howard Hinnant  <hhinnant@apple.com>

	* include/bits/stl_pair.h (pair<>::pair<>(_U1&&, _Arg0&&,
	_Args&&...)): Add.

From-SVN: r130085
2007-11-11 15:56:09 +00:00
Paolo Carlini
30e94eb293 lwg-active.html: Update to Revision R52.
2007-11-08  Paolo Carlini  <pcarlini@suse.de>

	* docs/html/ext/lwg-active.html: Update to Revision R52.
	* docs/html/ext/lwg-closed.html: Likewise.
	* docs/html/ext/lwg-defects.html: Likewise.
	* docs/html/ext/howto.html: Adjust.

From-SVN: r130083
2007-11-11 11:47:12 +00:00
Paolo Carlini
84237dbbf3 stl_list.h (list<>::_M_create_node<>(_Args&&...), [...]): Add.
2007-11-11  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_list.h (list<>::_M_create_node<>(_Args&&...),
	_M_insert<>(iterator, _Args&&...), push_front<>(_Args&&...),
	push_back<>(_Args&&...)): Add.
	(list<>::emplace<>(iterator, _Args&&...), insert(iterator,
	value_type&&)): Declare.
	(splice(iterator, list&&), splice(iterator, list&&, iterator),
	splice(iterator, list&&, iterator, iterator), merge(list&&),
	merge(list&&, _StrictWeakOrdering)): Add C++0x signatures.
	* include/bits/list.tcc (list<>::emplace<>(iterator, _Args&&...),
	insert(iterator, value_type&&)): Define.
	* include/debug/list (list<>::emplace<>(iterator, _Args&&...),
	insert(iterator, value_type&&)): Add.
	(splice(iterator, list&&), splice(iterator, list&&, iterator),
	splice(iterator, list&&, iterator, iterator), merge(list&&),
	merge(list&&, _StrictWeakOrdering)): Add C++0x signatures, use
	_GLIBCXX_MOVE.

From-SVN: r130082
2007-11-11 11:46:10 +00:00
Paolo Carlini
cbc6c888f9 stl_deque.h (deque<>::operator=(deque&&)): Implement resolution of DR 675, call clear first.
2007-11-09  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_deque.h (deque<>::operator=(deque&&)): Implement
	resolution of DR 675, call clear first.
	* include/bits/stl_list.h (list<>::operator=(list&&)): Likewise.
	* include/bits/stl_bvector.h (vector<bool>::operator=(vector&&)):
	Likewise.
	* include/bits/stl_vector.h (vector<>::operator=(vector&&)): Likewise.
	* include/bits/stl_map.h (map<>::operator=(map&&)): Likewise.
	* include/bits/stl_multimap.h (multimap<>::operator=(multimap&&)):
	Likewise.
	* include/bits/stl_multiset.h (multiset<>::operator=(multiset&&)):
	Likewise.
	* include/bits/stl_set.h (set<>::operator=(set&&)): Likewise.
	* include/debug/map.h (map<>::operator=(map&&)): Likewise.
	* include/debug/set.h (set<>::operator=(set&&)): Likewise.
	* include/debug/multimap.h (multimap<>::operator=(multimap&&)):
	Likewise.
	* include/debug/multiset.h (multiset<>::operator=(multiset&&)):
	Likewise.
	* include/debug/deque (deque<>::operator=(deque&&)): Likewise.
	* include/debug/list (list<>::operator=(list&&)): Likewise. 
	* include/debug/vector (vector<>::operator=(vector&&)): Likewise.
	* testsuite/23_containers/multimap/moveable.cc: Adjust.
	* testsuite/23_containers/multiset/moveable.cc: Likewise.
	* testsuite/23_containers/set/moveable.cc: Likewise.
	* testsuite/23_containers/map/moveable.cc: Likewise.
	* testsuite/20_util/pair/moveable.cc: Likewise.
	* testsuite/23_containers/deque/requirements/dr438/assign_neg.cc:
	Adjust dg-error line numbers.
	* testsuite/23_containers/deque/requirements/dr438/insert_neg.cc:
	Likewise.
	* testsuite/23_containers/deque/requirements/dr438/
	constructor_1_neg.cc: Likewise.
	* testsuite/23_containers/deque/requirements/dr438/
	constructor_2_neg.cc: Likewise.
	* testsuite/23_containers/list/requirements/dr438/assign_neg.cc:
	Likewise.
	* testsuite/23_containers/list/requirements/dr438/insert_neg.cc:
	Likewise.
	* testsuite/23_containers/list/requirements/dr438/
	constructor_1_neg.cc: Likewise.
	* testsuite/23_containers/list/requirements/dr438/
	constructor_2_neg.cc: Likewise.
 	* testsuite/23_containers/vector/requirements/dr438/assign_neg.cc:
	Likewise.
	* testsuite/23_containers/vector/requirements/dr438/insert_neg.cc:
	Likewise.
	* testsuite/23_containers/vector/requirements/dr438/
	constructor_1_neg.cc: Likewise.
	* testsuite/23_containers/vector/requirements/dr438/
	constructor_2_neg.cc: Likewise.

From-SVN: r130051
2007-11-09 17:18:10 +00:00
Paolo Carlini
18f310b7d3 re PR libstdc++/34032 (-std=c++0x causes undeclared symbols errors on cygwin)
2007-11-09  Paolo Carlini  <pcarlini@suse.de>

	PR libstdc++/34032
	* acinclude.m4 ([GLIBCXX_ENABLE_C99], [GLIBCXX_CHECK_C99_TR1]):
	Use -std=c++98 instead of the default -std=gnu++98.
	* configure: Regenerate.

From-SVN: r130047
2007-11-09 15:54:33 +00:00
Paolo Carlini
ec01f29236 basic_file_stdio.cc (fopen_mode): Add modes missing per DR 596.
2007-11-08  Paolo Carlini  <pcarlini@suse.de>

	* config/io/basic_file_stdio.cc (fopen_mode): Add modes missing
	per DR 596.
	* testsuite/27_io/basic_filebuf/open/char/4.cc: Extend.
	* include/std/fstream: Update comment preceding open.
	* docs/html/ext/howto.html: Update.

From-SVN: r130004
2007-11-08 16:22:21 +00:00
Paolo Carlini
ce796131e1 type_traits (__decay_selector<_Up, [...]): Change according to DR 705.
2007-11-08  Paolo Carlini  <pcarlini@suse.de>

	* include/std/type_traits (__decay_selector<_Up, false, false>):
	Change according to DR 705.
	* include/bits/stl_pair.h (make_pair(_T1&&, _T2&&)): Change
	according to DR 706.
	* include/tr1_impl/tuple: Tweak.

From-SVN: r130001
2007-11-08 14:40:33 +00:00
Paolo Carlini
0a485bae9f vector (push_back, emplace): Fix signature typo.
2007-11-08  Paolo Carlini  <pcarlini@suse.de>

	* include/debug/vector (push_back, emplace): Fix signature typo.

From-SVN: r129996
2007-11-08 11:11:47 +00:00
Paolo Carlini
8e0775fb17 locale_facets.h (ctype<char>::taple, [...]): Implement trivial resolution of DR 695 [Ready].
2007-11-08  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/locale_facets.h (ctype<char>::taple, classic_table):
	Implement trivial resolution of DR 695 [Ready].
	* testsuite/22_locale/ctype/dr695.cc: New.
	* docs/html/ext/howto.html: Update.

From-SVN: r129995
2007-11-08 10:55:32 +00:00
Paolo Carlini
6749ca7e8b lwg-active.html: Update to Revision R52.
2007-11-08  Paolo Carlini  <pcarlini@suse.de>

	* docs/html/ext/lwg-active.html: Update to Revision R52.
	* docs/html/ext/lwg-closed.html: Likewise.
	* docs/html/ext/lwg-defects.html: Likewise.
	* docs/html/ext/howto.html: Adjust.

From-SVN: r129994
2007-11-08 10:19:57 +00:00
Paolo Carlini
bd7d4f5fa1 complex (fabs): In C++0x mode adjust return type per DR 595 [Ready].
2007-11-07  Paolo Carlini  <pcarlini@suse.de>

	* include/tr1_impl/complex (fabs): In C++0x mode adjust
	return type per DR 595 [Ready].

From-SVN: r129983
2007-11-08 02:48:25 +00:00
Paolo Carlini
1a1b20be14 stl_iterator.h (move_iterator<>::pointer): Adjust typedef per DR 680 [Ready].
2007-11-07  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_iterator.h (move_iterator<>::pointer): Adjust
	typedef per DR 680 [Ready].

From-SVN: r129959
2007-11-07 12:43:35 +00:00
Paolo Carlini
812e8c79b4 vector.tcc (vector<>::_M_insert_aux<>(iterator, _Args&&...)): In C++0x mode do not use temporary copies.
2007-11-06  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/vector.tcc (vector<>::_M_insert_aux<>(iterator,
	_Args&&...)): In C++0x mode do not use temporary copies.
	(insert(iterator, const value_type&)): Copy to a temporary
	when not reallocating.

	* include/bits/vector.tcc (insert(iterator, value_type&&)):
	Minor tweaks in C++0x mode.

From-SVN: r129954
2007-11-07 00:36:33 +00:00
Jonathan Wakely
3de36a09ac boost_shared_ptr.h: Avoid unnecessary memory barriers in _S_atomic case.
2007-11-06  Jonathan Wakely  <jwakely.gcc@gmail.com>

	* include/tr1_impl/boost_shared_ptr.h: Avoid unnecessary memory
	barriers in _S_atomic case.

From-SVN: r129927
2007-11-06 14:28:28 +00:00
Chris Jefferson
6eef740212 stl_vector.h (vector<>::push_back<>(_Args...), [...]): Add.
2007-11-05  Chris Jefferson  <chris@bubblescope.net>
	    Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_vector.h (vector<>::push_back<>(_Args...),
	emplace<>(iterator, _Args...), insert(iterator, _Tp&&),
	_M_insert_aux<>(iterator, _Args&&...)): Add.
	* include/bits/vector.tcc (insert(iterator, value_type&&),
	emplace<>(iterator, _Args...), _M_insert_aux<>(iterator, _Args&&...)):
	Define.
	(_M_fill_insert(iterator, size_type, const value_type&),
	_M_range_insert(iterator, _ForwardIterator, _ForwardIterator,
	std::forward_iterator_tag)): Use __uninitialized_move_a,
	_GLIBCXX_MOVE_BACKWARD3 when possible.
	* include/bits/stl_uninitialized.h (__uninitialized_move_a): Add.
	* include/debug/vector (vector<>::push_back<>(_Args...),
	emplace<>(iterator, _Args...), insert(iterator, _Tp&&)): Add.
	* testsuite/23_containers/vector/modifiers/moveable.cc: Enable.
	* testsuite/23_containers/vector/resize/moveable.cc: Likewise.
	* testsuite/23_containers/vector/cons/moveable.cc: Likewise.
	* testsuite/23_containers/vector/requirements/dr438/assign_neg.cc:
	Adjust dg-error line numbers.
	* testsuite/23_containers/vector/requirements/dr438/insert_neg.cc:
	Likewise.
	* testsuite/23_containers/vector/requirements/dr438/
	constructor_1_neg.cc: Likewise.
	* testsuite/23_containers/vector/requirements/dr438/
	constructor_2_neg.cc: Likewise.

Co-Authored-By: Paolo Carlini <pcarlini@suse.de>

From-SVN: r129907
2007-11-05 19:46:07 +00:00
Paolo Carlini
202d1d5f54 random (variate_generator<>::min, [...]): Return non-trivial values when _Engine_result_type is a floating point type and...
2007-11-03  Paolo Carlini  <pcarlini@suse.de>
	    Kai-Uwe Bux  <bux@kubux.net>

	* include/tr1_impl/random (variate_generator<>::min, max,
	operator()()): Return non-trivial values when _Engine_result_type
	is a floating point type and result_type is an integer type.

Co-Authored-By: Kai-Uwe Bux <bux@kubux.net>

From-SVN: r129875
2007-11-03 23:27:55 +00:00
Paolo Carlini
f6547b6818 stl_algo.h (minmax, [...]): Add.
2007-11-02  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_algo.h (minmax, minmax_element): Add.
	* include/bits/algorithmfwd.h: Update.
	* testsuite/25_algorithms/minmax/requirements/
	explicit_instantiation/2.cc: New.
	* testsuite/25_algorithms/minmax/requirements/
	explicit_instantiation/pod.cc: Likewise.
	* testsuite/25_algorithms/minmax/1.cc: Likewise.
	* testsuite/25_algorithms/minmax_element/check_type.cc: Likewise.
	* testsuite/25_algorithms/minmax_element/requirements/
	explicit_instantiation/2.cc: Likewise.
	* testsuite/25_algorithms/minmax_element/requirements/
	explicit_instantiation/pod.cc: Likewise.
	* testsuite/25_algorithms/minmax_element/1.cc: Likewise.
	* testsuite/25_algorithms/headers/algorithm/synopsis.cc: Update.

From-SVN: r129853
2007-11-02 15:55:32 +00:00
Johannes Singler
59b567fbca re PR libstdc++/33892 ([libstdc++ v3 parallel mode] Parallel mode algorithms use critical sections with global scope)
2007-11-02  Johannes Singler  <singler@ira.uka.de>

      PR libstdc++/33892

      * include/parallel/workstealing.h: Replaced pragma by function
        call lock.
      * include/parallel/search.h: Same
      * include/parallel/partition.h: Same
      * include/parallel/find.h: Same

From-SVN: r129852
2007-11-02 15:34:24 +00:00
Janis Johnson
fdaea7e286 re PR testsuite/25352 (xfail within dg-do command has no effect)
gcc/
	PR testsuite/25352
	* doc/sourcebuild.texi (Test Directives): Document that xfail
	has no effect for dg-do except when dg-do-what is "run".

libstdc++-v3/
	PR testsuite/25352
	* testsuite/26_numerics/headers/cmath/c99_classification_macros_c.cc:
	Remove xfail from dg-do and add dg-skip-if.

gcc/testsuite/
	PR testsuite/25352
	* gcc.c-torture/compile/20000804-1.c: Remove xfail from dg-do and
	add dg-skip-if.
	* gcc.c-torture/compile/20001205-1.c: Ditto.
	* gcc.c-torture/compile/20001226-1.c: Ditto.
	* gcc.c-torture/compile/20020312-1.c: Ditto.
	* gcc.c-torture/compile/20020604-1.c: Ditto.
	* gcc.c-torture/compile/920501-12.c: Ditto.
	* gcc.c-torture/compile/920501-4.c: Ditto.
	* gcc.c-torture/compile/920520-1.c: Ditto.
	* gcc.c-torture/compile/980506-1.c: Ditto.
	* gcc.c-torture/compile/990617-1.c: Ditto.
	* gcc.dg/compare6.c: Ditto.
	* g++.old-deja/g++.brendan/crash43.C: Ditto.
	* g++.old-deja/g++.brendan/synth1.C: Ditto.
	* g++.old-deja/g++.oliva/dwarf2.C: Ditto.
	* g++.old-deja/g++.oliva/dwarf3.C: Ditto.
	* g++.old-deja/g++.pt/static6.C: Ditto.
	* g++.old-deja/g++.pt/crash16.C: Ditto.
	* g++.old-deja/g++.mike/p10416.C: Ditto.
	* g++.old-deja/g++.mike/ns15.C: Ditto.
	* g++.old-deja/g++.mike/eh46.C: Ditto.

From-SVN: r129823
2007-11-01 16:22:36 +00:00
Paolo Carlini
c54171fee6 stl_queue.h (queue<>::push(value_type&&)): Replace with "emplace" version per DR 756.
2007-10-31  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_queue.h (queue<>::push(value_type&&)): Replace
	with "emplace" version per DR 756.
	(priority_queue<>::push(value_type&&)): Likewise.
	* include/bits/stl_stack.h (stack<>::push(value_type&&)): Likewise.

From-SVN: r129814
2007-11-01 01:40:56 +00:00
Paolo Carlini
ebb82e2751 re PR libstdc++/33815 (tr1::uniform_int isn't uniform)
2007-10-19  Paolo Carlini  <pcarlini@suse.de>

	PR libstdc++/33815
	* include/tr1_impl/random
	(uniform_int<>::_M_call(_UniformRandomNumberGenerator&, result_type,
	result_type, true_type)): Avoid the modulo (which uses the low-order
	bits).

From-SVN: r129769
2007-10-30 13:05:26 +00:00
Benjamin Kosnik
43c772540e Correct filename.
2007-10-30  Benjamin Kosnik  <bkoz@redhat.com>

	*docs/html/ext/pb_ds/multimap_text_insert_timing_test_small.html:
	Correct filename.	
	*docs/html/ext/pb_ds/multimap_text_find_timing_test_large.html: Same.
	*docs/html/ext/pb_ds/
	multimap_text_insert_mem_usage_test_small.html: Same.
	*docs/html/ext/pb_ds/multimap_text_insert_timing_test_large.html: Same.
	*docs/html/ext/pb_ds/
	multimap_text_insert_mem_usage_test_large.html: Same.
	*docs/html/ext/pb_ds/multimap_text_find_timing_test_small.html: Same.

2007-10-30  Benjamin Kosnik  <bkoz@redhat.com>
	
	*include/Makefile.am (PCHFLAGS): Remove -Wno-deprecated.
	*include/Makefile.in: Regenerate.
	
	*include/std/memory: Remove extraneous include.

From-SVN: r129765
2007-10-30 05:25:33 +00:00
Benjamin Kosnik
40abbf1f17 c++config (_GLIBCXX_DEPRECATED, [...]): New.
2007-10-29  Benjamin Kosnik  <bkoz@redhat.com>
 
	* include/bits/c++config (_GLIBCXX_DEPRECATED,
	_GLIBCXX_USE_DEPRECATED): New. Adjust comments.
	* include/bits/stl_auto_ptr.h: Move...
	* includse/backward/auto_ptr.h: ...here.
	* include/bits/stl_function.h (binder1st, binder2nd, bind1st,
	bind2nd): Move...
	* include/backward/binders.h: ...here. Deprecate in C++0x.

	* include/tr1_impl/boost_shared_ptr.h: Guard auto_ptr usage.
	* include/std/memory: Same.
	* include/std/streambuf: Consistent use of _GLIBCXX_USE_DEPRECATED.

	* include/backward/strstream: Fix guard macros.
	* include/backward/backward_warning.h: Adjust for all new items.

	* config/abi/pre/gnu.ver: Export basic_streambuf::stossc.
	
	* include/Makefile.am (backward_headers): Adjust.
	* include/Makefile.in: Regenerate.
	* configure: Regenerate.

From-SVN: r129733
2007-10-29 21:13:23 +00:00
Benjamin Kosnik
04d053492e Makefile.am (ext_compat_headers): New.
2007-10-29  Benjamin Kosnik  <bkoz@redhat.com>

	* include/Makefile.am (ext_compat_headers): New.
	* include/Makefile.in: Regenerate.
	* configure: Regenerate.

From-SVN: r129728
2007-10-29 20:20:11 +00:00
Paolo Carlini
245a5fe5c0 stl_algobase.h (_GLIBCXX_MOVE3, [...]): Add.
2007-10-28  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_algobase.h (_GLIBCXX_MOVE3,
	_GLIBCXX_MOVE_BACKWARD3): Add.
	* include/bits/stl_iterator.h (_GLIBCXX_MAKE_MOVE_ITERATOR): Add.
	* include/bits/vector.tcc (vector<>::reserve): Use the latter.
	(vector<>::erase): Use _GLIBCXX_MOVE3.
	* include/bits/deque.tcc (deque<>::erase): Use _GLIBCXX_MOVE3
	and _GLIBCXX_MOVE_BACKWARD3.
	* testsuite/23_containers/vector/modifiers/erase/moveable.cc: New.
	* testsuite/23_containers/vector/capacity/reserve/moveable.cc: New.
	* testsuite/23_containers/deque/modifiers/erase/moveable.cc: New.

From-SVN: r129714
2007-10-29 01:59:49 +00:00
Paolo Carlini
e85b4fa7b5 stl_uninitialized.h (uninitialized_copy): Use ::new and value_type per the letter of the standard.
2007-10-28  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_uninitialized.h (uninitialized_copy): Use
	::new and value_type per the letter of the standard.
	* testsuite/20_util/specialized_algorithms/uninitialized_copy/
	move_iterators/1.cc: New.

	* testsuite/20_util/specialized_algorithms/16505.cc: Move to...
	* testsuite/20_util/specialized_algorithms/uninitialized_fill_n/
	16505.cc: ... here.
	* testsuite/20_util/specialized_algorithms/32158.cc: Move to...
	* testsuite/20_util/specialized_algorithms/uninitialized_fill/
	32158.cc: ... here.

	* include/bits/stl_construct.h (_Construct(_T1*)): Remove, unused.

From-SVN: r129698
2007-10-28 16:03:06 +00:00
Paolo Carlini
f0112db9b3 stl_algobase.h (struct __miter_base): Add.
2007-10-27  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_algobase.h (struct __miter_base): Add.
	(__copy_move_a2, __copy_move_backward_a2): Add.
	(copy, copy_backward, move, move_backward): Adjust, call *a2 helpers.
	* include/bits/cpp_type_traits.h (struct __is_move_iterator): Add.
	* include/bits/streambuf_iterator.h (__copy_move_a<>): Rename
	to __copy_move_a2.
	* include/std/streambuf (friend __copy_move_a<>): Likewise.
	* testsuite/25_algorithms/copy/move_iterators/1.cc: New.
	* testsuite/25_algorithms/copy_backward/move_iterators/1.cc: Likewise.

	* include/bits/stl_iterator.h (__normal_iterator<>::_Iterator_type):
	Rename to iterator_type.

From-SVN: r129678
2007-10-27 12:07:04 +00:00
Paolo Carlini
61fcb9fb0c throw_allocator.h (throw_allocator<>:: construct<>(pointer, _Args&&...)): Add.
2007-10-26  Paolo Carlini  <pcarlini@suse.de>

	* include/ext/throw_allocator.h (throw_allocator<>::
	construct<>(pointer, _Args&&...)): Add.
	* include/ext/pool_allocator.h (__pool_alloc<>::
	construct<>(pointer, _Args&&...)): Likewise.
	(construct(pointer, const _Tp&)): Cast pointer to void*. 
	* include/ext/bitmap_allocator.h (bitmap_allocator<>::
	construct<>(pointer, _Args&&...)): Add.
	(construct(pointer, const _Tp&)): Cast pointer to void*.
	* include/ext/new_allocator.h (new_allocator<>::
	construct<>(pointer, _Args&&...)): Add.
	(construct(pointer, const _Tp&)): Cast pointer to void*.
	* include/ext/malloc_allocator.h (malloc_allocator<>::
	construct<>(pointer, _Args&&...)): Add.
	(construct(pointer, const _Tp&)): Cast pointer to void*.
	* include/ext/array_allocator.h (array_allocator<>::
	construct<>(pointer, _Args&&...)): Add.
	(construct(pointer, const _Tp&)): Cast pointer to void*.
	* include/ext/mt_allocator.h (__mt_alloc<>::
	construct<>(pointer, _Args&&...)): Add.
	(construct(pointer, const _Tp&)): Cast pointer to void*.
	* testsuite/util/testsuite_allocator.h (tracker_allocator<>::
	construct<>(pointer, _Args&&...)): Add.
	(construct(pointer, const _Tp&)): Cast pointer to void*.
 	(uneq_allocator<>::construct<>(pointer, _Args&&...)): Add.
	(construct(pointer, const _Tp&)): Cast pointer to void*.
	* testsuite/ext/mt_allocator/variadic_construct.cc: New.
	* testsuite/ext/new_allocator/variadic_construct.cc: Likewise.
	* testsuite/ext/throw_allocator/variadic_construct.cc: Likewise.
	* testsuite/ext/malloc_allocator/variadic_construct.cc: Likewise.
	* testsuite/ext/pool_allocator/variadic_construct.cc: Likewise.
	* testsuite/ext/bitmap_allocator/variadic_construct.cc: Likewise.
	* testsuite/ext/array_allocator/variadic_construct.cc: Likewise.

From-SVN: r129672
2007-10-27 00:41:21 +00:00
Benjamin Kosnik
3f28024c07 unordered_map: Fix for parallel mode.
2007-10-26  Benjamin Kosnik  <bkoz@redhat.com>

	* include/std/unordered_map: Fix for parallel mode.
	* include/std/unordered_set: Same.

From-SVN: r129654
2007-10-26 14:38:12 +00:00
Andreas Tobler
ef99c95ece Makefile.am (parallel_headers): Remove timing.h.
2007-10-25  Andreas Tobler  <a.tobler@schweiz.org>

	* include/Makefile.am (parallel_headers): Remove timing.h.
	* include/Makefile.in: Regenerate.

From-SVN: r129630
2007-10-25 22:22:40 +02:00
Johannes Singler
740936e08e multiway_merge.h: Removed Timing<inactive_tag>
2007-10-25  Johannes Singler  <singler@ira.uka.de>

      * include/parallel/multiway_merge.h: Removed Timing<inactive_tag>
      * include/parallel/random_shuffle.h: Same
      * include/parallel/set_operations.h: Same
      * include/parallel/tree.h: Same
      * include/parallel/multiway_mergesort.h: Same
      * include/parallel/timing.h: Removed completely

From-SVN: r129629
2007-10-25 17:07:56 +00:00
Paolo Carlini
1fcd0a2c50 stl_algo.h (__lg<>(_Size)): Slightly tweak.
2007-10-25  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_algo.h (__lg<>(_Size)): Slightly tweak.
	(__lg(int), __lg(long), __lg(long long)): Add, overloads
	exploiting __builtin_clz*.

From-SVN: r129624
2007-10-25 10:11:58 +00:00
Paolo Carlini
32e520abfc array (_M_instance): Align naturally.
2007-10-24  Paolo Carlini  <pcarlini@suse.de>

	* include/tr1_impl/array (_M_instance): Align naturally.
	* testsuite/ext/array_allocator/1.cc: Use ext/vstring,
	more solid than our current basic_string vs alignment.
	* testsuite/ext/array_allocator/2.cc: Likewise.
	* testsuite/ext/array_allocator/3.cc: Likewise.

From-SVN: r129604
2007-10-24 15:21:22 +00:00
Paolo Carlini
85799c607b stl_move.h (_GLIBCXX_MOVE): Wrap in parentheses.
2007-10-20  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_move.h (_GLIBCXX_MOVE): Wrap in parentheses.
	* include/bits/stl_algobase.h (__niter_base<>): Pass iterators
	by value, as everywhere else.

From-SVN: r129509
2007-10-20 10:08:29 +00:00
Paolo Carlini
b59d6a2bba random (uniform_int<>::_M_call(_UniformRandomNumberGenerator&, result_type, result_type, true_type)): Fix small thinko.
2007-10-20  Paolo Carlini  <pcarlini@suse.de>

	* include/tr1_impl/random
	(uniform_int<>::_M_call(_UniformRandomNumberGenerator&, result_type,
	result_type, true_type)): Fix small thinko.

From-SVN: r129506
2007-10-20 10:02:09 +00:00
Paolo Carlini
23e8722aed re PR libstdc++/33815 (tr1::uniform_int isn't uniform)
2007-10-19  Paolo Carlini  <pcarlini@suse.de>

	PR libstdc++/33815
	* include/tr1_impl/random
	(uniform_int<>::_M_call(_UniformRandomNumberGenerator&, result_type,
	result_type, true_type)): Avoid the modulo (which uses the low-order
	bits).

From-SVN: r129493
2007-10-19 17:36:03 +00:00
Paolo Carlini
3c167a8bbb stl_algobase.h (struct __cm_assign, [...]): Add.
2007-10-19  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_algobase.h (struct __cm_assign,
	struct __copy_move, struct __copy_move_backward, move,
	move_backward): Add.
	(struct __copy, struct __copy_backward): Remove.
	(__copy_aux, __copy_backward_aux): Rename to...
	(__copy_move_a, __copy_move_backward_a): ... this, and
	adjust calls.
	(copy, copy_backward): Adjust calls.
	* include/bits/streambuf_iterator.h (__copy_aux): Rename
	to ...
	(__copy_move_a): ... this; add bool template parameter.
	* include/std/streambuf: Adjust friend declarations.
	* testsuite/util/testsuite_iterators.h
	(WritableObject<>::operator=(U&&)): Add.
	* testsuite/25_algorithms/move/1.cc: New.
	* testsuite/25_algorithms/move/requirements/
	explicit_instantiation/2.cc: Likewise.
	* testsuite/25_algorithms/move/requirements/
	explicit_instantiation/pod.cc: Likewise.
	* testsuite/25_algorithms/move_backward/1.cc: Likewise.
	* testsuite/25_algorithms/move_backward/requirements/
	explicit_instantiation/2.cc: Likewise.
	* testsuite/25_algorithms/move_backward/requirements/
	explicit_instantiation/pod.cc: Likewise.

From-SVN: r129492
2007-10-19 17:04:59 +00:00
Kaz Kojima
1a1349d050 05_comp_ellint_2/check_nan.cc: Add -mieee for sh.
* testsuite/tr1/5_numerical_facilities/special_functions/
	05_comp_ellint_2/check_nan.cc: Add -mieee for sh.

From-SVN: r129465
2007-10-18 23:22:23 +00:00
Paolo Carlini
67202da49d allocator.h (struct __alloc_neq): Add.
2007-10-18  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/allocator.h (struct __alloc_neq): Add.
	* include/bits/stl_list.h (list<>::_M_check_equal_allocators): Use it.

From-SVN: r129457
2007-10-18 19:31:22 +00:00
Benjamin Kosnik
e63637ea90 re PR libstdc++/30085 (switch debug mode hash containers from ext to tr1)
2007-10-18  Benjamin Kosnik  <bkoz@redhat.com>

	* include/ext/hash_map: To...
	* include/backward/hash_map: ...here. Remove debug mode.
	* include/ext/hash_set: To...
	* include/backward/hash_set: ...here. Remove debug mode.
	* include/ext/hash_fun.h: To...
	* include/backward/hash_fun.h: ...here.
	* include/ext/hashtable.h: To...
	* include/backward/hashtable.h: ...here.
	
	* include/bits/c++config: Remove __gnu_cxx namespace from debug mode.
	* include/debug/debug.h: Same.
		
	* include/debug/hash_map: Remove.
	* include/debug/hash_multimap.h: Remove.
	* include/debug/hash_set.h: Remove.
	* include/debug/hash_set: Remove.
	* include/debug/hash_multiset.h: Remove.
	* include/debug/hash_map.h: Remove.
	
	* include/Makefile.am (ext_headers): Move hash_set, hash_map to
	backward.
	(debug_headers): Remove hash_map, hash_set, hash_map.h,
	hash_map.h, hash_multiset.h, hash_multimap.h.	
	* include/Makefile.in: Regenerate.

	* docs/html/debug.html: Update.
	* docs/html/ext/howto.html: Same.
	* docs/html/faq/index.html: Same.
	* docs/doxygen/Intro.3: Same.
	* docs/doxygen/user.cfg.in: Adjust includes.
	* testsuite/ext/hash_map: Move to...
	* testsuite/backward/hash_map: ...here.
	* testsuite/ext/hash_set: Move to...
	* testsuite/backward/hash_set: ...here.
	
2007-10-18  Benjamin Kosnik  <bkoz@redhat.com>
        
	Removal of pre-ISO C++ items from include/backwards.
	* include/Makefile.am (backward_headers): Remove all but strstream,
	backward_warning.h.
	* include/Makefile.in: Regenerate.
	* include/backward/new.h: Remove.
	* include/backward/iterator.h: Same.
	* include/backward/alloc.h: Same.
	* include/backward/set.h: Same.
	* include/backward/hashtable.h: Same.
	* include/backward/hash_set.h: Same.
	* include/backward/fstream.h: Same.
	* include/backward/tempbuf.h: Same.
	* include/backward/istream.h: Same.
	* include/backward/bvector.h: Same.
	* include/backward/stack.h: Same.
	* include/backward/rope.h: Same.
	* include/backward/complex.h: Same.
	* include/backward/ostream.h: Same.
	* include/backward/heap.h: Same.
	* include/backward/iostream.h: Same.
	* include/backward/function.h: Same.
	* include/backward/multimap.h: Same.
	* include/backward/pair.h: Same.
	* include/backward/stream.h: Same.
	* include/backward/iomanip.h: Same.
	* include/backward/slist.h: Same.
	* include/backward/tree.h: Same.
	* include/backward/vector.h: Same.
	* include/backward/deque.h: Same.
	* include/backward/multiset.h: Same.
	* include/backward/defalloc.h: Same.
	* include/backward/list.h: Same.
	* include/backward/map.h: Same.
	* include/backward/algobase.h: Same.
	* include/backward/hash_map.h: Same.
	* include/backward/algo.h: Same.
	* include/backward/queue.h: Same.
	* include/backward/streambuf.h: Same.
	* testsuite/backward/header_hash_set_h.cc: Same.
	* testsuite/backward/header_slist_h.cc: Same.
	* testsuite/backward/header_hash_map_h.cc: Same.
	* testsuite/backward/header_tempbuf_h.cc: Same.
	* testsuite/backward/header_deque_h.cc: Same.
	* testsuite/backward/header_rope_h.cc: Same.
	* testsuite/backward/header_iterator_h.cc: Same.
	* testsuite/backward/header_hashtable_h.cc: Same.

2007-10-18  Benjamin Kosnik  <bkoz@redhat.com>

	PR libstdc++/30085
	* include/debug/unordered_map: New.
	* include/debug/unordered_set: New.
	* include/debug/safe_association.h: New.	
	* include/std/unordered_map: Include debug header if _GLIBCXX_DEBUG.
	* include/std/unordered_set: Same.
	* include/Makefile.am (debug_headers): Add unordered_map,
	unordered_set, safe_association.h.
	* include/Makefile.in: Regenerate.
	* testsuite/23_containers/unordered_map/requirements/debug.cc: New.
	* testsuite/23_containers/unordered_multimap/requirements/
	debug.cc: New.
	* testsuite/23_containers/unordered_set/requirements/debug.cc: New.
	* testsuite/23_containers/unordered_multiset/requirements/
	debug.cc: New.

2007-10-18  Benjamin Kosnik  <bkoz@redhat.com>
	
	* testsuite/util/native_type/assoc/native_hash_multimap.hpp: Remove
	hash_map include.

From-SVN: r129442
2007-10-18 15:22:58 +00:00
Paolo Carlini
741e7594be re PR libstdc++/33807 (Incorrect ambiguous overload)
2007-10-18  Paolo Carlini  <pcarlini@suse.de>

	PR libstdc++/33807
	* include/bits/allocator.h (operator==(const allocator<_Tp>&,
	const allocator<_Tp>&), operator!=(const allocator<_Tp>&,
	const allocator<_Tp>&)): Add.
	* testsuite/20_util/allocator/33807.cc: New.

From-SVN: r129434
2007-10-18 10:00:18 +00:00
Paolo Carlini
394033f804 cpp_type_traits.h (__is_byte): Add.
2007-10-17  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/cpp_type_traits.h (__is_byte): Add.
	* include/bits/stl_algobase.h (struct __fill, struct __fill_n,
	__fill_aux, __fill_n_aux): Remove.
	(__fill_a, __fill_n_a): Add.
	(fill, fill_n): Adjust.

From-SVN: r129421
2007-10-17 21:21:13 +00:00
Paolo Carlini
45d506995c stl_iterator.h (back_insert_iterator<>::operator= (typename _Container::value_type&&), [...]): Add.
2007-10-17  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_iterator.h (back_insert_iterator<>::operator=
	(typename _Container::value_type&&), front_insert_iterator<>::
	operator=(typename _Container::value_type&&), insert_iterator<>::
	operator=(typename _Container::value_type&&)): Add.

	* include/bits/stl_iterator.h (insert_iterator<>::operator=
	(typename _Container::const_reference)): Fix typo in signature.

From-SVN: r129413
2007-10-17 17:44:09 +00:00
Paolo Carlini
5f708c5444 array: Correct macro guarding cbegin, cend, crbegin, crend.
2007-10-17  Paolo Carlini  <pcarlini@suse.de>

	* include/tr1_impl/array: Correct macro guarding cbegin, cend,
	crbegin, crend.
	* include/tr1_impl/hashtable: Likewise.

From-SVN: r129404
2007-10-17 09:45:04 +00:00
Paolo Carlini
07d8d70f3f vstring.h (__versa_string<>::front, [...]): Add.
2007-10-16  Paolo Carlini  <pcarlini@suse.de>

	* include/ext/vstring.h (__versa_string<>::front, 
	__versa_string<>::back): Add.
	* testsuite/ext/vstring/element_access/char/front_back.cc: New.
	* testsuite/ext/vstring/element_access/wchar_t/front_back.cc: Likewise.

From-SVN: r129399
2007-10-17 00:46:27 +00:00
Paolo Carlini
7aa1cb97eb stl_queue.h (queue<>::queue(_Sequence&&), [...]): Add.
2007-10-16  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_queue.h (queue<>::queue(_Sequence&&),
	queue<>::queue(queue&&), queue<>::operator=(queue&&),
	queue<>::push(value_type&&), queue<>::swap(queue&&),
	swap(queue<>&, queue<>&), swap(queue<>&&, queue<>&),
	swap(queue<>&, queue<>&&), priority_queue<>::
	priority_queue(const _Compare&, _Sequence&&),
	priority_queue<>::priority_queue(_InputIterator, _InputIterator,
	const _Compare&, _Sequence&&),
	priority_queue<>::priority_queue(priority_queue&&),
	priority_queue<>::operator=(priority_queue&&),
	priority_queue<>::push(value_type&&),
	priority_queue<>::swap(priority_queue&&),
	swap(priority_queue<>&, priority_queue<>&),
	swap(priority_queue<>&&, priority_queue<>&),
	swap(priority_queue<>&, priority_queue<>&&)): Add.
	* include/bits/stl_stack.h (stack<>::stack(_Sequence&&),
	stack<>::push(value_type&&), stack<>::swap(stack&&),
	swap(stack<>&, stack<>&), swap(stack<>&&, stack<>&),
	swap(stack<>&, stack<>&&)): Add.
	* testsuite/23_containers/queue/moveable.cc: New.
	* testsuite/23_containers/priority_queue/moveable.cc: Likewise.

From-SVN: r129390
2007-10-16 21:54:41 +00:00
Paolo Carlini
053cc3801b vstring.h (__versa_string<>:: __versa_string(__versa_string&&), [...]): Add.
2007-10-16  Paolo Carlini  <pcarlini@suse.de>

	* include/ext/vstring.h (__versa_string<>::
	__versa_string(__versa_string&&),
	__versa_string<>::operator=(__versa_string&&,
	swap(__versa_string<>&&, __versa_string<>&),
	swap(__versa_string<>(&, __versa_string<>&&)): Add.
	(__versa_string<>::swap(__versa_string&&)): Adjust for C++0x.
	* include/ext/sso_string_base.h
	(__sso_string_base(__sso_string_base&&)): Add.
	(__sso_string_base()): Use _Alloc_hider(_CharT*).
	* include/ext/rc_string_base.h (__rc_string_base(__rc_string_base&&)):
	Add.
	(__rc_string_base()): Use _Alloc_hider(_CharT*).
	* include/ext/vstring_util.h (_Alloc_hider::_Alloc_hider(_CharT*)):
	Add.
	* testsuite/ext/vstring/moveable.cc: Add.

	* include/bits/stl_tree.h (_Rb_tree(_Rb_tree&&)): Add.
	* include/bits/stl_map.h (map<>::map(map&&)): Forward to the latter.
	* include/bits/stl_set.h (set<>::set(set&&)): Likewise.
	* include/bits/stl_multimap.h (multimap<>::multimap(multimap&&)):
	Likewise.
	* include/bits/stl_multiset.h (multiset<>::multiset(multiset&&)):
	Likewise.
	* include/bits/stl_deque.h (_Deque_base<>::_Deque_base(_Deque_base&&)):
	Add.
	(deque<>::deque(deque&&)): Forward to the latter.
	* include/bits/stl_list.h (_List_base<>::_List_base(_List_base&&)):
	Add.
	(list<>::list(list&&)): Forward to the latter.
	* include/bits/stl_vector.h
	(_Vector_base<>::_Vector_base(_Vector_base&&)): Add.
	(vector<>::vector(vector&&)): Forward to the latter.
	* include/bits/stl_bvector.h
	(_Bvector_base<>::_Bvector_base(_Bvector_base&&)): Add.
	(vector<bool>::vector(vector&&)): Forward to the latter.

	* testsuite/23_containers/vector/requirements/dr438/assign_neg.cc:
	Adjust dg-error lines.
	* testsuite/23_containers/vector/requirements/dr438/insert_neg.cc:
	Likewise.
	* 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/deque/requirements/dr438/assign_neg.cc:
	Likewise.
	* testsuite/23_containers/deque/requirements/dr438/insert_neg.cc:
	Likewise.
	* testsuite/23_containers/deque/requirements/dr438/
	constructor_1_neg.cc: Likewise.
	* testsuite/23_containers/deque/requirements/dr438/
	constructor_2_neg.cc: Likewise.
	* testsuite/23_containers/list/requirements/dr438/assign_neg.cc:
	Likewise.
	* testsuite/23_containers/list/requirements/dr438/insert_neg.cc:
	Likewise.
	* testsuite/23_containers/list/requirements/dr438/
	constructor_1_neg.cc: Likewise.
	* testsuite/23_containers/list/requirements/dr438/
	constructor_2_neg.cc: Likewise.

From-SVN: r129381
2007-10-16 15:20:09 +00:00
Paolo Carlini
0cd50f8913 set.h (set<>::cbegin, [...]): Add.
2007-10-15  Paolo Carlini  <pcarlini@suse.de>

	* include/debug/set.h (set<>::cbegin, cend, crbegin, crend): Add.
	* include/debug/multiset.h (set<>::cbegin, cend, crbegin, crend):
	Likewise.
	* include/debug/vector (vector<>::cbegin, cend, crbegin, crend):
	Likewise.
	* include/debug/map.h (map<>::cbegin, cend, crbegin, crend):
	Likewise.
	* include/debug/deque (deque<>::cbegin, cend, crbegin, crend): 
	Likewise.
	* include/debug/list (list<>::cbegin, cend, crbegin, crend):
	Likewise.
	* include/debug/multimap.h (multimap<>::cbegin, cend, crbegin,
	crend): Likewise.
	* include/tr1_impl/array (array<>::cbegin, cend, crbegin, crend):
	Likewise.
	* include/ext/vstring.h (__versa_string<>::cbegin, cend, crbegin,
	crend): Likewise.
	* include/bits/stl_list.h (list<>::cbegin, cend, crbegin, crend):
	Likewise.
	* include/bits/stl_map.h (map<>::cbegin, cend, crbegin, crend):
	Likewise.
	* include/bits/stl_set.h (set<>::cbegin, cend, crbegin, crend):
	Likewise.
	* include/bits/stl_multimap.h (multimap<>::cbegin, cend, crbegin,
	crend): Likewise.
	* include/bits/stl_vector.h (vector<>::cbegin, cend, crbegin, crend):
	Likewise.
	* include/bits/stl_deque.h (deque<>::cbegin, cend, crbegin, crend):
	Likewise.
	* include/bits/stl_multiset.h (multiset<>::cbegin, cend, crbegin,
	crend): Likewise.
	* include/bits/stl_bvector.h (vector<bool>::cbegin, cend, crbegin,
	crend): Likewise.
	* include/tr1_impl/hashtable (_Hashtable<>::cbegin, cend): Add.	

	* testsuite/ext/vstring/requirements/citerators.cc: Add.
	* testsuite/23_containers/unordered_map/requirements/citerators.cc:
	Likewise.
	* testsuite/23_containers/multimap/requirements/citerators.cc:
	Likewise.
	* testsuite/23_containers/set/requirements/citerators.cc: Likewise.
	* testsuite/23_containers/unordered_multimap/requirements/
	citerators.cc: Likewise.
	* testsuite/23_containers/unordered_set/requirements/citerators.cc:
	Likewise.
	* testsuite/23_containers/vector/requirements/citerators.cc: Likewise.
	* testsuite/23_containers/vector/bool/requirements/citerators.cc:
	Likewise.
	* testsuite/23_containers/deque/requirements/citerators.cc: Likewise.
	* testsuite/23_containers/multiset/requirements/citerators.cc:
	Likewise.
	* testsuite/23_containers/list/requirements/citerators.cc: Likewise.
	* testsuite/23_containers/unordered_multiset/requirements/
	citerators.cc: Likewise.
	* testsuite/23_containers/map/requirements/citerators.cc: Likewise.
	* testsuite/23_containers/array/requirements/citerators.cc: Likewise.

	* testsuite/23_containers/vector/requirements/dr438/assign_neg.cc:
	Adjust dg-error lines.
	* testsuite/23_containers/vector/requirements/dr438/insert_neg.cc:
	Likewise.
	* 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/deque/requirements/dr438/assign_neg.cc:
	Likewise.
	* testsuite/23_containers/deque/requirements/dr438/insert_neg.cc:
	Likewise.
	* testsuite/23_containers/deque/requirements/dr438/
	constructor_1_neg.cc: Likewise.
	* testsuite/23_containers/deque/requirements/dr438/
	constructor_2_neg.cc: Likewise.
	* testsuite/23_containers/list/requirements/dr438/assign_neg.cc:
	Likewise.
	* testsuite/23_containers/list/requirements/dr438/insert_neg.cc:
	Likewise.
	* testsuite/23_containers/list/requirements/dr438/
	constructor_1_neg.cc: Likewise.
	* testsuite/23_containers/list/requirements/dr438/
	constructor_2_neg.cc: Likewise.

From-SVN: r129370
2007-10-15 20:51:53 +00:00
Paolo Carlini
488fa69898 PR libstdc++/33773 (cont)
2007-10-15  Paolo Carlini  <pcarlini@suse.de>

	PR libstdc++/33773 (cont)
	* testsuite/21_strings/headers/cwchar/macros.cc: Guard with
	_GLIBCXX_USE_WCHAR_T, instead.

From-SVN: r129316
2007-10-15 13:43:33 +00:00
Paolo Carlini
5c7c209b1f re PR libstdc++/33771 (FAIL: 17_intro/headers/c++1998/all.cc (test for excess errors))
2007-10-15  Paolo Carlini  <pcarlini@suse.de>

	PR libstdc++/33771
	PR libstdc++/33773
	* testsuite/21_strings/headers/cwchar/macros.cc: Guard test with
	_GLIBCXX_HAVE_WCHAR_H.
	* testsuite/21_strings/headers/cwctype/macros.cc: Likewise with
	_GLIBCXX_HAVE_WCTYPE_H.
	* testsuite/17_intro/headers/c++200x/all.cc: Guard inclusions
	of <wchar.h> and <wctype.h>.
	* testsuite/17_intro/headers/c++200x/all_multiple_inclusion.cc:
	Likewise.
	* testsuite/17_intro/headers/c++1998/all.cc: Likewise.
	* testsuite/17_intro/headers/c++1998/all_multiple_inclusion.cc:
	Likewise.

From-SVN: r129314
2007-10-15 09:34:56 +00:00
Paolo Carlini
54bdca68ec re PR libstdc++/33771 (FAIL: 17_intro/headers/c++1998/all.cc (test for excess errors))
2007-10-15  Paolo Carlini  <pcarlini@suse.de>

	PR libstdc++/33771
	PR libstdc++/33773
	* testsuite/21_strings/headers/cwchar/macros.cc: Guard test with
	_GLIBCXX_HAVE_WCHAR_H.
	* testsuite/21_strings/headers/cwctype/macros.cc: Likewise with
	_GLIBCXX_HAVE_WCTYPE_H.
	* testsuite/17_intro/headers/c++200x/all.cc: Guard inclusions
	of <wchar.h> and <wctype.h>.
	* testsuite/17_intro/headers/c++200x/all_multiple_inclusion.cc:
	Likewise.
	* testsuite/17_intro/headers/c++1998/all.cc: Likewise.
	* testsuite/17_intro/headers/c++1998/all_multiple_inclusion.cc:
	Likewise.

From-SVN: r129313
2007-10-15 09:34:49 +00:00
Paolo Carlini
4b7ed13a8f stl_algo.h (is_sorted, [...]): Add.
2007-10-14  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_algo.h (is_sorted, is_sorted_until): Add.
	* include/bits/algorithmfwd.h: Add.
	* include/ext/algorithm: Adjust.
	* testsuite/25_algorithms/is_sorted/requirements/
	explicit_instantiation/2.cc: New.
	* testsuite/25_algorithms/is_sorted/requirements/
	explicit_instantiation/pod.cc: Likewise.
	* testsuite/25_algorithms/is_sorted/1.cc: Likewise.
	* testsuite/25_algorithms/is_sorted_until/requirements/
	explicit_instantiation/2.cc: Likewise.
	* testsuite/25_algorithms/is_sorted_until/requirements/
	explicit_instantiation/pod.cc: Likewise.
	* testsuite/25_algorithms/is_sorted_until/1.cc: Likewise.
	* testsuite/25_algorithms/headers/algorithm/synopsis.cc:
	Add is_sorted and is_sorted_until.

	* include/bits/stl_heap.h (is_heap_until): Add concept and
	debug-mode checks.

From-SVN: r129303
2007-10-14 21:17:23 +00:00
Paolo Carlini
e69f1bad5d stl_heap.h (__is_heap_until): Add.
2007-10-12  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_heap.h (__is_heap_until): Add.
	(__is_heap(_RandomAccessIterator, _Distance),
	__is_heap(_RandomAccessIterator, _Compare, _Distance)):
	Adjust, call the latter.
	(is_heap, is_heap_until): Add, call the above.
	* include/bits/algorithmfwd.h: Add.
	* testsuite/25_algorithms/is_heap/requirements/
	explicit_instantiation/2.cc: New.
	* testsuite/25_algorithms/is_heap/requirements/
	explicit_instantiation/pod.cc: Likewise.
	* testsuite/25_algorithms/is_heap/1.cc: Likewise.
	* testsuite/25_algorithms/is_heap_until/requirements/
	explicit_instantiation/2.cc: Likewise.
	* testsuite/25_algorithms/is_heap_until/requirements/
	explicit_instantiation/pod.cc: Likewise.
	* testsuite/25_algorithms/is_heap_until/1.cc: Likewise.
	* testsuite/25_algorithms/headers/algorithm/synopsis.cc:
	Add is_heap and is_heap_until.

From-SVN: r129266
2007-10-12 16:26:03 +00:00
Benjamin Kosnik
ece84738e7 user.cfg.in: Scan tr1_impl/hashtable.
2007-10-12  Benjamin Kosnik  <bkoz@redhat.com>

	* docs/doxygen/user.cfg.in: Scan tr1_impl/hashtable.
	* include/tr1_impl/hashtable: Correct comment.

	* include/ext/hash_map: Remove extraneous public markers.
	* include/ext/hash_set: Same.

	* testsuite/25_algorithms/headers/parallel_algorithm.cc: Move
	inside algorithm directory.	
	* testsuite/25_algorithms/headers/algorithm_parallel_mode.cc: Same.
	* testsuite/25_algorithms/headers/parallel_algorithm_mixed1.cc: Same.
	* testsuite/25_algorithms/headers/parallel_algorithm_mixed2.cc: Same.
	* testsuite/25_algorithms/headers/algorithm/parallel_algorithm.cc:
	To this.	
	* testsuite/25_algorithms/headers/algorithm/
	algorithm_parallel_mode.cc: Same.
	* testsuite/25_algorithms/headers/algorithm/
	parallel_algorithm_mixed1.cc: Same.
	* testsuite/25_algorithms/headers/algorithm/
	parallel_algorithm_mixed2.cc: Same.

	* testsuite/21_strings/basic_string/requirements/
	explicit_instantiation/debug.cc: Remove exception text.
	
	* testsuite/23_containers/vector/bool/modifiers/insert/31370.cc:
	Fix for debug mode testing.	
	* testsuite/23_containers/vector/bool/capacity/29134.cc: Same.

From-SVN: r129264
2007-10-12 16:11:41 +00:00
Jesper Nilsson
1de1af77d6 20_riemann_zeta/check_value_neg.c (MAX_ITERATIONS): Add limit when target is simulator.
2007-10-12  Jesper Nilsson  <jesper.nilsson@axis.com>

       * testsuite/tr1/5_numerical_facilities/special_functions/
       20_riemann_zeta/check_value_neg.c (MAX_ITERATIONS): Add limit
       when target is simulator.
       * testsuite/tr1/5_numerical_facilities/special_functions/
       20_riemann_zeta/check_value_pos.c (MAX_ITERATIONS): Likewise.

From-SVN: r129258
2007-10-12 10:23:55 +00:00
Roger Sayle
8885751219 acinclude.m4 (GLIBCXX_CHECK_SYSTEM_ERROR): Add EOVERFLOW for Tru64.
* acinclude.m4 (GLIBCXX_CHECK_SYSTEM_ERROR): Add EOVERFLOW for Tru64.
	* configure: Regenerate.
	* config/os/generic/error_constants.h: Guard.
	* testsuite/19_diagnostics/headers/system_error/
	types_std_c++0x.cc: Same.

From-SVN: r129245
2007-10-11 23:22:22 +00:00
Benjamin Kosnik
0c3de9003f Convert ext/hash_map, set to tr1/functional, tr1/unordered_map, set.
2007-10-11  Benjamin Kosnik  <bkoz@redhat.com>

	Convert ext/hash_map, set to tr1/functional, tr1/unordered_map, set.
	* include/ext/rope: Use tr1/functional hash instead of ext/hash_fun.h.
	* include/ext/pb_ds/detail/standard_policies.hpp: Same.
	* include/precompiled/extc++.h: Remove hash_map, hash_set.
	* testsuite/util/testsuite_abi.h (__gnu_cxx): Use unordered_map
	instead of hash_map. Remove hash specialization for string.
	* testsuite/util/testsuite_abi.cc: Include <vector>.
	* testsuite/util/native_type/assoc/native_hash_set.hpp: Remove
	hash_set code.
	* testsuite/util/native_type/assoc/native_hash_map.hpp: Remove
	hash_map code.
	* testsuite/util/native_type/assoc/native_hash_multimap.hpp:
	Change hash_multimap to unordered_multimap.
	* testsuite/util/testsuite_common_types.h: Remove hash_map, hash_set.
	* testsuite/ext/headers.cc: Same.
	* testsuite/17_intro/headers/all_c++200x_compatibility.cc: Remove
	hash_map.h, hash_set.h.
	* testsuite/17_intro/headers/all.cc: Same.
	* testsuite/17_intro/headers/all_pedantic_errors.cc: Same.

	* include/ext/pb_ds/detail/standard_policies.hpp: Format.
	* testsuite/util/native_type/assoc/native_set.hpp: Same, 
	update comment.
	* testsuite/util/native_type/assoc/native_map.hpp: Same.
	* testsuite/util/native_type/assoc/native_multimap.hpp: Same.
	* testsuite/util/performance/assoc/timing/
	multimap_insert_test.hpp: Same.
	* testsuite/util/performance/assoc/timing/multimap_find_test.hpp: Same.

From-SVN: r129243
2007-10-11 21:48:54 +00:00
Chris Jefferson
d70e9d8156 stl_heap.h (__push_heap, [...]): Use _GLIBCXX_MOVE.
2007-10-11  Chris Jefferson  <chris@bubblescope.net>
	    Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_heap.h (__push_heap, push_heap, __adjust_heap,
	make_heap): Use _GLIBCXX_MOVE.
	(__pop_heap): Likewise, adjust signature.
	(pop_heap): Adjust __pop_heap call.
	* include/bits/stl_algo.h (__heap_select): Likewise.
	* testsuite/25_algorithms/heap/moveable.cc: Remove dg-require-rvalref.
	* testsuite/25_algorithms/partial_sort/moveable.cc: Likewise.

Co-Authored-By: Paolo Carlini <pcarlini@suse.de>

From-SVN: r129237
2007-10-11 17:56:31 +00:00
Paolo Carlini
5f23223201 re PR libstdc++/33734 (iconv_t must not be assumed to be a pointer)
2007-10-11  Paolo Carlini  <pcarlini@suse.de>

	PR libstdc++/33734
	* include/ext/codecvt_specializations.h (encoding_state::good,
	init, destroy): Use cast notation instead of reinterpret_cast.

From-SVN: r129232
2007-10-11 10:50:09 +00:00
Paolo Carlini
a6bda7d08b moveable.cc: Fix and extend.
2007-10-11  Paolo Carlini  <pcarlini@suse.de>

	* testsuite/25_algorithms/heap/moveable.cc: Fix and extend.

From-SVN: r129231
2007-10-11 10:04:55 +00:00
Danny Smith
cccc4450ce re PR libstdc++/33578 (__gnu_parallel::yield means what?)
PR libstdc++/33578
	* include/parallel/compatibility.h.  Use POSIX sched_yield on
	__CYGWIN__ 
	(Sleep): Add prototype for __MINGW32__.

From-SVN: r129219
2007-10-10 23:39:30 +00:00
Jason Merrill
b0bb87a862 guard.cc (struct mutex_wrapper): Move into anonymous namespace.
* libsupc++/guard.cc (struct mutex_wrapper): Move into
        anonymous namespace.

From-SVN: r129218
2007-10-10 19:06:08 -04:00
Paolo Carlini
cc8c030d88 list (list<>::list(list&&)): Fix.
2007-10-10  Paolo Carlini  <pcarlini@suse.de>

	* include/debug/list (list<>::list(list&&)): Fix.
	* include/debug/vector (vector<>::vector(vector&&)): Likewise.
	* include/debug/deque (deque<>::deque(deque&&)): Likewise.
	* include/debug/set.h (set<>::set(set&&)): Likewise.
	* include/debug/map.h (map<>::map(map&&)): Likewise.
	* include/debug/multiset.h (multiset<>::multiset(multiset&&)):Likewise.
	* include/debug/multimap.h (multimap<>::multimap(multimap&&)):Likewise.

From-SVN: r129213
2007-10-10 17:31:28 +00:00
Benjamin Kosnik
c456e6f17c re PR libstdc++/33633 (-D_GLIBCXX_DEBUG vs ext/hash_*)
2007-10-10  Benjamin Kosnik  <bkoz@redhat.com>

	PR libstdc++/33633
	* include/debug/hash_multimap.h: Change _GLIBCXX_EXT to _GLIBCXX_EXT_D.
	* include/debug/hash_set.h: Same.
	* include/debug/hash_multiset.h: Same.
	* include/debug/hash_map.h: Same.

2007-10-10  Benjamin Kosnik  <bkoz@redhat.com>

	* include/parallel/losertree.h (loser_tree_traits_unguarded): To 
	loser_tree_unguarded_traits.
	* include/parallel/multiway_merge.h (__gnu_parallel): Same.

From-SVN: r129210
2007-10-10 15:23:59 +00:00
Paolo Carlini
e14e932bbb stl_algobase.h (swap): Move...
2007-10-10  Paolo Carlini  <pcarlini@suse.de>
	    Chris Fairles  <chris.fairles@gmail.com>

	* include/bits/stl_algobase.h (swap): Move...
	* include/bits/stl_move.h: ... here.
	* include/bits/stl_pair.h (pair<>::pair(_U1&&, _U2&&),
	pair<>::pair(pair<>&&), pair<>::operator=(pair<>&&),
	pair<>::swap(pair&&), swap(&, &), swap(&&, &), swap(&, &&),
	make_pair(_T1&&, _T2&&)): Add.
	* testsuite/20_util/pair/swap.cc: Add.

Co-Authored-By: Chris Fairles <chris.fairles@gmail.com>

From-SVN: r129198
2007-10-10 09:29:11 +00:00
Wolfgang Bangerth
c891154fad PR libstdc++/33485 continued.
2007-10-09  Wolfgang Bangerth  <bangerth@dealii.org>

	PR libstdc++/33485 continued.
	* include/parallel/multiway_mergesort.h: Use __builtin_alloca.

From-SVN: r129182
2007-10-09 21:51:06 +00:00
Zhou Drangon
3c8b6c602e re PR libstdc++/33682 (libstdc++ broken for !__GTHREAD_HAS_COND hosts)
2007-10-09  Zhou Drangon  <drangon.mail@gmail.com>

	PR libstdc++/33682
        * libsupc++/guard.cc: Make single conditional variable
        implementation dependent to __GTHREAD_HAS_COND.

From-SVN: r129181
2007-10-09 21:24:31 +00:00
Benjamin Kosnik
dfbed39786 PR libstdc++/33489 continued.
2007-10-09  Benjamin Kosnik  <bkoz@montsouris.artheist.org>

	PR libstdc++/33489 continued.		
	* include/parallel/features.h (_GLIBCXX_LOSER_TREE): Set to zero.
	(_GLIBCXX_LOSER_TREE_POINTER): Set to one.
	(_GLIBCXX_LOSER_TREE_UNGUARDED): Set to zero.
	(_GLIBCXX_LOSER_TREE_POINTER_UNGUARDED): Set to one.
	* include/parallel/multiway_merge.h (parallel_multiway_merge):
	Change array of value_type to array of value_type pointers.
 	(multiway_merge_bubble): Same.
	(multiway_merge_loser_tree): Same.
	* include/parallel/merge.h (merge_advance_movc): Change to avoid
	default construction.
	* include/parallel/multiseq_selection.h (multiseq_partition):
	Replace value_type, bool pair with value_type*, null-initialized.
	* include/parallel/multiway_mergesort.h (parallel_sort_mwms):
	Don't use array form of operator new for value_types.
	(parallel_sort_mwms_pu): Same.
	* include/parallel/quicksort.h (parallel_sort_qs_divide): Don't
	use array form to construct pointer to value_type on stack,
	instead use __builtin_alloca.	
	* include/parallel/random_shuffle.h (sequential_random_shuffle): Same,
	but use operator new.
	(parallel_random_shuffle_drs_pu): Same.
	* include/parallel/partial_sum.h ( parallel_partial_sum_linear): Same.

	* include/parallel/losertree.h: Format.
	* include/parallel/settings.h: Format.

	* include/parallel/multiway_merge.h: Move traits to....
	* include/parallel/losertree.h: ... here.

From-SVN: r129179
2007-10-09 20:48:38 +00:00
Paolo Carlini
beb1b47587 type_traitsfwd.h (add_reference): Remove.
2007-10-09  Paolo Carlini  <pcarlini@suse.de>

	* include/tr1_impl/type_traitsfwd.h (add_reference): Remove.
	* include/tr1/type_traits (add_reference): Add forward declaration.
	* include/tr1_impl/functional (class _Mu<>): Fix.

From-SVN: r129171
2007-10-09 17:17:33 +00:00
Paolo Carlini
56a51b00a9 boost_concept_check.h (*AssociativeContainerConcept): Remove, unused.
2007-10-09  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/boost_concept_check.h (*AssociativeContainerConcept):
	Remove, unused.

From-SVN: r129165
2007-10-09 13:30:56 +00:00
Johannes Singler
0e6c9eaa5c base.h: Added plus and multiplies functor for differently typed objects.
2007-10-08  Johannes Singler  <singler@ira.uka.de>

	* include/parallel/base.h: Added plus and multiplies functor
       for differently typed objects.
	* include/parallel/numeric: Use it.
	* include/parallel/for_each_selectors.h: Allowed different types.
	* include/parallel/partial_sum.h: Fixed return value.
	* testsuite/26_numerics/accumulate/1.cc: Tests for accumulate.
	* testsuite/26_numerics/inner_product/1.cc: Tests for inner_product.

From-SVN: r129140
2007-10-08 21:14:45 +00:00
Paolo Carlini
d98f312ce6 stl_move.h (_GLIBCXX_MOVE): Add.
2007-10-08  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_move.h (_GLIBCXX_MOVE): Add.
	* include/bits/stl_algobase.h: Adjust.
	* include/bits/stl_pair.h: Likewise.

	* include/bits/stl_algo.h: Minor formatting fixes.

From-SVN: r129138
2007-10-08 20:02:11 +00:00
Benjamin Kosnik
a222efd88a re PR libstdc++/33489 (parallel v3: not default constructible issues)
2007-10-08  Benjamin Kosnik  <bkoz@redhat.com>

	PR libstdc++/33489	
	* include/parallel/multiseq_selection.h: Remove default constructed
	value_type.
	* include/parallel/partition.h: 
	* include/parallel/partial_sum.h: Format.

From-SVN: r129132
2007-10-08 15:58:06 +00:00
Johannes Singler
1904bef10a parallel_mode.html: Added reference to MCSTL.
* docs/html/parallel_mode.html: Added reference to MCSTL.
        More documentation on compile-time settings and tuning.
        * include/parallel/multiway_merge.h: Added reference to paper.
        * include/parallel/multiseq_selection.h: Added reference to paper.
        * include/parallel/workstealing.h: Added reference to paper.
        * include/parallel/balanced_quicksort.h: Added reference to paper.
        * include/parallel/tree.h: Added reference to paper.

From-SVN: r129129
2007-10-08 15:17:28 +00:00
Paolo Carlini
1476e59ccc [multiple changes]
2007-10-08  Paolo Carlini  <pcarlini@suse.de>

	* include/std/utility (identity, move, forward): Move to...
	* include/bits/stl_move.h: ... here.
	* include/Makefile.am: Add.
	* include/bits/stl_algobase.h: Include the latter.
	* include/Makefile.in: Regenerate.
	* testsuite/20_util/pair/moveable.cc: Remove dg-require-rvalref.

2007-10-08  Chris Jefferson  <chris@bubblescope.net>
	    Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_pair.h (pair<>:pair(pair&&),
	pair<>::operator=(pair&&)): Add.

From-SVN: r129124
2007-10-08 11:19:37 +00:00
Paolo Carlini
6c5f0578d9 [multiple changes]
2007-10-08  Paolo Carlini  <pcarlini@suse.de>

	* include/std/utility (identity, move, forward): Move to...
	* include/bits/stl_move.h: ... here.
	* include/Makefile.am: Add.
	* include/bits/stl_algobase.h: Include the latter.
	* include/Makefile.in: Regenerate.
	* testsuite/20_util/pair/moveable.cc: Remove dg-require-rvalref.

2007-10-08  Chris Jefferson  <chris@bubblescope.net>
	    Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_pair.h (pair<>:pair(pair&&),
	pair<>::operator=(pair&&)): Add.

From-SVN: r129123
2007-10-08 11:16:51 +00:00
Chris Jefferson
ed540c0ab9 list (list<>::list(list&&), [...]): Add.
2007-10-07  Chris Jefferson  <chris@bubblescope.net>
	    Paolo Carlini  <pcarlini@suse.de>

	* include/debug/list (list<>::list(list&&),
	list<>::operator=(list&&)): Add.
	(list<>::swap): Adjust.
	(swap(list&&, list& __y), swap(list&, list&& __y)): Add.
	* include/debug/vector (vector<>::vector(vector&&),
	vector<>::operator=(vector&&)): Add.
	(vector<>::swap): Adjust.
	(swap(vector&&, vector& __y), swap(vector&, vector&& __y)): Add.
	* include/debug/deque (deque<>::deque(deque&&),
	deque<>::operator=(deque&&)): Add.
	(deque<>::swap): Adjust.
	(swap(deque&&, deque& __y), swap(deque&, deque&& __y)): Add.
	* include/debug/set.h (set<>::set(set&&),
	set<>::operator=(set&&)): Add.
	(set<>::swap): Adjust.
	(swap(set&&, set& __y), swap(set&, set&& __y)): Add.
	* include/debug/map.h (map<>::map(map&&),
	map<>::operator=(map&&)): Add.
	(map<>::swap): Adjust.
	(swap(map&&, map& __y), swap(map&, map&& __y)): Add.
	* include/debug/multiset.h (multiset<>::multiset(multiset&&),
	multiset<>::operator=(multiset&&)): Add.
	(smultiet<>::swap): Adjust.
	(swap(multiset&&, multiset& __y),
	swap(multiset&, multiset&& __y)): Add.
	* include/debug/multimap.h (multimap<>::multimap(multimap&&),
	multimap<>::operator=(multimap&&)): Add.
	(multimap<>::swap): Adjust.
	(swap(multimap&&, multimap& __y),
	swap(multimap&, multimap&& __y)): Add.

Co-Authored-By: Paolo Carlini <pcarlini@suse.de>

From-SVN: r129071
2007-10-07 16:33:59 +00:00
Paolo Carlini
3a6b0f5465 [multiple changes]
2007-10-07  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_algobase.h (_GLIBCXX_MOVE): Add.
	(swap, __iter_swap): Use it.
	* testsuite/25_algorithms/rotate/moveable.cc: Remove dg-require-rvalref.
	* testsuite/25_algorithms/remove/moveable.cc: Likewise.
	* testsuite/25_algorithms/partition/moveable.cc: Likewise. 
	* testsuite/25_algorithms/swap_ranges/moveable.cc: Likewise.
	* testsuite/25_algorithms/reverse/moveable.cc: Likewise. 
	* testsuite/25_algorithms/unique/moveable.cc: Likewise. 
	* testsuite/25_algorithms/remove_if/moveable.cc: Likewise. 

	* include/bits/stl_algobase.h (lexicographical_compare):
	Clean up.

2007-10-07  Chris Jefferson  <chris@bubblescope.net>
	    Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_algo.h (remove, remove_if, unique,
	__rotate(_RandomAccessIterator, _RandomAccessIterator,
	_RandomAccessIterator, random_access_iterator_tag)): Use _GLIBCXX_MOVE.
	(__rotate(_ForwardIterator, _ForwardIterator, _ForwardIterator,
	forward_iterator_tag), __rotate(_BidirectionalIterator,
	_BidirectionalIterator, _BidirectionalIterator,
	bidirectional_iterator_tag), __partition(_ForwardIterator,
	_ForwardIterator, _Predicate, forward_iterator_tag)): Use iter_swap.

From-SVN: r129068
2007-10-07 11:14:11 +00:00
Benjamin Kosnik
049d24222d re PR libstdc++/33678 (__do_catch, __do_upcast ABI change)
2007-10-06  Benjamin Kosnik  <bkoz@redhat.com>

	PR libstdc++/33678	
	* libsupc++/typeinfo (typeinfo): Revert ordering of virtual components.

From-SVN: r129058
2007-10-06 23:40:32 +00:00
Benjamin Kosnik
6f95a65aa1 re PR libstdc++/33487 (parallel v3: more functions not in right namespace)
2007-10-06  Benjamin Kosnik  <bkoz@redhat.com>

	PR libstdc++/33487
	* include/parallel/algorithmfwd.h (for_each, generate, generate_n,
	transform, replace, replace_if, max_element, min_element, count,
	count_if): Consistently construct overloads.
	* include/parallel/numericfwd.h (accumulate, adjacent_difference,
	inner_product): Same.
	* include/parallel/algobase.h: Same.
	* include/parallel/algo.h: Same.
	* include/parallel/numeric: Same.

	* include/bits/algorithmfwd.h: Correct find_end placement.

	* docs/html/parallel_mode.html: Document some of the interface
	conventions.

	* include/parallel/search.h (calc_borders): Only use operator ==.
	
	* include/parallel/algorithmfwd.h: Move __gnu_sequential bits to...
	* include/parallel/tags.h: ...here, and use a using directive.

	* include/parallel/random_shuffle.h: Include stl_numeric. Qualify
	uses of partial_num with __gnu_sequential.

	* include/parallel/tree.h: Formatting.

From-SVN: r129054
2007-10-06 15:08:58 +00:00
Benjamin Kosnik
6116ca65dd Fixes for --disable-libstdcxx-pch.
2007-10-05  Benjamin Kosnik  <bkoz@redhat.com>

	Fixes for --disable-libstdcxx-pch.
	* include/ext/rc_string_base.h: Include stl_iterator_base_funcs.h.
	* include/ext/vstring_util.h: Include stl_iterator.h and
	numeric_traits.h.
	* include/tr1/functional: Include new.
	* testsuite/util/testsuite_api.h: Include exception.
	* testsuite/lib/libstdc++.exp (libstdc++_init): Set
	PCH_CXXFLAGS via cxxpchflags.

	* testsuite/25_algorithms/binary_search/requirements/
	explicit_instantiation/2.cc: Same.: Fix includes.
	* testsuite/25_algorithms/count_if/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/equal_range/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/find_end/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/find_first_of/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/find_if/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/for_each/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/includes/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/inplace_merge/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/lexicographical_compare/
	requirements/explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/lower_bound/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/make_heap/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/max_element/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/max/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/merge/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/min_element/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/min/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/next_permutation/
	requirements/explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/nth_element/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/partial_sort_copy/
	requirements/explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/partial_sort/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/partition/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/pop_heap/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/prev_permutation/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/push_heap/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/random_shuffle/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/remove_copy_if/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/remove_if/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/replace_copy_if/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/replace_if/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/search_n/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/search/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/set_difference/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/set_intersection/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/set_symmetric_difference/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/set_union/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/sort_heap/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/sort/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/stable_partition/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/stable_sort/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/transform/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/unique_copy/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/unique/requirements/
	explicit_instantiation/2.cc: Same.
	* testsuite/25_algorithms/upper_bound/requirements/
	explicit_instantiation/2.cc: Same.

	* testsuite/25_algorithms/remove/requirements/
	explicit_instantiation/pod.cc: Provide a hint to the compiler.

From-SVN: r129049
2007-10-06 03:06:37 +00:00
Paolo Carlini
f63bc637f6 moveable.cc: Remove dg-require-rvalref.
2007-10-05  Paolo Carlini  <pcarlini@suse.de>

	* testsuite/23_containers/map/moveable.cc: Remove dg-require-rvalref.
	* testsuite/23_containers/multimap/moveable.cc: Likewise.
	* testsuite/23_containers/set/moveable.cc: Likewise. 
	* testsuite/23_containers/multiset/moveable.cc: Likewise.
	* testsuite/23_containers/deque/moveable.cc: Likewise. 
	* testsuite/23_containers/list/moveable.cc: Likewise. 
	* testsuite/23_containers/vector/moveable.cc: Likewise. 
	* include/std/utility: Use _GLIBCXX_BEGIN_NAMESPACE.

2007-10-05  Paolo Carlini  <pcarlini@suse.de>
	    Chris Jefferson  <chris@bubblescope.net>

	* include/bits/stl_iterator.h (class move_iterator,
	make_move_iterator): Add.

Co-Authored-By: Chris Jefferson <chris@bubblescope.net>

From-SVN: r129048
2007-10-06 02:33:12 +00:00
Doug Kwan
afd82ef5ab gthr-posix.h (__gthread_cond_broadcast, [...]): Add to extend interface for POSIX conditional variables.
2007-09-13  Doug Kwan  <dougkwan@google.com>

        * gcc/gthr-posix.h (__gthread_cond_broadcast, __gthread_cond_wait,
        __gthread_cond_wait_recursive): Add to extend interface for POSIX
        conditional variables. (__GTHREAD_HAS_COND): Macro defined to signify
        support of conditional variables.
        * gcc/gthr-posix95.h (__gthread_cond_broadcast, __gthread_cond_wait,
        __gthread_cond_wait_recursive): Add to extend interface for POSIX
        conditional variables. (__GTHREAD_HAS_COND): Macro defined to signify
        support of conditional variables.
        * gcc/gthr-single.h (__gthread_cond_broadcast, __gthread_cond_wait,
        __gthread_cond_wait_recursive): Add to extend interface for POSIX
        conditional variables.
        * gcc/gthr.h: Update comments to document new interface.
        * libstdc++-v3/include/ext/concurrent.h (class __mutex,
        class __recursive_mutex): Add new method gthread_mutex to access
        inner gthread mutex.
        [__GTHREAD_HAS_COND] (class __concurrence_broadcast_error,
        class __concurrence_wait_error, class __cond): Add.
        * guard.cc (recursive_push, recursive_pop): Delete.
        (init_in_progress_flag, set_init_in_progress_flag): Add to
        replace recursive_push and recursive_pop.
        (throw_recursive_init_exception): Add.
        (acquire, __cxa_guard_acquire, __cxa_guard_abort and
        __cxa_guard_release): [__GTHREAD_HAS_COND] Use a conditional
        for synchronization of static variable initialization.
        The global mutex is only held briefly when guards are
        accessed. [!__GTHREAD_HAS_COND] Fall back to the old code,
        which deadlocks.
        * testsuite/thread/guard.cc: Add new test. It deadlocks with the
        old locking code in libstdc++-v3/libsup++/guard.cc.

From-SVN: r129030
2007-10-05 01:35:46 -04:00
Paolo Carlini
78b36b70be [multiple changes]
2007-10-04  Paolo Carlini  <pcarlini@suse.de>

	* testsuite/23_containers/vector/requirements/dr438/assign_neg.cc:
	Adjust dg-error line number.
	* testsuite/23_containers/vector/requirements/dr438/insert_neg.cc:
	Likewise.
	* 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/deque/requirements/dr438/assign_neg.cc:
	Adjust dg-error line number.
	* testsuite/23_containers/deque/requirements/dr438/insert_neg.cc:
	Likewise.
	* testsuite/23_containers/deque/requirements/dr438/
	constructor_1_neg.cc: Likewise.
	* testsuite/23_containers/deque/requirements/dr438/
	constructor_2_neg.cc: Likewise.
	* testsuite/23_containers/list/requirements/dr438/assign_neg.cc:
	Adjust dg-error line number.
	* testsuite/23_containers/list/requirements/dr438/insert_neg.cc:
	Likewise.
	* testsuite/23_containers/list/requirements/dr438/
	constructor_1_neg.cc: Likewise.
	* testsuite/23_containers/list/requirements/dr438/
	constructor_2_neg.cc: Likewise.

2007-10-04  Chris Jefferson  <chris@bubblescope.net>
	    Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_list.h (list<>::list(list&&),
	list<>::operator=(list&&)): Add.
	(list<>::swap): Adjust.
	(swap(list&&, list& __y), swap(list&, list&& __y)): Add.
	* include/bits/stl_vector.h (vector<>::vector(vector&&),
	vector<>::operator=(vector&&)): Add.
	(vector<>::swap): Adjust.
	(swap(vector&&, vector& __y), swap(vector&, vector&& __y)): Add.
	* include/bits/stl_bvector.h (vector<>::vector(vector&&),
	vector<>::operator=(vector&&)): Add.
	(vector<>::swap): Adjust.
	* include/bits/stl_deque.h (deque<>::deque(deque&&),
	deque<>::operator=(deque&&)): Add.
	(deque<>::swap): Adjust.
	(swap(deque&&, deque& __y), swap(deque&, deque&& __y)): Add.
	* include/bits/stl_set.h (set<>::set(set&&),
	set<>::operator=(set&&)): Add.
	(set<>::swap): Adjust.
	(swap(set&&, set& __y), swap(set&, set&& __y)): Add.
	* include/bits/stl_map.h (map<>::map(map&&),
	map<>::operator=(map&&)): Add.
	(map<>::swap): Adjust.
	(swap(map&&, map& __y), swap(map&, map&& __y)): Add.
	* include/bits/stl_multiset.h (multiset<>::multiset(multiset&&),
	multiset<>::operator=(multiset&&)): Add.
	(smultiet<>::swap): Adjust.
	(swap(multiset&&, multiset& __y),
	swap(multiset&, multiset&& __y)): Add.
	* include/bits/stl_multimap.h (multimap<>::multimap(multimap&&),
	multimap<>::operator=(multimap&&)): Add.
	(multimap<>::swap): Adjust.
	(swap(multimap&&, multimap& __y),
	swap(multimap&, multimap&& __y)): Add.

2007-10-04  Paolo Carlini  <pcarlini@suse.de>

	Avoid copying some allocator objects.
	* include/bits/stl_list.h (_List_impl::_List_impl(),
	_List_base::_List_base(), list<>::list()): Add.
	* include/bits/stl_vector.h  (_Vector_impl::_Vector_impl(),
	_Vector_base::_Vector_base(), vector<>::vector()): Add.
	* include/bits/stl_bvector.h (_Bvector_impl::_Bvector_impl(),
	_Bvector_base::_Bvector_base(), vector<>::vector()): Add.
	* include/bits/stl_deque.h  (_Deque_impl::_Deque_impl(),
	_Deque_base::_Deque_base(), deque<>::deque()): Add.
	* include/bits/stl_tree.h (_Rb_tree_impl<>::_Rb_tree_impl(),
	_Rb_tree_impl<>::_M_initialize): Add.
	(_Rb_tree<>::_Rb_tree(const _Compare&, const allocator_type&),
	_Rb_tree(const _Rb_tree&)): Adjust.
	* include/bits/stl_set.h (set<>::set(),
	set(_InputIterator, _InputIterator)): Use _M_t default constructor. 
	* include/bits/stl_map.h (map<>::map(), set(_InputIterator,
	_InputIterator)): Use _M_t default constructor. 
	* include/bits/stl_multiset.h (multiset<>::multiset(),
	multiset(_InputIterator, _InputIterator)): Use _M_t default
	constructor. 
	* include/bits/stl_multimap.h (multimap<>::multimap(),
	multimap(_InputIterator, _InputIterator)): Use _M_t default
	constructor.

From-SVN: r129013
2007-10-04 15:12:34 +00:00
Chris Jefferson
f5783e34f9 moveable.cc: New.
2007-10-03  Chris Jefferson  <chris@bubblescope.net>
	    Benjamin Kosnik  <bkoz@redhat.com>

	* testsuite/20_util/pair/moveable.cc: New. Merge from 
	libstdcxx_so_7-branch.
	* testsuite/23_containers/deque/capacity/moveable.cc: Same.
	* testsuite/23_containers/deque/cons/moveable.cc: Same.
	* testsuite/23_containers/deque/modifiers/moveable.cc: Same.
	* testsuite/23_containers/deque/moveable.cc: Same.
	* testsuite/23_containers/list/moveable.cc: Same.
	* testsuite/23_containers/map/moveable.cc: Same.
	* testsuite/23_containers/multimap/moveable.cc: Same.
	* testsuite/23_containers/multiset/moveable.cc: Same.
	* testsuite/23_containers/set/moveable.cc: Same.
	* testsuite/23_containers/vector/cons/moveable.cc: Same.
	* testsuite/23_containers/vector/modifiers/moveable.cc: Same.
	* testsuite/23_containers/vector/moveable.cc: Same.
	* testsuite/23_containers/vector/resize/moveable.cc: Same.
	* testsuite/25_algorithms/heap/moveable.cc: Same.
	* testsuite/25_algorithms/nth_element/moveable.cc: Same.
	* testsuite/25_algorithms/partial_sort/moveable.cc: Same.
	* testsuite/25_algorithms/partition/moveable.cc: Same.
	* testsuite/25_algorithms/remove_if/moveable.cc: Same.
	* testsuite/25_algorithms/remove/moveable.cc: Same.
	* testsuite/25_algorithms/reverse/moveable.cc: Same.
	* testsuite/25_algorithms/rotate/moveable.cc: Same.
	* testsuite/25_algorithms/sort/moveable.cc: Same.
	* testsuite/25_algorithms/swap_ranges/moveable.cc: Same.
	* testsuite/25_algorithms/unique/moveable.cc: Same.
	* testsuite/util/testsuite_rvalref.h: New.

	* testsuite/25_algorithms/equal/equal.cc: Move to...
	* testsuite/25_algorithms/equal/no_operator_ne.cc: ...this.
	* testsuite/25_algorithms/heap/heap.cc: Move to...
	* testsuite/25_algorithms/heap/1.cc: ...this.
	* testsuite/25_algorithms/lower_bound/lower_bound.cc: Move to...
	* testsuite/25_algorithms/lower_bound/no_operator_ne.cc: ...this.
	* testsuite/25_algorithms/partition/partition.cc: Move to...
	* testsuite/25_algorithms/partition/1.cc: ...this.
	* testsuite/25_algorithms/stable_partition/1.cc: ... and this.
	
	* testsuite/25_algorithms/search/1.cc: Update from merge.
	* testsuite/25_algorithms/search/check_type.cc: Same.

	* testsuite/lib/dg-options.exp (dg-require-rvalref): New.
	* testsuite/lib/libstdc++.exp (check_v3_target_rvalref): New.
	

Co-Authored-By: Benjamin Kosnik <bkoz@redhat.com>

From-SVN: r128990
2007-10-03 17:27:18 +00:00
Richard Sandiford
b6f914f633 no-executables.m4 (GCC_TRY_COMPILE_OR_LINK): New function.
config/
	* no-executables.m4 (GCC_TRY_COMPILE_OR_LINK): New function.
	libstdc++-v3/

libstdc++/
	* acinclude.m4 (GLIBCXX_ENABLE_C99): Temporarily add
	-fno-exceptions to CXXFLAGS.  Use GCC_TRY_COMPILE_OR_LINK.
	Make the tests assign results to volatile variables.  Use -lm
	for link tests in GCC_TRY_COMPILE_OR_LINK.  Fall back to
	compile-only tests if -lm is not available.
	* configure: Regenerate.

From-SVN: r128982
2007-10-03 14:16:57 +00:00
Kenneth Zadeck
ed1345e8a3 revert accidential change in revision 128957.
From-SVN: r128976
2007-10-03 01:31:47 +00:00
Paolo Carlini
f5ad31630d re PR libstdc++/33613 (compilation inconsistency upper_bound vs lower_bound with -D_GLIBCXX_DEBUG)
2007-10-03  Paolo Carlini  <pcarlini@suse.de>

	PR libstdc++/33613
	* include/debug/functions.h (__check_partitioned): Rename to...
	(__check_partioned_lower): ... this.
	(__check_partioned_upper): Add.
	* include/debug/macros.h (__glibcxx_check_partitioned): Rename to...
	(__glibcxx_check_partitioned_lower): ... this, adjust.
	(__glibcxx_check_partitioned_upper): Add.
	* include/debug/debug.h (__glibcxx_requires_partitioned): Rename to...
	(__glibcxx_requires_partitioned_lower): ... this, adjust.
	(__glibcxx_requires_partitioned_upper): Add.
	* include/bits/stl_algo.h (lower_bound, upper_bound, equal_range,
	binary search): Use the above.
	* testsuite/25_algorithms/lower_bound/33613.cc: New.
	* testsuite/25_algorithms/upper_bound/33613.cc: Likewise.

From-SVN: r128974
2007-10-03 00:34:40 +00:00
Kazu Hirata
9e4e09166b revert: no-executables.m4 (GCC_TRY_COMPILE_OR_LINK): New function.
config/
	Revert:
	2007-10-02  Richard Sandiford  <richard@codesourcery.com>
	* no-executables.m4 (GCC_TRY_COMPILE_OR_LINK): New function.

libstdc++/
	Revert:
	2007-10-02  Richard Sandiford  <richard@codesourcery.com>
	* acinclude.m4 (GLIBCXX_ENABLE_C99): Temporarily add
	-fno-exceptions to CXXFLAGS.  Use GCC_TRY_COMPILE_OR_LINK.
	Make the tests assign results to volatile variables.
	* configure: Regenerate.

From-SVN: r128972
2007-10-03 00:25:22 +00:00
Richard Sandiford
b32265748a no-executables.m4 (GCC_TRY_COMPILE_OR_LINK): New function.
config/
	* no-executables.m4 (GCC_TRY_COMPILE_OR_LINK): New function.

libstdc++/
	* acinclude.m4 (GLIBCXX_ENABLE_C99): Temporarily add
	-fno-exceptions to CXXFLAGS.  Use GCC_TRY_COMPILE_OR_LINK.
	Make the tests assign results to volatile variables.
	* configure: Regenerate.

From-SVN: r128959
2007-10-02 17:25:18 +00:00
Benjamin Kosnik
506f93badb 2.cc: Split into...
2007-10-02  Benjamin Kosnik  <bkoz@redhat.com>

	* testsuite/25_algorithms/binary_search/2.cc: Split into...
	* testsuite/25_algorithms/upper_bound/2.cc: ... this.
	* testsuite/25_algorithms/lower_bound/2.cc: ... this.
	* testsuite/25_algorithms/equal_range/2.cc: ... and this.
	* testsuite/25_algorithms/sort/vectorbool.cc: Add from
	libstdcxx_so_7-branch.

From-SVN: r128958
2007-10-02 16:07:01 +00:00
Kenneth Zadeck
ba49cb7bff ra-conflict.c: New file.
2007-09-02  Kenneth Zadeck <zadeck@naturalbridge.com>

	* ra-conflict.c: New file.
	* ra.h: New file.
	* reload.c (push_reload, find_dummy_reload): Change DF_RA_LIVE
	usage to DF_LIVE usage.
	* rtlanal.c (subreg_nregs_with_regno): New function.  
	* df-scan.c (df_def_record_1, df_uses_record): Add code to set
	DF_REF_EXTRACT, DF_REF_STRICT_LOWER_PART, and DF_REF_SUBREG flags.
	(df_has_eh_preds): Removed.
	(df_bb_refs_collect, df_bb_refs_collect, df_bb_refs_collect,
	df_exit_block_uses_collect): Changed call from df_has_eh_preds to
	bb_has_eh_pred.
	* global.c (allocno, max_allocno, conflicts, allocno_row_words,
	reg_allocno, EXECUTE_IF_SET_IN_ALLOCNO_SET): Moved to ra.h
	(SET_ALLOCNO_LIVE, CLEAR_ALLOCNO_LIVE): Moved to ra-conflicts.c.
	(regs_set, record_one_conflict, record_conflicts, mark_reg_store,
	mark_reg_clobber, mark_reg_conflicts, mark_reg_death): Deleted.
	(global_alloc): Turn off rescanning insns after call to
	global_conflicts and added call to set_preferences.
	(global_conflicts): Moved to ra-alloc.c.
	(set_preferences_1, set_preferences): New function.
	(mirror_conflicts): Changed types for various variables.
	(mark_elimination): Change DF_RA_LIVE
	usage to DF_LIVE usage.
	(build_insn_chain): Rewritten from scratch and made local.
	(print_insn_chain, print_insn_chains): New functions.
	(dump_conflicts): Do not print conflicts for fixed_regs.
	(rest_of_handle_global_alloc): Turn off insn rescanning.
	* hard-reg-set.h: Fixed comment.
	* local-alloc.c (update_equiv_regs): Change DF_RA_LIVE
	usage to DF_LIVE usage and delete refs to TOP sets.
	(block_alloc): Mark regs as live if they are in the artificial
	defs at top of block.
	(find_stack_regs): New function.
	(rest_of_handle_local_alloc): Changed urec problem to live
	problem and do not turn off df rescanning.
	* df.h (DF_UREC, DF_UREC_BB_INFO, DF_LIVE_TOP, DF_RA_LIVE_IN,
	DF_RA_LIVE_TOP, DF_RA_LIVE_OUT, df_urec_bb_info, df_urec,
	df_urec_add_problem, df_urec_get_bb_info, df_has_eh_preds): Removed.
	(DF_CHAIN, DF_NOTE, DF_CHAIN): Renumbered.
	(DF_REF_EXTRACT, DF_REF_STRICT_LOWER_PART, DF_REF_SUBREG): New
	fields in df_ref_flags.  The rest have been renumbered.  
	* init-regs.c (initialize_uninitialized_regs): Enhanced debugging
	at -O1.
	* rtl.h (subreg_nregs_with_regno): New function.
	* df-problems.c: (df_get_live_out, df_get_live_in,
	df_get_live_top): Removed reference to DF_RA_LIVE.
	(df_lr_reset, df_lr_transfer_function, df_live_free_bb_info,
	df_live_alloc, df_live_reset, df_live_local_finalize,
	df_live_free): Make top set only if different from in set.
	(df_lr_top_dump, df_live_top_dump): Only print top set if
	different from in set.
	(df_lr_bb_local_compute): Removed unnecessary check.
	(df_urec_problem_data, df_urec_set_bb_info, df_urec_free_bb_info, 
	df_urec_alloc, df_urec_mark_reg_change, earlyclobber_regclass, 
	df_urec_check_earlyclobber, df_urec_mark_reg_use_for_earlyclobber,
	df_urec_mark_reg_use_for_earlyclobber_1, df_urec_bb_local_compute,
	df_urec_local_compute, df_urec_init, df_urec_local_finalize, 
	df_urec_confluence_n, df_urec_transfer_function, df_urec_free, 
	df_urec_top_dump, df_urec_bottom_dump, problem_UREC,
	df_urec_add_problem): Removed.
	(df_simulate_fixup_sets): Changed call from df_has_eh_preds to
	bb_has_eh_pred. 
	* Makefile.in (ra-conflict.o, ra.h): New dependencies.
	* basic_block.h (bb_has_abnormal_pred): New function.
	* reload1.c (compute_use_by_pseudos): Change DF_RA_LIVE
	usage to DF_LIVE usage.

From-SVN: r128957
2007-10-02 13:10:07 +00:00
Jonathan Wakely
ee5ca78921 valarray-inst.cc, [...]: Fix comment typos.
* src/valarray-inst.cc, include/ext/atomicity.h,
	include/ext/concurrence.h, include/bits/basic_string.h,
	include/bits/fstream.tcc, include/ext/vstring.h: Fix comment typos.

From-SVN: r128915
2007-10-01 21:49:39 +01:00
Jonathan Wakely
1b54a3bb1b test.html, [...]: Update docs to refer to Subversion not CVS.
* docs/html/test.html, docs/html/ext/mt_allocator.html,
	docs/html/ext/tr1.html, docs/html/17_intro/contribute.html,
	docs/html/documentation.html, docs/html/20_util/allocator.html:
	Update docs to refer to Subversion not CVS. Fix markup.

From-SVN: r128914
2007-10-01 21:39:08 +01:00
Jonathan Wakely
96cbc7348f * docs/html/Makefile: Follow up to libstdc++/14991, remove target.
From-SVN: r128909
2007-10-01 20:55:41 +01:00
Benjamin Kosnik
18080e8e7a algorithmfwd.h: Spacing.
2007-09-28  Benjamin Kosnik  <bkoz@redhat.com>

	* include/parallel/algorithmfwd.h: Spacing.
	* include/parallel/tags.h: Correct comment.
	
	* testsuite/Makefile.am (AM_MAKEFLAGS, AM_RUNTESTFLAGS): Remove.
	* testsuite/Makefile.in: Regenerate.

From-SVN: r128869
2007-09-28 17:49:28 +00:00
Benjamin Kosnik
5c13b77cb0 testsuite_hooks.cc (set_memory_limits): Adjust x86_64 virtual memory setting for libgomp.
2007-09-27  Benjamin Kosnik  <bkoz@redhat.com>

	* testsuite/util/testsuite_hooks.cc (set_memory_limits): Adjust
	x86_64 virtual memory setting for libgomp.

From-SVN: r128842
2007-09-27 18:06:10 +00:00
Benjamin Kosnik
4f99f3d0e5 stl_algo.h: Add return type information to comments.
2007-09-26  Benjamin Kosnik  <bkoz@redhat.com>

	* include/bits/stl_algo.h: Add return type information to comments.
	* include/bits/algorithmfwd.h: Formatting.
	* testsuite/util/testsuite_hooks.h (NonDefaultConstructible): Move..
	* testsuite/util/testsuite_api.h: ...here. Add necessary operators
	for use in testing chapters 25 and 26.
	* testsuite/util/testsuite_character.h: Same.

	* testsuite/25_algorithms/*/requirements/explicit_instantiation/
	2.cc, pod.cc: New.

	* testsuite/26_numerics/accumulate, adjacent_difference, inner_product,
	partial_sum/requirements/explicit_instantiation/2.cc, pod.cc: New.
	
	* testsuite/26_numerics/numeric_arrays/*: Move contents into
	testsuite/26_numerics.

	* testsuite/26_numerics/numeric_operations: Same.
	
	* testsuite/23_containers/*/requirements/explicit_instantiation/2.cc:
	Adjust includes from testsuite_eh.h to testsuite_api.h.


Co-Authored-By: Chalathip Thumkanon <chalathip@gmail.com>

From-SVN: r128822
2007-09-26 17:04:06 +00:00
Richard Sandiford
23b72f1746 libstdc++.exp (check_v3_target_fileio): Test lseek.
libstdc++-v3/
	* testsuite/lib/libstdc++.exp (check_v3_target_fileio): Test lseek.

From-SVN: r128772
2007-09-25 21:18:11 +00:00
Benjamin Kosnik
80a6ca747a re PR libstdc++/32819 (pb_ds/hash_based_containers.html errors)
2007-09-17  Benjamin Kosnik  <bkoz@redhat.com>
	    Chalathip Thumkanon  <chalathip@gmail.com>

	PR libstdc++/32819
	PR libstdc++/32822
	* docs/html/ext/pb_ds/hash_based_containers.html: Correct.

From-SVN: r128589
2007-09-18 22:49:24 +00:00
Benjamin Kosnik
805c2c336c hash_based_containers.html: Correct.
2007-09-17  Benjamin Kosnik  <bkoz@redhat.com>
	    Chalathip Thumkanon  <chalathip@gmail.com>

	* docs/html/ext/pb_ds/hash_based_containers.html: Correct.
	

Co-Authored-By: Chalathip Thumkanon <chalathip@gmail.com>

From-SVN: r128588
2007-09-18 22:48:29 +00:00
Benjamin Kosnik
bdfb7c6d56 configure.host: Set atomic_flags on i486.
2007-09-17  Benjamin Kosnik  <bkoz@redhat.com>

	* configure.host: Set atomic_flags on i486.

	* include/Makefile.am: Remove parallel-mode pch.	
	* include/Makefile.in: Regenerate.

	* testsuite/lib/libstdc++.exp: Set ld_library_flags for libgomp if
	present.

	* acinclude.m4 (GLIBCXX_ENABLE_PARALLEL): Comment.
	* configure: Regenerate.

From-SVN: r128579
2007-09-18 15:25:39 +00:00
Johannes Singler
a3e6b31a0f for_each.h: Fixed comment/doxygen markup typos.
2007-09-17  Johannes Singler  <singler@ira.uka.de>

        * include/parallel/for_each.h: Fixed comment/doxygen markup typos.
        * include/parallel/base.h: Same.
        * include/parallel/numeric: Same.
        * include/parallel/quicksort.h: Same.
        * include/parallel/compiletime_settings.h: Same.
        * include/parallel/random_shuffle.h: Same.
        * include/parallel/balanced_quicksort.h: Same.
        * include/parallel/tree.h: Same.
        * include/parallel/settings.h: Same.
        * include/parallel/search.h: Same.
        * include/parallel/partition.h: Same.
        * include/parallel/partial_sum.h: Same.

From-SVN: r128545
2007-09-17 12:58:07 +00:00
Paolo Carlini
fd735b6a2e type_traitsfwd.h (aligned_storage): Remove declaration.
2007-09-17  Paolo Carlini  <pcarlini@suse.de>

	* include/tr1_impl/type_traitsfwd.h (aligned_storage): Remove
	declaration.
	* include/tr1_impl/type_traits (aligned_storage): Remove.
	* include/std/type_traits (aligned_storage, __aligned_storage_msa):
	Add.
	* include/tr1/type_traits (aligned_storage): Add.
	* testsuite/20_util/aligned_storage/value.cc: New.
	* testsuite/20_util/aligned_storage/requirements/
	explicit_instantiation.cc: Likewise.
	* testsuite/20_util/make_signed/requirements/typedefs_neg.cc: Adjust
	dg-error lines.
	* testsuite/20_util/make_unsigned/requirements/typedefs_neg.cc:
	Likewise.

From-SVN: r128542
2007-09-17 10:18:51 +00:00
Paolo Carlini
1f9e358abb type_traits (aligned_storage): Implement in the neat and general way.
2007-09-16  Paolo Carlini  <pcarlini@suse.de>
	    Douglas Gregor  <doug.gregor@gmail.com>

	* include/tr1_impl/type_traits (aligned_storage): Implement
	in the neat and general way.

Co-Authored-By: Douglas Gregor <doug.gregor@gmail.com>

From-SVN: r128532
2007-09-16 23:59:34 +00:00
Benjamin Kosnik
c5654e49f0 base.h (__gnu_parallel::less<Tp>): Add partial specialization for one argument.
2007-09-14  Benjamin Kosnik  <bkoz@redhat.com>
        
	* include/parallel/base.h (__gnu_parallel::less<Tp>): Add partial
        specialization for one argument. 
	(__gnu_parallel::less): Add operator.

	* include/parallel/multiway_merge.h: Use __builtin_alloca. 
	* include/parallel/partial_sum.h: Same.
	* include/parallel/find.h: Same.

From-SVN: r128505
2007-09-14 20:37:25 +00:00
Jonathan Wakely
e31fc6a531 boost_shared_ptr.h: (__weak_ptr::lock()): Add missing template argument.
2007-09-14  Jonathan Wakely  <jwakely.gcc@gmail.com>

	* include/tr1_impl/boost_shared_ptr.h: (__weak_ptr::lock()): Add
	missing template argument.
	* testsuite/tr1/2_general_utilities/shared_ptr/requirements/
	explicit_instantiation/2.cc: New.
	* testsuite/tr1/2_general_utilities/weak_ptr/requirements/
	explicit_instantiation/2.cc: New.

From-SVN: r128503
2007-09-14 21:17:29 +01:00
Benjamin Kosnik
c417817a85 all_pedantic_errors.cc: New.
2007-09-14  Benjamin Kosnik  <bkoz@redhat.com>

        * testsuite/17_intro/headers/all_pedantic_errors.cc: New.
        * include/tr1_impl/cinttypes: Add pragma GCC system_header.
        * include/tr1_impl/cfenv: Same.
        * include/tr1_impl/cstdint: Same.
        * include/tr1/cstdbool: Same.
        * include/ext/pb_ds/detail/resize_policy/
        hash_prime_size_policy_imp.hpp: Same.
        * include/parallel/partial_sum.h: Avoid VLA error with
        __builtin_alloca.

From-SVN: r128500
2007-09-14 17:46:56 +00:00
Richard Sandiford
d9dced1370 configure.ac (mips*-sde-elf*): New stanza.
* configure.ac (mips*-sde-elf*): New stanza.  Add target-libiberty
	to $skipdirs and only disable gprof for newlib.  Use the normal
	mips*-elf* handling in other respects.
	* configure: Regnerate.

gcc/
2007-xx-xx  Nigel Stephens  <nigel@mips.com>
	    David Ung  <davidu@mips.com>
	    Thiemo Seufer  <ths@mips.com>
	    Richard Sandiford  <richard@codesourcery.com>

	* config.gcc (mips*-sde-elf*): Add support for the SDE C libraries.
	* configure.ac: Add a mipssde threading type.
	* configure: Regenerate.
	* config/mips/sdemtk.h: New file.
	* config/mips/t-sdemtk: Likewise.
	* config/mips/sdemtk.opt: Likewise.
	* gthr-mipssde.h: Likewise.
	* config/mips/sde.h (FUNCTION_PROFILER): Move to config/mips/sdemtk.h.
	* config/mips/mips.h (MIPS_SAVE_REG_FOR_PROFILING_P): New macro.
	(MIPS_ICACHE_SYNC): New macro, split from ...
	* config/mips/mips.md (clear_cache): ...here.
	* config/mips/mips.c (mips_save_reg_p): Check
	MIPS_SAVE_REG_FOR_PROFILING_P on profiled functions.
	(build_mips16_function_stub): Use targetm.strip_name_encoding.
	(build_mips16_call_stub): Likewise.

libstdc++-v3/
2007-xx-xx  Thiemo Seufer  <ths@mips.com>

	* crossconfig.m4 (mips*-sde-elf*): New stanza.
	* configure: Regenerate.

From-SVN: r128495
2007-09-14 14:50:26 +00:00
Benjamin Kosnik
5e11f978ed *: Change namespace pb_ds to __gnu_pbds.
2007-09-12  Benjamin Kosnik  <bkoz@redhat.com>

	* include/ext/pb_ds/*: Change namespace pb_ds to __gnu_pbds.
	* docs/html/ext/pb_ds/*: Same.
	* testsuite/ext/pb_ds/*: Same.
	* testsuite/performance/ext/pb_ds/*: Same.
	* testsuite/util/*: Same.

From-SVN: r128448
2007-09-12 23:06:27 +00:00
Benjamin Kosnik
94dabea728 find.h: Doxygen fixups.
2007-09-12  Benjamin Kosnik  <bkoz@redhat.com>

	* include/parallel/find.h: Doxygen fixups.
	* include/bits/hashtable.h: Same.

From-SVN: r128440
2007-09-12 15:33:43 +00:00
Johannes Singler
c2ba97097b Add parallel mode.
2007-09-11  Johannes Singler  <singler@ira.uka.de>
	    Leonor Frias Moya  <lfrias@lsi.upc.edu>
            Felix Putze  <kontakt@felix-putze.de>
            Marius Elvert  <marius.elvert@ira.uka.de>
	    Felix Bondarenko  <f.bondarenko@web.de>
	    Robert Geisberger  <robert.geisberger@stud.uni-karlsruhe.de>
	    Robin Dapp  <r.dapp@freenet.de>
  	    Benjamin Kosnik  <bkoz@redhat.com>

	Add parallel mode.
	* include/parallel: New.
	* include/parallel/iterator.h: New.
	* include/parallel/multiway_merge.h: New.
	* include/parallel/parallel.h: New.
	* include/parallel/algorithm
	* include/parallel/find_selectors.h: New.
	* include/parallel/losertree.h: New.
	* include/parallel/list_partition.h: New.
	* include/parallel/types.h: New.
	* include/parallel/for_each.h: New.
	* include/parallel/multiseq_selection.h: New.
	* include/parallel/workstealing.h: New.
	* include/parallel/base.h: New.
	* include/parallel/par_loop.h: New.
	* include/parallel/numeric
	* include/parallel/features.h: New.
	* include/parallel/quicksort.h: New.
	* include/parallel/algorithmfwd.h: New.
	* include/parallel/equally_split.h: New.
	* include/parallel/compiletime_settings.h: New.
	* include/parallel/for_each_selectors.h: New.
	* include/parallel/basic_iterator.h: New.
	* include/parallel/omp_loop_static.h: New.
	* include/parallel/random_shuffle.h: New.
	* include/parallel/balanced_quicksort.h: New.
	* include/parallel/set_operations.h: New.
	* include/parallel/tags.h: New.
	* include/parallel/merge.h: New.
	* include/parallel/tree.h: New.
	* include/parallel/settings.h: New.
	* include/parallel/unique_copy.h: New.
	* include/parallel/multiway_mergesort.h: New.
	* include/parallel/numericfwd.h: New.
	* include/parallel/search.h: New.
	* include/parallel/partition.h: New.
	* include/parallel/compatibility.h: New.
	* include/parallel/algobase.h: New.
	* include/parallel/find.h: New.
	* include/parallel/partial_sum.h: New.
	* include/parallel/algo.h: New.
	* include/parallel/omp_loop.h: New.
	* include/parallel/queue.h: New.
	* include/parallel/timing.h: New.
	* include/parallel/sort.h: New.
	* include/parallel/checkers.h: New.
	* include/parallel/random_number.h: New.
	* include/bits/algorithmfwd.h: New.

	* acinclude.m4 (GLIBCXX_ENABLE_PARALLEL): New.
	* configure.host: Add atomic_flags.
	* configure.ac: Export ATOMIC_FLAGS, call GLIBCXX_ENABLE_PARALLEL.
	* src/Makefile.am: Add parallel_list rules.
	* include/Makefile.am: Add parallel files.
	* testsuite/Makefile.am (check-parallel): Add.
	(check-performance-parallel): Add.
	* config.h.in: Regenerate.
	* configure: Same.
	* libsupc++/Makefile.in: Same.
	* testsuite/Makefile.in: Same.
	* Makefile.in: Same.
	* libmath/Makefile.in: Same.
	* include/Makefile.in: Same.
	* src/Makefile.in: Same.
	* po/Makefile.in: Same.
	
	* config/abi/pre/gnu.ver: Export parallel list bits.

	* docs/html/parallel_mode.html: New.
	* docs/html/documentation.html: Add link.
	* docs/doxygen/user.cfg.in: Adjust for new files and directory.
	* docs/doxygen/doxygroups.cc: Adjust namespace markup.

	* include/debug/set.h: Adjust for _GLIBCXX_STD_D or _P change.
	* include/debug/bitset: Same.
	* include/debug/multiset.h: Same.
	* include/debug/vector: Same.
	* include/debug/map.h: Same.
	* include/debug/deque: Same.
	* include/debug/list: Same.
	* include/debug/debug.h: Same.
	* include/debug/multimap.h: Same.
	* include/std/algorithm: Same.
	* include/std/numeric: Same.
	* include/std/bitset: Same.
	* include/std/string: Same.
	* include/ext/hash_map: Same.
	* include/ext/hash_set: Same.
	* include/bits/stl_list.h: Same.
	* include/bits/stl_map.h: Same.
	* include/bits/stl_algobase.h: Same.
	* include/bits/stl_set.h: Same.
	* include/bits/stl_multimap.h: Same.
	* include/bits/stl_vector.h: Same.
	* include/bits/stl_numeric.h: Same.
	* include/bits/stl_deque.h: Same.
	* include/bits/stl_multiset.h: Same.
	* include/bits/char_traits.h: Same.
	* include/bits/stl_algo.h: Same.
	* include/bits/c++config: Same.
	* include/bits/vector.tcc: Same.
	* include/bits/deque.tcc: Same.
	* include/bits/stl_bvector.h: Same.
	* include/bits/list.tcc: Same.
	* src/list.cc: Same.
	* src/parallel_list.cc: New.

	* testsuite/lib/libstdc++.exp (check_v3_target_parallel_mode): New.
	* testsuite/lib/dg-options.exp (dg-require-parallel-mode): New.
	* scripts/testsuite_flags.in (--cxxparallelflags): New.
	* scripts/check_performance: Adjust.
	* testsuite/25_algorithms/headers/parallel_algorithm.cc: New.
	* testsuite/25_algorithms/headers/algorithm_parallel_mode.cc: New.
	* testsuite/25_algorithms/headers/parallel_algorithm_mixed1.cc: New.
	* testsuite/25_algorithms/headers/parallel_algorithm_mixed2.cc: New.
	* testsuite/26_numerics/headers/numeric/parallel_numeric.cc: New.
	* testsuite/26_numerics/headers/numeric/numeric_parallel_mode.cc: New.
	* testsuite/26_numerics/headers/numeric/
	parallel_numeric_mixed1.cc: New.
	* testsuite/26_numerics/headers/numeric/
	parallel_numeric_mixed2.cc: New.
	

Co-Authored-By: Benjamin Kosnik <bkoz@redhat.com>
Co-Authored-By: Felix Bondarenko <f.bondarenko@web.de>
Co-Authored-By: Felix Putze <kontakt@felix-putze.de>
Co-Authored-By: Leonor Frias Moya <lfrias@lsi.upc.edu>
Co-Authored-By: Marius Elvert <marius.elvert@ira.uka.de>
Co-Authored-By: Robert Geisberger <robert.geisberger@stud.uni-karlsruhe.de>
Co-Authored-By: Robin Dapp <r.dapp@freenet.de>

From-SVN: r128395
2007-09-11 22:32:51 +00:00
Daniel Jacobowitz
fa6763a6fc libstdc++.exp (libstdc++_init): Revert part of 2007-09-06 change.
* testsuite/lib/libstdc++.exp (libstdc++_init): Revert part of
	2007-09-06 change.

From-SVN: r128384
2007-09-11 15:48:15 +00:00
Roger Sayle
3110357b8f acinclude.m4 (GLIBCXX_CHECK_SYSTEM_ERROR): Add ECANCELED for cygwin.
* acinclude.m4 (GLIBCXX_CHECK_SYSTEM_ERROR): Add ECANCELED for cygwin.
	* configure: Regenerate.
	* config/os/generic/error_constants.h: Guard.
	* testsuite/19_diagnostics/headers/system_error/
	types_std_c++0x.cc: Same.

From-SVN: r128307
2007-09-09 21:47:04 +00:00
Benjamin Kosnik
0098d80686 binary_search.cc: Move...
2007-09-09  Benjamin Kosnik  <bkoz@redhat.com>
	
	* testsuite/25_algorithms/binary_search.cc: Move...
	* testsuite/25_algorithms/binary_search/2.cc: ...here.

	* testsuite/25_algorithms/sort.cc: Move...	
	* testsuite/25_algorithms/sort/1.cc: ...here.
	* testsuite/25_algorithms/partial_sort_copy/2.cc: ...here.
	* testsuite/25_algorithms/nth_element/3.cc: ...here.
	* testsuite/25_algorithms/partial_sort/2.cc: ...here.
	* testsuite/25_algorithms/stable_sort/2.cc: ...here.

	* testsuite/25_algorithms/min_max.cc: Move...
	* testsuite/25_algorithms/min/1.cc: ...here.
	* testsuite/25_algorithms/min/2.cc: ...here.
	* testsuite/25_algorithms/max/1.cc: ...here.
	* testsuite/25_algorithms/max/2.cc: ...here.

From-SVN: r128303
2007-09-09 18:56:00 +00:00
Joseph Myers
7cff41e891 file-format.exp (gcc_target_object_format): Use remote_exec to call objdump.
gcc/testsuite:
	* lib/file-format.exp (gcc_target_object_format): Use remote_exec
	to call objdump.
	* lib/scanasm.exp (scan-assembler-dem, scan-assembler-dem-not):
	Use remote_exec to call c++filt.
	* lib/target-supports-dg.exp (dg-require-host-local): New.
	* gcc.misc-tests/options.exp: Allow .exe in command paths.
	* g++.dg/parse/repo1.C: Use dg-require-host-local.
	* g++.dg/rtti/repo1.C: Likewise.
	* g++.dg/template/repo1.C: Likewise.
	* g++.dg/template/repo2.C: Likewise.
	* g++.dg/template/repo3.C: Likewise.
	* g++.dg/template/repo4.C: Likewise.
	* g++.dg/template/repo5.C: Likewise.
	* g++.old-deja/g++.pt/instantiate4.C: Likewise.
	* g++.old-deja/g++.pt/instantiate6.C: Likewise.
	* g++.old-deja/g++.pt/repo1.C: Likewise.
	* g++.old-deja/g++.pt/repo2.C: Likewise.
	* g++.old-deja/g++.pt/repo3.C: Likewise.
	* g++.old-deja/g++.pt/repo4.C: Likewise.
	* gcc.dg/cpp/trad/builtins.c: Likewise.

libstdc++-v3:
	* testsuite/lib/libstdc++.exp (v3-build-support): Specify output
	file for preprocessing.  Use remote_exec to call ar and ranlib.

From-SVN: r128283
2007-09-09 02:10:17 +01:00
Benjamin Kosnik
9adfc73cd3 functional_hash.h: Add ext/numeric_traits.h.
2007-09-08  Benjamin Kosnik  <bkoz@redhat.com>

	* include/bits/functional_hash.h: Add ext/numeric_traits.h.
	* include/tr1/functional_hash.h Same.
	* include/tr1/functional: Remove string, ext/type_traits.h includes.
	* include/tr1_impl/functional_hash.h: Move string, wstring
	definitions for std::<hash>::operator into separate file.
	* include/std/functional
	* src/hash.cc: New, move definitions here.
	* src/hash_c++0x.cc: Same.
	* src/Makefile.am: Add new source files.
	* configure: Regenerate.
	* Makefile.in: Same.
	* src/Makefile.in: Same.
	* po/Makefile.in: Same.
	* libmath/Makefile.in: Same.
	* libsupc++/Makefile.in: Same.
	* testsuite/Makefile.in: Same.
	* config/abi/pre/gnu.ver: Add symbols.
	* config/abi/pre/gnu-versioned-namespace.ver: Same, fix.

From-SVN: r128278
2007-09-09 00:05:13 +00:00
Benjamin Kosnik
12187c13b9 copy_neg.cc: Correct line number.
2007-09-07  Benjamin Kosnik  <bkoz@redhat.com>

	* testsuite/19_diagnostics/error_category/cons/copy_neg.cc:
	Correct line number.

From-SVN: r128255
2007-09-07 21:09:35 +00:00
Danny Smith
e4bf5dfca1 re PR libstdc++/33203 (libstdc++-v3 build broken on i386-pc-mingw32)
PR libstdc++/33203
	* configure.host (error_constants_dir):  New variable,
	defaulting to os/generic.
	( mingw32*): Overide default.
	* configure.ac (ERROR_CONSTANTS_SRCDIR): New.
	* configure: Regenerate.
	* include/Makefile.am (host_headers): Add
	$(ERROR_CONSTANTS_SRCDIR)/error_constants.h .
	* include/Makefile.in: Regenerate.
	* include/std/system_error (enum posix_errno): Remove.
	Include <bits/error_constants.h> instead.
	* config/os/mingw32/error_constants.h: New.
	* config/os/generic/error_constants.h: New.

From-SVN: r128228
2007-09-07 04:18:40 +00:00
Benjamin Kosnik
bd1a56a0c3 libstdc++.exp: Check CXXFLAGS.
2007-09-06  Benjamin Kosnik  <bkoz@redhat.com>

	* testsuite/lib/libstdc++.exp: Check CXXFLAGS.
	* scripts/testsuite_flags.in: CXXFLAGS_default, matching dejagnu.

	* include/std/ostream: Spacing tweak.
	* include/ext/hashtable.h: Use <algorithm>.
	* include/ext/slist: Same.
	* include/ext/rope: Same.
	* include/bits/stl_function.h: Format.
	* include/tr1_impl/array: Remove section number in doxygen markup.
	* src/list.cc: Comment tweak.	
	
	* docs/doxygen/user.cfg.in: Update for include/tr1_impl.
	
	* testsuite/25_algorithms/search_n/iterator.cc: Add using declaration.
	* testsuite/25_algorithms/nth_element/1.cc:  Same.
	* testsuite/21_strings/char_traits/requirements/short/1.cc: Use
	char_type typedef to the underlying character type.	
	* testsuite/21_strings/char_traits/requirements/wchar_t/typedefs.cc:
	Remove -ansi -pedantic-errors.
	* testsuite/21_strings/char_traits/requirements/char/typedefs.cc: Same.
	* testsuite/tr1/6_containers/headers/functional/synopsis.cc:
	Remove specializations.

From-SVN: r128225
2007-09-07 03:01:53 +00:00
Benjamin Kosnik
e054e6fb64 re PR libstdc++/29367 (pb_ds hash containers vs. _GLIBCXX_DEBUG)
2007-09-06  Benjamin Kosnik  <bkoz@redhat.com>
	
	PR libstdc++/29367
	* include/ext/pb_ds/detail/map_debug_base.hpp: From this..
	* include/ext/pb_ds/detail/debug_map_base.hpp: ...to this.
	Rename map_debug_base to debug_map_base, add std::pair output
	extractors, change duplicate map_debug_base typedef in containers
	to debug_base. Use m_store_extra_indicator for m_store_hash_indicator.
	* include/ext/pb_ds/*: Likewise.
	* include/Makefile.am: Same.
	* include/Makefile.in: Regenerate.

From-SVN: r128222
2007-09-07 02:25:45 +00:00
Benjamin Kosnik
551fe1a243 re PR libstdc++/29367 (pb_ds hash containers vs. _GLIBCXX_DEBUG)
2007-09-06  Benjamin Kosnik  <bkoz@redhat.com>
	
	PR libstdc++/29367
	* include/ext/pb_ds/detail/map_debug_base.hpp: From this..
	* include/ext/pb_ds/detail/debug_map_base.hpp: ...to this.
	Rename map_debug_base to debug_map_base, add std::pair output
	extractors, change duplicate map_debug_base typedef in containers
	to debug_base. Use m_store_extra_indicator for m_store_hash_indicator.
	* include/ext/pb_ds/*: Likewise.
	* include/Makefile.am: Same.
	* include/Makefile.in: Regenerate.

From-SVN: r128221
2007-09-07 02:20:58 +00:00
Paolo Carlini
ccd04b9f89 stl_vector.h (_Vector_base<>::_M_allocate): Do not call _M_impl.allocate when __n == 0.
2007-09-06  Paolo Carlini  <pcarlini@suse.de>

	* include/bits/stl_vector.h (_Vector_base<>::_M_allocate):
	Do not call _M_impl.allocate when __n == 0.
	* testsuite/23_containers/vector/zero_sized_allocations.cc: New.

From-SVN: r128220
2007-09-07 01:37:31 +00:00
Matthias Klose
6f6cc094a0 cstdlib: Remove empty directory.
2007-09-06  Matthias Klose  <doko@debian.org>

        * testsuite/27_io/headers/cstdlib: Remove empty directory.

From-SVN: r128204
2007-09-06 19:17:30 +00:00
Roger Sayle
7336815f6f acinclude.m4 (GLIBCXX_CHECK_SYSTEM_ERROR): Add EBADMSG for darwin.
* acinclude.m4 (GLIBCXX_CHECK_SYSTEM_ERROR): Add EBADMSG for darwin.
	* configure: Regenerate.
	* include/std/system_error: Guard.
	* testsuite/19_diagnostics/headers/system_error/
	types_std_c++0x.cc: Same.
	* testsuite/19_diagnostics/error_category/cons/copy_neg.cc: Adjust
	line numbers.

From-SVN: r128154
2007-09-05 21:30:04 +00:00
Paolo Carlini
d46c958bfa re PR libstdc++/33293 (inlining std::inner_product())
2007-09-03  Paolo Carlini  <pcarlini@suse.de>

	PR libstdc++/33293
	* include/bits/stl_numeric.h (accumulate, inner_product):
	Add inline function-specifier.

From-SVN: r128053
2007-09-03 17:48:31 +00:00
Doug Gregor
1ab28be596 mangle.c (write_type): Change mangling of rvalue reference from RR' to O'.
2007-08-31  Douglas Gregor  <doug.gregor@gmail.com>

	* mangle.c (write_type): Change mangling of rvalue reference from
	`RR' to `O'. 

2007-08-31  Douglas Gregor  <doug.gregor@gmail.com>
	
	* demangle.h (enum demangle_component_type): Add
	DEMANGLE_COMPONENT_RVALUE_REFERENCE. 

2007-08-31  Douglas Gregor  <doug.gregor@gmail.com>
	
	* cp-demangle.c (d_dump): Handle
	DEMANGLE_COMPONENT_RVALUE_REFERENCE. 
	(d_make_comp): Ditto.
	(cplus_demangle_type): Ditto.
	(d_print_comp): Ditto.
	(d_print_mod): Ditto.
	(d_print_function_type): Ditto.

2007-08-31  Douglas Gregor  <doug.gregor@gmail.com>

	* testsuite/abi/demangle/cxx0x/rref.cc: New.

From-SVN: r127999
2007-08-31 19:15:26 +00:00
Benjamin Kosnik
e4e5e7f5f8 acinclude.m4 (GLIBCXX_CHECK_SYSTEM_ERROR): Add ENODATA, ENOSR, ENOSTR, ETIME for freebsd.
2007-08-29  Benjamin Kosnik  <bkoz@redhat.com>

	* acinclude.m4 (GLIBCXX_CHECK_SYSTEM_ERROR): Add ENODATA, ENOSR,
	ENOSTR, ETIME for freebsd.	
	* configure: Regenerate.
	* include/std/system_error: Guard.	
	* testsuite/19_diagnostics/headers/system_error/
	types_std_c++0x.cc: Same.
	* testsuite/19_diagnostics/error_category/cons/copy_neg.cc: Adjust
	line numbers.

From-SVN: r127912
2007-08-29 19:53:50 +00:00
Paolo Carlini
44d5230cc3 re PR libstdc++/33128 (std::tr1::uniform_int returns value out of range)
2007-08-28  Paolo Carlini  <pcarlini@suse.de>

	PR libstdc++/33128
	* include/tr1_impl/random (uniform_int<>::_M_call): Deal with
	__urng() returning negative values.
	* testsuite/tr1/5_numerical_facilities/random/uniform_int/33128.cc:
	New.

From-SVN: r127849
2007-08-28 08:48:24 +00:00
Benjamin Kosnik
80bf9cff52 acinclude.m4: Fix duplicate variable names.
2007-08-24  Benjamin Kosnik  <bkoz@redhat.com>

	* acinclude.m4: Fix duplicate variable names.
	* configure: Regenerate.

From-SVN: r127784
2007-08-24 18:05:54 +00:00
Benjamin Kosnik
c6a8035acf acinclude.m4 (GLIBCXX_CHECK_SYSTEM_ERROR): Add ENOLINK, EPROTO for netbsd.
2007-08-24  Benjamin Kosnik  <bkoz@redhat.com>

	* acinclude.m4 (GLIBCXX_CHECK_SYSTEM_ERROR): Add ENOLINK, EPROTO
	for netbsd.
	* configure: Regenerate.
	* include/std/system_error: Guard.	
	* testsuite/19_diagnostics/headers/system_error/
	types_std_c++0x.cc: Same.
	* testsuite/19_diagnostics/error_category/cons/copy_neg.cc: Adjust
	line numbers.

From-SVN: r127772
2007-08-24 15:19:36 +00:00