re PR rtl-optimization/48542 (unchanged variables in code which calls setjmp may be clobbered (including the return-address))
PR rtl-optimization/48542
* reload.c (find_equiv_reg): Stop looking when finding a
setjmp-type call.
* reload1.c (reload_as_needed): Invalidate all reload
registers when crossing a setjmp-type call.
Kaz Kojima [Thu, 16 Jun 2011 22:08:20 +0000 (22:08 +0000)]
re PR target/49307 (ICE in spill_failure, at reload1.c:2113)
PR target/49307
* config/sh/sh.md (UNSPEC_CHKADD): New.
(chk_guard_add): New define_insn_and_split.
(symGOT_load): Use chk_guard_add instead of blockage.
Kaz Kojima [Wed, 8 Jun 2011 04:10:26 +0000 (04:10 +0000)]
re PR target/49238 ([SH] ICE in extract_insn, at recog.c:2113)
PR target/49238
* config/sh/sh.c (expand_cbranchdi4): Use a scratch register if
needed when original operands are used for msw_skip comparison.
* gcc.c-torture/compile/pr49238.c: New.
Kaz Kojima [Sun, 5 Jun 2011 21:50:29 +0000 (21:50 +0000)]
re PR target/49186 (optimize problem with unsigned long long value.)
PR target/49186
* config/sh/sh.c (expand_cbranchdi4): Set msw_skip when the high
part of the second operand is 0.
* gcc.c-torture/execute/pr49186.c: New.
Ira Rosen [Sat, 4 Jun 2011 09:12:55 +0000 (09:12 +0000)]
re PR tree-optimization/49038 (-ftree-vectorise introduces reads past end of array)
PR tree-optimization/49038
* tree-vect-loop-manip.c (vect_generate_tmps_on_preheader):
Ensure at least one epilogue iteration if required by data
accesses with gaps.
* tree-vectorizer.h (struct _loop_vec_info): Add new field
to mark loops that require peeling for gaps.
* tree-vect-loop.c (new_loop_vec_info): Initialize new field.
(vect_estimate_min_profitable_iters): Take peeling for gaps into
account.
(vect_transform_loop): Generate epilogue if required by data
access with gaps.
* tree-vect-data-refs.c (vect_analyze_group_access): Mark the
loop as requiring an epilogue if there are gaps in the end of
the strided group.
Thomas Koenig [Thu, 2 Jun 2011 09:09:53 +0000 (09:09 +0000)]
backport: re PR fortran/45786 (Relational operators .eq. and == are not recognized as equivalent)
2011-06-02 Thomas Koenig <tkoenig@gcc.gnu.org>
Backport from trunk
PR fortran/45786
* interface.c (gfc_equivalent_op): New function.
(gfc_check_interface): Use gfc_equivalent_op instead
of switch statement.
* decl.c (access_attr_decl): Also set access to an
equivalent operator.
2011-06-02 Thomas Koenig <tkoenig@gcc.gnu.org>
Backport from trunk
PR fortran/45786
* gfortran.dg/operator_7.f90: New test case.
re PR target/43995 (internal compiler error: Segmentation fault on Mips64 crossbuild of ext2progs)
gcc/
PR target/43995
* config/mips/mips.c (mips_pic_call_symbol_from_set): Add a
recurse_p argument. Only follow register copies if it is set,
and prevent mips_find_pic_call_symbol from recursing.
(mips_find_pic_call_symbol): Add a recurse_p argument.
Pass it to mips_pic_call_symbol_from_set.
(mips_annotate_pic_calls): Update accordingly.
Eric Botcazou [Thu, 26 May 2011 12:43:06 +0000 (12:43 +0000)]
backport: re PR rtl-optimization/41619 (ICE in insert_save (caller-save.c) for SPEC CPU2000's 252.eon)
Backport from mainline
2011-01-21 Jeff Law <law@redhat.com>
PR rtl-optimization/41619
* caller-save.c (setup_save_areas): Break out code to determine
which hard regs are live across calls by examining the reload chains
so that it is always used.
Eliminate code which checked REG_N_CALLS_CROSSED.
Eric Botcazou [Sat, 21 May 2011 22:04:35 +0000 (22:04 +0000)]
sparc.c (eligible_for_return_delay): Do not return false if there are call-saved registers here...
* config/sparc/sparc.c (eligible_for_return_delay): Do not return
false if there are call-saved registers here...
(sparc_can_use_return_insn_p): ...but here instead.
(save_or_restore_regs): Fix thinko.
(sparc_expand_prologue): Use current_function_is_leaf.
(sparc_frame_pointer_required): Likewise.
Ira Rosen [Thu, 5 May 2011 07:34:59 +0000 (07:34 +0000)]
backport: re PR target/48252 (ARM neon: problem with consecutive vzip, vuzp and vtrn)
Backport from mainline:
2011-04-18 Ulrich Weigand <ulrich.weigand@linaro.org>
Ira Rosen <ira.rosen@linaro.org>
PR target/48252
* config/arm/arm.c (neon_emit_pair_result_insn): Swap arguments
to match neon_vzip/vuzp/vtrn_internal.
* config/arm/neon.md (neon_vtrn<mode>_internal): Make both
outputs explicitly dependent on both inputs.
(neon_vzip<mode>_internal, neon_vuzp<mode>_internal): Likewise.
Uros Bizjak [Wed, 4 May 2011 18:22:23 +0000 (20:22 +0200)]
i386.md (*movdi_internal_rex64): Use %v prefix in insn mnemonic to handle TARGET_AVX.
* config/i386/i386.md (*movdi_internal_rex64) <TYPE_SSEMOV>:
Use %v prefix in insn mnemonic to handle TARGET_AVX.
(*movdi_internal): Use "maybe_vex" instead of "vex" in "prefix"
attribute calculation.
(*movdf_internal): Output AVX mnemonics. Add "prefix" attribute.
* config/i386/sse.md (*sse2_storeq_rex64): Do not emit %v prefix
for mov{q} mnemonic.
(*vec_extractv2di_1_rex64_avx): Ditto.
(*vec_concatv2di_rex64_sse4_1): Use %vmovd for reg<->xmm moves.
(*vec_concatv2di_rex64_sse): Use movd for reg<->xmm moves.
* config/i386/mmx.md (*mov<mode>_internal_rex64): Ditto.
testsuite/ChangeLog:
Backport from mainline
2010-12-08 H.J. Lu <hongjiu.lu@intel.com>
* gcc.target/i386/sse2-init-v2di-2.c: Add "-dp" and update
expected scan.
* df-problems.c (df_simulate_initialize_forwards): Set, don't clear,
bits for artificial defs at the top of the block.
* fwprop.c (single_def_use_enter_block): Don't call it.
* ifcvt.c (dead_or_predicable): Use df_simulate_find_defs and
df_simulate_find_noclobber_defs as appropriate. Keep track of an
extra set merge_set_noclobber, and use it to relax the final test
slightly.
* df.h (df_simulate_find_noclobber_defs): Declare.
* df-problems.c (df_simulate_find_defs): Don't ignore partial or
conditional defs.
(df_simulate_find_noclobber_defs): New function.
Rainer Orth [Mon, 2 May 2011 12:41:34 +0000 (12:41 +0000)]
backport: osf.S (UA_SI, [...]): Define.
Backport from mainline:
2011-04-29 Rainer Orth <ro@CeBiTec.Uni-Bielefeld.DE>
* src/alpha/osf.S (UA_SI, FDE_ENCODING, FDE_ENCODE, FDE_ARANGE):
Define.
Use them to handle ELF vs. ECOFF differences.
[__osf__] (_GLOBAL__F_ffi_call_osf): Define.