2014-05-24 Dominique d'Humieres <dominiq@lps.ens.fr>
Backport r195492 and r195815
2013-01-27 Paul Thomas <pault@gcc.gnu.org>
PR fortran/55789
* gfortran.dg/associate_14.f90: New test.
PR fortran/56047
* gfortran.dg/associate_13.f90: New test.
2013-02-06 Paul Thomas <pault@gcc.gnu.org>
PR fortran/55789
* gfortran.dg/array_constructor_41.f90: New test.
From-SVN: r210894
2014-05-24 Dominique d'Humieres <dominiq@lps.ens.fr>
Backport r195492 and r195815
2013-01-27 Paul Thomas <pault@gcc.gnu.org>
PR fortran/55789
PR fortran/56047
* gfortran.h : Add associate_var to symbol_attr.
* resolve.c (resolve_assoc_var): Set associate_var attribute.
If the target class_ok is set, set it for the associate
variable.
* check.c (allocatable_check): Associate variables should not
have the allocatable attribute even if their symbols do.
* class.c (gfc_build_class_symbol): Symbols with associate_var
set will always have a good class container.
2013-02-06 Paul Thomas <pault@gcc.gnu.org>
PR fortran/55789
* trans-array.c (trans_array_constructor): Remove condition
'dynamic' = true if the loop ubound is a VAR_DECL.
From-SVN: r210893
2014-05-23 Richard Biener <rguenther@suse.de>
Backport from mainline
2013-08-30 Richard Biener <rguenther@suse.de>
PR tree-optimization/58228
* tree-vect-data-refs.c (vect_analyze_data_ref_access): Do not
allow invariant loads in nested loop vectorization.
* gcc.dg/torture/pr58228.c: New testcase.
2013-09-26 Richard Biener <rguenther@suse.de>
PR tree-optimization/58539
* tree-vect-loop.c (vect_create_epilog_for_reduction): Honor
the fact that debug statements are not taking part in loop-closed
SSA construction.
* gcc.dg/torture/pr58539.c: New testcase.
From-SVN: r210847
2014-05-16 Janne Blomqvist <jb@gcc.gnu.org>
Backport from trunk:
PR libfortran/61187
* io/unix.c (raw_close): Check if s->fd is -1.
(fd_to_stream): Check return value of fstat(), handle error.
From-SVN: r210529
2014-05-13 Richard Biener <rguenther@suse.de>
Backport from mainline
2014-03-04 Richard Biener <rguenther@suse.de>
PR tree-optimization/60382
* tree-vect-loop.c (vect_is_simple_reduction_1): Do not consider
dead PHIs a reduction.
* gcc.dg/vect/pr60382.c: New testcase.
From-SVN: r210371
gcc/
Backport from 2014-05-09 trunk r210267
PR target/61055
* config/avr/avr.md (cc): Add new attribute set_vzn.
(addqi3, negqi2) [cc]:
Set cc insn attribute to set_vzn instead of set_zn for alternatives
with INC, DEC or NEG.
* config/avr/avr.c (avr_notice_update_cc): Handle SET_VZN.
(avr_out_plus_1): ADIW sets cc0 to CC_SET_CZN.
INC, DEC set cc0 to CC_CLOBBER.
gcc/testsuite/
Backport from 2014-05-09 trunk r210267
PR target/61055
* gcc.target/avr/torture/pr61055.c: New test.
From-SVN: r210270
Backported from mainline
2013-10-21 Marek Polacek <polacek@redhat.com>
PR middle-end/58809
* fold-const.c (fold_range_test): Return 0 if the type is not
an integral type.
* gcc.dg/gomp/pr58809.c: New test.
From-SVN: r210180
Backported from mainline
2013-12-03 Jakub Jelinek <jakub@redhat.com>
PR middle-end/59011
* gimplify.c (nonlocal_vla_vars): New variable.
(gimplify_var_or_parm_decl): Put VAR_DECLs for VLAs into
nonlocal_vla_vars chain.
(gimplify_body): Call declare_vars on nonlocal_vla_vars chain
if outer_bind has DECL_INITIAL (current_function_decl) block.
* gcc.dg/pr59011.c: New test.
From-SVN: r210179
Backported from mainline
2013-11-27 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/59014
* gcc.c-torture/execute/pr59014-2.c: New test.
2013-11-26 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/59014
* tree-vrp.c (register_edge_assert_for_1): Don't look
through conversions from non-integral types or through
narrowing conversions.
* gcc.c-torture/execute/pr59014.c: New test.
From-SVN: r210177
Backported from mainline
2013-11-14 Jakub Jelinek <jakub@redhat.com>
Uros Bizjak <ubizjak@gmail.com>
PR target/59101
* config/i386/i386.md (*anddi_2): Only allow CCZmode if
operands[2] satisfies_constraint_Z that might have bit 31 set.
* gcc.c-torture/execute/pr59101.c: New test.
From-SVN: r210176
Backported from mainline
2013-09-30 Jakub Jelinek <jakub@redhat.com>
PR middle-end/58564
* fold-const.c (fold_ternary_loc): For A < 0 : <sign bit of A> : 0
optimization, punt if sign_bit_p looked through any zero extension.
* gcc.c-torture/execute/pr58564.c: New test.
From-SVN: r210174
Backported from mainline
2013-09-10 Jakub Jelinek <jakub@redhat.com>
PR rtl-optimization/58365
* cfgcleanup.c (merge_memattrs): Also clear MEM_READONLY_P
resp. MEM_NOTRAP_P if they differ, or set MEM_VOLATILE_P if
it differs.
* gcc.c-torture/execute/pr58365.c: New test.
From-SVN: r210173
Backported from mainline
2013-08-30 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/58277
* tree-ssa-strlen.c (strlen_enter_block): If do_invalidate gave up
after seeing too many stmts with vdef in between dombb and current
bb, invalidate everything.
* gcc.c-torture/execute/pr58277-1.c: New test.
* gcc.c-torture/execute/pr58277-2.c: New test.
From-SVN: r210171
Backported from mainline
2013-08-23 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/58209
* tree-tailcall.c (find_tail_calls): Give up for pointer result types
if m or a is non-NULL.
* gcc.c-torture/execute/pr58209.c: New test.
From-SVN: r210170
Backported from mainline
2013-07-03 Jakub Jelinek <jakub@redhat.com>
PR target/57777
* config/i386/predicates.md (vsib_address_operand): Disallow
SYMBOL_REF or LABEL_REF in parts.disp if TARGET_64BIT && flag_pic.
* gcc.target/i386/pr57777.c: New test.
From-SVN: r210169
Backported from mainline
2013-06-27 Jakub Jelinek <jakub@redhat.com>
PR target/57623
* config/i386/i386.md (bmi_bextr_<mode>): Swap predicates and
constraints of operand 1 and 2.
* gcc.target/i386/bmi-bextr-3.c: New test.
From-SVN: r210168
Backported from mainline
2013-06-27 Jakub Jelinek <jakub@redhat.com>
PR target/57623
* config/i386/i386.md (bmi2_bzhi_<mode>3): Swap AND arguments
to match RTL canonicalization. Swap predicates and
constraints of operand 1 and 2.
* gcc.target/i386/bmi2-bzhi-1.c: New test.
From-SVN: r210166
2014-05-07 Richard Biener <rguenther@suse.de>
Backport from mainline
2013-11-19 Richard Biener <rguenther@suse.de>
PR tree-optimization/59164
* tree-vect-loop.c (vect_analyze_loop_operations): Adjust
check whether we can create an epilogue loop to reflect the
cases where we create one.
* gcc.dg/torture/pr59164.c: New testcase.
From-SVN: r210154
2014-05-07 Richard Biener <rguenther@suse.de>
PR tree-optimization/57864
* tree-ssa-pre.c (phi_translate_1): Backport NAME case
simplification from mainline. Do not lookup the VN
value-number here.
* gcc.dg/torture/pr57864.c: New testcase.
From-SVN: r210144
2014-05-07 Richard Biener <rguenther@suse.de>
Backport from mainline
2013-08-29 Richard Biener <rguenther@suse.de>
PR tree-optimization/58246
* tree-ssa-dce.c (mark_aliased_reaching_defs_necessary_1): Properly
handle the dominance check inside a basic-block.
* gcc.dg/torture/pr58246.c: New testcase.
From-SVN: r210141
2014-04-12 Jerry DeLisle <jvdelisle@gcc.gnu>
Backport from mainline
PR libfortran/60810
gfortran.dg/arrayio_13.f90: New test.
PR libfortran/60810
io/unit.c (is_trim_ok): If internal unit is array, do not trim.
From-SVN: r209345
2014-04-06 Dominique d'Humieres <dominiq@lps.ens.fr>
Iain Sandoe <iain@codesourcery.com>
PR target/54083
* gcc.dg/attr-weakref-1.c: Allow the test on darwin with
the additional options -Wl,-undefined,dynamic_lookup and
-Wl,-flat_namespace
* gcc.dg/torture/pr53922.c: Additional option
-Wl,-flat_namespace for darwin[89].
Co-Authored-By: Iain Sandoe <iain@codesourcery.com>
From-SVN: r209162
2014-04-29 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/60522
* frontend-passes.c (cfe_code): Do not walk subtrees
for WHERE.
2014-04-29 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/60522
* gfortran.dg/where_4.f90: New test case.
From-SVN: r208934
PR libstdc++/60658
* include/bits/atomic_base.h (__atomic_base<_PTp*>::is_lock_free()):
Use sizeof pointer type not the element type.
* testsuite/29_atomics/atomic/60658.cc: New.
From-SVN: r208821
PR target/60568
* config/i386/i386.c (x86_output_mi_thunk): Surround UNSPEC_GOT
into CONST, put pic register as first operand of PLUS. Use
gen_const_mem for both 32-bit and 64-bit PIC got loads.
From-SVN: r208717
2014-03-20 Joel Sherrill <joel.sherrill@oarcorp.com>
* config.host (v850*-*-*): Add to tmake_file instead of resetting
it. This was removing the v850*-*-rtems* settings.
From-SVN: r208711
2014-03-18 Richard Biener <rguenther@suse.de>
Backport from mainline
2013-11-05 Richard Biener <rguenther@suse.de>
PR middle-end/58941
* tree-dfa.c (get_ref_base_and_extent): Merge common code
in MEM_REF and TARGET_MEM_REF handling. Make sure to
process trailing array detection before diving into the
view-converted object (and possibly apply some extra offset).
* gcc.dg/torture/pr58941.c: New testcase.
2012-05-07 Eric Botcazou <ebotcazou@adacore.com>
* tree-dfa.c (get_ref_base_and_extent) <ARRAY_REF>: Do the offset
computation using the precision of the index type.
2012-05-31 Eric Botcazou <ebotcazou@adacore.com>
* tree-dfa.c (get_ref_base_and_extent): Compute the offset using
double ints throughout.
From-SVN: r208640
2014-03-18 Richard Biener <rguenther@suse.de>
Backport from mainline
2013-08-27 Richard Biener <rguenther@suse.de>
PR tree-optimization/57521
* tree-if-conv.c (if_convertible_bb_p): Verify that at least
one edge is non-critical.
(find_phi_replacement_condition): Make sure to use a non-critical
edge. Cleanup and remove old bug workarounds.
(bb_postdominates_preds): Remove.
(if_convertible_loop_p_1): Do not compute post-dominators.
(combine_blocks): Do not free post-dominators.
(main_tree_if_conversion): Likewise.
* gcc.dg/torture/pr57521.c: New testcase.
2013-09-03 Richard Biener <rguenther@suse.de>
PR middle-end/57656
* fold-const.c (negate_expr_p): Fix division case.
(negate_expr): Likewise.
* gcc.dg/torture/pr57656.c: New testcase.
2013-11-19 Richard Biener <rguenther@suse.de>
PR tree-optimization/57517
* tree-predcom.c (combinable_refs_p): Verify the combination
is always executed when the refs are.
* gfortran.fortran-torture/compile/pr57517.f90: New testcase.
* gcc.dg/torture/pr57517.c: Likewise.
From-SVN: r208632
2014-03-15 Jerry DeLisle <jvdelisle@gcc.gnu>
Backport from mainline
PR libfortran/58324
PR libfortran/38199
* intrinsics/string_intriniscs_inc.c (string_len_trim):
Remove prototypes for string_len_trim and move to...
* libgfortran.h (string_len_trim): ... here and
(string_len_trim_char4): ...here.
* io/list_read.c (finish_list_read): Read one character to check
for the end of the file. If it is the end, then issue the file
end error message. If not, use eat_line to reach the end
without giving error. The next attempt to read will then
issue the error as described above.
* io/read.c (read_decimal): Quickly skip spaces to avoid calls
to next_char.
* io/unit.c (is_trim_ok): New helper function to check various
conditions to see if its OK to trim the internal unit string.
(get_internal_unit): Use LEN_TRIM to shorten selected internal
unit strings for optimizing READ. Enable this optimization for
formatted READ.
Backport from mainline
PR libfortran/58324
* gfortran.dg/list_read_12.f90: New test.
From-SVN: r208599
Backport from 2014-03-14 trunk r208562.
PR target/59396
* config/avr/avr.c (avr_set_current_function): Pass function name
through default_strip_name_encoding before sanity checking instead
of skipping the first char of the assembler name.
From-SVN: r208565
PR ada/51483
* back_end.ads (Register_Type_Proc): Add 'precision' parameter.
* cstand.adb (Register_Float_Type): Add 'precision' parameter and use
it to set the RM size. Use directly 'size' for the Esize.
* gcc-interface/gigi.h (enumerate_modes): Add integer parameter.
* gcc-interface/misc.c (enumerate_modes): Likewise. Do not register
types for vector modes, pass the size in addition to the precision.
From-SVN: r208548
2014-03-09 Janus Weil <janus@gcc.gnu.org>
Backport from 4.8
2014-03-08 Janus Weil <janus@gcc.gnu.org>
PR fortran/60450
* simplify.c (gfc_simplify_shape): Only clear shape if it was really
created successfully.
2014-03-09 Janus Weil <janus@gcc.gnu.org>
Backport from 4.8
2014-03-08 Janus Weil <janus@gcc.gnu.org>
PR fortran/60450
* gfortran.dg/shape_8.f90: New.
From-SVN: r208443
fortran/
PR fortran/60341
* frontend-passes.c (optimize_comparison): Guard two union
accesses with the corresponding tag checks.
testsuite/
PR fortran/60341
* gfortran.dg/str_comp_optimize_1.f90: New test.
From-SVN: r208259
2014-02-28 Joey Ye <joey.ye@arm.com>
Backport from mainline r208229
2014-02-28 Joey Ye <joey.ye@arm.com>
PR libgcc/60166
* config/arm/sfp-machine.h (_FP_NANFRAC_H,
_FP_NANFRAC_S, _FP_NANFRAC_D, _FP_NANFRAC_Q):
Set to zero.
From-SVN: r208233
fortran/
PR fortran/59599
* trans-intrinsic.c (gfc_conv_intrinsic_ichar): Calculate the
number of arguments.
testsuite/
PR fortran/59599
* gfortran.dg/ichar_3.f90: New test.
From-SVN: r208043
Backport from mainline
2014-02-21 Jakub Jelinek <jakub@redhat.com>
* config/i386/i386.c (ix86_expand_vec_perm): Use V8SImode
mode for mask of V8SFmode permutation.
Backport from 4.8 branch
2014-02-20 Jakub Jelinek <jakub@redhat.com>
PR target/57896
* config/i386/i386.c (expand_vec_perm_interleave2): Don't call
gen_reg_rtx if d->testing_p.
(expand_vec_perm_pshufb2, expand_vec_perm_even_odd_1,
expand_vec_perm_broadcast_1): Return early if d->testing_p and
we will certainly return true.
From-SVN: r207983
2014-02-20 Janus Weil <janus@gcc.gnu.org>
Backport from mainline
2014-02-17 Janus Weil <janus@gcc.gnu.org>
PR fortran/55907
* resolve.c (build_default_init_expr): Don't initialize character
variable if -fno-automatic is given.
2014-02-20 Janus Weil <janus@gcc.gnu.org>
Backport from mainline
2014-02-17 Janus Weil <janus@gcc.gnu.org>
PR fortran/55907
* gfortran.dg/init_flag_12.f90: New.
From-SVN: r207935
2014-02-20 Terry Guo <terry.guo@arm.com>
Backport from mainline
2014-02-08 Terry Guo <terry.guo@arm.com>
* doc/invoke.texi: Document ARM -march=armv7e-m.
From-SVN: r207931
2014-02-18 Kai Tietz <ktietz@redhat.com>
Backport from mainline
PR target/60193
* config/i386/i386.c (ix86_expand_prologue): Use
rax register as displacement for restoring %r10, %rax.
Additional fix wrong offset for restoring both-registers.
2014-02-18 Kai Tietz <ktietz@redhat.com>
PR target/60193
* gcc.target/i386/nest-1.c: New testcase.
From-SVN: r207846
PR driver/60233
* config/i386/driver-i386.c (host_detect_local_cpu): If
YMM state is not saved by the OS, also clear has_f16c. Move
CPUID 0x80000001 handling before YMM state saving checking.
Co-Authored-By: Uros Bizjak <ubizjak@gmail.com>
From-SVN: r207835
2014-02-08 Paul Thomas <pault@gcc.gnu.org>
PR fortran/59906
* trans-array.c (gfc_add_loop_ss_code): In the case of character
SS_REFERENCE, use gfc_conv_string_parameter to ensure that a
pointer to the string is stored.
* trans-expr.c (gfc_conv_expr_reference): Likewise, use
gfc_conv_string_parameter to ensure that a pointer to is passed
to the elemental function.
2014-02-08 Paul Thomas <pault@gcc.gnu.org>
PR fortran/59906
* gfortran.dg/elemental_subroutine_9.f90 : New test
From-SVN: r207617
2014-01-29 Markus Trippelsdorf <markus@trippelsdorf.de>
Backport from mainline
2012-12-13 Jakub Jelinek <jakub@redhat.com>
PR gcov-profile/55650
* coverage.c (coverage_obj_init): Return false if no functions
are being emitted.
* g++.dg/other/pr55650.C: New test.
* g++.dg/other/pr55650.cc: New file
From-SVN: r207277
fortran/
PR fortran/58007
* module.c (fp2, find_pointer2): Remove.
(mio_component_ref): Don't forcedfully set the containing derived type
symbol for loading. Remove unused argument.
(mio_ref): Update caller
(skip_list): New argument nest_level. Initialize level with the new
argument.
(read_module): Add forced pointer components association for derived
type symbols.
testsuite/
PR fortran/58007
* gfortran.dg/unresolved_fixup_1.f90: New test.
* gfortran.dg/unresolved_fixup_2.f90: New test.
From-SVN: r207119
2014-01-25 Walter Lee <walt@tilera.com>
Backport from mainline
2014-01-25 Walter Lee <walt@tilera.com>
* config/tilepro/atomic.c (pre_atomic_barrier): Mark inline.
(post_atomic_barrier): Ditto.
(__fetch_and_do): New macro.
(__atomic_fetch_and_do): Use __fetch_and_do.
(__sync_fetch_and_do): New macro.
(__sync_fetch_and_add_4): New function.
(__sync_fetch_and_sub_4): New function.
(__sync_fetch_and_or_4): New function.
(__sync_fetch_and_and_4): New function.
(__sync_fetch_and_xor_4): New function.
(__sync_fetch_and_nand_4): New function.
(__sync_fetch_and_add_8): New function.
(__sync_fetch_and_sub_8): New function.
(__sync_fetch_and_or_8): New function.
(__sync_fetch_and_and_8): New function.
(__sync_fetch_and_xor_8): New function.
(__sync_fetch_and_nand_8): New function.
(__do_and_fetch): New macro.
(__atomic_do_and_fetch): Use __do_and_fetch.
(__sync_do_and_fetch): New macro.
(__sync_add_and_fetch_4): New function.
(__sync_sub_and_fetch_4): New function.
(__sync_or_and_fetch_4): New function.
(__sync_and_and_fetch_4): New function.
(__sync_xor_and_fetch_4): New function.
(__sync_nand_and_fetch_4): New function.
(__sync_add_and_fetch_8): New function.
(__sync_sub_and_fetch_8): New function.
(__sync_or_and_fetch_8): New function.
(__sync_and_and_fetch_8): New function.
(__sync_xor_and_fetch_8): New function.
(__sync_nand_and_fetch_8): New function.
(__sync_exchange_methods): New macro.
(__sync_val_compare_and_swap_4): New function.
(__sync_bool_compare_and_swap_4): New function.
(__sync_lock_test_and_test_4): New function.
(__sync_val_compare_and_swap_8): New function.
(__sync_bool_compare_and_swap_8): New function.
(__sync_lock_test_and_test_8): New function.
(__subword_cmpxchg_body): New macro.
(__atomic_compare_exchange_1): Use __subword_cmpxchg_body.
(__atomic_compare_exchange_2): Ditto.
(__sync_subword_cmpxchg): New macro.
(__sync_val_compare_and_swap_1): New function.
(__sync_bool_compare_and_swap_1): New function.
(__sync_val_compare_and_swap_2): New function.
(__sync_bool_compare_and_swap_2): New function.
(__atomic_subword): Rename to ...
(__subword): ... New name.
(__atomic_subword_fetch): Use __subword.
(__sync_subword_fetch): New macro.
(__sync_fetch_and_add_1): New function.
(__sync_fetch_and_sub_1): New function.
(__sync_fetch_and_or_1): New function.
(__sync_fetch_and_and_1): New function.
(__sync_fetch_and_xor_1): New function.
(__sync_fetch_and_nand_1): New function.
(__sync_fetch_and_add_2): New function.
(__sync_fetch_and_sub_2): New function.
(__sync_fetch_and_or_2): New function.
(__sync_fetch_and_and_2): New function.
(__sync_fetch_and_xor_2): New function.
(__sync_fetch_and_nand_2): New function.
(__sync_add_and_fetch_1): New function.
(__sync_sub_and_fetch_1): New function.
(__sync_or_and_fetch_1): New function.
(__sync_and_and_fetch_1): New function.
(__sync_xor_and_fetch_1): New function.
(__sync_nand_and_fetch_1): New function.
(__sync_add_and_fetch_2): New function.
(__sync_sub_and_fetch_2): New function.
(__sync_or_and_fetch_2): New function.
(__sync_and_and_fetch_2): New function.
(__sync_xor_and_fetch_2): New function.
(__sync_nand_and_fetch_2): New function.
(__atomic_subword_lock): Use __subword.
(__sync_subword_lock): New macro.
(__sync_lock_test_and_set_1): New function.
(__sync_lock_test_and_set_2): New function.
From-SVN: r207107
2014-01-25 Walter Lee <walt@tilera.com>
Backport from mainline
2014-01-25 Walter Lee <walt@tilera.com>
* config/tilepro/atomic.c (BIT_OFFSET): Define.
(__atomic_subword_cmpxchg): Use BIT_OFFSET.
(__atomic_subword): Ditto.
From-SVN: r207106
2014-01-25 Walter Lee <walt@tilera.com>
Backport from mainline
2014-01-25 Walter Lee <walt@tilera.com>
* config/tilepro/atomic.c (__atomic_do_and_fetch): Add
a prefix op argument.
(__atomic_nand_fetch_4): Add prefix op.
(__atomic_nand_fetch_8): Ditto.
From-SVN: r207105
2014-01-25 Walter Lee <walt@tilera.com>
Backport from mainline
2014-01-25 Walter Lee <walt@tilera.com>
* config/tilegx/sync.md (atomic_fetch_sub): Fix negation and
avoid clobbering a live register.
From-SVN: r207104
2014-01-25 Walter Lee <walt@tilera.com>
Backport from mainline
2014-01-25 Walter Lee <walt@tilera.com>
* config/tilegx/tilegx-c.c (tilegx_cpu_cpp_builtins):
Define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_{1,2}.
* config/tilegx/tilepro-c.c (tilepro_cpu_cpp_builtins):
Define __GCC_HAVE_SYNC_COMPARE_AND_SWAP_{1,2,4,8}.
From-SVN: r207103
2014-01-25 Walter Lee <walt@tilera.com>
Backport from mainline
2014-01-25 Walter Lee <walt@tilera.com>
* config/tilegx/tilegx.c (tilegx_gen_bundles): Delete barrier
insns before bundling.
* config/tilegx/tilegx.md (tile_network_barrier): Update
comment.
From-SVN: r207102
2014-01-25 Walter Lee <walt@tilera.com>
Backport from mainline
2014-01-25 Walter Lee <walt@tilera.com>
* config/tilegx/tilegx.c (tilegx_expand_builtin): Set
PREFETCH_SCHEDULE_BARRIER_P to true for prefetches.
* config/tilepro/tilepro.c (tilepro_expand_builtin): Ditto.
From-SVN: r207101
2014-01-25 Walter Lee <walt@tilera.com>
Backport from mainline
2014-01-25 Walter Lee <walt@tilera.com>
* config/tilepro/tilepro.md (ctzdi2): Use register_operand
predicate.
(clzdi2): Ditto.
(ffsdi2): Ditto.
From-SVN: r207100
2014-01-25 Walter Lee <walt@tilera.com>
Backport from mainline
2014-01-25 Walter Lee <walt@tilera.com>
* config/tilegx/tilegx.c (tilegx_expand_to_rtl_hook): New.
(TARGET_EXPAND_TO_RTL_HOOK): Define.
From-SVN: r207099
PR target/59880
* config/i386/i386.c (ix86_avoid_lea_for_addr): Return false
for SImode_address_operand operands. Return false
if operands[1] is a REG.
Co-Authored-By: Jakub Jelinek <jakub@redhat.com>
From-SVN: r206940
2014-01-17 Charles Baylis <charles.baylis@linaro.org>
Backport from mainline
2013-12-19 Charles Baylis <charles.baylis@linaro.org>
PR target/59142
* config/arm/arm-ldmstm.ml: Use low_register_operand for Thumb
patterns.
* config/arm/ldmstm.md: Regenerate.
2013-12-19 Charles Baylis <charles.baylis@linaro.org>
PR target/59142
* config/arm/predicates.md (arm_hard_general_register_operand):
New predicate.
(arm_hard_register_operand): Remove.
* config/arm/arm-ldmstm.ml: Use arm_hard_general_register_operand
for all patterns.
* config/arm/ldmstm.md: Regenerate.
From-SVN: r206707
PR target/59839
* config/i386/i386.c (ix86_expand_builtin): If target doesn't
satisfy operand 0 predicate for gathers, use a new pseudo as
subtarget.
* gcc.target/i386/pr59839.c: New test.
From-SVN: r206684
PR middle-end/59827
* gimple-low.c (gimple_check_call_args): Don't use DECL_ARG_TYPE if
it is error_mark_node.
testsuite/
* gcc.dg/pr59827.c: New test.
From-SVN: r206665
PR rtl-optimization/54300
gcc:
* regcprop.c (copyprop_hardreg_forward_1): Ensure any unused
outputs in a single-set are killed from the value chains.
gcc/testsuite:
* gcc.target/arm/pr54300.C: New test.
From-SVN: r206533
libgcc:
* config/rs6000/ibm-ldouble.c (__gcc_qdiv): Scale up arguments in
case of small numerator and finite nonzero result.
gcc/testsuite:
* gcc.target/powerpc/rs6000-ldouble-3.c: New test.
From-SVN: r206321
Backport from mainline
2013-11-23 Uros Bizjak <ubizjak@gmail.com>
PR target/56788
* config/i386/i386.c (bdesc_multi_arg) <IX86_BUILTIN_VFRCZSS>:
Declare as MULTI_ARG_1_SF instruction.
<IX86_BUILTIN_VFRCZSD>: Decleare as MULTI_ARG_1_DF instruction.
* config/i386/sse.md (*xop_vmfrcz<mode>2): Rename
from *xop_vmfrcz_<mode>.
* config/i386/xopintrin.h (_mm_frcz_ss): Use __builtin_ia32_movss
to merge scalar result with __A.
(_mm_frcz_sd): Use __builtin_ia32_movsd to merge scalar
result with __A.
testsuite/ChangeLog:
Backport from mainline
2013-11-27 Uros Bizjak <ubizjak@gmail.com>
Ganesh Gopalasubramanian <Ganesh.Gopalasubramanian@amd.com>
PR target/56788
* gcc.target/i386/xop-frczX.c: New test.
From-SVN: r205497
Backport from mainline
2013-11-18 Uros Bizjak <ubizjak@gmail.com>
* config/i386/i386.c (ix86_decompose_address): Use REG_P instead of
ix86_address_subreg_operand. Move subreg checks to
ix86_validate_address_register. Move address override check to
ix86_legitimate_address_p.
(ix86_validate_address_register): New function.
(ix86_legitimate_address_p): Call ix86_validate_address_register
to validate base and index registers. Add address override check
from ix86_decompose_address.
(ix86_decompose_address): Remove.
Backport from mainline
2013-11-17 Uros Bizjak <ubizjak@gmail.com>
PR target/59153
* config/i386/i386.c (ix86_address_subreg_operand): Do not
reject non-integer subregs.
(ix86_decompose_address): Do not reject invalid CONST_INT RTXes.
Move check for invalid x32 constant addresses ...
(ix86_legitimate_address_p): ... here.
Bacport from mainline
2012-03-13 Uros Bizjak <ubizjak@gmail.com>
* config/i386/i386.c (ix86_decompose_address): Prevent %fs:(%reg)
addresses only when %reg is not in word mode.
From-SVN: r205122
2013-11-17 Paul Thomas <pault@gcc.gnu.org>
PR fortran/58771
* trans-io.c (transfer_expr): If the backend_decl for a derived
type is missing, build it with gfc_typenode_for_spec.
2013-11-17 Paul Thomas <pault@gcc.gnu.org>
PR fortran/58771
* gfortran.dg/derived_external_function_1.f90 : New test
From-SVN: r204913
Merged from trunk
PR plugins/52872
* configure.ac: Adding for exported symbols check
and for rdynamic-check executable-extension.
* configure: Regenerated.
Co-Authored-By: Kai Tietz <ktietz@redhat.com>
From-SVN: r204653
Back-merged from trunk
* config/i386/cygming-crtbegin.c (__gcc_register_frame):
Increment load-count on use of LIBGCC_SONAME DLL.
(hmod_libgcc): New static variable to hold handle of
LIBGCC_SONAME DLL.
(__gcc_deregister_frame): Decrement load-count of
LIBGCC_SONAME DLL.
From-SVN: r204637
2013-10-28 Tom de Vries <tom@codesourcery.com>
* cfgexpand.c (gimple_expand_cfg): Remove test for parm_birth_insn.
Don't commit insertions after NOTE_INSN_FUNCTION_BEG.
* gcc.target/arm/require-pic-register-loc.c: New test.
From-SVN: r204121
PR rtl-optimization/58831
* alias.c (init_alias_analysis): At the beginning of each iteration, set
the reg_seen[N] flag if static_reg_base_value[N] is non-null.
From-SVN: r204058
2013-10-20 Chris Jefferson <chris@bubblescope.net>
Paolo Carlini <paolo.carlini@oracle.com>
PR libstdc++/58800
* include/bits/stl_algo.h (__unguarded_partition_pivot): Change
__last - 2 to __last - 1.
* testsuite/25_algorithms/nth_element/58800.cc: New
Co-Authored-By: Paolo Carlini <paolo.carlini@oracle.com>
From-SVN: r203874
2013-09-18 Daniel Morris <danielm@ecoscentric.com>
Paolo Carlini <paolo.carlini@oracle.com>
PR c++/58458
* doc/implement-cxx.texi: Fix references to the C++ standards.
Co-Authored-By: Paolo Carlini <paolo.carlini@oracle.com>
From-SVN: r202698
2013-09-12 Terry Guo <terry.guo@arm.com>
Backport from mainline
2012-09-17 Richard Guenther <rguenther@suse.de>
PR lto/54598
* tree-streamer-in.c (unpack_ts_real_cst_value_fields): Use ggc'ed
FIXED_VALUE_TYPE instead of struct fixed_value.
From-SVN: r202551
backport from 4.8
gcc/
* doc/tm.texi.in (TARGET_OBJC_DECLARE_UNRESOLVED_CLASS_REFERENCE,
TARGET_OBJC_DECLARE_CLASS_DEFINITION): Add @hooks.
(ASM_DECLARE_CLASS_REFERENCE, ASM_DECLARE_UNRESOLVED_REFERENCE):
Remove.
* doc/tm.texi: Regenerate.
* config/darwin.h (ASM_OUTPUT_LABELREF): Remove special case for
.objc_class_name_*.
* config/darwin-c.c: Include target.h.
(darwin_objc_declare_unresolved_class_reference): New function.
(darwin_objc_declare_class_definition): New function.
(TARGET_OBJC_DECLARE_UNRESOLVED_CLASS_REFERENCE): Define.
(TARGET_OBJC_DECLARE_CLASS_DEFINITION): Define.
c-family/
* c-target.def (objc_declare_unresolved_class_reference,
objc_declare_class_definition): Add new hooks.
objc/
* objc-next-runtime-abi-01.c: Do not include tm.h and output.h.
Include c-family/c-target.h.
(handle_next_class_ref): Rewrite to emit top-level asm statements.
(handle_next_impent): Likewise.
* objc/Make-lang.in: Fix dependencies for objc-next-runtime-abi-01.o.
From-SVN: r202155
gcc:
Backport from mainline:
2013-07-22 Uros Bizjak <ubizjak@gmail.com>
* config/i386/i386.md (nonlocal_goto_receiver): Delete insn if
it is not needed after split.
2013-07-20 Iain Sandoe <iain@codesourcery.com>
PR target/51784
* config/i386/i386.c (output_set_got) [TARGET_MACHO]: Adjust to emit a
second label for nonlocal goto receivers. Don't output pic base labels
unless we're producing PIC; mark that action unreachable().
(ix86_save_reg): If the function contains a nonlocal label, save the
PIC base reg.
* config/darwin-protos.h (machopic_should_output_picbase_label): New.
* gcc/config/darwin.c (emitted_pic_label_num): New GTY.
(update_pic_label_number_if_needed): New.
(machopic_output_function_base_name): Adjust for nonlocal receiver
case.
(machopic_should_output_picbase_label): New.
* config/i386/i386.md (enum unspecv): UNSPECV_NLGR: New.
(nonlocal_goto_receiver): New insn and split.
From-SVN: r202147
PR target/56979
* arm.c (aapcs_vfp_allocate): Decompose the argument if the
suggested mode for the assignment isn't compatible with the
registers required.
From-SVN: r201904
PR c++/58119
* cp-tree.h (WILDCARD_TYPE_P): Split out from...
(MAYBE_CLASS_TYPE_P): ...here.
* cvt.c (build_expr_type_conversion): Don't complain about a
template that can't match the desired type category.
From-SVN: r201881
2013-08-13 Marek Polacek <polacek@redhat.com>
Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/57980
* tree-tailcall.c (process_assignment): Return false
when not dealing with integers or floats.
* gcc.dg/pr57980.c: New test.
From-SVN: r201688
2013-08-11 Janus Weil <janus@gcc.gnu.org>
Backport from trunk:
2013-08-09 Janus Weil <janus@gcc.gnu.org>
PR fortran/58058
* trans-intrinsic.c (gfc_conv_intrinsic_transfer): Free the temporary
string, if necessary.
2013-08-11 Janus Weil <janus@gcc.gnu.org>
Backport from trunk:
2013-08-09 Janus Weil <janus@gcc.gnu.org>
PR fortran/58058
* gfortran.dg/transfer_intrinsic_6.f90: New.
From-SVN: r201653
Backport from 2013-07-11 trunk r200901.
PR target/57631
* config/avr/avr.c (avr_set_current_function): Sanity-check signal
name seen by assembler/linker if available.
From-SVN: r200903
Backport from mainline
2013-07-06 Uros Bizjak <ubizjak@gmail.com>
* config/i386/sse.md (sse_movlhps): Change alternative 3
of operand 2 to "m".
From-SVN: r200864
PR rtl-optimization/57829
* simplify-rtx.c (simplify_binary_operation_1) <case IOR>: Ensure that
mask bits outside of mode are just sign-extension from mode to HWI.
* gcc.c-torture/execute/pr57829.c: New test.
From-SVN: r200773
Backport from mainline
2013-06-20 Uros Bizjak <ubizjak@gmail.com>
PR target/57655
* config/i386/i386.c (construct_container): Report error if
long double is used with disabled x87 float returns.
testsuite/ChangeLog:
Backport from mainline
2013-06-20 Uros Bizjak <ubizjak@gmail.com>
PR target/57655
* gcc.target/i386/pr57655.c: New test.
From-SVN: r200716
Backport from mainline
2013-06-20 Uros Bizjak <ubizjak@gmail.com>
* config/fpu-387.h (_FPU_MASK_ALL): New.
(_FPU_EX_ALL): Ditto.
(set_fpu): Use fstcw to store x87 FPU control word. Use fnclex to
clear stalled exception flags. Correctly clear stalled SSE
exception flags. Simplify code.
Backport from mainline
2013-06-19 Uros Bizjak <ubizjak@gmail.com>
* config/fpu-387.h: Use __asm__ and __volatile__ consistently.
From-SVN: r200635
Backport from mainline:
2013-06-08 Walter Lee <walt@tilera.com>
* config/tilepro/atomic.h: Don't include stdint.h or features.h.
Replace int64_t with long long. Add __extension__ where
appropriate.
From-SVN: r199857
2013-05-20 Chung-Ju Wu <jasonwucj@gmail.com>
Backport from mainline:
2012-05-24 Olivier Hainque <hainque@adacore.com>
* Makefile.in (clean): Remove libgcc_tm.stamp as well.
Use a separate command for stamp removals.
From-SVN: r199091
[gcc]
2013-05-07 Michael Meissner <meissner@linux.vnet.ibm.com>
Backport from trunk
2013-05-03 Michael Meissner <meissner@linux.vnet.ibm.com>
PR target/57150
* config/rs6000/rs6000.h (HARD_REGNO_CALLER_SAVE_MODE): Use DFmode
to save TFmode registers and DImode to save TImode registers for
caller save operations.
(HARD_REGNO_CALL_PART_CLOBBERED): TFmode and TDmode do not need to
mark being partially clobbered since they only use the first
double word.
* config/rs6000/rs6000.c (rs6000_init_hard_regno_mode_ok): TFmode
and TDmode only use the upper 64-bits of each VSX register.
[gcc/testsuite]
2013-05-07 Michael Meissner <meissner@linux.vnet.ibm.com>
Backport from trunk
2013-05-03 Michael Meissner <meissner@linux.vnet.ibm.com>
PR target/57150
* gcc.target/powerpc/pr57150.c: New file.
From-SVN: r198692
2013-04-28 Jerry DeLisle <jvdelisle@gcc.gnu.org>
Backport from mainline:
2013-03-20 Tilo Schwarz <tilo@tilo-schwarz.de>
PR libfortran/51825
* io/list_read.c (nml_read_obj): Don't end the component loop on a
nested derived type, but continue with the next loop iteration.
(nml_get_obj_data): Don't move the first_nl pointer further in the
list if a qualifier was found.
PR fortran/51825
* gfortran.dg/namelist_77.f90: New test.
* gfortran.dg/namelist_78.f90: New test.
From-SVN: r198386
2013-04-28 Jerry DeLisle <jvdelisle@gcc.gnu.org>
Backport from mainline:
PR libfortran/56786
* io/list_read.c (nml_parse_qualifier): Remove spurious next_char call
when checking for EOF. Use error return mechanism when EOF detected.
Do not return FAILURE unless parse_err_msg and parse_err_msg_size have
been set. Use hit_eof.
(nml_get_obj_data): Likewise use the correct error mechanism.
* io/transfer.c (hit_eof): Do not set AFTER_ENDFILE if in namelist
mode.
Backport from trunk:
PR fortran/56786
* gfortran.dg/namelist_81.f90: New test.
From-SVN: r198375
2013-04-28 Jerry DeLisle <jvdelisle@gcc.gnu.org>
Backport from mainline:
2013-03-25 Tilo Schwarz <tilo@tilo-schwarz.de>
PR libfortran/52512
* io/list_read.c (nml_parse_qualifier): To check for a derived type
don't use the namelist head element type but the current element type.
(nml_get_obj_data): Add current namelist element type to
nml_parse_qualifier call.
2013-04-28 Jerry DeLisle <jvdelisle@gcc.gnu.org>
Backport from trunk:
PR fortran/52512
* gfortran.dg/namelist_79.f90: New test.
From-SVN: r198373
PR target/56866
* config/i386/sse.md (xop_rotr<mode>3): Fix up computation of
the immediate rotate count.
* gcc.c-torture/execute/pr56866.c: New test.
* gcc.target/i386/pr56866.c: New test.
From-SVN: r198357
Backport from mainline
2013-01-08 Steven Bosscher <steven@gcc.gnu.org>
Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/48189
* predict.c (predict_loops): If max is 0, don't call compare_tree_int.
If nitercst is 0, don't predict the exit edge.
* gcc.dg/pr48189.c: New test.
From-SVN: r198085
2013-04-16 Jack Howarth <howarth@bromo.med.uc.edu>
Backport from mainline
2012-05-29 Jack Howarth <howarth@bromo.med.uc.edu>
* config/darwin.h (STARTFILE_SPEC): Use -no_new_main with -lgcrt1.o
on Darwin >= 12.
(DARWIN_CRT1_SPEC): Use -lcrt1.10.6.o when Darwin >= 10 and < 12.
2012-05-29 Jack Howarth <howarth@bromo.med.uc.edu>
PR debug/53453
* doc/tm.texi: Update.
* doc/tm.texi.in (SDB and DWARF) <TARGET_FORCE_AT_COMP_DIR>: Add @hook.
* target.def (force_at_comp_dir): New hook.
* config/darwin.h (TARGET_FORCE_AT_COMP_DIR): Define.
* dwarf2out.c (dwarf2out_finish): Check targetm.force_at_comp_dir.
From-SVN: r198031
2013-04-16 Jack Howarth <howarth@bromo.med.uc.edu>
Backport from mainline
2012-05-29 Jack Howarth <howarth@bromo.med.uc.edu>
* config/darwin.h (STARTFILE_SPEC): Use -no_new_main with -lgcrt1.o
on Darwin >= 12.
(DARWIN_CRT1_SPEC): Use -lcrt1.10.6.o when Darwin >= 10 and < 12.
2012-05-29 Jack Howarth <howarth@bromo.med.uc.edu>
PR debug/53453
* doc/tm.texi: Update.
* doc/tm.texi.in (SDB and DWARF) <TARGET_FORCE_AT_COMP_DIR>: Add @hook.
* target.def (force_at_comp_dir): New hook.
* config/darwin.h (TARGET_FORCE_AT_COMP_DIR): Define.
* dwarf2out.c (dwarf2out_finish): Check targetm.force_at_comp_dir.
From-SVN: r198005
PR target/56890
* config/sparc/sparc.c (enum sparc_mode_class): Add H_MODE value.
(S_MODES): Set H_MODE bit.
(SF_MODES): Set only S_MODE and SF_MODE bits.
(DF_MODES): Set SF_MODES and only D_MODE and DF_MODE bits.
(sparc_init_modes) <MODE_INT>: Set H_MODE bit for sub-word modes.
<MODE_VECTOR_INT>: Do not set SF_MODE for sub-word modes.
<MODE_FLOAT>: Likewise.
From-SVN: r197960
* config/arm/linux-atomic.c (SUBWORD_SYNC_OP, SUBWORD_VAL_CAS)
(SUBWORD_TEST_AND_SET): Use signed char/short types instead of
unsigned char/unsigned short.
(__sync_val_compare_and_swap_{1,2}): Handle signed argument.
From-SVN: r197818
* doc/xml/manual/allocator.xml: Adjust link to Dr.Dobb's article.q
* doc/xml/manual/appendix_contributing.xml: Adjust link to GNU
Coding Standards.
* doc/xml/manual/debug.xml: Adjust link for ThreadSanitizer.
* doc/xml/manual/debug_mode.xml: Adjust link for SafeSTL.
* doc/xml/manual/documentation_hacking.xml: Adjust Doxygen link.
* doc/xml/manual/messages.xml: Adjust link to Java API specs.
* doc/xml/manual/policy_data_structures: Remove direct link to
IBM Haifa Research Labs.
* doc/xml/manual/policy_data_structures_biblio.xml: Adjust links
for biblio.maverik_lowerbounds and biblio.nelson96stlpq.
* doc/xml/manual/profile_mode.xml: Adjust two links to acm.org
papers.
* doc/xml/manual/shared_ptr.xml: Use canonical address for
www.boost.org.
From-SVN: r197543
PR debug/56819
* tree.c (strip_typedefs): Copy NON_DEFAULT_TEMPLATE_ARGS_COUNT
from args to new_args.
(strip_typedefs_expr): Copy NON_DEFAULT_TEMPLATE_ARGS_COUNT from t to
r instead of doing {S,G}ET_NON_DEFAULT_TEMPLATE_ARGS_COUNT.
* g++.dg/debug/pr56819.C: New test.
From-SVN: r197454
Backported from mainline
2013-03-06 Jakub Jelinek <jakub@redhat.com>
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. Adjust function comment.
* gcc.c-torture/compile/pr56539.c: New test.
From-SVN: r197392
Backported from mainline
2013-03-05 Jakub Jelinek <jakub@redhat.com>
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.
* gcc.dg/pr56510.c: New test.
From-SVN: r197391
2013-04-02 Wei Mi <wmi@google.com>
* config/i386/i386.c (ix86_rtx_costs): Set proper rtx cost for
ashl<mode>3_mask, *<shift_insn><mode>3_mask and
*<rotate_insn><mode>3_mask in i386.md.
From-SVN: r197364
2013-04-02 Richard Biener <rguenther@suse.de>
PR middle-end/56768
Backport from mainline
2012-05-16 Richard Guenther <rguenther@suse.de>
* tree-inline.c (declare_return_variable): Properly handle
DECL_BY_REFERENCE return vars in SSA form.
* g++.dg/torture/pr56768.C: New testcase.
From-SVN: r197351
Backport from mainline
2013-02-27 Andrey Belevantsev <abel@ispras.ru>
PR middle-end/45472
* sel-sched-ir.c (merge_expr): Also change vinsn of merged expr
when the may_trap_p bit of the exprs being merged differs.
Reorder tests for speculativeness in the logical and operator.
Backport from mainline
2013-03-05 Jakub Jelinek <jakub@redhat.com>
PR middle-end/56461
* sel-sched-ir.c (free_sched_pools): Release
succs_info_pool.stack[succs_info_pool.max_top] vectors too
if succs_info_pool.max_top isn't -1.
Backport from mainline
2013-02-27 Andrey Belevantsev <abel@ispras.ru>
PR middle-end/45472
* gcc.dg/pr45472.c: New test.
From-SVN: r197299
Backport from mainline
2012-02-19 Andrey Belevantsev <abel@ispras.ru>
PR middle-end/55889
* sel-sched.c: Include ira.h.
(implicit_clobber_conflict_p): New function.
(moveup_expr): Use it.
* Makefile.in (sel-sched.o): Depend on ira.h.
From-SVN: r197298
* toplev.c (process_options): Do not disable -fomit-frame-pointer on a
general basis if unwind info is requested and ACCUMULATE_OUTGOING_ARGS
is not enabled.
From-SVN: r197188
Backport from mainline:
2013-03-27 Walter Lee <walt@tilera.com>
* config/tilegx/tilegx.c (tilegx_expand_prologue): Avoid
double-decrement of next_scratch_regno.
From-SVN: r197149
Backport from mainline:
2013-03-27 Walter Lee <walt@tilera.com>
* config/tilegx/tilegx.h (ASM_OUTPUT_ADDR_VEC_ELT): Delete
extra tab.
(ASM_OUTPUT_ADDR_DIFF_ELT): Ditto.
From-SVN: r197147
Backport from mainline:
2013-03-27 Walter Lee <walt@tilera.com>
* config/tilegx/tilegx.md (*sibcall_insn): Fix type atribute
for jr.
(*sibcall_value): Ditto.
From-SVN: r197146
Backport from mainline:
2013-03-27 Walter Lee <walt@tilera.com>
* config/tilegx/tilegx.md (insn_mnz_<mode>): Replaced by ...
(insn_mnz_v8qi): ... this ...
(insn_mnz_v4hi): ... and this. Replace (const_int 0) with the
vector equivalent.
(insn_v<n>mnz): Replaced by ...
(insn_v1mnz): ... this ...
(insn_v2mnz): ... and this. Replace (const_int 0) with the vector
equivalent.
(insn_mz_<mode>): Replaced by ...
(insn_mz_v8qi): ... this ...
(insn_mz_v4hi): ... and this. Replace (const_int 0) with the
vector equivalent.
(insn_v<n>mz): Replaced by ...
(insn_v1mz): ... this ...
(insn_v2mz): ... and this. Replace (const_int 0) with the vector
equivalent.
From-SVN: r197145
2013-03-26 Richard Biener <rguenther@suse.de>
Backport from mainline
2013-03-13 Richard Biener <rguenther@suse.de>
PR tree-optimization/56608
* tree-vect-slp.c (vect_schedule_slp): Do not remove scalar
calls when vectorizing basic-blocks.
* gcc.dg/vect/fast-math-bb-slp-call-3.c: New testcase.
2013-03-05 Richard Biener <rguenther@suse.de>
PR tree-optimization/56270
* tree-vect-slp.c (vect_schedule_slp): Clear vectorized stmts
of loads after scheduling an SLP instance.
* gcc.dg/vect/slp-38.c: New testcase.
From-SVN: r197096
Backport from mainline:
2013-03-25 Walter Lee <walt@tilera.com>
* config/tilegx/tilegx.c (expand_set_cint64_one_inst): Inline
tests for constraint J, K, N, P.
From-SVN: r197091
Backport from mainline:
2013-03-25 Walter Lee <walt@tilera.com>
* config/tilegx/tilegx.c (tilegx_asm_preferred_eh_data_format):
Use indirect/pcrel encoding.
* config/tilepro/tilepro.c (tilepro_asm_preferred_eh_data_format):
Ditto.
From-SVN: r197090
Backport from mainline:
2012-04-03 Kaz Kojima <kkojima@gcc.gnu.org>
* config/sh/t-sh (MULTILIB_MATCHES): Match m2a-single-only
to m2a-single instead of m2e.
From-SVN: r197070
PR c++/54277
* semantics.c (lambda_capture_field_type): Don't build a
magic decltype for pointer types.
(lambda_proxy_type): Likewise.
(finish_non_static_data_member): Get the quals from
the object.
From-SVN: r197009
gcc/
PR target/56560
* config/i386/i386.c (init_cumulative_args): Also set
cum->callee_return_avx256_p.
(ix86_function_arg): Set cum->callee_pass_avx256_p. Set
cfun->machine->callee_pass_avx256_p only when MODE == VOIDmode.
* config/i386/i386.h (ix86_args): Add callee_pass_avx256_p and
callee_return_avx256_p.
gcc/
PR target/56560
* gcc.target/i386/pr56560.c: New file.
From-SVN: r196976
Backport from mainline:
2012-12-04 Ian Lance Taylor <iant@google.com>
* godump.c (find_dummy_types): Output a dummy type if we couldn't
output the real type.
From-SVN: r196822
PR target/56470
* arm.c (shift_op): Validate RTL pattern on the fly.
(arm_print_operand, case 'S'): Don't use shift_operator to validate
the RTL.
From-SVN: r196780
PR libstdc++/56002
* include/std/mutex (lock_guard, unique_lock, lock): Define without
depending on _GLIBCXX_HAS_GTHREADS.
* testsuite/30_threads/lock_guard/cons/1.cc: Run on all targets.
From-SVN: r196710
2013-03-13 Paul Thomas <pault@gcc.gnu.org>
PR fortran/56575
* expr.c (gfc_default_initializer): Check that a class declared
type has any components.
* resolve.c (resolve_fl_derived0): On failing the test for C437
set the type to BT_UNKNOWN to prevent repeat error messages.
2013-03-13 Paul Thomas <pault@gcc.gnu.org>
PR fortran/56575
* gfortran.dg/class_56.f90: New test.
From-SVN: r196627
2013-03-10 Paul Thomas <pault@gcc.gnu.org>
PR fortran/55362
* check.c (array_check): It is an error if a procedure is
passed.
2013-03-10 Paul Thomas <pault@gcc.gnu.org>
PR fortran/55362
* gfortran.dg/intrinsic_size_4.f90 : New test.
From-SVN: r196582
2013-03-09 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.
From-SVN: r196571
Backport from mainline
2013-03-06 Joey Ye <joey.ye@arm.com>
PR lto/50293
* gcc.c (convert_white_space): New function.
(main): Handles white space in function name.
From-SVN: r196534
Backport from mainline
2013-03-06 Oleg Endo <olegendo@gcc.gnu.org>
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): Use table for mdiv= option. Document
mdiv= call-div1, call-fp, call-table options.
Backport from mainline.
2013-03-06 Oleg Endo <olegendo@gcc.gnu.org>
PR target/56529
* config/sh/lib1funcs.S (udivsi3_i4i, sdivsi3_i4i): Add __SH2A__ to
inclusion list.
From-SVN: r196510
2013-03-01 Richard Biener <rguenther@suse.de>
Backport from mainline
2012-12-12 Zdenek Dvorak <ook@ucw.cz>
PR tree-optimization/55481
* tree-ssa-loop-ivopts.c (rewrite_use_nonlinear_expr): Fall
back to general rewriting if we cannot leave an original biv
definition alone.
* gcc.dg/torture/pr55481.c: New testcase.
* gcc.dg/torture/pr56488.c: Likewise.
From-SVN: r196379
PR target/56453
Import this patch from the mainline:
2012-08-17 Nick Clifton <nickc@redhat.com>
* config/fr30/fr30.md (cbranchsi4): Remove mode from comparison.
(branch_true): Likewise.
(branch_false): Likewise.
From-SVN: r196292
PR tree-optimization/56443
* tree-vect-stmts.c (get_vectype_for_scalar_type_and_size): For
overaligned types, pass TYPE_UNSIGNED (scalar_type) as second argument
to type_for_mode langhook.
* gcc.dg/torture/pr56443.c: New test.
From-SVN: r196279
PR bootstrap/56258
* doc/invoke.texi (-fdump-rtl-pro_and_epilogue): Use @item
instead of @itemx.
* gnat-style.texi (@title): Remove @hfill.
* projects.texi: Avoid line wrapping inside of @pxref or
@xref.
* doc/cp-tools.texinfo (Virtual Machine Options): Use just
one @gccoptlist instead of 3 separate ones.
From-SVN: r196197
PR ada/56271
Backport from mainline
2012-05-15 Olivier Hainque <hainque@adacore.com>
* gcc-interface/Make-lang.in (COMMON_FLAGS_TO_PASS): Use WARN_CFLAGS
instead of trying to mimic it.
From-SVN: r196178
Backport from mainline:
2012-06-20 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
* gcc.target/i386/clearcapv2.map: New file.
* gcc.target/i386/i386.exp: Try it first before clearcap.map.
From-SVN: r196168
Backported from mainline
2013-02-19 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/56350
* tree-vect-loop.c (vectorizable_reduction): If orig_stmt, return false
if haven't found reduction or nested cycle operand, rather than
asserting we must find it.
* gcc.dg/pr56350.c: New test.
From-SVN: r196150
Backported from mainline
2013-02-19 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/56381
* tree-ssa-pre.c (create_expression_by_pieces): Fix up last argument
to fold_build3.
From-SVN: r196149
Backported from mainline
2013-02-09 Jakub Jelinek <jakub@redhat.com>
PR other/56245
* regex.c (PTR_INT_TYPE): Define.
(EXTEND_BUFFER): Change incr type from int to PTR_INT_TYPE.
From-SVN: r196148
Backported from mainline
2013-02-08 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/56250
* fold-const.c (extract_muldiv_1) <case NEGATE_EXPR>: Don't optimize
if type is unsigned and code isn't MULT_EXPR.
* gcc.c-torture/execute/pr56250.c: New test.
From-SVN: r196147
Backported from mainline
2013-02-07 Jakub Jelinek <jakub@redhat.com>
PR c++/56241
* init.c (build_vec_init): Don't append NULL values into new_vec.
(build_zero_init_1): Don't push anything into v if recursive call
returned NULL_TREE.
(build_value_init_noctor): Don't push anything into v if
build_value_init call returned NULL_TREE.
* g++.dg/parse/crash61.C: New test.
From-SVN: r196146
Backported from mainline
2013-02-07 Jakub Jelinek <jakub@redhat.com>
PR c++/56237
* decl.c (push_local_name): Look at DECL_DISCRIMINATOR (t)
only if DECL_DISCRIMINATOR_SET_P (t) rather than just
DECL_LANG_SPECIFIC (t).
* g++.dg/abi/mangle61.C: New test.
From-SVN: r196142
Backported from mainline
2012-11-27 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/55110
* tree-vect-loop.c (vectorizable_reduction): Don't assert
that STMT_VINFO_RELATED_STMT of orig_stmt is stmt.
* gcc.dg/pr55110.c: New test.
From-SVN: r196140
2013-02-14 Rainer Emrich <rainer@emrich-ebersheim.de>
PR target/52123
* adaint.c (__gnat_check_OWNER_ACL): Cast from pointer via
SECURITY_DESCRIPTOR *.
(__gnat_set_OWNER_ACL): Cast from DWORD to ACCESS_MODE.
(__gnat_portable_spawn): Fix cast to char* const*.
(add_handle): Cast from pointer via void **.
(add_handle): Cast from pointer via int *.
(__gnat_locate_exec_on_path): Cast from pointer via TCHAR *.
(__gnat_locate_exec_on_path): Cast from pointer via char *.
* initialize.c (append_arg): Cast from pointer via LPWSTR.
(__gnat_initialize): Cast from pointer via LPWSTR.
* seh_init.c (__gnat_SEH_error_handler): Cast from pointer via FARPROC.
* tracebak.c: Cast from pointer via FARPROC.
From-SVN: r196046
Backport from mainline
2013-02-11 Uros Bizjak <ubizjak@gmail.com>
PR rtl-optimization/56275
* simplify-rtx.c (avoid_constant_pool_reference): Check that
offset is non-negative and less than cmode size before
calling simplify_subreg.
testsuite/ChangeLog:
Backport from mainline
2013-02-11 Uros Bizjak <ubizjak@gmail.com>
PR rtl-optimization/56275
* gcc.dg/pr56275.c: New test.
From-SVN: r195946
Backport from mainline
2013-02-08 Uros Bizjak <ubizjak@gmail.com>
* config/i386/sse.md (FMAMODEM): New mode iterator.
(fma<mode>4, fms<mode>4, fnma<mode>4, fnms<mode>4): Use FMAMODEM
mode iterator. Do not use TARGET_SSE_MATH in insn constraint.
2013-02-08 Uros Bizjak <ubizjak@gmail.com>
* config/i386/gnu-user.h (TARGET_CAN_SPLIT_STACK): Define only
when HAVE_GAS_CFI_PERSONALITY_DIRECTIVE is set.
* config/i386/gnu-user64.h (TARGET_CAN_SPLIT_STACK): Ditto.
From-SVN: r195912
[gcc]
2013-02-08 Michael Meissner <meissner@linux.vnet.ibm.com>
PR target/56043
* config/rs6000/rs6000.c (rs6000_builtin_vectorized_libmass):
If there is no implicit builtin declaration, just return NULL.
[gcc/testsuite]
2013-02-08 Michael Meissner <meissner@linux.vnet.ibm.com>
PR target/56043
* gcc.target/powerpc/vsx-mass-1.c: Only run this test on
powerpc*-*-linux*.
From-SVN: r195899
2013-02-08 David Edelsohn <dje.gcc@gmail.com>
Michael Meissner <meissner@linux.vnet.ibm.com>
Backport from mainline
* config/rs6000/rs6000.c (rs6000_option_override_internal): Clear
MASK_VSX from set_masks if OS_MISSING_ALTIVEC.
Co-Authored-By: Michael Meissner <meissner@linux.vnet.ibm.com>
From-SVN: r195887
* dwarf2out.c (based_loc_descr): Perform leaf register remapping
on 'reg'.
* var-tracking.c (vt_add_function_parameter): Test the presence of
HAVE_window_save properly and do not remap argument registers when
we have a leaf function.
From-SVN: r195870
PR target/50678
* init.c (__darwin_major_version): New function for x86-64/Darwin.
(__gnat_adjust_context_for_raise) [Darwin]: Disable the workaround
on Darwin 12 and above.
From-SVN: r195863
Backport from mainline
2013-02-03 David Edelsohn <dje.gcc@gmail.com>
Andrew Dixie <andrewd@gentrack.com>
* collect2.c (GCC_CHECK_HDR): Do not scan objects with F_LOADONLY
flag set.
From-SVN: r195763
PR libgomp/51376
PR libgomp/56073
* task.c (GOMP_task): Revert 2011-12-09 change.
(GOMP_taskwait): Likewise. Instead use atomic load with acquire
barrier to read task->children..
(gomp_barrier_handle_tasks): ..and matching atomic store with
release barrier here when setting parent->children to NULL.
From-SVN: r195756
2013-02-05 Richard Biener <rguenther@suse.de>
Backport from mainline
2012-12-10 Richard Biener <rguenther@suse.de>
PR tree-optimization/55107
* tree-ssa-pre.c (struct pre_stats): Remove constified field.
(bitmap_set_replace_value): Add gcc_unreachable.
(do_regular_insertion): Re-write all_same handling. Insert
an assignment instead of a PHI in this case.
(execute_pre): Do not record constified events.
* gcc.dg/torture/pr55107.c: New testcase.
* gcc.dg/tree-ssa/ssa-pre-5.c: Adjust.
From-SVN: r195755
2013-02-05 Richard Biener <rguenther@suse.de>
PR tree-optimization/54767
* tree-vrp.c (vrp_visit_phi_node): For PHI arguments coming via
backedges drop all symbolical range information.
(execute_vrp): Compute backedges.
* gfortran.fortran-torture/execute/pr54767.f90: New testcase.
From-SVN: r195754
2013-02-04 Richard Biener <rguenther@suse.de>
Backport from mainline
2012-01-11 Richard Guenther <rguenther@suse.de>
PR tree-optimization/44061
* tree-vrp.c (extract_range_basic): Compute zero as
value-range for __builtin_constant_p of function parameters.
* gcc.dg/pr44061.c: New testcase.
2013-01-08 Jakub Jelinek <jakub@redhat.com>
PR middle-end/55890
* tree-ssa-ccp.c (evaluate_stmt): Use gimple_call_builtin_class_p.
* gcc.dg/torture/pr55890-3.c: New test.
From-SVN: r195718
2013-02-04 Richard Biener <rguenther@suse.de>
Backport from mainline
2012-07-04 Richard Guenther <rguenther@suse.de>
PR tree-optimization/53844
* tree-ssa-dse.c (dse_possible_dead_store_p): Properly handle
the loop virtual PHI.
* g++.dg/tree-ssa/pr53844.C: New testcase.
2012-12-13 Richard Biener <rguenther@suse.de>
PR lto/55660
* tree-streamer.c (record_common_node): Check that we are not
recursively pre-loading nodes we want to skip. Handle
char_type_node appearing as part of va_list_type_node.
* gcc.dg/lto/pr55660_0.c: New testcase.
* gcc.dg/lto/pr55660_1.c: Likewise.
2013-02-04 Richard Biener <rguenther@suse.de>
PR middle-end/55890
* gimple.h (gimple_call_builtin_class_p): New function.
* gimple.c (validate_call): New function.
(gimple_call_builtin_class_p): Likewise.
* tree-ssa-structalias.c (find_func_aliases_for_builtin_call):
Use gimple_call_builtin_class_p.
(find_func_clobbers): Likewise.
* tree-ssa-strlen.c (adjust_last_stmt): Likewise.
(strlen_optimize_stmt): Likewise.
* gcc.dg/torture/pr55890-1.c: New testcase.
* gcc.dg/torture/pr55890-2.c: Likewise.
From-SVN: r195708
2013-02-02 Thomas Koenig <tkoenig@gcc.gnu.org>
Backport from trunk
PR fortran/50627
PR fortran/56054
* decl.c (gfc_match_end): Remove half-ready namespace
from parent if the end of a block is missing.
* parse.c (parse_module): Do not put namespace into
gsymbol on error.
2013-02-02 Thomas Koenig <tkoenig@gcc.gnu.org>
Backport from trunk
PR fortran/50627
PR fortran/56054
* gfortran.dg/block_12.f90: New test.
* gfortran.dg/module_error_1.f90: New test.
From-SVN: r195687
Backported from mainline
2013-01-28 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/56125
* tree-ssa-math-opts.c (gimple_expand_builtin_pow): Don't optimize
pow(x,c) into sqrt(x) * powi(x, n/2) or
1.0 / (sqrt(x) * powi(x, abs(n/2))) if c is an integer or when
optimizing for size.
Don't optimize pow(x,c) into powi(x, n/3) * powi(cbrt(x), n%3) or
1.0 / (powi(x, abs(n)/3) * powi(cbrt(x), abs(n)%3)) if 2c is an
integer.
* gcc.dg/pr56125.c: New test.
From-SVN: r195664
Backported from mainline
2013-01-25 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/56098
* tree-ssa-phiopt.c (nt_init_block): Don't call add_or_mark_expr
for stmts with volatile ops.
(cond_store_replacement): Don't optimize if assign has volatile ops.
(cond_if_else_store_replacement_1): Don't optimize if either
then_assign or else_assign have volatile ops.
* gcc.dg/pr56098-1.c: New test.
From-SVN: r195663
Backported from mainline
2013-01-23 Jakub Jelinek <jakub@redhat.com>
PR fortran/56052
* trans-decl.c (gfc_get_symbol_decl): Set DECL_ARTIFICIAL
and DECL_IGNORED_P on select_type_temporary and don't set
DECL_BY_REFERENCE.
* gfortran.dg/gomp/pr56052.f90: New test.
From-SVN: r195662
Backported from mainline
2013-01-23 Jakub Jelinek <jakub@redhat.com>
PR target/49069
* config/arm/arm.md (cbranchdi4, cstoredi4): Use s_register_operand
instead of cmpdi_operand for first comparison operand.
Don't assert that comparison operands aren't both constants.
* gcc.dg/pr49069.c: New test.
From-SVN: r195661
Backported from mainline
2013-01-21 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/56051
* fold-const.c (fold_binary_loc): Don't fold
X < (cast) (1 << Y) into (X >> Y) != 0 if cast is either
a narrowing conversion, or widening conversion from signed
to unsigned.
* gcc.c-torture/execute/pr56051.c: New test.
From-SVN: r195658
Backported from mainline
2013-01-18 Jakub Jelinek <jakub@redhat.com>
PR middle-end/56015
* expr.c (expand_expr_real_2) <case COMPLEX_EXPR>: Handle
the case where writing real complex part of target modifies
op1.
* gfortran.dg/pr56015.f90: New test.
From-SVN: r195657
Backported from mainline
2013-01-15 Jakub Jelinek <jakub@redhat.com>
PR target/55940
* function.c (thread_prologue_and_epilogue_insns): Always
add crtl->drap_reg to set_up_by_prologue.set, even if
stack_realign_drap is false.
* gcc.dg/pr55940.c: New test.
From-SVN: r195656
Backported from mainline
2013-01-10 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/55921
* tree-complex.c (expand_complex_asm): New function.
(expand_complex_operations_1): Call it for GIMPLE_ASM.
* gcc.c-torture/compile/pr55921.c: New test.
From-SVN: r195655
Backported from mainline
2013-01-03 Jakub Jelinek <jakub@redhat.com>
PR rtl-optimization/55838
* loop-iv.c (iv_number_of_iterations): Call lowpart_subreg on
iv0.step, iv1.step and step.
* gcc.dg/pr55838.c: New test.
From-SVN: r195654
Backported from mainline
2012-12-01 Jakub Jelinek <jakub@redhat.com>
PR c++/55542
* pt.c (make_ith_pack_parameter_name): Return NULL if
name is NULL.
(tsubst_decl): Call make_ith_pack_parameter_name even if
DECL_NAME is NULL.
* g++.dg/cpp0x/vt-55542.C: New test.
From-SVN: r195652
Backported from mainline
2012-11-20 Jakub Jelinek <jakub@redhat.com>
PR middle-end/55094
* builtins.c (expand_builtin_trap): Add REG_ARGS_SIZE note
on the trap insn for !ACCUMULATE_OUTGOING_ARGS.
* cfgcleanup.c (outgoing_edges_match): Don't look at debug insns
on the first old_insns_match_p call. For !ACCUMULATE_OUTGOING_ARGS
fail if the last real insn doesn't have REG_ARGS_SIZE note.
* gcc.dg/pr55094.c: New test.
From-SVN: r195650
Backported from mainline
2012-11-17 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/55236
* fold-const.c (make_range_step) <case NEGATE_EXPR>: For -fwrapv
and signed ARG0_TYPE, force low and high to be non-NULL.
* gcc.dg/pr55236.c: New test.
From-SVN: r195649
Backported from mainline
2012-11-13 Jakub Jelinek <jakub@redhat.com>
PR rtl-optimization/54127
* cfgrtl.c (force_nonfallthru_and_redirect): When redirecting
asm goto labels from BB_HEAD (e->dest) to target bb, decrement
LABEL_NUSES of BB_HEAD (e->dest) and increment LABEL_NUSES of
BB_HEAD (target) appropriately and adjust JUMP_LABEL and/or
REG_LABEL_TARGET and REG_LABEL_OPERAND.
* gcc.dg/torture/pr54127.c: New test.
From-SVN: r195648
Merged from trunk
PR other/54620
* sha1.c (sha1_process_block): Handle case that size_t is
a wider-integer-scalar as a 32-bit unsigned integer.
From-SVN: r195605
Merged from trunk.
PR other/53285
* md5.c (md5_finish_ctx): Declare swap_bytes. Assign SWAP() output
to swap_bytes, and then call memcpy to move it to ctx->buffer.
From-SVN: r195601
2013-01-29 Richard Biener <rguenther@suse.de>
PR tree-optimization/56113
* tree-ssa-structalias.c (equiv_class_lookup): Also return
the bitmap leader.
(label_visit): Free duplicate bitmaps and record the leader instead.
(perform_var_substitution): Adjust.
From-SVN: r195542
PR target/35294
* config/arm/arm.c (arm_expand_binop_builtin): Add new parameter.
Fix mode checks to allow for the passing of constants in the
second parameter.
(arm_expand_builtin): Adjust calls to arm_expand_binop_builtin.
Add entries in the switch statement for builtin iwmmxt vector
shift and rotate builtins.
From-SVN: r195510
Backport from mainline
2013-01-16 Janis Johnson <janisjo@codesourcery.com>
PR testsuite/55994
* gcc.c-torture/execute/builtins/builtins.exp: Add
-Wl,--allow-multiple-definition for eabi and elf targets.
From-SVN: r195458
Backport from mainline
2012-10-12 Janis Johnson <janisjo@codesourcery.com>
* lib/target-supports.exp (check_effective_target_arm_hard_vfp_ok):
Return 0 if already specifying -mfloat-abi other than hard.
From-SVN: r195456
2013-01-24 Martin Jambor <mjambor@suse.cz>
Backport from mainline
2013-01-04 Martin Jambor <mjambor@suse.cz>
PR tree-optimization/55755
* tree-sra.c (sra_modify_assign): Do not check that an access has no
children when trying to avoid producing a VIEW_CONVERT_EXPR.
testsuite/
* gcc.dg/torture/pr55755.c: New test.
* gcc.dg/tree-ssa/sra-13.c: Likewise.
* gcc.dg/tree-ssa/pr45144.c: Update.
From-SVN: r195425
PR c++/53650
* call.c (type_has_extended_temps): New.
* cp-tree.h: Declare it.
* decl.c (check_initializer): Use build_aggr_init for arrays
if it is false.
* init.c (build_vec_init): Avoid mixed signed/unsigned arithmetic.
From-SVN: r195380
Backport from mainline
2012-01-21 Uros Bizjak <ubizjak@gmail.com>
* config/i386/i386.md (enabled): Do not disable fma4 for TARGET_FMA.
From-SVN: r195349
PR rtl-optimization/56023
* haifa-sched.c (fix_inter_tick): Do not update ticks of instructions,
dependent on debug instruction.
testsuite/ChangeLog:
PR rtl-optimization/56023
* gcc.dg/pr56023.c: New test.
From-SVN: r195344
2013-01-21 Martin Jambor <mjambor@suse.cz>
PR tree-optimizations/55264
* cgraph.c (cgraph_create_virtual_clone): Mark clones as non-virtual.
* cgraph.h (cgraph_only_called_directly_p_or_aliased_p): Return false
for virtual functions.
* ipa-inline-transform.c (can_remove_node_now_p_1): Never return true
for virtual methods.
* ipa.c (cgraph_remove_unreachable_nodes): Never return true for
virtual methods before inlining is over.
testsuite/
* g++.dg/ipa/pr55264.C: New test.
From-SVN: r195339
Backport from 2013-01-14 trunk r195169.
PR target/55974
* config/avr/avr-c.c (avr_cpu_cpp_builtins): Define __FLASH
etc. to 1 and not to __flash.
Use LL suffix for __INT24_MAX__ with -mint8.
Use ULL suffix for __UINT24_MAX__ with -mint8.
From-SVN: r195170
2013-01-13 Janus Weil <janus@gcc.gnu.org>
PR fortran/55072
* trans-array.c (gfc_conv_array_parameter): No packing was done for
full arrays of derived type.
2013-01-13 Janus Weil <janus@gcc.gnu.org>
PR fortran/55072
* gfortran.dg/internal_pack_13.f90: New test.
* gfortran.dg/internal_pack_14.f90: New test.
From-SVN: r195135
2013-01-13 Paul Thomas <pault@gcc.gnu.org>
PR fortran/55618
* trans-expr.c (gfc_conv_procedure_call): Dereference scalar
character function arguments to elemental procedures in
scalarization loops.
2013-01-13 Paul Thomas <pault@gcc.gnu.org>
PR fortran/55618
* gfortran.dg/elemental_scalar_args_2.f90: New test.
From-SVN: r195129
PR fortran/42769
PR fortran/45836
PR fortran/45900
* module.c (read_module): Don't reuse local symtree if the associated
symbol isn't exactly the one wanted. Don't reuse local symtree if it is
ambiguous.
* resolve.c (resolve_call): Use symtree's name instead of symbol's to
lookup the symtree.
PR fortran/42769
PR fortran/45836
PR fortran/45900
* gfortran.dg/use_23.f90: New test.
* gfortran.dg/use_24.f90: New test.
* gfortran.dg/use_25.f90: New test.
* gfortran.dg/use_26.f90: New test.
* gfortran.dg/use_27.f90: New test.
From-SVN: r195031
Backport from 2013-01-07 trunk r194991, r194992.
PR target/55897
* doc/extend.texi (AVR Named Address Spaces): __memx goes into
.progmemx.data now.
* config/avr/avr.h (ADDR_SPACE_COUNT): New enum.
(avr_addrspace_t): Add .section_name field.
* config/avr/avr.c (progmem_section): Use ADDR_SPACE_COUNT as
array size.
(avr_addrspace): Same. Initialize .section_name. Remove last
NULL entry. Put __memx into .progmemx.data.
(progmem_section_prefix): Remove.
(avr_asm_init_sections): No need to initialize progmem_section.
(avr_asm_named_section): Use avr_addrspace[].section_name to get
section name prefix.
(avr_asm_select_section): Ditto. And use get_unnamed_section to
retrieve the progmem section.
* avr-c.c (avr_cpu_cpp_builtins): Use ADDR_SPACE_COUNT as loop
boundary to run over avr_addrspace[].
(avr_register_target_pragmas): Ditto.
From-SVN: r194993
2013-01-07 Steven G. Kargl <kargl@gcc.gnu.org>
Mikael Morin <mikael@gcc.gnu.org>
PR fortran/55827
* class.c (gfc_fix_class_refs): Adapt ts initialization for the case
e->symtree == NULL.
* trans-expr.c (gfc_conv_function_expr): Init sym earlier. Use it.
2013-01-07 Steven G. Kargl <kargl@gcc.gnu.org>
Mikael Morin <mikael@gcc.gnu.org>
PR fortran/55827
* gfortran.dg/use_22.f90: New test.
Co-Authored-By: Mikael Morin <mikael@gcc.gnu.org>
From-SVN: r194985
gcc/ChangeLog
2013-01-07 Terry Guo <terry.guo@arm.com>
Backport from mainline
2012-12-19 Terry Guo <terry.guo@arm.com>
* config/arm/arm.c (thumb_find_work_register): Check argument
register number based on current PCS.
gcc/testsuite/ChangeLog
2013-01-07 Terry Guo <terry.guo@arm.com>
Backport from mainline
2012-12-19 Terry Guo <terry.guo@arm.com>
* gcc.target/arm/thumb-find-work-register.c: New.
From-SVN: r194959
Backport from mainline:
2012-12-09 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
* gcc.dg/torture/pr47917.c: Change "dg-xfail-if" to "dg-xfail-run-if"
for *-*-hpux10*.
From-SVN: r194697
Backport from mainline:
2012-12-09 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
* gcc.dg/20030711-1.c: Define MAP_FAILED if not defined.
* gcc.dg/20050826-1.c: Likewise.
From-SVN: r194695
2012-12-22 Thomas Koenig <tkoenig@gcc.gnu.org>
PR libfortran/30162
Backport from trunk
* io/unix.c (raw_tell): If the lseek is done on a
non-seekable file, return 0.
From-SVN: r194694
PR ada/53737
* sem_ch12.adb (Analyze_Associations): Do not check the legality of
actuals for RACW types if this is an internal instantiation for a formal
package with defaulted parameters.
From-SVN: r194688
2012-12-21 Martin Jambor <mjambor@suse.cz>
PR tree-optimization/55355
* tree-sra.c (type_internals_preclude_sra_p): Also check that
bit_position is small enough to fit a single HOST_WIDE_INT.
* testsuite/g++.dg/torture/pr55355.C: New test.
From-SVN: r194684
Backport r192475 from mainline.
gcc/
2012-10-15 Matthias Klose <doko@ubuntu.com>
* config.gcc: Match arm*-*-linux-* for ARM Linux/GNU.
* doc/install.texi: Use arm-*-*linux-* instead of arm-*-*linux-gnueabi.
gcc/testsuite/
2012-10-15 Matthias Klose <doko@ubuntu.com>
* lib/target-supports.exp (check_profiling_available): Match
arm*-*-linux-* for ARM Linux/GNU.
* g++.dg/torture/predcom-1.C: Match arm*-*-linux-* for ARM Linux/GNU.
* gfortran.dg/enum_10.f90: Likewise.
* gfortran.dg/enum_9.f90: Likewise.
* gcc.target/arm/synchronize.c: Likewise.
* g++.old-deja/g++.jason/enum6.C: Likewise.
* g++.old-deja/g++.other/enum4.C: Likewise.
* g++.old-deja/g++.law/enum9.C: Likewise.
gcc/ada/
2012-10-15 Matthias Klose <doko@ubuntu.com>
* gcc-interface/Makefile.in: Match arm*-*-linux-*eabi* for
ARM Linux/GNU.
libgcc/
2012-10-15 Matthias Klose <doko@ubuntu.com>
* config.host: Match arm*-*-linux-* for ARM Linux/GNU.
libstdc++-v3/
2012-10-15 Matthias Klose <doko@ubuntu.com>
* configure.host: Match arm*-*-linux-* for ARM Linux/GNU.
* testsuite/20_util/make_signed/requirements/typedefs-2.cc: Likewise.
* testsuite/20_util/make_unsigned/requirements/typedefs-2.cc: Likewise.
libjava/
2012-10-15 Matthias Klose <doko@ubuntu.com>
* configure.ac: Match arm*-*-linux-* for ARM Linux/GNU.
* configure: Regenerate.
From-SVN: r194580
* doc/xml/manual/abi.xml: Update URLs for C++ ABI.
* doc/xml/manual/policy_data_structures_biblio.xml: Add xmlns
* doc/xml/manual/policy_data_structures.xml: Set filename for chunk.
* doc/xml/manual/spine.xml: Update copyright years.
* doc/html/*: Regenerate.
From-SVN: r194577
2012-12-17 Matthias Klose <doko@ubuntu.com>
* config/arm/unwind-arm.h (__gnu_unwind_24bit): Mark parameters
as unused.
(_Unwind_decode_typeinfo_ptr): Mark base as unused.
From-SVN: r194555
PR ada/54614
Backport from mainline
2012-10-01 Vincent Pucci <pucci@adacore.com>
* s-gearop.adb (Vector_Matrix_Product): Fix dimension check and index
of Left in S evaluation.
From-SVN: r194534
PR ada/53766
Backport from mainline
2012-07-17 Hristian Kirtchev <kirtchev@adacore.com>
* exp_attr.adb (Expand_N_Attribute_Reference): Add local variables Attr
and Conversion_Added. Add local constant Typ.
Retrieve the original attribute after the arithmetic check
machinery has modified the node. Add a conversion to the target
type when the prefix of attribute Max_Size_In_Storage_Elements
is a controlled type.
From-SVN: r194522
Backport from mainline
2012-12-06 Uros Bizjak <ubizjak@gmail.com>
H.J. Lu <hongjiu.lu@intel.com>
PR target/55597
* config/i386/i386.c (legitimize_tls_address): Zero-extend x to Pmode,
before using it as insn or call equivalent.
testsuite/ChangeLog:
Backport from mainline
2012-12-06 Uros Bizjak <ubizjak@gmail.com>
PR target/55597
* gcc.target/i386/pr55597.c: New test.
From-SVN: r194292
PR c++/54947
* parser.c (cp_parser_initializer_list): Don't require an
expression in [] to be constant until we know it's a C99
designator.
From-SVN: r194254
* config/ia64/ia64.c (ia64_compute_frame_size): Allocate the scratch
area if the function allocates dynamic stack space.
(ia64_initial_elimination_offset): Adjust offsets to above change.
From-SVN: r194122
Backport from mainline:
2012-11-12 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
PR target/55195
* config/pa/pa.md (type): Add sibcall and sh_func_adrs insn types.
(in_branch_delay): Don't allow sibcall or sh_func_adrs insns.
(in_nullified_branch_delay): Likewise.
(in_call_delay): Likewise.
Define delay for sibcall insns. Adjust Z3 and Z4 insn reservations for
new types. Add opaque cond to mark all calls, sibcalls, dyncalls and
the $$sh_func_adrs call as variable. Update type of sibcalls and
$$sh_func_adrs call.
* config/pa/pa.c (pa_adjust_insn_length): Revise to return updated
length instead of adjustment. Handle negative and undefined call
adjustments for insn_default_length. Remove adjustment for millicode
insn with unfilled delay slot.
(pa_output_millicode_call): Update for revised millicode length.
* config/pa/pa.h (ADJUST_INSN_LENGTH): Revise to set LENGTH.
From-SVN: r194027
PR c++/53137
* pt.c (tsubst_expr) [DECL_EXPR]: Set LAMBDA_EXPR_THIS_CAPTURE here.
(tsubst_copy_and_build) [LAMBDA_EXPR]: And clear it here.
(instantiate_class_template_1): Not here.
From-SVN: r193957
2012-11-27 Paolo Bonzini <pbonzini@redhat.com>
PR rtl-optimization/55489
* gcse.c (compute_transp): Precompute a canonical version
of XEXP (x, 0), and pass it to canon_true_dependence.
From-SVN: r193867
2012-11-27 Richard Biener <rguenther@suse.de>
PR middle-end/55331
* gimple-fold.c (gimplify_and_update_call_from_tree): Replace
stmt with a NOP instead of removing it.
* g++.dg/opt/pr55331.C: New testcase.
From-SVN: r193840
2012-11-26 Richard Biener <rguenther@suse.de>
Backport from mainline
2012-10-19 Richard Biener <rguenther@suse.de>
PR tree-optimization/54976
* tree-vect-stmts.c (get_vectype_for_scalar_type_and_size):
Robustify against odd inner_mode inputs.
2012-10-12 Richard Biener <rguenther@suse.de>
PR tree-optimization/54894
* tree-vect-stmts.c (get_vectype_for_scalar_type_and_size):
Handle over-aligned scalar types properly.
2012-10-02 Richard Guenther <rguenther@suse.de>
PR middle-end/54735
* tree-ssa-pre.c (do_pre): Make sure to update virtual SSA form before
cleaning up the CFG.
2012-10-12 Richard Biener <rguenther@suse.de>
PR tree-optimization/54894
* gcc.dg/torture/pr54894.c: New testcase.
2012-10-02 Richard Guenther <rguenther@suse.de>
PR middle-end/54735
* g++.dg/torture/pr54735.C: New testcase.
From-SVN: r193816
/cp
2012-11-24 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/55446
* init.c (build_vec_init): Do not early return error_mark_mode
when integer_all_onesp (maxindex).
/testsuite
2012-11-24 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/55446
* g++.dg/init/new41.C: New.
From-SVN: r193786
2012-11-24 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/55314
Backport from trunk
* resolve.c (resolve_allocate_deallocate): Compare all
subscripts when deciding if to reject a (de)allocate
statement.
2012-11-24 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/55314
Backport from trunk
* gfortran.dg/allocate_error_4.f90: New test.
From-SVN: r193780
2012-11-23 Janus Weil <janus@gcc.gnu.org>
PR fortran/55352
* trans-decl.c (generate_local_decl): Don't warn for explicitly imported
but unused module variables which are in a namelist or common block.
2012-11-23 Janus Weil <janus@gcc.gnu.org>
PR fortran/55352
* gfortran.dg/namelist_76.f90: New.
From-SVN: r193766
2012-11-21 Michael Meissner <meissner@linux.vnet.ibm.com>
Backport from mainline
2012-11-20 Michael Meissner <meissner@linux.vnet.ibm.com>
* config/rs6000/rs6000.md (movdf_hardfloat32): Add a comment
explaining the register ordering preferences.
2012-11-19 Michael Meissner <meissner@linux.vnet.ibm.com>
* config/rs6000/rs6000.md (movdf_hardfloat32): Reorder move
constraints so that the traditional floating point loads, stores,
and moves are done first, then the VSX loads, stores, and moves,
and finally the GPR loads, stores, and moves so that reload
chooses FPRs over GPRs, and uses the traditional load/store
instructions which provide an offset.
(movdf_hardfloat64): Likewise.
From-SVN: r193708
gcc/
2012-11-19 H.J. Lu <hongjiu.lu@intel.com>
Backported from mainline
2012-11-13 Eric Botcazou <ebotcazou@adacore.com>
H.J. Lu <hongjiu.lu@intel.com>
PR middle-end/55142
* config/i386/i386.c (legitimize_pic_address): Properly handle
REG + CONST.
(ix86_print_operand_address): Set code to 'k' when forcing
addr32 prefix. For x32, zero-extend negative displacement if
it < -16*1024*1024.
gcc/testsuite/
2012-11-19 H.J. Lu <hongjiu.lu@intel.com>
Backported from mainline
2012-11-13 H.J. Lu <hongjiu.lu@intel.com>
PR middle-end/55142
* gcc.target/i386/pr55142-1.c: New file.
* gcc.target/i386/pr55142-2.c: Likewise.
From-SVN: r193635
Backport from mainline
2012-11-06 Uros Bizjak <ubizjak@gmail.com>
* config/i386/i386.c (ix86_init_machine_status): Do not
explicitly clear tls_descriptor_call_expanded_p again.
2012-11-06 Uros Bizjak <ubizjak@gmail.com>
* config/i386/sse.md
(<avx_avx2>_maskstore<ssemodesuffix><avxsizesuffix>): Mark operand 0
as read and written by the instruction.
2012-11-06 Uros Bizjak <ubizjak@gmail.com>
* config/i386/i386.c (TARGET_INSTANTIATE_DECLS): New define.
(ix86_instantiate_decls): New function.
(ix86_expand_builtin) <case IX86_BUILTIN_LDMXCSR>: Use SLOT_TEMP
stack slot instead of SLOT_VIRTUAL.
<case IX86_BUILTIN_STMXCSR>: Ditto.
(assign_386_stack_local): Do not assert when virtual slot is valid.
* config/i386/i386.h (enum ix86_stack_slot): Remove SLOT_VIRTUAL.
* config/i386/i386.md (truncdfsf2): Do not use SLOT_VIRTUAL stack slot.
(truncxf<mode>2): Ditto.
(floatunssi<mode>2): Ditto.
(isinf<mode>2): Ditto.
* config/i386/sync.md (atomic_load<mode>): Ditto.
(atomic_store<mode>): Ditto.
From-SVN: r193333
PR middle-end/55219
* fold-const.c (fold_binary_op_with_conditional_arg): Do not fold if
the argument is itself a conditional expression.
From-SVN: r193313
PR tree-optimization/54986
* gimple-fold.c (canonicalize_constructor_val): Strip again all no-op
conversions on entry but add them back on exit if needed.
From-SVN: r193189
Backported from mainline
2012-10-24 Jakub Jelinek <jakub@redhat.com>
PR debug/54828
* gimple.h (is_gimple_sizepos): New inline function.
* gimplify.c (gimplify_one_sizepos): Use it. Remove useless
final assignment to expr variable.
* tree.c (RETURN_TRUE_IF_VAR): Return true also if
!TYPE_SIZES_GIMPLIFIED (type) and _t is going to be gimplified
into a local temporary.
* g++.dg/debug/pr54828.C: New test.
From-SVN: r193166
Backported from mainline
2012-10-23 Jakub Jelinek <jakub@redhat.com>
PR c++/54988
* decl2.c (cplus_decl_attributes): Don't return early
if attributes is NULL.
* c-c++-common/pr54988.c: New test.
From-SVN: r193165
Backported from mainline
2012-10-10 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/54877
* tree-vect-loop.c (vect_is_simple_reduction_1): For MINUS_EXPR
use make_ssa_name instead of copy_ssa_name.
* gcc.dg/torture/pr54877.c: New test.
From-SVN: r193164
Backport from mainline
2012-10-31 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/53708
* tree-vect-data-refs.c (vect_can_force_dr_alignment_p): Preserve
user-supplied alignment when used with an explicit section name.
From-SVN: r193121
PR tree-optimization/54985
* tree-ssa-threadedge.c (cond_arg_set_in_bb): New function extracted
from thread_across_edge.
(thread_across_edge): Use it in all cases where we might thread
across a back edge.
* gcc.c-torture/execute/pr54985.c: New test.
From-SVN: r193108
Backport from mainline
2012-10-11 Terry Guo <terry.guo@arm.com>
* config/arm/arm.c (arm_arch6m): New variable to denote armv6-m
architecture.
* config/arm/arm.h (TARGET_HAVE_DMB): The armv6-m also has DMB
instruction.
From-SVN: r192907
Backport from mainline
2012-10-23 Terry Guo <terry.guo@arm.com>
PR target/55019
* config/arm/arm.c (thumb1_expand_prologue): Don't push high regs with
live argument regs.
gcc/testsuite/ChangeLog
Backport from mainline
2012-10-23 Terry Guo <terry.guo@arm.com>
PR target/55019
* gcc.dg/pr55019.c: New.
From-SVN: r192831
Backport from mainline
2012-10-22 Uros Bizjak <ubizjak@gmail.com>
* config/i386/i386.c (memory_address_length): Assert that non-null
base or index RTXes are registers. Do not check for REG RTXes.
Determine addr32 prefix using SImode_address_operand or
from original base and index RTXes. Simplify code.
2012-10-21 Uros Bizjak <ubizjak@gmail.com>
* config/i386/i386-protos.h (memory_address_length): Add new bool
argument. Update all uses.
* config/i386/i386.c (memory_address_length): If not LEA insn, then
add length of addr32 prefix based on mode of base or index register.
(ix86_attr_length_address_default) <TYPE_LEA>: Do not handle SImode
addresses here. Update call to memory_address_length.
(ix86_print_address_operand): Use SImode_address_operand predicate.
* config/i386/predicates.md (SImode_address_operand): New.
* config/i386/i386.md (lea<mode>): Use SImode_address_operand
to calculate "mode" attribute. Use SImode_address_operand predicate
instead of open-coding accepted RTX codes.
From-SVN: r192769
Backport from 2012-10-22 trunk r192685.
* doc/invoke.texi (AVR Options): Document __AVR_ARCH__.
Note __AVR_<device>__ is not defined for cores.
Don't point to --help=target.
Order --mcu= documentation according to trunk:/gcc/doc/avr-mmcu.texi.
From-SVN: r192686
* gcc-interface/decl.c (gnat_to_gnu_entity) <E_Array_Type>: Force
BLKmode on the type if it is passed by reference.
<E_Array_Subtype>: Likewise.
<E_Record_Type>: Guard the call to Is_By_Reference_Type predicate.
<E_Record_Subtype>: Likewise.
From-SVN: r192674
* gcc-interface/decl.c (gnat_to_gnu_entity) <E_Out_Parameter>: Do not
generate the special PARM_DECL for an Out parameter in LTO mode.
From-SVN: r192668
Backported from mainline
2012-10-19 Zhenqiang Chen <zhenqiang.chen@linaro.org>
PR target/54892
* config/arm/arm.c (arm_expand_compare_and_swap): Use SImode to make
sure the mode is correct when falling through from above cases.
gcc/testsuite/ChangeLog
Backported from mainline
2012-10-19 Zhenqiang Chen <zhenqiang.chen@linaro.org>
PR target/54892
* gcc.target/arm/pr54892.c: New.
From-SVN: r192610
* config/rs6000/predicates.md (splat_input_operand): Don't call
input_operand for MEMs. Instead check for volatile and call
memory_address_addr_space_p with modified mode.
From-SVN: r192591
PR rtl-optimization/54870
* tree.h (TREE_ADDRESSABLE): Document special usage on SSA_NAME.
* cfgexpand.c (update_alias_info_with_stack_vars ): Set it on the
SSA_NAME pointer that points to a partition if there is at least
one variable with it set in the partition.
* dse.c (local_variable_can_escape): New predicate.
(can_escape): Call it.
* gimplify.c (mark_addressable): If this is a partitioned decl, also
mark the SSA_NAME pointer that points to a partition.
From-SVN: r192518
2012-10-16 Andrey Belevantsev <abel@ispras.ru>
Backport from mainline
2012-08-09 Andrey Belevantsev <abel@ispras.ru>
PR rtl-optimization/53701
* sel-sched.c (vinsn_vec_has_expr_p): Clarify function comment.
Process not only expr's vinsns but all old vinsns from expr's
history of changes.
(update_and_record_unavailable_insns): Clarify comment.
testsuite:
2012-10-16 Andrey Belevantsev <abel@ispras.ru>
Backport from mainline
2012-08-09 Andrey Belevantsev <abel@ispras.ru>
PR rtl-optimization/53701
* gcc.dg/pr53701.c: New test.
From-SVN: r192498
Backport from mainline
2012-10-15 Uros Bizjak <ubizjak@gmail.com>
* config/i386/sse.md (UNSPEC_MOVU): Remove.
(UNSPEC_LOADU): New.
(UNSPEC_STOREU): Ditto.
(<sse>_movu<ssemodesuffix><avxsizesuffix>): Split to ...
(<sse>_loadu<ssemodesuffix><avxsizesuffix>): ... this and ...
(<sse>_storeu<ssemodesuffix><avxsizesuffix>) ... this.
(<sse2>_movdqu<avxsizesuffix>): Split to ...
(<sse2>_loaddqu<avxsizesuffix>): ... this and ...
(<sse2>_storedqu<avxsizesuffix>): ... this.
(*sse4_2_pcmpestr_unaligned): Update.
(*sse4_2_pcmpistr_unaligned): Ditto.
* config/i386/i386.c (ix86_avx256_split_vector_move_misalign): Use
gen_avx_load{dqu,ups,upd}256 to load from unaligned memory and
gen_avx_store{dqu,ups,upd}256 to store to unaligned memory.
(ix86_expand_vector_move_misalign): Use gen_sse_loadups or
gen_sse2_load{dqu,upd} to load from unaligned memory and
gen_sse_loadups or gen_sse2_store{dqu,upd}256 to store to
unaligned memory.
(struct builtin_description bdesc_spec) <IX86_BUILTIN_LOADUPS>:
Use CODE_FOR_sse_loadups.
<IX86_BUILTIN_LOADUPD>: Use CODE_FOR_sse2_loadupd.
<IX86_BUILTIN_LOADDQU>: Use CODE_FOR_sse2_loaddqu.
<IX86_BUILTIN_STOREUPS>: Use CODE_FOR_sse_storeups.
<IX86_BUILTIN_STOREUPD>: Use CODE_FOR_sse2_storeupd.
<IX86_BUILTIN_STOREDQU>: Use CODE_FOR_sse2_storedqu.
<IX86_BUILTIN_LOADUPS256>: Use CODE_FOR_avx_loadups256.
<IX86_BUILTIN_LOADUPD256>: Use CODE_FOR_avx_loadupd256.
<IX86_BUILTIN_LOADDQU256>: Use CODE_FOR_avx_loaddqu256.
<IX86_BUILTIN_STOREUPS256>: Use CODE_FOR_avx_storeups256.
<IX86_BUILTIN_STOREUPD256>: Use CODE_FOR_avx_storeupd256.
<IX86_BUILTIN_STOREDQU256>: Use CODE_FOR_avx_storedqu256.
testsuite/ChangeLog:
Bacport from mainline
2012-10-15 Uros Bizjak <ubizjak@gmail.com>
* gcc.target/i386/avx256-unaligned-load-1.c: Update asm scan patterns.
* gcc.target/i386/avx256-unaligned-load-2.c: Ditto.
* gcc.target/i386/avx256-unaligned-load-3.c: Ditto.
* gcc.target/i386/avx256-unaligned-load-4.c: Ditto.
* gcc.target/i386/avx256-unaligned-store-1.c: Ditto.
* gcc.target/i386/avx256-unaligned-store-2.c: Ditto.
* gcc.target/i386/avx256-unaligned-store-3.c: Ditto.
* gcc.target/i386/avx256-unaligned-store-4.c: Ditto.
From-SVN: r192477
Backport from trunk (r190222):
PR tree-optimization/54146
* ifcvt.c: Include pointer-set.h.
(cond_move_process_if_block): Change type of then_regs and
else_regs from alloca'd array to pointer_sets.
(check_cond_move_block): Update for this change.
(cond_move_convert_if_block): Likewise.
* Makefile.in: Fix dependencies for ifcvt.o.
From-SVN: r192476
2012-10-14 Janus Weil <janus@gcc.gnu.org>
PR fortran/54784
* trans-stmt.c (gfc_trans_allocate): Correctly determine the reference
to the _data component for polymorphic allocation with SOURCE.
2012-10-14 Janus Weil <janus@gcc.gnu.org>
PR fortran/54784
* gfortran.dg/class_allocate_13.f90: New.
From-SVN: r192442
2012-10-06 Thomas König <tkoenig@gcc.gnu.org>
PR libfortran/54736
Backport from trunk
* runtime/environ.c (search_unit): Correct logic
for binary search.
(mark_single): Fix index errors.
From-SVN: r192408
2012-10-08 Terry Guo <terry.guo@arm.com>
Backported from mainline
2012-09-19 Terry Guo <terry.guo@arm.com>
* lib/gcc-dg.exp (dg_runtest_extra_prunes): New variable to define
extra prune rules that will be applied to all tests in a .exp file.
(gcc-dg-prune): Use rules defined by the above variable.
* gcc.target/arm/arm.exp (dg_runtest_extra_prunes): Skip all the
harmless warnings on architecture switch conflict.
From-SVN: r192196
Backported from mainline
* config/i386/driver-i386.c (host_detect_local_cpu): Fix logic
in SSE and YMM state support check for -march=native.
From-SVN: r192045
PR c++/54777
* semantics.c (cxx_eval_constant_expression) <case COMPOUND_EXPR>: If
not ignoring the second operand, pass the original second operand
and not one with stripped nops to cxx_eval_constant_expression.
* g++.dg/cpp0x/constexpr-ref4.C: New test.
From-SVN: r192037
* gcc-interfaces/decl.c (elaborate_expression_1): Use the variable for
bounds of loop iteraration scheme only for locally defined subtypes.
* gcc-interface/trans.c (build_return_expr): Apply the NRV optimization
only for BLKmode.
From-SVN: r191972
2012-10-01 Tom de Vries <tom@codesourcery.com>
* var-tracking.c (set_dv_changed): Add an 'inline' function specifier to
the prototype.
From-SVN: r191916
2012-09-29 Andreas Tobler <andreast@fgznet.ch>
Backport from mainline
2012-09-29 Andreas Tobler <andreast@fgznet.ch>
* config.gcc: Replace 'host' with 'target' when configuring for
powerpc64*-*-freebsd.
From-SVN: r191850
PR c/54552
* c-typeck.c (c_cast_expr): When casting to a type requiring
C_MAYBE_CONST_EXPR to be created, pass the inner expression to
c_fully_fold first.
testsuite:
* gcc.c-torture/compile/pr54552-1.c: New test.
From-SVN: r191591
PR c/54103
* c-typeck.c (build_unary_op): Pass original argument of
TRUTH_NOT_EXPR to c_objc_common_truthvalue_conversion, then remove
any C_MAYBE_CONST_EXPR, if it has integer operands.
(build_binary_op): Pass original arguments of TRUTH_ANDIF_EXPR,
TRUTH_ORIF_EXPR, TRUTH_AND_EXPR, TRUTH_OR_EXPR and TRUTH_XOR_EXPR
to c_objc_common_truthvalue_conversion, then remove any
C_MAYBE_CONST_EXPR, if they have integer operands. Use
c_objc_common_truthvalue_conversion not
c_common_truthvalue_conversion.
(c_objc_common_truthvalue_conversion): Build NE_EXPR directly and
call note_integer_operands for arguments with integer operands
that are not integer constants.
testsuite:
* gcc.c-torture/compile/pr54103-1.c,
gcc.c-torture/compile/pr54103-2.c,
gcc.c-torture/compile/pr54103-3.c,
gcc.c-torture/compile/pr54103-4.c,
gcc.c-torture/compile/pr54103-5.c,
gcc.c-torture/compile/pr54103-6.c: New tests.
* gcc.dg/c90-const-expr-8.c: Update expected column number.
From-SVN: r191589
Backported from mainline
2012-09-17 Jakub Jelinek <jakub@redhat.com>
PR tree-optimization/54563
* tree-ssa-math-opts.c (execute_cse_sincos): Call
gimple_purge_dead_eh_edges if last call has been changed.
* g++.dg/torture/pr54563.C: New test.
From-SVN: r191571
Backported from mainline
2012-09-14 Jakub Jelinek <jakub@redhat.com>
PR target/54564
* config/i386/sse.md (fmai_vmfmadd_<mode>): Use (match_dup 1)
instead of (match_dup 0) as second argument to vec_merge.
(*fmai_fmadd_<mode>, *fmai_fmsub_<mode>): Likewise.
Remove third alternative.
(*fmai_fnmadd_<mode>, *fmai_fnmsub_<mode>): Likewise. Negate
operand 2 instead of operand 1, but put it as first argument
of fma.
* config/i386/fmaintrin.h (_mm_fnmadd_sd, _mm_fnmadd_ss,
_mm_fnmsub_sd, _mm_fnmsub_ss): Negate the second argument instead
of the first.
From-SVN: r191570
2012-09-20 Richard Guenther <rguenther@suse.de>
Backport from mainline
2012-09-11 Jan Hubicka <jh@suse.cz>
PR lto/54312
* lto.c (uniquify_nodes): Remove quadratic loop checking if the
type is variant leader.
From-SVN: r191568
Backport from mainline.
2012-09-14 Walter Lee <walt@tilera.com>
* doc/invoke.texi (Option Summary): fix typesetting for -mcpu
option for TILEPro and TILE-Gx.
From-SVN: r191310
2012-09-13 Tobias Burnus <burnus@net-b.de>
PR fortran/54556
* resolve.c (resolve_formal_arglist): Allow VALUE arguments
with implicit_pure.
(gfc_impure_variable): Don't check gfc_pure such that the
function also works for gfc_implicit_pure procedures.
2012-09-13 Tobias Burnus <burnus@net-b.de>
PR fortran/54556
* gfortran.dg/implicit_pure_3.f90: New.
From-SVN: r191275
* config/i386/i386.h (x86_prefetchw): New global variable.
(TARGET_PREFETCHW): New macro.
* config/i386/i386.c (PTA_PREFETCHW): Ditto.
(processor_alias_table): Add PTA_PREFETCHW to
bdver1, bdver2 and btver1.
(ix86_option_override_internal): Set x86_prefetchw for
PTA_PREFETCHW targets.
* config/i386/i386.md (prefetch): Expand to prefetchw
for TARGET_PREFETCHW.
(*prefetch_3dnow_<mode>): Also enable for TARGET_PREFETCHW.
Backport from mainline
2012-08-13 Uros Bizjak <ubizjak@gmail.com>
* config/i386/i386.md (prefetch): Do not assert mode of operand 0.
(*prefetch_sse_<mode>): Do not set mode of address_operand predicate.
Rename to ...
(*prefetch_sse): ... this.
(*prefetch_3dnow_<mode>): Do not set mode of address_operand predicate.
Rename to ...
(*prefetch_3dnow): ... this.
From-SVN: r191272
PR c/54559
* c-typeck.c (c_finish_return): Do convert to BOOLEAN_TYPE or
COMPLEX_TYPE with in_late_binary_op set temporarily to true.
* gcc.c-torture/compile/pr54559.c: New test.
From-SVN: r191271
2012-09-12 Teresa Johnson <tejohnson@google.com>
Backport from mainline.
2012-09-12 Teresa Johnson <tejohnson@google.com>
PR gcov-profile/54487
* configure.ac (HOST_HAS_F_SETLKW): Set based on compile
test using F_SETLKW with fcntl.
* configure, config.in: Regenerate.
From-SVN: r191254
Backport from mainline
2012-09-12 Ganesh Gopalasubramanian <Ganesh.Gopalasubramanian@amd.com>
* config/i386/i386.md : Comments on fma4 instruction selection
reflect requirement on register pressure based cost model.
* config/i386/driver-i386.c (host_detect_local_cpu): fma4
flag is set-reset as informed by the cpuid flag.
* config/i386/i386.c (processor_alias_table): fma4
flag is enabled for bdver2.
From-SVN: r191227
PR c++/54506
* decl.c (move_signature_fn_p): Split out from move_fn_p.
* method.c (process_subob_fn): Use it.
* cp-tree.h: Declare it.
From-SVN: r191146
PR c++/54341
PR c++/54253
* semantics.c (sort_constexpr_mem_initializers): New.
(build_constexpr_constructor_member_initializers): Use it.
(cx_check_missing_mem_inits): Skip artificial fields.
* init.c (expand_aggr_init_1): Don't zero out a class
with no data.
From-SVN: r191145
2012-09-07 Markus Trippelsdorf <markus@trippelsdorf.de>
PR middle-end/54515
* tree-sra.c (disqualify_base_of_expr): Check for possible
NULL_TREE returned by get_base_address()
* g++.dg/tree-ssa/pr54515.C: new testcase
From-SVN: r191130
2012-09-09 Thiago Macieira <thiago.macieira@intel.com>
PR libstdc++/54172
* libsupc++/guard.cc (__cxa_guard_acquire): Exit the loop earlier if
we detect that another thread has had success. Don't compare_exchange
from a finished state back to a waiting state. Comment.
From-SVN: r191125
2012-09-07 Richard Guenther <rguenther@suse.de>
Backport from mainline
2012-06-26 Jan Hubicka <jh@suse.cz>
PR lto/53572
* cgraph.h (varpool_can_remove_if_no_refs): Fix handling of
used symbols.
From-SVN: r191073
2012-09-07 Richard Guenther <rguenther@suse.de>
Backport from mainline
2012-07-13 Richard Guenther <rguenther@suse.de>
PR tree-optimization/53922
* tree-vrp.c (value_inside_range): Change prototype to take
min/max instead of value-range.
(range_includes_zero_p): Likewise. Return the result from
value_inside_range.
(extract_range_from_binary_expr_1): Adjust to handle dont-know
return value from range_includes_zero_p.
(extract_range_from_unary_expr_1): Likewise.
(compare_range_with_value): Likewise.
(vrp_meet_1): Likewise.
* gcc.dg/torture/pr53922.c: New testcase.
From-SVN: r191072
2012-09-07 Jakub Jelinek <jakub@redhat.com>
Backported from mainline
2012-09-06 Jakub Jelinek <jakub@redhat.com>
PR rtl-optimization/54455
* sel-sched-ir.c (maybe_tidy_empty_bb): Give up if previous fallthru
bb ends up with asm goto referencing bb's label.
* gcc.dg/54455.c: New test.
From-SVN: r191060
Fix PR target/54252
2012-09-07 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
Backport from mainline.
2012-08-29 Ramana Radhakrishnan <ramana.radhakrishnan@arm.com>
Richard Earnshaw <richard.earnshaw@arm.com>
PR target/54252
* config/arm/arm.c (neon_dereference_pointer): Adjust nelems by
element size. Use elem_type from the formal parameter. New parameter
fcode.
(neon_expand_args): Adjust call to neon_dereference_pointer.
From-SVN: r191059
2012-09-06 Richard Guenther <rguenther@suse.de>
PR tree-optimization/54498
* tree-ssa-alias.h (get_continuation_for_phi): Add flag to
abort when reaching an already visited region.
* tree-ssa-alias.c (maybe_skip_until): Likewise. And do it.
(get_continuation_for_phi_1): Likewise.
(walk_non_aliased_vuses): When we translated the reference,
abort when we re-visit a region.
* tree-ssa-pre.c (translate_vuse_through_block): Adjust.
From-SVN: r191031
PR middle-end/54486
* builtins.c (fold_builtin_strspn, fold_builtin_strcspn): Use
build_int_cst with size_type_node instead of size_int.
* c-c++-common/pr54486.c: New test.
From-SVN: r190987
Backport from 2012-09-04 mainline r190919
PR target/45070
* config/arm/arm.c (thumb1_extra_regs_pushed): Handle return value of size
less than 4 bytes by using macro ARM_NUM_INTS.
(thumb1_unexpanded_epilogue): Use macro ARM_NUM_INTS.
From-SVN: r190970
Backported from mainline
2012-09-01 Jakub Jelinek <jakub@redhat.com>
PR target/54436
* config/i386/i386.md (*mov<mode>_insv_1_rex64, *movsi_insv_1): If
operands[1] is CONST_INT_P, convert it to QImode before printing.
* gcc.dg/torture/pr54436.c: New test.
From-SVN: r190900
Backported from mainline
2012-08-31 Jakub Jelinek <jakub@redhat.com>
PR c/54428
* c-convert.c (convert): Don't call fold_convert_loc if
TYPE_MAIN_VARIANT of a COMPLEX_TYPE is the same, unless e
is a COMPLEX_EXPR. Remove TYPE_MAIN_VARIANT check from
COMPLEX_TYPE -> COMPLEX_TYPE conversion.
* gcc.c-torture/compile/pr54428.c: New test.
From-SVN: r190899
Backported from mainline
2012-08-24 Jakub Jelinek <jakub@redhat.com>
PR c/54363
* gimplify.c (optimize_compound_literals_in_ctor): Only recurse
if init is a CONSTRUCTOR.
* gcc.dg/pr54363.c: New test.
From-SVN: r190898
Backport from mainline
2012-08-23 Yuri Rumyantsev <ysrumyan@gmail.com>
* config/i386/i386.c (ia32_multipass_dfa_lookahead) : Add
case for Atom processor.
From-SVN: r190837
because it causes an extra copy when bfins reuses one of its inputs.
Backport from mainline
2012-08-27 Walter Lee <walt@tilera.com>
* config/tilegx/tilegx.md (*bfins): Rename to insn_bfins.
(insn_bfins): Delete.
From-SVN: r190725
Properly set the latency of atomic ops to the approximate latency of a
remote memory operation.
Backport from mainline
2012-08-27 Walter Lee <walt@tilera.com>
* config/tilegx/sync.md (atomic_compare_and_swap_bare<mode>,
atomic_exchange_bare<mode>,
atomic_fetch_<fetchop_name>_bare<mode>): Set type to X1_remote.
* config/tilegx/tilegx-generic.md (X1_remote): New
insn_reservation.
* config/tilegx/tilegx.md (type): Add X1_remove.
(insn_cmpexch<four_if_si>, insn_exch<four_if_si>,
insn_fetchadd<four_if_si>, insn_fetchaddgez<four_if_si>,
insn_fetchand<four_if_si>, insn_fetchor<four_if_si>): Set type to
X1_remote.
From-SVN: r190723
PR libstdc++/54297
* include/std/future (~_Async_state_impl): Join thread before
derived class members are destroyed.
(~_Async_state_common): Only define non-trivial destructor when
included from future.cc for ABI compatibility reasons.
* src/c++11/future.cc (_GLIBCXX_ABI_COMPAT_ASYNC): Define.
* testsuite/30_threads/async/54297.cc: New.
From-SVN: r190673
Add a stub header file "feedback.h," needed to compile glibc and
linux.
Backport from mainline
2012-08-16 Walter Lee <walt@tilera.com>
* config.gcc (tilegx-*-linux*): Add feedback.h.
(tilepro-*-linux*): Likewise.
* config/tilegx/feedback.h: New file.
* config/tilepro/feedback.h: New file.
From-SVN: r190453
Backport from mainline r189840 and r187586:
2012-07-25 Sergey Melnikov <sergey.melnikov@intel.com>
* config/i386/i386.md (stack_protect_set): Disable the pattern
for Android since Android libc (bionic) does not provide random
value for stack protection guard at gs:0x14. Guard value
will be provided from external symbol (default implementation).
(stack_protect_set_<mode>): Likewise.
(stack_protect_test): Likewise.
(stack_protect_test_<mode>): Likewise.
* gcc/defaults.h: Define macro TARGET_HAS_BIONIC to 0 - target does
not have Bionic by default
* config/linux.h: Redefine macro TARGET_HAS_BIONIC to (OPTION_BIONIC)
Macro OPTION_BIONIC is defined in this file and provides Bionic
accessibility status
2012-05-16 Igor Zamyatin <igor.zamyatin@intel.com>
* configure.ac: Stack protector enabling for Android targets.
* configure: Regenerate.
From-SVN: r190383
Backported from trunk
2012-07-19 Jakub Jelinek <jakub@redhat.com>
PR rtl-optimization/53942
* function.c (assign_parm_setup_reg): Avoid zero/sign extension
directly from likely spilled non-fixed hard registers, move them
to pseudo first.
* gcc.dg/pr53942.c: New test.
From-SVN: r190338
ChangeLog:
Backport from mainline
2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
Richard Earnshaw <rearnsha@arm.com>
* target.def (vector_alignment): New target hook.
* doc/tm.texi.in (TARGET_VECTOR_ALIGNMENT): Document new hook.
* doc/tm.texi: Regenerate.
* targhooks.c (default_vector_alignment): New function.
* targhooks.h (default_vector_alignment): Add prototype.
* stor-layout.c (layout_type): Use targetm.vector_alignment.
* config/arm/arm.c (arm_vector_alignment): New function.
(TARGET_VECTOR_ALIGNMENT): Define.
* tree-vect-data-refs.c (vect_update_misalignment_for_peel): Use
vector type alignment instead of size.
* tree-vect-loop-manip.c (vect_do_peeling_for_loop_bound): Use
element type size directly instead of computing it from alignment.
Fix variable naming and comment.
testsuite/ChangeLog:
Backport from mainline
2012-07-30 Ulrich Weigand <ulrich.weigand@linaro.org>
* lib/target-supports.exp
(check_effective_target_vect_natural_alignment): New function.
* gcc.dg/align-2.c: Only run on targets with natural alignment
of vector types.
* gcc.dg/vect/slp-25.c: Adjust tests for targets without natural
alignment of vector types.
From-SVN: r190295
* config/alpha/alpha.c (alpha_pad_noreturn): Rename to ...
(alpha_pad_function_end): ... this. Also insert NOP between
sibling call and GP load.
(alpha_reorg): Update call to alpha_pad_function_end. Expand comment.
From-SVN: r190262
gcc/
2012-08-09 H.J. Lu <hongjiu.lu@intel.com>
Backport from mainline
2012-08-08 Richard Sandiford <rdsandiford@googlemail.com>
H.J. Lu <hongjiu.lu@intel.com>
PR rtl-optimization/54157
* combine.c (gen_lowpart_for_combine): Don't return identity
for CONST or symbolic reference.
gcc/testsuite/
2012-08-09 H.J. Lu <hongjiu.lu@intel.com>
Backport from mainline
2012-08-08 H.J. Lu <hongjiu.lu@intel.com>
PR rtl-optimization/54157
* gcc.target/i386/pr54157.c: New file.
From-SVN: r190256
Backport from mainline
2012-07-23 Uros Bizjak <ubizjak@gmail.com>
* config/i386/i386-protos.h (ix86_lea_outperforms): Remove prototype.
* config/i386/i386.c (ix86_lea_outperforms): Make static. Make
split_cost argument signed.
(ix86_use_lea_for_mov): Use INVALID_REGNUM instead of -1.
(ix86_avoid_lea_for_addr): Ditto.
2012-07-27 Uros Bizjak <ubizjak@gmail.com>
* config/i386/i386.c (ix86_avoid_lea_for_addr): Return false if
the address has less than two components.
From-SVN: r190183
Backport from mainline
2012-08-01 Uros Bizjak <ubizjak@gmail.com>
* config/i386/i386.c (ix86_address_subreg_operand): Reject
stack pointer.
(ix86_print_operand_address): Assert that parts.base and parts.index
are non-NULL after call to simplify_subreg.
From-SVN: r190045
2012-07-29 François Dumont <fdumont@gcc.gnu.org>
PR libstdc++/54075
* include/bits/hashtable_policy.h
(_Prime_rehash_policy::_M_next_bkt): Add a growth factor set to 2
to boost growth in the number of buckets.
* testsuite/performance/23_containers/insert/unordered_set.cc: New.
From-SVN: r189941
2012-07-26 François Dumont <fdumont@gcc.gnu.org>
PR libstdc++/54075
* include/bits/hashtable.h
(_Hashtable<>::_Hashtable(_InputIterator, _InputIterator,
size_type, ...): Remove std::max usage to guarantee that hashtable
state is consistent with hash policy state.
(_Hashtable<>::rehash): Likewise. Set _M_prev_resize to 0 to avoid
the hashtable shrinking on next insertion.
* testsuite/23_containers/unordered_set/modifiers/reserve.cc: New.
* testsuite/23_containers/unordered_multiset/modifiers/reserve.cc: New.
* testsuite/23_containers/unordered_map/modifiers/reserve.cc: New.
* testsuite/23_containers/unordered_multimap/modifiers/reserve.cc: New.
From-SVN: r189889
PR target/33135
* config/sh/sh.opt (mieee): Use Var instead of Mask. Correct
description.
* config/sh/sh.c (sh_option_override): Do not change
flag_finite_math_only. Set TARGET_IEEE to complement of
flag_finite_math_only.
* doc/invoke.texi (SH options): Add mno-ieee. Correct
description of mieee and mno-ieee behavior.
From-SVN: r189761
PR c++/54038
* tree.c (build_cplus_array_type): Use build_cplus_array_type to build
canonical array type rather than mess with its TYPE_*_VARIANT.
From-SVN: r189720
Backport from mainline
2012-03-06 Andrey Belevantsev <abel@ispras.ru>
PR rtl-optimization/52250
* sel-sched-ir.c (maybe_tidy_empty_bb): Try harder to find a bb
to put note list into. Unconditionally call move_bb_info.
(move_bb_info): Do not assert the blocks being in the same region,
just drop the note list if they are not.
From-SVN: r189705
* gcc-interface/decl.c (gnat_to_gnu_entity) <object>: Try to ensure
that an object of CW type initialized to a value is sufficiently
aligned for this value.
From-SVN: r189683
* tree-ssa-ccp.c (valid_lattice_transition): Clarify comment
about transition from invariant to known bits.
(likely_value): Addresses with UNDEFINED components are UNDEFINED.
Co-Authored-By: Eric Botcazou <ebotcazou@adacore.com>
From-SVN: r189679
* gcc-interface/decl.c (gnat_to_gnu_entity) <E_Record_Subtype>: Do not
look up the REP part of the base type in advance. Deal with that of
the variant types.
(get_rep_part): Be prepared for record types with fields.
From-SVN: r189667
PR middle-end/54017
* tree-cfgcleanup.c (cleanup_omp_return): Remove.
(cleanup_tree_cfg_bb): Don't call it.
* omp-low.c (expand_omp_sections): Fix up the !exit_reachable case
handling.
* c-c++-common/gomp/pr54017.c: New test.
From-SVN: r189659
2012-07-18 Richard Guenther <rguenther@suse.de>
Backport from mainline
2012-05-03 Richard Guenther <rguenther@suse.de>
* gfortran.dg/pr52621.f90: Add -w to avoid diagnostic about
unsupported prefetching support.
From-SVN: r189606
PR target/53961
Backport from mainline
2012-04-25 Jakub Jelinek <jakub@redhat.com>
PR target/53110
* config/i386/i386.md (and<mode>3): For andq $0xffffffff, reg
instead expand it as zero extension.
From-SVN: r189491
* config/i386/i386.md (QImode and HImode cmove splitters): Merge
QImode and HImode splitters. Use ix86_comparison_operator.
Explicitly match FLAGS_REG.
(DFmode cmove splitter): Explicitly match FLAGS_REG.
From-SVN: r189478
2012-07-06 Richard Guenther <rguenther@suse.de>
Backport from mainline
2012-03-30 Richard Guenther <rguenther@suse.de>
PR middle-end/52786
* double-int.c (rshift_double): Remove not
needed cast.
2012-03-28 Richard Guenther <rguenther@suse.de>
PR middle-end/50708
* double-int.h (rshift_double): Remove.
* double-int.c (lshift_double): Use absu_hwi to make count
positive.
(rshift_double): Make static, take unsigned count argument,
remove handling of negative count argument.
(double_int_rshift): Dispatch to lshift_double.
From-SVN: r189314
2012-07-06 Richard Guenther <rguenther@suse.de>
Backport from mainline
2012-06-18 Richard Guenther <rguenther@suse.de>
PR tree-optimization/53693
* tree-vect-patterns.c (vect_operation_fits_smaller_type):
Reject operands with more than one use.
* g++.dg/torture/pr53693.C: New testcase.
From-SVN: r189313
Backport from mainline
2012-05-24 Pat Haugen <pthaugen@us.ibm.com>
* config/rs6000/rs6000.c (rs6000_option_override_internal): Change
rs6000_sched_costly_dep default to true_store_to_load_dep_costly.
(adjacent_mem_locations): Move some code to and call...
(get_memref_parts): ...new function.
(mem_locations_overlap): New function.
(rs6000_adjust_priority): Adjust calls to is_load_insn/is_store_insn.
(is_mem_ref): Rename to...
(find_mem_ref): ...this. Return MEM rtx.
(get_store_dest): Remove function.
(is_load_insn1, is_load_insn, is_store_insn1, is_store_insn): Add
new parameter and adjust calls.
(rs6000_is_costly_dependence): Update calls for extra arg. Make sure
mem refs overlap for true_store_to_load_dep_costly.
(rs6000_sched_reorder2): Update calls for extra arg. Adjust args
passed to adjacent_mem_locations.
(is_costly_group): Walk resolved dependency list.
(force_new_group): Emit group ending nop for Power6/Power7.
* config/rs6000/rs6000.md (UNSPEC_GRP_END_NOP): New enum value.
(group_ending_nop): New define_insn.
gcc/testsuite:
* gcc.target/powerpc/lhs-1.c: New.
* gcc.target/powerpc/lhs-2.c: New.
* gcc.target/powerpc/lhs-3.c: New.
From-SVN: r189303
PR libstdc++/53830
* include/std/condition_variable (condition_variable_any::wait):
Move _Unlock type to class scope.
(condition_variable_any::wait_until): Reuse it.
* testsuite/30_threads/condition_variable_any/53830.cc: New.
From-SVN: r189273
2012-07-04 Richard Guenther <rguenther@suse.de>
PR middle-end/53433
* gimple-fold.c (get_base_constructor): Do not return an
error_mark_node DECL_INITIAL.
From-SVN: r189262
2012-07-04 Tristan Gingold <gingold@adacore.com>
Backport from mainline.
2012-06-25 Tristan Gingold <gingold@adacore.com>
* config/i386/winnt.c (i386_pe_seh_end_prologue): Move code to ...
(seh_cfa_adjust_cfa): ... that function.
(seh_emit_stackalloc): Do not emit out of range values.
* config/i386/i386.md: Delete unused UNSPEC_REG_SAVE,
UNSPEC_DEF_CFA constants.
* config/i386/i386.h (SEH_MAX_FRAME_SIZE): Define.
* config/i386/i386.c (ix86_frame_pointer_required): Required
for very large frames on SEH target.
(ix86_compute_frame_layout): Save area is before frame pointer
on SEH target. Handle very large frames.
(ix86_expand_prologue): Likewise.
From-SVN: r189258
2012-07-04 Richard Guenther <rguenther@suse.de>
* tree.c (find_decls_types_r): Handle TYPE_CONTEXT the same
as in free_lang_data_in_type.
From-SVN: r189253
* exp_disp.adb (Expand_Dispatching_Call): Propagate the convention on
the designated subprogram type and also set Is_Dispatch_Table_Entity.
(Expand_Interface_Thunk): Propagate the convention on the thunk.
(Set_CPP_Constructors_Old): Set Is_Constructor and Convention_CPP on
the internal view of the constructors.
(Set_CPP_Constructors): Likewise.
* sem_prag.adb (Analyze_Pragma) <Pragma_CPP_Constructor>: Set the
convention on the function.
* gcc-interface/gigi.h (is_cplusplus_method): Declare.
* gcc-interface/decl.c (Has_Thiscall_Convention): New macro.
(gnat_to_gnu_entity) <E_Subprogram_Type>: Test it to set the `thiscall'
calling convention
(get_minimal_subprog_decl): Likewise.
(is_cplusplus_method): New predicate.
* gcc-interface/trans.c (Attribute_to_gnu) <Attr_Access>: Issue an
error on access to C++ constructor or member function.
From-SVN: r189200
2012-07-02 Martin Jambor <mjambor@suse.cz>
PR middle-end/38474
* ipa-prop.c (compute_known_type_jump_func): Put BINFO check before a
dynamic type change check.
From-SVN: r189164
2012-06-28 Richard Guenther <rguenther@suse.de>
PR middle-end/53790
* expr.c (expand_expr_real_1): Verify if the type is complete
before inspecting its size.
* gcc.dg/torture/pr53790.c: New testcase.
From-SVN: r189047
PR target/53759
* config/i386/sse.md (sse_loadlps): Use x m x constraints instead
of x x x in the vmovlps load alternative.
* gcc.target/i386/pr53759.c: New test.
From-SVN: r188938
PR c++/53594
* class.c (check_bases_and_members): Avoid -Wuninitialized
diagnostics for non-static const members or references if they
use NSDMI.
* g++.dg/cpp0x/nsdmi7.C: New test.
From-SVN: r188926
PR c++/52637
* dwarf2out.c (modified_type_die): Use scope_die_for.
(gen_type_die_with_usage, dwarf2out_finish): Likewise.
(uses_local_type_r, uses_local_type): New.
(scope_die_for): Keep a type that uses a local type in local scope.
Use get_context_die for namespace and type scope.
From-SVN: r188812
2012-06-11 Richard Guenther <rguenther@suse.de>
PR middle-end/53470
* tree.c (free_lang_data_in_type): Do not clear TYPE_CONTEXT but
replace it with the first non-BLOCK context.
* g++.dg/lto/pr53470_0.C: New testcase.
* gcc.dg/lto/pr53470_0.c: Likewise.
From-SVN: r188811
Reapply:
PR c++/53137
* pt.c (instantiate_class_template_1): Set LAMBDA_EXPR_THIS_CAPTURE.
(instantiate_decl): Don't push_to_top_level for local class methods.
(instantiate_class_template_1): Or for local classes.
From-SVN: r188810
2012-06-18 Vladimir Makarov <vmakarov@redhat.com>
PR rtl-optimization/53700
Backport from mainline
2012-03-29 Vladimir Makarov <vmakarov@redhat.com>
* ira-color.c (setup_left_conflict_sizes_p): Process all
conflicting objects.
From-SVN: r188750
PR ada/53592
* gcc-interface/gigi.h (maybe_vector_array): Make static inline.
* gcc-interface/utils.c (maybe_vector_array): Delete.
* gcc-interface/trans.c (gnat_to_gnu) <N_Indexed_Component>: Mark the
array object as addressable if it has vector type and is on the LHS.
From-SVN: r188654
runtime: Fix printing of names in stack dumps.
compiler: Fix taking address of field of local variable.
compiler, reflect: Handle package path like gc compiler.
os: Use Entersyscall when reading directories.
os/user: Use Entersyscall.
compiler: Avoid unnecessary interface conversions.
libgo: Make the subdirectory in the CHECK target.
From-SVN: r188633
Backported from mainline
2012-06-12 Jakub Jelinek <jakub@redhat.com>
PR rtl-optimization/53589
* cfgrtl.c (force_nonfallthru_and_redirect): Do asm_goto_edge
discovery even when e->dest != target. If any LABEL_REF points
to e->dest label, redirect it to target's label.
* gcc.dg/torture/pr53589.c: New test.
From-SVN: r188626
Backported from mainline
2012-06-06 Jakub Jelinek <jakub@redhat.com>
PR libgomp/52993
* config/linux/lock.c (gomp_init_nest_lock_25): Fix up last
argument to memset call.
From-SVN: r188624
2012-06-14 Richard Guenther <rguenther@suse.de>
Backport from mainline
2012-06-11 Richard Guenther <rguenther@suse.de>
PR c++/53616
* mangle.c (write_array_type): Use double-ints for array domain
arithmetic.
* g++.dg/ext/pr53605.C: New testcase.
From-SVN: r188615
PR target/53621
* config/sh/sh.c (sh_option_override): Don't force
flag_omit_frame_pointer and maccumulate_outgoing_args.
* config/sh/sh.opt (maccumulate-outgoing-args): Init as Var.
* gcc.dg/stack-usage-1.c: Force -fomit-frame-pointer on SH.
From-SVN: r188599
2012-05-19 Eric Botcazou <ebotcazou@adacore.com>
* gcc-interface/decl.c (Has_Thiscall_Convention): New macro.
(gnat_to_gnu_entity) <E_Subprogram_Type>: Test it to set the thiscall
calling convention
(get_minimal_subprog_decl): Likewise.
(gnat_first_param_is_class): New predicate.
From-SVN: r188513
PR c++/53599
Revert:
PR c++/53137
* pt.c (instantiate_class_template_1): Set LAMBDA_EXPR_THIS_CAPTURE.
(instantiate_decl): Don't push_to_top_level for local class methods.
(instantiate_class_template_1): Or for local classes.
From-SVN: r188460
PR c++/53602
* combine-stack-adj.c (force_move_args_size_note): Add ARGS_SIZE
note to a clobber insn when no other insn is available.
From-SVN: r188356
2012-06-04 Richard Guenther <rguenther@suse.de>
PR middle-end/53471
* dwarf2out.c (dwarf2out_finish): If generating LTO do not
create new assembler names.
From-SVN: r188182
2012-06-04 Richard Guenther <rguenther@suse.de>
Backport from mainline
2012-04-25 Jakub Jelinek <jakub@redhat.com>
PR middle-end/52979
* stor-layout.c (get_best_mode): Don't return mode with bitsize
larger than maxbits. Don't compute maxbits modulo align.
Also check that unit bytes long store at bitpos / unit * unit
doesn't affect bits beyond bitregion_end.
* expmed.c (store_bit_field_1): Avoid trying insv if OP_MODE MEM
would not fit into bitregion_start ... bitregion_end + 1 bit
region.
(store_split_bit_field): Decrease unit close to end of bitregion_end
if access is restricted in order to avoid mutual recursion.
* gcc.c-torture/compile/pr52979-1.c: New test.
* gcc.c-torture/execute/pr52979-1.c: New test.
* gcc.c-torture/execute/pr52979-2.c: New test.
From-SVN: r188176
PR tree-optimization/53550
* tree-ssa-loop-niter.c (number_of_iterations_cond): If type
is POINTER_TYPE_P, use sizetype as step type instead of type.
* gcc.dg/pr53550.c: New test.
From-SVN: r188170
2012-06-04 Richard Guenther <rguenther@suse.de>
Eric Botcazou <ebotcazou@adacore.com>
Backport from mainline
2012-04-03 Eric Botcazou <ebotcazou@adacore.com>
* expr.c (get_bit_range): Add OFFSET parameter and adjust BITPOS.
Change type of BITOFFSET to signed. Make sure the lower bound of
the computed range is non-negative by adjusting OFFSET and BITPOS.
(expand_assignment): Adjust call to get_bit_range.
2012-03-27 Eric Botcazou <ebotcazou@adacore.com>
* expr.c (get_bit_range): Return the null range if the enclosing record
is part of a larger bit field.
2012-03-20 Richard Guenther <rguenther@suse.de>
* stor-layout.c (finish_bitfield_representative): Fallback
to conservative maximum size if the padding up to the next
field cannot be computed as a constant.
(finish_bitfield_layout): If we cannot compute the distance
between the start of the bitfield representative and the
bitfield member start a new representative.
* expr.c (get_bit_range): The distance between the start of
the bitfield representative and the bitfield member is zero
if the field offsets are not constants.
2012-03-16 Richard Guenther <rguenther@suse.de>
* stor-layout.c (finish_bitfield_representative): Fall back
to the conservative maximum size if we cannot compute the
size of the tail padding.
2012-03-14 Richard Guenther <rguenther@suse.de>
* tree.h (DECL_BIT_FIELD_REPRESENTATIVE): New define.
* stor-layout.c (start_bitfield_representative): New function.
(finish_bitfield_representative): Likewise.
(finish_bitfield_layout): Likewise.
(finish_record_layout): Call finish_bitfield_layout.
* tree.c (free_lang_data_in_decl): Only free DECL_QUALIFIER
for QUAL_UNION_TYPE fields.
* tree-streamer-in.c (lto_input_ts_field_decl_tree_pointers):
Stream DECL_BIT_FIELD_REPRESENTATIVE.
* tree-streamer-out.c (write_ts_field_decl_tree_pointers): Likewise.
PR middle-end/52080
PR middle-end/52097
PR middle-end/48124
* expr.c (get_bit_range): Unconditionally extract bitrange
from DECL_BIT_FIELD_REPRESENTATIVE.
(expand_assignment): Adjust call to get_bit_range.
* gcc.dg/torture/pr48124-1.c: New testcase.
* gcc.dg/torture/pr48124-2.c: Likewise.
* gcc.dg/torture/pr48124-3.c: Likewise.
* gcc.dg/torture/pr48124-4.c: Likewise.
* gnat.dg/pack16.adb: Likewise.
* gnat.dg/pack16_pkg.ads: Likewise.
* gnat.dg/pack17.adb: Likewise.
* gnat.dg/specs/pack7.ads: Likewise.
* gnat.dg/specs/pack8.ads: Likewise.
* gnat.dg/specs/pack8_pkg.ads: Likewise.
Co-Authored-By: Eric Botcazou <ebotcazou@adacore.com>
From-SVN: r188167
PR c++/53137
* pt.c (instantiate_class_template_1): Set LAMBDA_EXPR_THIS_CAPTURE.
(instantiate_decl): Don't push_to_top_level for local class methods.
(instantiate_class_template_1): Or for local classes.
From-SVN: r188123
Backport from mainline
2012-03-21 Kaz Kojima <kkojima@gcc.gnu.org>
PR target/52642
* config/sh/sh.c (sh_expand_prologue): Emit blockage at the end of
prologue for unwinder and profiler.
From-SVN: r188087
Backport from mainline
2012-03-03 Kaz Kojima <kkojima@gcc.gnu.org>
* config/sh/sh.c (shiftcosts): Return MAX_COST when the first
operand is CONST_INT. Take COSTS_N_INSNS into account.
(sh_rtx_costs): Don't apply COSTS_N_INSNS to the return value of
shiftcosts.
From-SVN: r188084
2012-05-31 Richard Guenther <rguenther@suse.de>
PR middle-end/48493
* expr.c (expand_assignment): Do not use movmisalign on
non-memory.
* gcc.dg/torture/pr48493.c: New testcase.
From-SVN: r188056
2012-05-30 Richard Guenther <rguenther@suse.de>
PR middle-end/53501
* fold-const.c (fold_binary_loc): Make sure to call
fold_plusminus_mult_expr with the original sign of operands.
* gcc.dg/torture/pr53501.c: New testcase.
* c-c++-common/restrict-2.c: Adjust.
From-SVN: r188010
PR rtl-optimization/53519
* combine.c (simplify_shift_const_1) <case NOT>: Use constm1_rtx
instead of GEN_INT (GET_MODE_MASK (mode)) as second operand of XOR.
* gcc.c-torture/compile/pr53519.c: New test.
From-SVN: r188002
* gcc-interface/decl.c (variant_desc): Rename 'record' to 'new_type'.
(build_variant_list): Adjust to above renaming.
(gnat_to_gnu_entity) <E_Record_Subtype>: Likewise. Give a unique name
to the type of the variant containers.
(create_variant_part_from): Likewise. Give a unique name to the type
of the variant part.
From-SVN: r187909
libgcc/:
* config/i386/morestack.S (__morestack_non_split): Check whether
caller is varargs and needs %bp to hold the stack frame on return.
gcc/testsuite/:
* gcc.dg/split-6.c: New test.
From-SVN: r187895
PR lto/52178
* tree-inline.c (remap_gimple_op_r): Fix handling of FIELD_DECL.
* tree.c (RETURN_TRUE_IF_VAR): Do not return true for PLACEHOLDER_EXPR.
From-SVN: r187893
2012-05-25 Alexander Ivchenko <alexander.ivchenko@intel.com>
PR target/53435
* config/i386/i386.c (ix86_expand_vec_perm): Use correct op.
(ix86_expand_vec_perm): Use int mode instead of float.
From-SVN: r187882
PR ada/52362
* config.gcc (i[34567]86-*-mingw* | x86_64-*-mingw*): Set gas and
gnu_ld variables to yes.
* configure.ac (HAVE_GNU_LD): Move to after config.gcc inclusion.
(HAVE_GNU_AS): Likewise.
* config.in: Regenerate.
* configure: Likewise.
ada/
* link.c (__gnat_object_file_option): Set to "-Wl,@" for GNU linker.
(__gnat_using_gnu_linker): Delete.
* gnatlink.adb (Gnatlink): Declare Object_File_Option_Ptr here...
Declare Object_File_Option string constant and Using_GNU_response_file
boolean constant.
(Process_Binder_File): ...instead of here. Delete Using_GNU_Linker,
Opening and Closing local variables. Do not handle the GNU linker
specially.
(Write_RF): New procedure to write into the response file. Escape some
characters if a GNU response file is used. Keep track of error status.
Invoke Write_RF to write into the response file. Delete the file only
if the link was successful.
* mlib-utl.adb: Do not `with' package System.
(Gcc): Likewise. Declare Object_File_Option string constant and
Using_GNU_response_file boolean constant.
(Write_RF): Take a string instead of address and length. Escape some
characters if a GNU response file is used.
Invoke Write_RF to write into the response file. Delete the file only
if the link was successful. Do not warn if it cannot be deleted.
From-SVN: r187877
2012-05-25 Ramana Radhakrishnan <ramana.radhakrishnan@linaro.org>
Backport from mainline
2012-03-12 Richard Guenther <rguenther@suse.de>
* config/arm/arm.c (neon_dereference_pointer): Do not call
covert during RTL expansion.
From-SVN: r187876
2012-05-24 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
Backport from mainline
2012-05-18 Bill Schmidt <wschmidt@linux.vnet.ibm.com>
PR target/53385
* config/rs6000/rs6000.c (print_operand): Revise code that unsafely
relied on signed overflow behavior.
From-SVN: r187835
2012-05-24 Richard Guenther <rguenther@suse.de>
PR middle-end/53460
* tree-profile.c (tree_profiling): Cleanup the CFG if
execute_fixup_cfg requests it.
* g++.dg/tree-prof/pr53460.C: New testcase.
From-SVN: r187832
PR tree-optimization/53465
* tree-vrp.c (extract_range_from_cond_expr): First copy_value_range
vr0 into *vr, then vrp_meet that.
(vrp_meet): If one vr type is VR_UNDEFINED, ensure the result doesn't
have any equivalences.
(vrp_visit_phi_node): Call copy_value_range instead of vrp_meet the
first time.
* gcc.c-torture/execute/pr53465.c: New test.
From-SVN: r187828
* gimple.c (gimple_types_compatible_p_1) <ARRAY_TYPE>: Remove bogus
size handling.
(gimple_canonical_types_compatible_p) <ARRAY_TYPE>: Likewise.
(iterative_hash_gimple_type): Adjust comment.
(iterative_hash_canonical_type): Likewise. Hash the bounds of the
domain for an array type instead of the domain type itself.
From-SVN: r187809
2012-05-22 Richard Guenther <rguenther@suse.de>
PR tree-optimization/53408
* tree-vect-loop.c (vectorizable_induction): Properly check
the restriction that we cannot handle induction results from
the inner loop outside of the outer loop.
* gcc.dg/torture/pr53408.c: New testcase.
From-SVN: r187770
PR tree-optimization/53436
* omp-low.c (omp_build_component_ref): New function.
(build_receiver_ref, build_sender_ref, create_task_copyfn): Use it.
From-SVN: r187742
PR tree-optimization/53366
* tree-vect-slp.c (vect_supported_load_permutation_p): Don't shortcut
tests if complex_numbers == 2, but there are non-complex number loads
too.
* gcc.dg/torture/pr53366-1.c: New test.
* gcc.dg/torture/pr53366-2.c: New test.
* gcc.target/i386/pr53366-1.c: New test.
* gcc.target/i386/pr53366-2.c: New test.
From-SVN: r187740
PR tree-optimization/53410
* fold-const.c (fold_binary_loc): Use build_zero_cst (type)
instead of build_int_cst (type, 0) where vector types might be
involved.
* gcc.c-torture/compile/pr53410-1.c: New test.
* gcc.c-torture/compile/pr53410-2.c: New test.
From-SVN: r187738
2012-05-21 Andrew Pinski <apinski@cavium.com>
PR bootstrap/53183
* configure.ac: Define the default includes to being none.
* configure: Regenerate.
From-SVN: r187733
PR c/53418
* c-typeck.c (build_conditional_expr): Remove C_MAYBE_CONST_EXPR
from folded operands before wrapping another around the
conditional expression.
testsuite:
* gcc.c-torture/compile/pr53418-1.c,
gcc.c-torture/compile/pr53418-2.c: New tests.
From-SVN: r187726
Backport from mainline
2012-05-14 Eric Botcazou <ebotcazou@adacore.com>
* tree-ssa-pre.c (can_value_number_call): Delete.
(compute_avail): Skip all statements with side effects.
<GIMPLE_CALL>: Skip calls to internal functions.
From-SVN: r187683
2012-05-19 Eric Botcazou <ebotcazou@adacore.com>
* gcc-interface/decl.c (Has_Thiscall_Convention): New macro.
(gnat_to_gnu_entity) <E_Subprogram_Type>: Test it to set the thiscall
calling convention
(get_minimal_subprog_decl): Likewise.
(gnat_first_param_is_class): New predicate.
Backport from mainline
2012-05-15 Javier Miranda <miranda@adacore.com>
* exp_ch3.adb (Build_Offset_To_Top): Modify the
expansion of the offset_to_top functions to ensure that their
profile is conformant with the profile specified in Ada.Tags. No
change in functionality.
From-SVN: r187677
Backport r185385 from mainline.
2012-03-14 Richard Guenther <rguenther@suse.de>
PR middle-end/52584
* tree-vect-generic.c (type_for_widest_vector_mode): Take
element type instead of mode, use build_vector_type_for_mode
instead of the langhook, build a vector of proper signedness.
(expand_vector_operations_1): Adjust.
From-SVN: r187675
* gcc-interface/decl.c (gnat_to_gnu_entity) <object>: For an object at
global level with unconstrained nominal subtype and a non-fixed size,
make a variable for the size.
From-SVN: r187668
If during reorg we delete a code label, and as a result we decide to
delete all the code following that label, we hit this condition in
jump.c:delete_related_insns():
if (was_code_label && prev && BARRIER_P (prev))
which passes and then we proceed to delete insns until we hit a
non-deleted code label.
During this traversal, we can end up deleting a CALL, but in doing so
we will leave the var tracking note for the call arguments around.
Later in dwarf2_var_location() we will ICE, because we can't find the
CALL when we search backwards for it.
gcc/
* jump.c (delete_related_insns): If we remove a CALL, make sure
we delete it's NOTE_INSN_CALL_ARG_LOCATION note too.
From-SVN: r187605
toplevel/
* Makefile.tpl (gcc-no-fixedincludes): Rename into ...
(gcc-install-no-fixedincludes): Now forwarder to local target in gcc/
(install-no-fixedincludes): Adjust accordingly.
* Makefile.in: Regenerate.
gcc/
* Makefile.in (install-no-fixedincludes): New target, former toplevel
gcc-no-fixedincludes. Stash "include-fixed" in addition to "include".
Add comments and improve stamp preservation across the whole sequence.
(stmp-int-hdrs): Use move-if-change + cp -p to setup fix_dir/limits.h.
From-SVN: r187601
libgcc/
* Makefile.in (install-unwind_h): Rename into ...
(install-unwind_h-forbuild): New target.
(all): Use it instead of the former install-unwind_h.
(install-unwind_h): Reinstate, copy to user install destination
for include files, not to the internal gcc object directory one.
(install-leaf): Depend on it.
From-SVN: r187600
2012-05-16 Richard Guenther <rguenther@suse.de>
PR tree-optimization/53364
* tree-ssa-alias.c (indirect_ref_may_alias_decl_p): Properly
detect a view-conversion of the decl.
* g++.dg/torture/pr53364.C: New testcase.
From-SVN: r187589
PR target/53358
* config/i386/i386.md (*addqi_2 peephole with QImode addition): Check
that operands[2] is either immediate, or q_regs_operand.
* gcc.dg/pr53358.c: New test.
From-SVN: r187545
Backport r187139 from mainline.
2012-05-04 Bin Cheng <bin.cheng@arm.com>
PR rtl-optimization/52804
* reload1.c (reload_reg_reaches_end_p): Check whether successor
reload with type RELOAD_FOR_INPUT_ADDRESS kills reload register
of current one with type RELOAD_FOR_INPADDR_ADDRESS.
Same stands for reloads with type RELOAD_FOR_OUTPUT_ADDRESS and
RELOAD_FOR_OUTADDR_ADDRESS.
From-SVN: r187496
* dwarf2out.c (dwarf2out_define, dwarf2out_undef): Treat
lineno 1 the same as lineno 0 before first start file directive.
(optimize_macinfo_range): Likewise.
From-SVN: r187476
* dwarf2out.c (have_macinfo): Define.
(dwarf2out_finish): Don't emit DW_AT_GNU_macros or DW_AT_macro_info
attribute, don't force empty compilation unit and don't emit any
.debug_macinfo/.debug_macro section if macinfo_table is empty.
From-SVN: r187474
2012-05-12 Tobias Burnus <burnus@net-b.de>
PR fortran/53310
* intrinsics/eoshift2.c (eoshift2): Do not leak
memory by allocating it in the loop.
From-SVN: r187417
* include/bits/random.tcc (seed_seq::generate): Cast max()
operands to size_t to ensure a template match.
* include/std/bitset (_M_copy_from_ptr): Cast min() operands to
size_t to ensure a template match.
From-SVN: r187379
* lang.opt: Add -fgo-pkgpath.
* go-lang.c (go_pkgpath): New static variable.
(go_prefix): New static variable.
(go_langhook_init): Pass go_pkgpath and go_prefix to
go_create_gogo.
(go_langhook_handle_option): Handle -fgo-pkgpath. Change
-fgo-prefix handling to just set go_prefix.
* go-c.h (go_set_prefix): Don't declare.
(go_create_gogo): Add pkgpath and prefix to declaration.
* go-gcc.cc (Gcc_backend::global_variable): Change unique_prefix
to pkgpath. Don't include the package name in the asm name.
* gccgo.texi (Invoking gccgo): Document -fgo-pkgpath. Update the
docs for -fgo-prefix.
From-SVN: r187357
PR target/53272
* config/cris/cris.c (cris_normal_notice_update_cc): For TARGET_V32,
when a constant source operand matches an "I" constraint, the "no
CC0 change" applies to a register-destination only, not a
strict_low_part-destination.
From-SVN: r187285
PR tree-optimization/53239
* tree-vrp.c (get_value_range): Set VR of
SSA_NAME_IS_DEFAULT_DEF of DECL_BY_REFERENCE RESULT_DECL
to nonnull.
* g++.dg/opt/vrp3.C: New test.
* g++.dg/opt/vrp3-aux.cc: New file.
* g++.dg/opt/vrp3.h: New file.
From-SVN: r187241
2012-05-07 Richard Guenther <rguenther@suse.de>
PR tree-optimization/53195
* tree-inline.c (setup_one_parameter): Properly add referenced
vars from the parameters new known value.
From-SVN: r187237
Backport from mainline:
2012-04-27 John David Anglin <dave.anglin@nrc-cnrc.gc.ca>
PR target/52999
* config/pa/pa.c (pa_legitimate_constant_p): Don't put function labels
in constant pool.
From-SVN: r187216
gcc/ada/
Revert
2012-02-24 Dave Korn <dave.korn.cygwin@gmail.com>
* gcc-interface/Makefile.in (WIN_SO_PREFIX [windows targets]): New
Windows-specific make variable.
(WIN_SO_INSTALL_DIR [windows targets]): Likewise.
(install-gnatlib): Respect the above during installation when set,
and also install any windows import library that has been built.
(gnatlib-shared-win32): Use WIN_SO_PREFIX to name output DLL and also
build a corresponding import library.
libada/
Revert
2012-02-24 Dave Korn <dave.korn.cygwin@gmail.com>
* Makefile.in (bindir): Import from autoconf and pass down to submake.
From-SVN: r187205
Backport from mainline
2012-05-04 Uros Bizjak <ubizjak@gmail.com>
PR target/53228
* config/i386/i386.h (X86_ARCH_CMOV): Rename from X86_ARCH_CMOVE.
(TARGET_CMOV): Rename from TARGET_CMOVE.
(TARGET_CMOVE): New define.
* config/i386/i386.c (ix86_option_override_internal): Use TARGET_CMOV.
Do not set TARGET_CMOVE here.
From-SVN: r187169
2012-05-04 Ulrich Weigand <ulrich.weigand@linaro.org>
Backport from mainline:
2012-05-04 Ulrich Weigand <ulrich.weigand@linaro.org>
PR tree-optimization/52633
* tree-vect-patterns.c (vect_vect_recog_func_ptrs): Swap order of
vect_recog_widen_shift_pattern and vect_recog_over_widening_pattern.
(vect_recog_over_widening_pattern): Remove handling of code that was
already detected as over-widening pattern. Remove special handling
of "unsigned" cases. Instead, support general case of conversion
of the shift result to another type.
2012-05-04 Ulrich Weigand <ulrich.weigand@linaro.org>
* tree-vect-patterns.c (vect_single_imm_use): New function.
(vect_recog_widen_mult_pattern): Use it instead of open-coding loop.
(vect_recog_over_widening_pattern): Likewise.
(vect_recog_widen_shift_pattern): Likewise.
2012-04-10 Ulrich Weigand <ulrich.weigand@linaro.org>
PR tree-optimization/52870
* tree-vect-patterns.c (vect_recog_widen_mult_pattern): Verify that
presumed pattern statement is within the same loop or basic block.
2012-05-04 Ulrich Weigand <ulrich.weigand@linaro.org>
Backport from mainline:
2012-05-04 Ulrich Weigand <ulrich.weigand@linaro.org>
PR tree-optimization/52633
* gcc.dg/vect/vect-over-widen-1.c: Two patterns should now be
recognized as widening shifts instead of over-widening.
* gcc.dg/vect/vect-over-widen-1-big-array.c: Likewise.
* gcc.dg/vect/vect-over-widen-4.c: Likewise.
* gcc.dg/vect/vect-over-widen-4-big-array.c: Likewise.
* gcc.target/arm/pr52633.c: New test.
2012-04-10 Ulrich Weigand <ulrich.weigand@linaro.org>
PR tree-optimization/52870
* gcc.dg/vect/pr52870.c: New test.
From-SVN: r187162
2012-05-04 Richard Guenther <rguenther@suse.de>
* common.opt (flto-report): Do not mark as Optimization.
lto/
* lang.opt (fwpa): Do not mark as Optimization.
(fltrans): Likewise.
* gcc.dg/lto/pr53214_0.c: New testcase.
From-SVN: r187154
PR target/48496
* recog.c (constrain_operands): If extra constraints are present, also
accept pseudo-registers with equivalent memory locations during reload.
From-SVN: r187152
[gcc]
2012-05-03 Michael Meissner <meissner@linux.vnet.ibm.com>
PR target/53199
* config/rs6000/rs6000.md (bswapdi splitters): If
-mavoid-indexed-addresses (or -mcpu=power6 which sets it by
default) is used, generate an alternate sequence that does not
depend on using indexed addressing.
[gcc/testsuite]
2012-05-03 Michael Meissner <meissner@linux.vnet.ibm.com>
PR target/53199
* gcc.target/powwerpc/pr53199.c: New file.
From-SVN: r187132
PR target/52684
* config/sparc/sparc.c (emit_soft_tfmode_libcall): If we pass a
MEM directly into a libcall, mark it's MEM_EXPR as addressable.
(sparc_emit_float_lib_cmp): Likewise.
From-SVN: r187124
2012-05-03 Martin Jambor <mjambor@suse.cz>
PR lto/52605
* dwarf2out.c (dwarf2out_decl): Only lookup die representing context
of a variable when the contect is a function.
* gcc/testsuite/g++.dg/lto/pr52605_0.C: New test.
From-SVN: r187109
/cp
2012-05-03 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/53186
* call.c (build_over_call): Handle final member functions
and class types.
(build_new_method_call_1): Do not handle here.
/testsuite
2012-05-03 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/53186
* g++.dg/other/final2.C: New.
From-SVN: r187098
PR plugins/53126
* gcc-ar.c (main): If GCC_EXEC_PREFIX is set in env,
append program name to it and pass that as first argument
to make_relative_prefix. Always pass standard_libexec_prefix
as last argument to make_relative_prefix. If
make_relative_prefix returns NULL, fall back to
standard_libexec_prefix.
From-SVN: r187091
PR target/53187
* config/arm/arm.c (arm_select_cc_mode): If x has MODE_CC class
mode, return that mode.
* gcc.target/arm/pr53187.c: New test.
* gcc.c-torture/compile/pr53187.c: New test.
From-SVN: r187086
PR rtl-optimization/53160
* ree.c (combine_reaching_defs): Handle the case where cand->insn
has been modified by ree pass already.
* gcc.c-torture/execute/pr53160.c: New test.
From-SVN: r187036
2012-04-30 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/53148
Backport from trunk
* frontend-passes.c (create_var): If the statement has a label,
put the label around the block.
2012-04-30 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/53148
Backport from trunk
* gfortran.dg/function_optimize_12.f90: New test.
From-SVN: r186999
2012-04-30 Andreas Tobler <andreast@fgznet.ch>
Backport from mainline
2012-03-21 Andreas Tobler <andreast@fgznet.ch>
* testsuite/23_containers/vector/bool/modifiers/insert/31370.cc:
Skip this test on powerpc64-*-freebsd*.
From-SVN: r186997
2012-04-30 Andreas Tobler <andreast@fgznet.ch>
Backport from mainline
2012-03-21 Andreas Tobler <andreast@fgznet.ch>
* config.host: Add bits to support powerpc64-*-freebsd*.
* config/rs6000/freebsd-unwind.h: New file.
* config/rs6000/t-freebsd64: New file.
From-SVN: r186996
2012-04-30 Andreas Tobler <andreast@fgznet.ch>
Backport from mainline
2012-03-21 Andreas Tobler <andreast@fgznet.ch>
* configure.ac (HAVE_LD_NO_DOT_SYMBOLS): Add powerpc64-*-freebsd*.
Introduce emul_name to select the right linker emulation for
powerpc64-*-freebsd*.
* configure: Regenerate.
* config.gcc: Add bits to support powerpc64-*-freebsd*.
* config/rs6000/freebsd.h (POWERPC_FREEBSD): Define.
* config/rs6000/freebsd64.h: New file.
* config/rs6000/rs6000.c (rs6000_option_override_internal): Use
POWERPC_FREEBSD.
(rs6000_savres_strategy): Likewise.
(rs6000_savres_routine_name): Likewise.
(rs6000_elf_file_end): Likewise.
* config/rs6000/t-freebsd64: New file.
* config/rs6000/sysv4.h (SUBTARGET_OVERRIDE_OPTIONS): Set the
rs6000_current_abi for 64-bit FreeBSD to ABI_AIX.
From-SVN: r186995
* config/i386/i386.c (ix86_handle_struct_attribute): Use the proper
predicate to discriminate types.
ada/
* gcc-interface/utils.c (finish_record_type): Force the traditional GCC
layout for bitfields on the type if it is packed or has a representation
clause and an alternate layout is available.
From-SVN: r186959
PR go/52358
math: Work around bug in Solaris 9 implementation of ldexp.
The bug is that ldexp(-1, -1075) should return -0, but the
Solaris 9 implementation returns +0.
From-SVN: r186914
PR target/53120
* config/cris/cris.md ("*andhi_lowpart_v32")
("*andqi_lowpart_v32"): Change first input-only operand from
a (match_operand ...) to (match_dup 0). Drop alternatives with
const_int-matching constraints for redundancy.
("*andhi_lowpart_non_v32", "*andqi_lowpart_non_v32"): Ditto. Drop
three-operand alternative.
From-SVN: r186848
PR go/52583
net: Solaris fixes.
In particular fix fd_select.go to handle the case where a file
descriptor is closed by one goroutine while another goroutine
is waiting for it.
From-SVN: r186802
2012-04-23 Chris Jefferson <chris@bubblescope.net>
PR testsuite/53046
* testsuite/25_algorithms/stable_partition/mem_check.cc: Fix size
of array A.
* testsuite/25_algorithms/stable_sort/mem_check.cc: Likewise.
From-SVN: r186713
PR tree-optimizations/52891
* tree-vect-patterns.c (adjust_bool_pattern): Use
build_nonstandard_type even if rhs1 has unsigned INTEGER_TYPE,
but with non-standard precision.
* gcc.c-torture/compile/pr52891-1.c: New test.
* gcc.c-torture/compile/pr52891-2.c: New test.
From-SVN: r186695
Backport from 2012-04-19 mainline r186588.
PR target/53033
* config/avr/avr.c (avr_out_load_psi): Fix assembler template for
the case *(X+const).
From-SVN: r186589
/cp
2012-04-17 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/53003
* parser.c (cp_parser_member_declaration): Check that
initializer_token_start is non null before dereferencing it.
/testsuite
2012-04-17 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/53003
* g++.dg/parse/crash59.C: New.
From-SVN: r186544
Fixes compilation of incorrect code:
const f, g = g, f
func S() []byte { return []byte(f) }
The problem was already handled for numerical constants.
Part of issue 3186 (go).
From-SVN: r186512
2012-04-16 Martin Jambor <mjambor@suse.cz>
PR middle-end/52939
* gimple-fold.c (gimple_get_virt_method_for_binfo): Bail out if
fold_ctor_reference returns a zero constant.
* testsuite/g++.dg/ipa/pr52939.C: New test.
From-SVN: r186489
2012-04-15 Fabien Chêne <fabien@gcc.gnu.org>
PR c++/52465
* g++.dg/lookup/using52.C: New.
gcc/cp/ChangeLog
2012-04-15 Fabien Chêne <fabien@gcc.gnu.org>
PR c++/52465
* parser.c (cp_parser_class_name): Call strip_using_decl and
return the target decl.
* name-lookup.c (strip_using_decl): Returns NULL_TREE if the decl
to be stripped is NULL_TREE.
(qualify_lookup): Call strip_using_decl and perform some checks on
the target decl.
From-SVN: r186473
2012-04-14 Paolo Carlini <paolo.carlini@oracle.com>
PR libstdc++/52699
* include/bits/random.tcc (independent_bits_engine<>::operator()())
Avoid various overflows; use common_type on result_type and
_RandomNumberEngine::result_type; avoid floating point computations;
other smaller tweaks.
* include/bits/random.tcc (uniform_int_distribution<>::operator())
Use common_type; assume _UniformRandomNumberGenerator::result_type
unsigned; tidy.
* include/bits/stl_algobase.h (__lg(unsigned), __lg(unsigned long),
__lg(unsigned long long)): Add.
From-SVN: r186461
2012-04-13 Tom de Vries <tom@codesourcery.com>
Backport from mainline r186419.
2012-04-13 Tom de Vries <tom@codesourcery.com>
* gcc.dg/pr52734.c: New test.
From-SVN: r186425
2012-04-13 Tom de Vries <tom@codesourcery.com>
Backport from mainline r186418.
2012-04-13 Tom de Vries <tom@codesourcery.com>
* tree-ssa-tail-merge.c (gsi_advance_bw_nondebug_nonlocal): Add
parameters vuse and vuse_escaped.
(find_duplicate): Init vuse1, vuse2 and vuse_escaped. Pass to
gsi_advance_bw_nondebug_nonlocal. Return if vuse_escaped and
vuse1 != vuse2.
From-SVN: r186424
2012-04-13 Richard Guenther <rguenther@suse.de>
PR tree-optimization/52969
* tree-if-conv.c (predicate_mem_writes): Properly gimplify
the condition for the COND_EXPR and handle predicate negation
by swapping the COND_EXPR arms.
* gcc.dg/torture/pr52969.c: New testcase.
From-SVN: r186417
Fix PR52822 (stable_partition move-assigns object to itself) by
scanning for the first value that doesn't match the predicate before
starting to rearrange values.
2012-04-03 Jeffrey Yasskin <jyasskin@google.com>
PR libstdc++/52822
* include/bits/stl_algo.h (__find_if_not): Expose in
C++98 mode.
(__find_if_not_n): Like __find_if_not, but works on and updates a
counted range instead of a bounded range.
(stable_partition): Guarantee !__pred(*__first) in call to
__stable_partition_adaptive() or __inplace_stable_partition().
(__stable_partition_adaptive): Use new precondition to avoid
moving/copying objects onto themselves. Guarantee new
precondition to recursive calls.
(__inplace_stable_partition): Use new precondition to simplify
base case, remove __last parameter. Guarantee new precondition to
recursive calls.
* testsuite/25_algorithms/stable_partition/moveable.cc (test02):
Test a sequence that starts with a value matching the predicate.
* testsuite/25_algorithms/stable_partition/pr52822.cc:
Test vectors, which have a destructive self-move-assignment.
From-SVN: r186394
[gcc]
2012-04-12 Michael Meissner <meissner@linux.vnet.ibm.com>
Backport from mainline
2012-04-12 Michael Meissner <meissner@linux.vnet.ibm.com>
PR target/52775
* config/rs6000/rs6000.h (TARGET_FCFID): Add TARGET_PPC_GPOPT to
the list of options to enable the FCFID instruction.
(TARGET_EXTRA_BUILTINS): Adjust comment.
[gcc/testsuite]
012-04-12 Michael Meissner <meissner@linux.vnet.ibm.com>
Backport from mainline
2012-04-12 Michael Meissner <meissner@linux.vnet.ibm.com>
PR target/52775
* gcc.target/powerpc/pr52775.c: New file.
From-SVN: r186392
2012-04-12 Richard Guenther <rguenther@suse.de>
PR tree-optimization/52943
* tree-chrec.h (chrec_is_positive): Remove.
* tree-scalar-evolution.c (chrec_is_positive): Move ...
* tree-data-ref.c (chrec_is_positive): ... here. Make static.
Return false for a constant zero instead of negative.
(analyze_siv_subscript_cst_affine): Handle zero difference
in the initial condition explicitely.
* gcc.dg/torture/pr52943.c: New testcase.
From-SVN: r186377
PR middle-end/52894
* varasm.c (process_pending_assemble_externals): Set
pending_assemble_externals_processed true.
(assemble_external): Call assemble_external_real if the pending
assemble externals have been processed.
From-SVN: r186296
PR target/52717
* config/sparc/sparc.c (sparc_file_end): Set TREE_PUBLIC explicitly on
the DECL generated for the special GOT helper.
From-SVN: r186238
2012-04-07 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/52893
Backport from trunk
* frontend-passes.c: Keep track of wether we are in an implicit
DO loop; do not do function elimination if we are.
2012-04-07 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/52893
Backport from trunk
* gfortran.dg/function_optimize_11.f90: New test.
From-SVN: r186215
2012-04-07 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/52668
Backport from trunk
* module.c: Only mark symbols as use_only if they have been
imported via an only list.
2012-04-07 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/52668
Backport from trunk
* gfortran.dg/use_only_6.f90: New test.
From-SVN: r186214
2012-04-06 Walter Lee <walt@tilera.com>
Backport from mainline
2012-03-07 Walter Lee <walt@tilera.com>
* config/tilepro/atomic.c: Rename "atomic_" prefix to
"arch_atomic_".
(atomic_xor): Rename and move definition to
config/tilepro/atomic.h.
(atomic_nand): Ditto.
* config/tilepro/atomic.h: Rename "atomic_" prefix to
"arch_atomic_".
(arch_atomic_xor): Move from config/tilepro/atomic.c.
(arch_atomic_nand): Ditto.
From-SVN: r186196
2012-04-06 Walter Lee <walt@tilera.com>
Backport from mainline
2012-03-07 Walter Lee <walt@tilera.com>
* config/tilegx/tilegx.c (tilegx_expand_prologue): Don't generate
REG_CFA_* notes for the stack pointer.
(tilegx_expand_epilogue): Restore stack pointer by adjusting it by
EH_RETURN_STACKADJ_RTX.
* config/tilepro/tilepro.c (tilepro_expand_prologue): Don't
generate REG_CFA_* notes for the stack pointer.
(tilepro_expand_epilogue): Restore stack pointer by adjusting it
by EH_RETURN_STACKADJ_RTX.
From-SVN: r186195
2012-04-04 H.J. Lu <hongjiu.lu@intel.com>
Backported from mainline
2012-04-04 H.J. Lu <hongjiu.lu@intel.com>
PR libitm/52854
* config/x86/target.h (gtm_jmpbuf): Replace long with long long
for x86-64.
From-SVN: r186141
2012-04-03 Richard Guenther <rguenther@suse.de>
Backport from mainline
2012-03-02 Richard Guenther <rguenther@suse.de>
PR tree-optimization/52406
* tree-data-ref.h: Update documentation about DR_BASE_OBJECT.
(struct indices): Add unconstrained_base member.
(struct dr_alias): Remove unused vops member.
(DR_UNCONSTRAINED_BASE): New define.
* tree-data-ref.c (dr_analyze_indices): For COMPONENT_REFs
add indices to allow their disambiguation. Make DR_BASE_OBJECT
be an artificial access that covers the whole indexed object,
or mark it with DR_UNCONSTRAINED_BASE if we cannot do so. Canonicalize
plain decl base-objects to their MEM_REF variant.
(dr_may_alias_p): When the base-object of either data reference
has unknown size use only points-to information.
(compute_affine_dependence): Make dumps easier to read and
more verbose.
* tree-vect-data-ref.c (vector_alignment_reachable_p): Use
DR_REF when looking for packed references.
(vect_supportable_dr_alignment): Likewise.
* gcc.dg/torture/pr52406.c: New testcase.
From-SVN: r186108
2012-04-03 Richard Guenther <rguenther@suse.de>
Backport from mainline
2012-03-15 Richard Guenther <rguenther@suse.de>
PR middle-end/52580
* tree-data-ref.c (subscript_dependence_tester_1): Check
all dimensions for non-conflicting access functions.
* gfortran.dg/vect/pr52580.f: New testcase.
From-SVN: r186107
2012-04-03 Richard Guenther <rguenther@suse.de>
Backport from mainline
2012-03-06 Richard Guenther <rguenther@suse.de>
PR middle-end/52493
* tree-ssa-alias.c (ptr_derefs_may_alias_p): Robustify.
* gcc.dg/torture/pr52493.c: New testcase.
2012-03-23 Richard Guenther <rguenther@suse.de>
PR tree-optimization/52678
* tree-vectorizer.h (struct _stmt_vec_info): Add
loop_phi_evolution_part member.
(STMT_VINFO_LOOP_PHI_EVOLUTION_PART): New define.
* tree-vect-loop.c (vect_analyze_scalar_cycles_1): Initialize
STMT_VINFO_LOOP_PHI_EVOLUTION_PART.
* tree-vect-loop-manip.c (vect_update_ivs_after_vectorizer):
Use the cached evolution part and the PHI nodes value from
the loop preheader edge instead of re-analyzing the evolution.
* gfortran.dg/pr52678.f: New testcase.
2012-03-26 Richard Guenther <rguenther@suse.de>
PR tree-optimization/52701
* tree-vect-loop.c (vect_analyze_scalar_cycles_1): Always
compute and set the evolution part of PHI nodes.
* gfortran.dg/pr52701.f90: New testcase.
2012-03-30 Richard Guenther <rguenther@suse.de>
PR tree-optimization/52754
* tree-ssa-forwprop.c (forward_propagate_addr_expr_1): Only
propagate arbitrary addresses into really plain dereferences.
* gcc.target/i386/pr52754.c: New testcase.
From-SVN: r186105
2012-03-25 Eric Botcazou <ebotcazou@adacore.com>
* gcc-interface/decl.c (SS_MARK_NAME): New define.
(gnat_to_gnu_entity) <E_Function>: Prepend leaf attribute on entities
whose name is SS_MARK_NAME.
From-SVN: r186039
2012-03-31 Martin Jambor <mjambor@suse.cz>
* tree-ssa-ccp.c (insert_clobbers_for_var): Do not assert that there
is a builtin_stack_save in a dominating BB.
From-SVN: r186037
/cp
2012-03-29 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/52718
* decl.c (check_default_argument): With -Wzero-as-null-pointer-constant
warn for a zero as null pointer constant default argument.
/testsuite
2012-03-29 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/52718
* g++.dg/warn/Wzero-as-null-pointer-constant-5.C: New.
From-SVN: r185984
PR c++/52746
* typeck.c (lookup_destructor): Clear BASELINK_QUALIFIED_P if
we didn't get an explicit scope.
* pt.c (tsubst_baselink): Likewise.
From-SVN: r185961
This patch fixes an ICE caused by syntax errors in arguments
to unary built-in functions like len().
Updates issue 7.
From Rémy Oudompheng.
From-SVN: r185936
2012-03-28 Martin Jambor <mjambor@suse.cz>
PR middle-end/52693
* tree-sra.c (sra_modify_assign): Do not call
load_assign_lhs_subreplacements when working with an unscalarizable
region.
* testsuite/gcc.dg/torture/pr52693.c: New test.
From-SVN: r185920
PR middle-end/52691
* tree-ssa-ccp.c (optimize_stdarg_builtin): Optimize
__builtin_va_start to __builtin_next_arg if the latter is
builtin_decl_explicit_p rather than when it is not.
* gcc.dg/pr52691.c: New test.
From-SVN: r185918
PR middle-end/52750
* tree-vect-generic.c (vector_element): Perform multiplication
for pos in bitsizetype type instead of idx type.
* gcc.c-torture/compile/pr52750.c: New test.
From-SVN: r185916
Backport from 2012-03-28 mainline r185907.
PR target/52737
* contrib/gcc_update (files_and_dependencies):
Remove gcc/config/avr/t-multilib from touch data.
gcc/
Backport from 2012-03-28 mainline r185907.
PR target/52737
* config.gcc (tm_file): Remove avr/multilib.h.
* doc/invoke.texi (AVR Options): Adjust
documentation of -mtiny-stack.
* config/avr/genmultilib.awk: Remove code to generate multilib.h.
(BEGIN): Use -msp8 as multilib option instead of -mtiny-stack.
* config/avr/t-avr: Remove generation of multilib.h.
* config/avr/t-multilib: Regenerate.
* config/avr/multilib.h: Remove.
* config/avr/avr.opt (-msp8): New option.
(avr_sp8): New variable.
* config/avr/driver-avr.c (avr_device_to_sp8): New function.
* config/avr/avr.h (AVR_HAVE_SPH): New define.
(AVR_HAVE_8BIT_SP): Also set by avr_sp8 i.e. -msp8.
(avr_device_to_sp8): New prototype.
(EXTRA_SPEC_FUNCTIONS): Add { "device_to_sp8", avr_device_to_sp8 }
(DRIVER_SELF_SPECS): New define.
* config/avr/avr-c.c (avr_cpu_cpp_builtins): New built-in defines:
__AVR_SP8__, __AVR_HAVE_SPH__.
* config/avr/avr.c (output_movhi): Use AVR_HAVE_SPH instead of
AVR_HAVE_8BIT_SP to decide if SP_H is present.
(avr_file_start): Ditto.
libgcc/
Backport from 2012-03-28 mainline r185907.
PR target/52737
* config/avr/lib1funcs.S: Use __AVR_HAVE_SPH__ for SP_H checks
instead of __AVR_HAVE_8BIT_SP__.
From-SVN: r185908
PR target/52736
* config/i386/sse.md (sse2_loadlpd splitter): Use offset 0
instead of 8 in adjust_address.
* gcc.target/i386/pr52736.c: New test.
From-SVN: r185905
* gcc-interface/decl.c (SS_MARK_NAME): New define.
(gnat_to_gnu_entity) <E_Function>: Prepend leaf attribute on entities
whose name is SS_MARK_NAME.
From-SVN: r185781
gcc/
PR middle-end/52640
* varasm.c: Include pointer-set.h.
(pending_assemble_externals_set): New pointer set.
(process_pending_assemble_externals): Destroy the pointer set.
(assemble_external): See if decl is in pending_assemble_externals_set,
and add it to pending_assemble_externals if necessary.
(init_varasm_once): Allocate pending_assemble_externals_set.
testsuite/
PR middle-end/52640
* gcc.c-torture/compile/limits-externdecl.c: New test.
From-SVN: r185759
2012-03-23 Paweł Sikora <pawel.sikora@agmk.net>
PR libstdc++/52540
* include/Makefile.am (c++config.h): Fix sed rule to not break
the _GLIBCXX_EXTERN_TEMPLATE redefinition.
* include/Makefile.in: Regenerate.
From-SVN: r185733
Backported from mainline
2012-03-02 Kaz Kojima <kkojima@gcc.gnu.org>
PR target/48596
PR target/48806
* config/sh/sh.c (sh_register_move_cost): Increase cost between
GENERAL_REGS and FP_REGS for SImode.
From-SVN: r185714
2012-03-22 Tobias Burnus <burnus@net-b.de>
PR fortran/52452
* resolve.c (resolve_intrinsic): Don't search for a
function if we know that it is a subroutine.
2012-03-22 Tobias Burnus <burnus@net-b.de>
PR fortran/52452
* gfortran.dg/intrinsic_8.f90: New.
From-SVN: r185713
PR c++/52671
* decl.c (check_tag_decl): Only use CLASSTYPE_TEMPLATE_INSTANTIATION
on CLASS_TYPE_P types.
* g++.dg/ext/attrib44.C: New test.
From-SVN: r185711
PR c++/52671
* decl.c (check_tag_decl): Only use CLASSTYPE_TEMPLATE_INSTANTIATION
on CLASS_TYPE_P types.
* g++.dg/ext/attrib44.C: New test.
From-SVN: r185710
PR middle-end/52547
* tree-nested.c (convert_tramp_reference_stmt): Call declare_vars
on any new_local_var_chain vars declared during recursing on
GIMPLE_OMP_PARALLEL or GIMPLE_OMP_TASK body.
* testsuite/libgomp.c/pr52547.c: New test.
From-SVN: r185708
2012-03-22 David Edelsohn <dje.gcc@gmail.com>
Backport from mainline:
2012-03-09 David Edelsohn <dje.gcc@gmail.com>
* src/powerpc/aix_closure.S (ffi_closure_ASM): Adjust for Darwin64
change to return value of ffi_closure_helper_DARWIN and load type
from return type.
From Tom Honermann <tom.honermann@oracle.com>:
* src/powerpc/aix.S: Declare .ffi_prep_args. Insert nops after
branch instructions.
* src/powerpc/aix_closure.S: Declare .ffi_closure_helper_DARWIN.
From-SVN: r185706
Backport from 2012-03-20 mainline r185583.
* gcc.target/avr/progmem.h (pgm_read_char): Define depending on
__AVR_HAVE_LPMX__
Backport from 2012-03-20 mainline r185570.
PR target/49868
* gcc.target/avr/torture/addr-space-2.h: New file.
* gcc.target/avr/torture/addr-space-2-g.h: New test.
* gcc.target/avr/torture/addr-space-2-0.h: New test.
* gcc.target/avr/torture/addr-space-2-1.h: New test.
* gcc.target/avr/torture/addr-space-2-x.h: New test.
Backport from 2012-03-12 mainline r185255.
PR target/49868
* gcc.target/avr/torture/addr-space-1.h: New file.
* gcc.target/avr/torture/addr-space-g.h: New test.
* gcc.target/avr/torture/addr-space-0.h: New test.
* gcc.target/avr/torture/addr-space-1.h: New test.
* gcc.target/avr/torture/addr-space-x.h: New test.
From-SVN: r185696
2012-03-22 Paolo Carlini <paolo.carlini@oracle.com>
* include/std/array (array<>::at(size_type) const): Fix version
for undefined __EXCEPTIONS.
From-SVN: r185690
Backported from mainline
2012-03-14 Jakub Jelinek <jakub@redhat.com>
PR c++/52521
* parser.c (lookup_literal_operator): Return fn only if
processed all arguments from args vector and argtypes is
void_list_node.
* g++.dg/cpp0x/udlit-args2.C: New test.
From-SVN: r185683
Backported from trunk
2012-03-13 Jakub Jelinek <jakub@redhat.com>
* config/i386/smmintrin.h: Avoid /* within a comment.
* config/i386/nmmintrin.h: Likewise.
From-SVN: r185681
2012-03-12 Michael Meissner <meissner@linux.vnet.ibm.com>
Backport from mainline
2012-03-09 Michael Meissner <meissner@linux.vnet.ibm.com>
* config/rs6000/linux64.h (OPTION_TARGET_CPU_DEFAULT): Do not
redefine to be NULL if the current bit-size is different from the
configured bit-size.
* config/rs6000/rs6000.c (rs6000_option_override_internal): If the
cpu is defaulted, use PROCESSOR_DEFAULT and PROCESSOR_DEFAULT64 to
set the default tuning. Add asserts to make sure the cpu and tune
indexes are defined. Fix tests for cpu/tune index to use >= 0 to
test whether the index is set, instead of > 0.
(rs6000_file_start): Do not reset the default cpu if the current
bit-size is different from the configured bit-size.
From-SVN: r185248
* go-gcc.cc (Gcc_backend::assignment_statement): Convert the rhs
to the lhs type if necessary.
* go-gcc.cc (Gcc_backend::init_statement): Don't initialize a
zero-sized variable.
(go_non_zero_struct): New global variable.
(Gcc_backend::non_zero_size_type): New function.
(Gcc_backend::global_variable): Don't build an assignment for a
zero-sized value.
* go-c.h (go_non_zero_struct): Declare.
* config-lang.in (gtfiles): Add go-c.h.
From-SVN: r185180
* trans-mem.c: New typedef for tm_region_p.
Define vector types for tm_region_p.
(tm_region_init): Replace region_worklist to a vector called
bb_regions.
From-SVN: r185001