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: r202942
* config/msp430/msp430.c (msp430_expand_epilogue): Fix compile
time warning message.
(msp430_print_operand_raw): Delete unused letter parameter.
(TARGET_PRINT_OPERAND_ADDRESS): Define.
(msp430_print_operand_address): New function.
(msp430_print_operand): Move address printing code from here to
new function.
* config/msp430/msp430.md (movsipsi2): Add comment in generated
assembler.
(zero_extendpsisi2): Likewise.
(extendpsisi2): New pattern.
(andneghi3): New pattern.
From-SVN: r202941
* tree-flow.h (thread_through_all_blocks): Prototype moved into
tree-ssa-threadupdate.h.
(register_jump_thread): Similarly.
* tree-ssa-threadupdate.h: New header file.
* tree-ssa-dom.c: Include tree-ssa-threadupdate.h.
* tree-vrp.c: Likewise.
* tree-ssa-threadedge.c: Include tree-ssa-threadupdate.h.
(thread_around_empty_blocks): Change type of path vector argument to
an edge,type pair from just an edge. Initialize both elements when
appending to a jump threading path. Tweak references to elements
appropriately.
(thread_across_edge): Similarly. Release memory for the elements
as needed.
* tree-ssa-threadupdate.c: Include tree-ssa-threadupdate.h.
(dump_jump_thread_path): New function broken out from
register_jump_thread.
(register_jump_thread): Use dump_jump_thread_path. Change type of
path vector entries. Search the path for NULL edges and dump
the path if one is found. Tweak the conversion of path to 3-edge
form to use the block copy type information embedded in the path.
* gcc.dg/tree-ssa/ssa-dom-thread-3.c: Update expected output.
From-SVN: r202933
2013-09-25 Yvan Roux <yvan.roux@linaro.org>
Vladimir Makarov <vmakarov@redhat.com>
* rtlanal.c (lsb_bitfield_op_p): New predicate for bitfield operations
from the least significant bit.
(strip_address_mutations): Add bitfield operations handling.
(must_be_index_p): Add shifting and rotate operations handling.
(set_address_base): Use must_be_base_p predicate.
(set_address_index):Use must_be_index_p predicate.
Co-Authored-By: Vladimir Makarov <vmakarov@redhat.com>
From-SVN: r202914
* tree-ssa-threadedge.c (thread_across_edge): Use foo.last () rather
than foo[foo.length () - 1] to access last member in a vec.
* tree-ssa-threadupdate.c (register_jump_thread): Similarly.
From-SVN: r202892
PR sanitizer/58413
c-family/
* c-ubsan.c (ubsan_instrument_shift): Don't instrument
an expression if we can prove it is correct.
(ubsan_instrument_division): Likewise. Remove unnecessary
check.
testsuite/
* c-c++-common/ubsan/shift-5.c: New test.
* c-c++-common/ubsan/shift-6.c: New test.
* c-c++-common/ubsan/div-by-zero-5.c: New test.
* gcc.dg/ubsan/c-shift-1.c: New test.
Co-Authored-By: Jakub Jelinek <jakub@redhat.com>
From-SVN: r202886
PR middle-end/57134
PR middle-end/57586
* stmt.c (expand_asm_operands): Call expand_expr with
EXPAND_MEMORY for output operands that disallow regs. Don't
use EXPAND_WRITE on inout operands.
From-SVN: r202866
2013-09-24 Richard Biener <rguenther@suse.de>
PR middle-end/58513
* tree.c (reference_alias_ptr_type): Move ...
* alias.c (reference_alias_ptr_type): ... here and implement
in terms of the new reference_alias_ptr_type_1.
(ref_all_alias_ptr_type_p): New helper.
(get_deref_alias_set_1): Drop flag_strict_aliasing here,
use ref_all_alias_ptr_type_p.
(get_deref_alias_set): Add flag_strict_aliasing check here.
(reference_alias_ptr_type_1): New function, split out from ...
(get_alias_set): ... here.
(alias_ptr_types_compatible_p): New function.
* alias.h (reference_alias_ptr_type): Declare.
(alias_ptr_types_compatible_p): Likewise.
* tree.h (reference_alias_ptr_type): Remove.
* fold-const.c (operand_equal_p): Use alias_ptr_types_compatible_p
to compare MEM_REF alias types.
* g++.dg/vect/pr58513.cc: New testcase.
From-SVN: r202865