* testsuite/experimental/filesystem/iterators/
recursive_directory_iterator.cc: Ensure that error_code arguments are
cleared when required.
* testsuite/experimental/filesystem/operations/create_directory.cc:
Remove redundant check.
* testsuite/experimental/filesystem/operations/temp_directory_path.cc:
Ensure that error_code argument is cleared when required.
From-SVN: r253897
* include/experimental/bits/fs_path.h (path::iterator++(int))
(path::iterator--(int)): Fix for paths with only one component.
* testsuite/experimental/filesystem/path/itr/traversal.cc: Test
post-increment and post-decrement.
From-SVN: r253896
PR debug/82509
* dwarf2out.c (new_die_raw): New static inline function.
(new_die): Use it to create the DIE.
(add_AT_external_die_ref): Likewise.
(clone_die): Likewise.
(clone_as_declaration): Likewise.
(dwarf2out_vms_debug_main_pointer): Likewise.
(base_type_die): Likewise. Remove early return for corner cases.
Do not call add_pubtype on the DIE here.
(is_base_type): Remove ERROR_MARK and return 0 for VOID_TYPE.
(modified_type_die): Adjust the lookup for reverse order DIEs. Skip
typedefs for base types with DW_AT_endianity. Make sure a DIE with
native order exists for base types, attach the DIE manually and call
add_pubtype on it. Do not equate a reverse order DIE to the type.
From-SVN: r253893
Peephole patterns exist in the arm backend to spot load/store
operations to adjacent memory operations in order to convert them into
ldrd/strd instructions. However, when we have strict alignment
enforced, then we can only do this if the accesses are known to be
64-bit aligned; this is unlikely to be the case for most loads. The
patch adds some alignment checking to the code that validates the
addresses for use in the peephole patterns. This should also fix
incorrect generation of ldrd/strd with unaligned accesses that could
previously have occurred on ARMv5e where all such operations must be
64-bit aligned.
I've added some new tests as well. In doing so I discovered that the
ldrd/strd peephole tests could never fail since they would match the
source file name in the scanned assembly as well as any instructions
of the intended type. I've fixed those by tightening the scan results
slightly.
gcc:
* config/arm/arm.c (align_ok_ldrd_strd): New function.
(mem_ok_for_ldrd_strd): New parameter align. Extract the alignment of the
mem into it.
(gen_operands_ldrd_strd): Validate the alignment of the accesses.
testsuite:
* gcc.target/arm/peep-ldrd-1.c: Tighten test scan pattern.
* gcc.target/arm/peep-strd-1.c: Likewise.
* gcc.target/arm/peep-ldrd-2.c: New test.
* gcc.target/arm/peep-strd-2.c: New test.
From-SVN: r253890
Currently gen* warn about a missing mode on an UNSPEC_TOCSLOT unspec in
some call patterns. Those unspecs are created from rs6000.c, with Pmode
always. This patch fixes the patterns to say :P as well.
* config/rs6000/rs6000.md (*call_indirect_aix<mode>,
*call_value_indirect_aix<mode>, *call_indirect_elfv2<mode>,
*call_value_indirect_elfv2<mode>): Add correct mode to the unspec.
From-SVN: r253885
PR target/82580
* config/i386/i386.md (setcc + movzbl to xor + setcc): New peephole2.
(setcc + and to xor + setcc): New peephole2.
* gcc.target/i386/pr82580.c: Use {\msbb} instead of "sbb" in
scan-assembler-times. Check that there are no movzb* instructions
if lp64.
From-SVN: r253884
2017-10-19 Martin Liska <mliska@suse.cz>
PR sanitizer/82517
* gimplify.c (gimplify_decl_expr): Do not instrument variables
that have a large alignment.
(gimplify_target_expr): Likewise.
2017-10-19 Martin Liska <mliska@suse.cz>
PR sanitizer/82517
* gcc.dg/asan/pr82517.c: New test.
From-SVN: r253879
2017-10-18 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/82567
* frontend-passes.c (combine_array_constructor): If an array
constructor is all constants and has more elements than a small
constant, don't convert a*[b,c] to [a*b,a*c] to reduce compilation
times.
2017-10-18 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/82567
* gfortran.dg/array_constructor_51.f90: New test.
From-SVN: r253872
A volatile asm statement can not be moved (relative to other volatile
asm, etc.), but IRA would do it nevertheless. This patch fixes it.
PR rtl-optimization/82602
* ira.c (rtx_moveable_p): Return false for volatile asm.
From-SVN: r253869
2017-10-18 Thomas Koenig <tkoenig@gcc.gnu.org>
PR libfortran/82233
* gfortran.dg/execute_command_line_3.f90: Remove unneeded output.
Move test with wait=.false. before the last test.
From-SVN: r253865
2017-10-18 Vladimir Makarov <vmakarov@redhat.com>
PR middle-end/82556
* lra-constraints.c (curr_insn_transform): Use non-input operand
instead of output one for matched reload.
2017-10-18 Vladimir Makarov <vmakarov@redhat.com>
PR middle-end/82556
* gcc.target/i386/pr82556.c: New.
From-SVN: r253862
* tree-loop-distribution.c (INCLUDE_ALGORITHM): New header file.
(tree-ssa-loop-ivopts.h): New header file.
(struct builtin_info): New fields.
(classify_builtin_1): Compute and record base and offset parts for
memset builtin partition by calling strip_offset.
(offset_cmp, fuse_memset_builtins): New functions.
(finalize_partitions): Fuse adjacent memset partitions by calling
above function.
* tree-ssa-loop-ivopts.c (strip_offset): Delete static declaration.
Expose the interface.
* tree-ssa-loop-ivopts.h (strip_offset): New declaration.
* gcc.dg/tree-ssa/ldist-17.c: Adjust test string.
* gcc.dg/tree-ssa/ldist-32.c: New test.
* gcc.dg/tree-ssa/ldist-35.c: New test.
* gcc.dg/tree-ssa/ldist-36.c: New test.
From-SVN: r253859
PR tree-optimization/82574
* tree-loop-distribution.c (find_single_drs): New parameter. Check
that data reference must be executed exactly once per iteration
against the outermost loop in nest.
(classify_partition): Update call to above function.
gcc/testsuite
* gcc.dg/tree-ssa/pr82574.c: New test.
From-SVN: r253857
2017-10-18 Martin Liska <mliska@suse.cz>
* gcc.dg/tree-prof/switch-case-2.c: Scan IPA profile dump
file instead of expand. Reason is that switch statement is
not yet expanded as decision tree, which also contains a BB
with count == 2000.
From-SVN: r253854
PR lto/82598
* simple-object.c (handle_lto_debug_sections): Copy over also
.note.GNU-stack section with unchanged name.
* simple-object-elf.c (SHF_EXECINSTR): Define.
(simple_object_elf_copy_lto_debug_section): Drop SHF_EXECINSTR bit
on .note.GNU-stack section.
From-SVN: r253851
gcc/ChangeLog:
2017-10-17 Robin Dapp <rdapp@linux.vnet.ibm.com>
* config/s390/s390.c (s390_bb_fallthru_entry_likely): New function.
(s390_sched_init): Do not reset s390_sched_state if we entered the
current basic block via a fallthru edge and all others are unlikely.
From-SVN: r253850
gcc/ChangeLog:
2017-10-18 Robin Dapp <rdapp@linux.vnet.ibm.com>
* config/s390/s390.c (NUM_SIDES): New variable.
(LONGRUNNING_THRESHOLD): New variable.
(LATENCY_FACTOR): New variable.
(s390_sched_score): Decrease score for long-running instructions on
wrong side.
(s390_sched_variable_issue): Perform bookkeeping for long-running
instructions.
From-SVN: r253849
2017-10-18 Paul Thomas <pault@gcc.gnu.org>
PR fortran/82550
* trans_decl.c (gfc_get_symbol_decl): Procedure symbols that
have the 'used_in_submodule' attribute should be processed by
'gfc_get_extern_function_decl'.
2017-10-18 Paul Thomas <pault@gcc.gnu.org>
PR fortran/82550
* gfortran.dg/submodule_30.f08 : New test.
From-SVN: r253848
The functions all call foo and therefore need a stack frame what makes
them subject to shrink wrapping. Also all the additional instructions
in the function body makes it fragile wrt instruction scheduling. Just
set a global variable instead to circumvent this.
gcc/testsuite/ChangeLog:
2017-10-18 Andreas Krebbel <krebbel@linux.vnet.ibm.com>
* gcc.target/s390/zvector/vec-cmp-2.c
(all_eq_double, all_ne_double, all_gt_double)
(all_lt_double, all_ge_double, all_le_double)
(any_eq_double, any_ne_double, any_gt_double)
(any_lt_double, any_ge_double, any_le_double)
(all_eq_int, all_ne_int, all_gt_int)
(all_lt_int, all_ge_int, all_le_int)
(any_eq_int, any_ne_int, any_gt_int)
(any_lt_int, any_ge_int, any_le_int): Set global variable instead
of calling foo(). Fix return type.
From-SVN: r253846
2017-10-18 Martin Liska <mliska@suse.cz>
PR sanitizer/82545
* asan.c (asan_expand_poison_ifn): Do not put gimple stmt
on an abnormal edge.
2017-10-18 Martin Liska <mliska@suse.cz>
PR sanitizer/82545
* gcc.dg/asan/pr82545.c: New test.
From-SVN: r253845
* config/visium/visium.c (visium_select_cc_mode): Return CCmode
for any RTX present on the RHS of a SET.
* compare-elim.c (try_eliminate_compare): Restore comment.
From-SVN: r253830
* langhooks.h (struct lang_hooks): Document that tree_size langhook
may be also called on tcc_type nodes.
* langhooks.c (lhd_tree_size): Likewise.
* gcc-interface/misc.c (gnat_tree_size): New function.
(LANG_HOOKS_TREE_SIZE): Redefine.
From-SVN: r253829