2005-06-03 Paolo Carlini <pcarlini@suse.de>
PR libstdc++/21770
* include/bits/stl_deque.h: Add concept-check. In class _Deque_base
rebind _Alloc to _Tp_alloc_type, change _Deque_impl to inherit from
the latter and add _M_get_Tp_allocator() which returns it. Use
everywhere _M_get_Tp_allocator() instead of get_allocator().
* include/bits/deque.tcc: Likewise, use _M_get_Tp_allocator().
* include/bits/stl_list.h: Add concept-check. In class _List_base
rebind _Alloc to _Tp_alloc_type and add _M_get_Tp_allocator(), which
returns the allocator (of type _Node_alloc_type) converted to
_Tp_alloc_type. Use everywhere _M_get_Tp_allocator() instead of
get_allocator().
* include/bits/list.tcc: Likewise, use _M_get_Tp_allocator().
* include/bits/stl_vector.h: Add concept-check. In class _Vector_base
rebind _Alloc to _Tp_alloc_type, change _Vector_impl to inherit from
the latter and add _M_get_Tp_allocator() which returns it. Use
everywhere _M_get_Tp_allocator() instead of get_allocator().
* include/bits/vector.tcc: Likewise, use _M_get_Tp_allocator().
* include/bits/stl_map.h: Add concept-check. Rebind _Alloc to
_Pair_alloc_type and use it for _Rb_tree.
* include/bits/stl_multimap.h: Likewise.
* include/bits/stl_multiset.h: Add concept-check. Rebind _Alloc to
_Key_alloc_type and use it for _Rb_tree.
* include/bits/stl_set.h: Likewise.
* include/bits/basic_string.h: Rebind _Alloc to _CharT_alloc_type and
use it for the allocator typedefs.
* testsuite/21_strings/basic_string/1.cc: New.
* testsuite/23_containers/deque/explicit_instantiation.cc: Move to...
* testsuite/23_containers/deque/explicit_instantiation/1.cc: ... here.
* testsuite/23_containers/deque/explicit_instantiation/3.cc: New.
* testsuite/23_containers/list/explicit_instantiation.cc: Move to...
* testsuite/23_containers/list/explicit_instantiation/1.cc: ... here.
* testsuite/23_containers/list/explicit_instantiation/3.cc: New.
* testsuite/23_containers/map/explicit_instantiation.cc: Move to...
* testsuite/23_containers/map/explicit_instantiation/1.cc: ... here.
* testsuite/23_containers/map/explicit_instantiation/3.cc: New.
* testsuite/23_containers/multimap/explicit_instantiation.cc: Move to...
* testsuite/23_containers/multimap/explicit_instantiation/1.cc: .. here.
* testsuite/23_containers/multimap/explicit_instantiation/3.cc: New.
* testsuite/23_containers/multiset/explicit_instantiation.cc: Move to...
* testsuite/23_containers/multiset/explicit_instantiation/1.cc: .. here.
* testsuite/23_containers/multiset/explicit_instantiation/3.cc: New.
* testsuite/23_containers/set/explicit_instantiation.cc: Move to...
* testsuite/23_containers/set/explicit_instantiation/1.cc: .. here.
* testsuite/23_containers/set/explicit_instantiation/3.cc: New.
* testsuite/23_containers/vector/explicit_instantiation.cc: Move to...
* testsuite/23_containers/vector/explicit_instantiation/1.cc: ... here.
* testsuite/23_containers/vector/explicit_instantiation/3.cc: New.
From-SVN: r100546
PR c++/21336
* cp-tree.h (grok_op_properties): Remove friendp parameter.
* decl.c (grokfndecl): Adjust call.
(grok_op_properties): Determine the class of which the function is
a member by looking at its DECL_CONTEXT, not current_class_type.
* pt.c (tsubst_decl): Adjust call to grok_op_properties.
PR c++/21336
* g++.dg/template/new2.C: New test.
From-SVN: r100541
2005-06-03 Richard Guenther <rguenth@gcc.gnu.org>
PR middle-end/21858
* fold-const.c (fold_binary): Fix type mismatches in folding
of comparisons.
* gcc.dg/pr21858.c: New testcase.
From-SVN: r100539
PR java/21722:
* class.c (build_static_field_ref): Don't fold constant fields if
current class is from a .class file and we're using indirect
dispatch.
From-SVN: r100533
2005-06-03 Andrew Pinski <pinskia@physics.uc.edu>
* trans.c (gnat_gimplify_expr): Call
recompute_tree_invarant_for_addr_expr when we change
the operand of the ADDR_EXPR.
From-SVN: r100522
2005-06-02 Richard Guenther <rguenth@gcc.gnu.org>
* tree-chrec.c (chrec_fold_plus_1): Ensure we build
binary operations with the correct types.
* tree-ssa-loo-ivopts.c (idx_find_step): Use sizetype
for all computation.
From-SVN: r100517
2005-05-31 Geoffrey Keating <geoffk@geoffk.org>
* config/rs6000/rs6000.md (sync_boolcshort_internal): New.
* config/rs6000/rs6000.c (rs6000_emit_sync): Shift count must
be complemented for big-endian. Mask for AND must be rotated,
not shifted. Handle short operands with NOT on the memory
operation.
Index: testsuite/ChangeLog
2005-05-31 Geoffrey Keating <geoffk@geoffk.org>
* lib/target-supports.exp
(check_effective_target_sync_char_short): New.
* gcc.dg/sync-2.c: New.
From-SVN: r100515
* gimplify.c (gimplify_ctx): Change the type of case_labels to
VEC from VARRAY.
(gimplify_switch_expr, gimplify_case_label_expr): Adjust uses
of case_labels.
From-SVN: r100513
* configure.in: Set noconfigdirs for ms1.
* configure: Regenerate.
Co-Authored-By: Michael Snyder <msnyder@redhat.com>
Co-Authored-By: Stan Cox <scox@redhat.com>
From-SVN: r100509
2005-06-02 Eric Christopher <echristo@redhat.com>
* config/mips/mips.h (processor_type): Remove PROCESSOR_DEFAULT,
add PROCESSOR_MAX.
(mips_rtx_cost_data): New datatype.
(MEMORY_MOVE_COST): Use data from structure.
(BRANCH_COST): Ditto.
(LOGICAL_OP_NON_SHORT_CIRCUIT): Define to zero.
* config/mips/mips.md (cpu): Rework for processor_type changes.
* config/mips/mips.c (mips_cost): New variable.
(DEFAULT_COSTS): Define.
(mips_rtx_cost_data): New.
(mips_rtx_costs): Use. Minor formatting changes. Use COSTS_N_INSNS
for NEG cost. Add support for FLOAT, UNSIGNED_FLOAT, FIX,
FLOAT_EXTEND, FLOAT_TRUNCATE, and SQRT.
(override_options): Set cost data.
(mips_register_move_cost): Formatting changes.
(bdesc_arrays): Use PROCESSOR_MAX.
(mips_init_builtins): Ditto.
From-SVN: r100503
cp:
PR c++/21280
* Make-lang.in (method.o): Add diagnostic.h
* decl.c (start_preparsed_function): Use decl's location for file
info.
* decl2.c (cp_finish_file): Set input_location before synthesizing
a function.
(mark_used): When deferring a synthesized function, save current
location. Do not set function's location when actually
synthesizing it.
* method.c: #include diagnostic.h.
(synthesize_method): Set the functions source location. Show
needed location if errors are emitted.
testsuite:
PR c++/21280
* g++.dg/opt/interface2.h: New.
* g++.dg/opt/interface2.C: New.
* g++.dg/init/ctor4.C: Adjust error lines.
* g++.old-deja/g++.bob/inherit2.C: Likewise.
* g++.old-deja/g++.bugs/900205_04.C: Likewise.
* g++.old-deja/g++.jason/opeq3.C: Likewise.
* g++.old-deja/g++.pt/assign1.C: Likewise.
* g++.old-deja/g++.pt/crash20.C: Likewise.
From-SVN: r100500
PR tree-optimization/21734
* tree-vectorizer.c (slpeel_update_phis_for_duplicate_loop): Use the
phi_result when current_def is not available.
(slpeel_update_phi_nodes_for_guard1): Don't fail if current_def is not
available.
From-SVN: r100494
> 2005-06-02 Steven Bosscher <stevenb@suse.de>
> Mostafa Hagog <mustafa@il.ibm.com>
>
> * cfgloop.h (doloop_condition_get): Make external.
> * loop-doloop.c (doloop_condition_get): Generalize to make it
> usable in modulo-sched.c.
> * modulo-sched.c (doloop_register_get): Use
> doloop_condition_get instead of duplicating it.
Co-Authored-By: Mostafa Hagog <mustafa@il.ibm.com>
From-SVN: r100490