2018-05-10 Steven G. Kargl <kargl@gcc.gnu.org>
PR fortran/85687
* check.c (gfc_check_rank): Check that the argument is a data object.
2018-05-10 Steven G. Kargl <kargl@gcc.gnu.org>
PR fortran/85687
* gfortran.dg/pr85687.f90: new test.
From-SVN: r260141
2018-05-10 Michael Meissner <meissner@linux.vnet.ibm.com>
* config/rs6000/rs6000.c (mode_supports_dq_form): Rename
mode_supports_vsx_dform_quad to mode_supports_dq_form.
(mode_supports_vsx_dform_quad): Likewise.
(mode_supports_vmx_dform): Move these functions to be next to the
other mode_supports functions.
(mode_supports_dq_form): Likewise.
(quad_address_p): Change calls of mode_supports_vsx_dform_quad to
mode_supports_dq_form.
(reg_offset_addressing_ok_p): Likewise.
(offsettable_ok_by_alignment): Likewise.
(rs6000_legitimate_offset_address_p): Likewise.
(legitimate_lo_sum_address_p): Likewise.
(rs6000_legitimize_address): Likewise.
(rs6000_legitimize_reload_address): Likewise.
(rs6000_secondary_reload_inner): Likewise.
(rs6000_preferred_reload_class): Likewise.
(rs6000_output_move_128bit): Likewise.
From-SVN: r260140
2018-05-10 Steven G. Kargl <kargl@gcc.gnu.org>
PR fortran/85521
* array.c (gfc_resolve_character_array_constructor): Substrings
with upper bound smaller than lower bound are zero length strings.
2018-05-10 Steven G. Kargl <kargl@gcc.gnu.org>
PR fortran/85521
* gfortran.dg/pr85521_1.f90: New test.
* gfortran.dg/pr85521_2.f90: New test.
From-SVN: r260139
2018-05-10 Steven G. Kargl <kargl@gcc.gnu.org>
PR fortran/70870
* data.c (gfc_assign_data_value): Check that a data object does
not also have default initialization.
2018-05-10 Steven G. Kargl <kargl@gcc.gnu.org>
PR fortran/70870
* gfortran.dg/pr70870_1.f90: New test.
From-SVN: r260138
gcc/ChangeLog:
2018-05-10 Carl Love <cel@us.ibm.com>
* config/rs6000/rs6000.md (prefetch): Generate ISA 2.06 instructions
dcbtt and dcbtstt if operands[2] is 0.
From-SVN: r260134
* doc/xml/faq.xml: Link to C++17 status. Add note to outdated answer.
* doc/xml/manual/debug_mode.xml: Add array and forward_list to list
of C++11 containers with Debug Mode support.
* doc/xml/manual/using.xml: Document Dual ABI for ios_base::failure.
* doc/html/*: Regenerate.
From-SVN: r260129
PR c++/85662
* c-common.h (fold_offsetof_1): Removed.
(fold_offsetof): Add TYPE argument defaulted to size_type_node and
CTX argument defaulted to ERROR_MARK.
* c-common.c (fold_offsetof_1): Renamed to ...
(fold_offsetof): ... this. Remove wrapper function. Add TYPE
argument, convert the pointer constant to TYPE and use size_binop
with PLUS_EXPR instead of fold_build_pointer_plus if type is not
a pointer type. Adjust recursive calls.
* c-fold.c (c_fully_fold_internal): Use fold_offsetof rather than
fold_offsetof_1, pass TREE_TYPE (expr) as TYPE to it and drop the
fold_convert_loc.
* c-typeck.c (build_unary_op): Use fold_offsetof rather than
fold_offsetof_1, pass argtype as TYPE to it and drop the
fold_convert_loc.
* cp-gimplify.c (cp_fold): Use fold_offsetof rather than
fold_offsetof_1, pass TREE_TYPE (x) as TYPE to it and drop the
fold_convert.
* g++.dg/ext/offsetof2.C: New test.
From-SVN: r260119
2018-05-10 Paul Thomas <pault@gcc.gnu.org>
PR fortran/68846
PR fortran/70864
* resolve.c (get_temp_from_expr): The temporary must not have
dummy or intent attributes.
2018-05-10 Paul Thomas <pault@gcc.gnu.org>
PR fortran/68846
* gfortran.dg/temporary_3.f90 : New test.
PR fortran/70864
* gfortran.dg/temporary_2.f90 : New test.
From-SVN: r260113
* configure.ac (gcc_gxx_include_dir_add_sysroot): Set it to 1 only
when --with-gxx-include-dir is also specified.
* configure: Regenerate.
From-SVN: r260108
PR tree-optimization/85699
* gcc.dg/nextafter-1.c (NO_LONG_DOUBLE): Define if not defined. Use
!NO_LONG_DOUBLE instead of __LDBL_MANT_DIG__ != 106.
* gcc.dg/nextafter-2.c: Include stdlib.h. For glibc < 2.24 define
NO_LONG_DOUBLE to 1 before including nextafter-1.c.
From-SVN: r260107
PR c++/85400
cp/
* decl2.c (adjust_var_decl_tls_model): New static function.
(comdat_linkage): Call it on a variable.
(maybe_make_one_only): Likewise.
c-family/
* c-attribs.c (handle_visibility_attribute): Do not set no_add_attrs.
From-SVN: r260106
Several recent changes to the gc version of cmd/go improve the
gofrontend support. These changes are partially copies of existing
gofrontend differences, and partially new code. This CL makes the
gofrontend match the upstream code.
The changes included here come from:
https://golang.org/cl/111575https://golang.org/cl/111595https://golang.org/cl/111635https://golang.org/cl/111636
For the record, the following recent gc changes are based on code
already present in the gofrontend repo:
https://golang.org/cl/110915https://golang.org/cl/111615
For the record, a gc change, partially based on earlier gofrontend
work, also with new gc code, was already copied to gofrontend repo in
CL 111099:
https://golang.org/cl/111097
This moves the generated list of standard library packages from
cmd/go/internal/load to go/build.
Reviewed-on: https://go-review.googlesource.com/112475
gotools/:
* Makefile.am (check-go-tool): Don't copy zstdpkglist.go.
* Makefile.in: Rebuild.
From-SVN: r260097
2018-05-09 Tom de Vries <tom@codesourcery.com>
PR libgomp/82901
* oacc-parallel.c (GOACC_declare): Use GOMP_ASYNC_SYNC as async argument
to GOACC_enter_exit_data.
From-SVN: r260085
To satisfy the CopyConstructible requirement a callable object stored in
a std::function must behave the same when copied from a const or
non-const source. If copying a non-const object doesn't produce an
equivalent copy then the behaviour is undefined. But we can make our
std::function more tolerant of such objects by ensuring we always copy
from a const lvalue.
Additionally use an if constexpr statement in the _M_get_pointer
function to avoid unnecessary instantiations in the discarded branch.
* include/bits/std_function.h (_Base_manager::_M_get_pointer):
Use constexpr if in C++17 mode.
(_Base_manager::_M_clone(_Any_data&, const _Any_data&, true_type)):
Copy from const object.
* testsuite/20_util/function/cons/non_copyconstructible.cc: New.
From-SVN: r260080
2018-05-09 Richard Biener <rguenther@suse.de>
* tree-vect-slp.c (vect_bb_slp_scalar_cost): Fill a cost
vector.
(vect_bb_vectorization_profitable_p): Adjust. Compute
actual scalar cost using the cost vector and the add_stmt_cost
machinery.
From-SVN: r260078
The one for the prologue mflr did not have any value set, which means
use the SET that is in the insn pattern. This works fine, except when
some late pass decides to replace the SET_SRC -- this changes the
meaning of the REG_CFA_REGISTER! Such passes should not do these
things, but let's be more explicit here, for extra robustness. It
could be argued that this defaulting is a design misfeature (it does
not save much space either, etc.)
PR rtl-optimization/85645
* config/rs6000/rs6000.c (rs6000_emit_prologue_components): Put a SET
in the REG_CFA_REGISTER note for LR, don't leave it empty.
From-SVN: r260077
In the testcase for PR85645 we do a pretty dumb placement of the
prologue/epilogue for the LR component: we place an epilogue for LR
before a control flow split where one of the branches clobbers LR
eventually, and the other does not. The branch that does clobber it
will need a prologue again some time later. Because saving and
restoring LR is a two step process---it needs to be moved via a GPR---
the backend emits CFI directives so that we get correct unwind
information. But both regcprop and regrename do not properly handle
such CFI directives leading to ICEs.
Now, neither of the two branches needs to have LR restored at all,
because both of the branches end up in an infinite loop.
This patch makes spread_component return a boolean saying if anything
was changed, and if so, it is called again. This obviously is finite
(there is a finite number of basic blocks, each with a finite number
of components, and spread_components can only assign more components
to a block, never less). I also instrumented the code, and on a
bootstrap+regtest spread_components made changes a maximum of two
times. Interestingly though it made changes on two iterations in
a third of the cases it did anything at all!
PR rtl-optimization/85645
* shrink-wrap.c (spread_components): Return a boolean saying if
anything was changed.
(try_shrink_wrapping_separate): Iterate spread_components until
nothing changes anymore.
From-SVN: r260076