François Dumont [Fri, 8 Mar 2013 20:08:20 +0000 (20:08 +0000)]
vector.tcc (vector<>operator=(const vector<>&): Reset pointers after deallocation when memory can be reused.
2013-03-08 François Dumont <fdumont@gcc.gnu.org>
* include/bits/vector.tcc (vector<>operator=(const vector<>&):
Reset pointers after deallocation when memory can be reused.
* testsuite/23_containers/vector/allocator/minimal.cc: Insert
elements to really challenge C++11 allocator integration.
* testsuite/23_containers/vector/allocator/copy.cc: Likewise.
* testsuite/23_containers/vector/allocator/copy_assign.cc:
Likewise.
* testsuite/23_containers/vector/allocator/move_assign.cc:
Likewise.
* testsuite/23_containers/vector/allocator/swap.cc: Likewise and
swap vector back before checks on memory/personality mapping are
performed.
* testsuite/23_containers/forward_list/allocator/minimal.cc:
Insert element to really challenge C++11 allocator integration.
* testsuite/23_containers/forward_list/allocator/copy.cc:
Likewise.
* testsuite/23_containers/forward_list/allocator/copy_assign.cc:
Likewise.
* testsuite/23_containers/forward_list/allocator/move_assign.cc:
Likewise.
* testsuite/23_containers/forward_list/allocator/swap.cc: Likewise
and swap forward_list back before checks on memory/personality
mapping are performed.
Marek Polacek [Fri, 8 Mar 2013 14:41:14 +0000 (14:41 +0000)]
re PR tree-optimization/56478 (ICE: Floating point exception in tree_estimate_probability)
PR tree-optimization/56478
* predict.c (is_comparison_with_loop_invariant_p): Change the
type of loop_step to tree.
(predict_loops): Adjust.
(predict_iv_comparison): Perform the computations on double_ints.
Co-Authored-By: Jakub Jelinek <jakub@redhat.com>
From-SVN: r196547
Richard Biener [Fri, 8 Mar 2013 11:29:06 +0000 (11:29 +0000)]
tree-inline.c (expand_call_inline): Do not associate a BLOCK with the location in BLOCK_SOURCE_LOCATION.
2013-03-08 Richard Biener <rguenther@suse.de>
* tree-inline.c (expand_call_inline): Do not associate
a BLOCK with the location in BLOCK_SOURCE_LOCATION.
* tree-cfg.c (verify_location): Verify BLOCK_SOURCE_LOCATION.
Richard Biener [Fri, 8 Mar 2013 08:45:29 +0000 (08:45 +0000)]
tree-ssa-ter.c (is_replaceable_p): Do not TER across location or block changes with -Og.
2013-03-08 Richard Biener <rguenther@suse.de>
* tree-ssa-ter.c (is_replaceable_p): Do not TER across location
or block changes with -Og. Fix for location / block encoding
changes and PHI arguments with locations.
Steven Bosscher [Thu, 7 Mar 2013 17:27:52 +0000 (17:27 +0000)]
bitmap.c (struct bitmap_descriptor_d): Use unsigned HOST_WIDEST_INT for all counters.
* bitmap.c (struct bitmap_descriptor_d): Use unsigned HOST_WIDEST_INT
for all counters.
(struct output_info): Likewise.
(register_overhead): Remove bad gcc_assert.
(bitmap_find_bit): If there is only a single bitmap element, do not
count a miss as a search.
(print_statistics): Update for counter type changes.
(dump_bitmap_statistics): Likewise. Print headers such that they
are properly lined up with the printed counters.
Jakub Jelinek [Wed, 6 Mar 2013 23:26:42 +0000 (00:26 +0100)]
re PR tree-optimization/56539 (ICE: verify_ssa failed: caused by -foptimize-sibling-calls)
PR tree-optimization/56539
* tree-tailcall.c (adjust_return_value_with_ops): Use GSI_SAME_STMT
instead of GSI_CONTINUE_LINKING as last argument to
force_gimple_operand_gsi.
Kai Tietz [Wed, 6 Mar 2013 18:29:46 +0000 (19:29 +0100)]
20090914-2_0.c: Skip for mingw and cygwin targets.
* gcc.dg/lto/20090914-2_0.c: Skip for mingw and cygwin
targets.
* gcc.dg/lto/20091013-1_1.c: Set x64-mingw as xfail.
* gcc.dg/lto/20091013-1_2.c: Likewise.
* gcc.dg/pr31490.c: Adjust for LLP64 targets.
Richard Biener [Wed, 6 Mar 2013 11:24:07 +0000 (11:24 +0000)]
re PR tree-optimization/56294 (BOOT_CFLAGS='-O2 -g -fno-ipa-sra' leads to bootstrap comparison failure)
2013-03-06 Richard Biener <rguenther@suse.de>
PR middle-end/56294
* tree-into-ssa.c (insert_phi_nodes_for): Add dumping.
(insert_updated_phi_nodes_compare_uids): New function.
(update_ssa): Sort symbols_to_rename after UID before
traversing it to insert PHI nodes.
Richard Biener [Wed, 6 Mar 2013 08:38:46 +0000 (08:38 +0000)]
re PR lto/50494 (gcc.dg/vect/vect-reduc-2char.c fails spuriously on ppc with -flto)
2013-03-06 Richard Biener <rguenther@suse.de>
PR middle-end/50494
* tree-vect-data-refs.c (vect_can_force_dr_alignment_p):
Do not adjust alignment of DECL_IN_CONSTANT_POOL decls.
Revert
2013-02-13 Richard Biener <rguenther@suse.de>
PR lto/50494
* varasm.c (output_constant_def_1): Get the decl representing
the constant as argument.
(output_constant_def): Wrap output_constant_def_1.
(make_decl_rtl): Use output_constant_def_1 with the decl
representing the constant.
(build_constant_desc): Optionally re-use a decl already
representing the constant.
(tree_output_constant_def): Adjust.
Oleg Endo [Wed, 6 Mar 2013 00:41:25 +0000 (00:41 +0000)]
re PR target/56529 ([SH] Calls to __sdivsi3_i4i and __udivsi3_i4i are generated on SH2)
PR target/56529
* config/sh/sh.c (sh_option_override): Check for TARGET_DYNSHIFT
instead of TARGET_SH2 for call-table case. Do not set sh_div_strategy
to SH_DIV_CALL_TABLE for TARGET_SH2.
* config.gcc (sh_multilibs): Add m2 and m2a to sh*-*-linux* multilib
list.
* doc/invoke.texi (SH options): Document mdiv= call-div1, call-fp,
call-table options.
Jakub Jelinek [Tue, 5 Mar 2013 22:31:50 +0000 (23:31 +0100)]
re PR debug/56510 (More var-tracking scalability problems)
PR debug/56510
* cfgexpand.c (expand_debug_parm_decl): Call copy_rtx on incoming.
(avoid_complex_debug_insns): New function.
(expand_debug_locations): Call it.
Jakub Jelinek [Tue, 5 Mar 2013 22:25:43 +0000 (23:25 +0100)]
re PR rtl-optimization/56484 (ICE in assign_by_spills, at lra-assigns.c:1268)
PR rtl-optimization/56484
* ifcvt.c (noce_process_if_block): If else_bb is NULL, avoid extending
lifetimes of hard registers on small register class machines.
Jakub Jelinek [Tue, 5 Mar 2013 15:51:48 +0000 (16:51 +0100)]
re PR middle-end/56461 (GCC is leaking lots of memory)
PR middle-end/56461
* ggc-common.c (gt_pch_save): For ENABLE_VALGRIND_CHECKING,
if VALGRIND_GET_VBITS is defined, temporarily make object
memory all defined, and restore previous valgrind addressability
and definability afterwards. Free this_object at the end.
* c-pch.c (pch_init): Free target_validity at the end.
Jakub Jelinek [Tue, 5 Mar 2013 15:50:38 +0000 (16:50 +0100)]
re PR middle-end/56461 (GCC is leaking lots of memory)
PR middle-end/56461
* lra.c (lra): Call lra_clear_live_ranges if live_p,
right before calling lra_create_live_ranges, also call it
when clearing live_p. Only call lra_clear_live_ranges
at the end if live_p.
Steven Bosscher [Tue, 5 Mar 2013 14:45:23 +0000 (14:45 +0000)]
re PR c++/55135 (Segfault of gcc on a big file)
gcc/
PR c++/55135
* except.h (remove_unreachable_eh_regions): New prototype.
* except.c (remove_eh_handler_splicer): New function, split out
of remove_eh_handler.
(remove_eh_handler): Use remove_eh_handler_splicer. Add comment
warning about running it on many EH regions one at a time.
(remove_unreachable_eh_regions_worker): New function, walk the
EH tree in depth-first order and remove non-marked regions.
(remove_unreachable_eh_regions): New function.
* tree-eh.c (mark_reachable_handlers): New function, split out
from remove_unreachable_handlers.
(remove_unreachable_handlers): Use mark_reachable_handlers and
remove_unreachable_eh_regions.
(remove_unreachable_handlers_no_lp): Use mark_reachable_handlers
and remove_unreachable_eh_regions.
Jakub Jelinek [Tue, 5 Mar 2013 09:46:34 +0000 (10:46 +0100)]
Makefile.in (dg_target_exps): Add aarch64.exp, epiphany.exp and tic6x.exp.
* Makefile.in (dg_target_exps): Add aarch64.exp, epiphany.exp and
tic6x.exp.
(check_gcc_parallelize): Run guality.exp as a separate job from
vect.exp with unsorted.exp and $(dg_target_exps) separately from
struct-layout-1.exp with stackalign.exp.
Jakub Jelinek [Tue, 5 Mar 2013 09:38:48 +0000 (10:38 +0100)]
re PR middle-end/56461 (GCC is leaking lots of memory)
PR middle-end/56461
* tree-ssa-loop-niter.c (bb_queue): Remove typedef.
(discover_iteration_bound_by_body_walk): Change queues to
vec<vec<basic_block> > and queue to vec<basic_block>. Fix up
spelling in comment. Call safe_push on queues[bound_index] directly.
Release queues[queue_index] in every iteration unconditionally.
Release bounds vector.
Jakub Jelinek [Tue, 5 Mar 2013 09:37:56 +0000 (10:37 +0100)]
re PR middle-end/56461 (GCC is leaking lots of memory)
PR middle-end/56461
* tree-vect-stmts.c (free_stmt_vec_info_vec): Call
free_stmt_vec_info on any left-over stmt_vec_info in the vector.
* tree-vect-loop.c (vect_create_epilog_for_reduction): Release
inner_phis vector.
Richard Biener [Tue, 5 Mar 2013 09:20:30 +0000 (09:20 +0000)]
re PR lto/56515 (location references block not in block tree, verify_gimple failed (LTO + profile))
2013-03-05 Richard Biener <rguenther@suse.de>
PR lto/56515
* tree-inline.c (remap_blocks_to_null): New function.
(expand_call_inline): When expanding a call stmt without
an associated block inline remap all callee blocks to NULL.
Jakub Jelinek [Tue, 5 Mar 2013 06:04:14 +0000 (07:04 +0100)]
re PR rtl-optimization/56494 (ICE in simplify_truncation, at simplify-rtx.c:619)
PR rtl-optimization/56494
* simplify-rtx.c (simplify_truncation): If C is narrower than A,
optimize (truncate:A (subreg:B (truncate:C X) 0)) into
(subreg:A (truncate:C X) 0) instead of (truncate:A X).
Jakub Jelinek [Mon, 4 Mar 2013 10:06:22 +0000 (11:06 +0100)]
re PR middle-end/56461 (GCC is leaking lots of memory)
PR middle-end/56461
* tree-vect-stmts.c (vectorizable_shift): Don't call create methods
on vec_oprnds0 or vec_oprnds1 before loop, only call it on
vec_oprnds1 right before pushing anything to it for
scalar_shift_arg.
Jakub Jelinek [Mon, 4 Mar 2013 10:02:26 +0000 (11:02 +0100)]
re PR middle-end/56461 (GCC is leaking lots of memory)
PR middle-end/56461
* tree-vect-loop.c (destroy_loop_vec_info): For !clean_stmts, just
set nbbs to 0 instead of having separate code path.
(vect_analyze_loop_form): Call destroy_loop_vec_info with true
instead of false as last argument if returning NULL.
gcc/
* target.def (TARGET_OPTION_VALID_ATTRIBUTE_P): Update comments;
the attribute is now called "target" instead of "option".
(TARGET_OPTION_PRAGMA_PARSE): Likewise, for the pragma.
* doc/tm.texi.in (Target Attributes): Likewise document the correct
attribute/pragma name for TARGET_OPTION_VALID_P and
TARGET_OPTION_PRAGMA_PARSE. Also copy-edit and correct markup.
* doc/tm.texi: Regenerated.