Backported from mainline r217076.
2014-11-04 Michael Collison <michael.collison@linaro.org>
* config/aarch64/iterators.md (lconst_atomic): New mode attribute
to support constraints for CONST_INT in atomic operations.
* config/aarch64/atomics.md
(atomic_<atomic_optab><mode>): Use lconst_atomic constraint.
(atomic_nand<mode>): Likewise.
(atomic_fetch_<atomic_optab><mode>): Likewise.
(atomic_fetch_nand<mode>): Likewise.
(atomic_<atomic_optab>_fetch<mode>): Likewise.
(atomic_nand_fetch<mode>): Likewise.
Michael Matz [Fri, 12 Jun 2015 14:06:41 +0000 (14:06 +0000)]
backport: re PR debug/63623 (Lots of functions get -fvar-tracking silently turned off unnecessarily)
Backported from mainline
2014-10-23 Jakub Jelinek <jakub@redhat.com>
PR debug/63623
* var-tracking.c (stack_adjust_offset_pre_post_cb): New function.
(stack_adjust_offset_pre_post): Use it through for_each_inc_dec,
instead of only handling autoinc in dest if it is a MEM.
(vt_stack_adjustments): Fix up formatting.
Richard Biener [Thu, 11 Jun 2015 13:39:56 +0000 (13:39 +0000)]
backport: [multiple changes]
2015-06-11 Richard Biener <rguenther@suse.de>
Backport from mainline, guarded with in_lto_p
2015-06-02 Richard Biener <rguenther@suse.de>
PR debug/65549
* dwarf2out.c (lookup_context_die): New function.
(resolve_addr): Avoid forcing a full DIE for the
target of a DW_TAG_GNU_call_site during late compilation.
Instead create a stub DIE without a type if we have a
context DIE present.
Backport from mainline
2014-04-04 Jan Hubicka <hubicka@ucw.cz>
PR ipa/59626
* lto-cgraph.c (input_overwrite_node): Check that partitioning
flags are set only during streaming.
* ipa.c (process_references, symtab_remove_unreachable_nodes):
Drop bodies of always inline after early inlining.
(symtab_remove_unreachable_nodes): Remove always_inline attribute.
* gcc.dg/lto/pr59626_0.c: New testcase.
* gcc.dg/lto/pr59626_1.c: New testcase.
Michael Meissner [Wed, 10 Jun 2015 17:34:12 +0000 (17:34 +0000)]
backport: re PR target/66474 (Document the use of %x in powerpc asm statements)
2015-06-10 Michael Meissner <meissner@linux.vnet.ibm.com>
Backport from mainline:
2015-06-10 Michael Meissner <meissner@linux.vnet.ibm.com>
PR target/66474
* doc/md.texi (Machine Constraints): Document that on the PowerPC
if you use a constraint that targets a VSX register, you must use
%x<n> in the template.
Richard Biener [Wed, 10 Jun 2015 12:53:09 +0000 (12:53 +0000)]
backport: [multiple changes]
2015-06-10 Richard Biener <rguenther@suse.de>
Backport from mainline
2014-04-04 Cong Hou <congh@google.com>
PR tree-optimization/60656
* tree-vect-stmts.c (supportable_widening_operation):
Fix a bug that elements in a vector with vect_used_by_reduction
property are incorrectly reordered when the operation on it is not
consistant with the one in reduction operation.
* gcc.dg/vect/pr60656.c: New test.
2014-01-31 Richard Biener <rguenther@suse.de>
PR middle-end/59990
* builtins.c (fold_builtin_memory_op): Make sure to not
use a floating-point mode or a boolean or enumeral type for
the copy operation.
* gcc.dg/torture/pr59990.c: New testcase.
* gcc.target/i386/pr49168-1.c: Adjust.
Jakub Jelinek [Wed, 10 Jun 2015 09:34:21 +0000 (11:34 +0200)]
re PR target/66470 (TLS ICE due to ix86_split_long_move)
PR target/66470
* config/i386/i386.c (ix86_split_long_move): For collisions
involving direct tls segment refs, move the UNSPEC_TP possibly
wrapped in ZERO_EXTEND out of the address for lea, to each of
the memory loads.
* gcc.dg/tls/pr66470.c: New test.
* gcc.target/i386/pr66470.c: New test.
Uros Bizjak [Mon, 8 Jun 2015 20:59:07 +0000 (22:59 +0200)]
backport: re PR target/66275 (__attribute__((sysv_abi)) with x86_64-w64-mingw32-gcc generates incorrect code)
Backport from mainline:
2015-06-03 Uros Bizjak <ubizjak@gmail.com>
PR target/66275
* config/i386/i386.c (ix86_function_arg_regno): Use ix86_cfun_abi
to determine current function ABI.
(ix86_function_value_regno_p): Ditto.
testsuite/ChangeLog:
Backport from mainline:
2015-06-03 Uros Bizjak <ubizjak@gmail.com>
PR target/66275
* gcc.target/i386/pr66275.c: New test.
Jakub Jelinek [Wed, 3 Jun 2015 21:36:26 +0000 (23:36 +0200)]
backport: re PR middle-end/66133 (Wrong-code with noreturn #pragma omp task body)
Backported from mainline
2015-05-13 Jakub Jelinek <jakub@redhat.com>
PR middle-end/66133
* omp-low.c (expand_omp_taskreg): For GIMPLE_OMP_TASK expansion,
make sure it is never noreturn, even when the task body does not
return.
(lower_omp_taskreg): For GIMPLE_OMP_TASK, emit GIMPLE_OMP_CONTINUE
right before GIMPLE_OMP_RETURN.
* tree-cfg.c (make_edges): Accept GIMPLE_OMP_CONTINUE as ->cont
for GIMPLE_OMP_TASK. For GIMPLE_OMP_RETURN corresponding to
GIMPLE_OMP_TASK add an EDGE_ABNORMAL edge from entry to exit.
Jakub Jelinek [Wed, 3 Jun 2015 21:33:22 +0000 (23:33 +0200)]
backport: re PR gcov-profile/64634 (gcov reports catch(...) as not executed)
Backported from mainline
2015-02-18 Jakub Jelinek <jakub@redhat.com>
PR gcov-profile/64634
* tree-eh.c (frob_into_branch_around): Fix up typos
in function comment.
(lower_catch): Put eh_seq resulting from EH lowering of
the cleanup sequence after the cleanup rather than before
it.
PR tree-optimization/66123
* tree-ssa-dom.c (propagate_rhs_into_lhs): Check if we found
a taken edge.
* gcc.dg/torture/pr66123.c: New testcase.
2015-05-27 Richard Biener <rguenther@suse.de>
PR tree-optimization/66272
Revert parts of
2014-08-15 Richard Biener <rguenther@suse.de>
PR tree-optimization/62031
* tree-data-ref.c (dr_analyze_indices): Do not set
DR_UNCONSTRAINED_BASE.
(dr_may_alias_p): All indirect accesses have to go the
formerly DR_UNCONSTRAINED_BASE path.
* tree-data-ref.h (struct indices): Remove
unconstrained_base member.
(DR_UNCONSTRAINED_BASE): Remove.
backport: varasm.c (output_constant_pool_1): Pass down alignment from constant pool entry's descriptor to output_constant_pool_2.
Backported from mainline
2015-05-14 Rohit Arul Raj <rohitarulraj@freescale.com>
* varasm.c (output_constant_pool_1): Pass down alignment from
constant pool entry's descriptor to output_constant_pool_2.
(output_object_block): Add comment prior to call to
output_constant_pool_1.