]> git.ipfire.org Git - thirdparty/gcc.git/log
thirdparty/gcc.git
6 years agoReduce code instantiated by filesystem::path::_S_convert_loc
Jonathan Wakely [Fri, 14 Jun 2019 18:11:30 +0000 (19:11 +0100)] 
Reduce code instantiated by filesystem::path::_S_convert_loc

Jakub noted in https://gcc.gnu.org/ml/libstdc++/2019-04/msg00140.html
that an unwanted std::wstring::_M_replace_dispatch symbol has started to
be exported from the Fedora shared library. This symbol is triggered by
the instantiation of std::wstring::assign(const char*, const char*) from
std::__str_codecvt_in which is called from path::_S_convert_loc. The
branch that triggers that instantiation can't actually happen in that
case, because codecvt facets will only return noconv when the input and
output types are the same. Guarding the assign call with an if-constexpr
check that the types are the same avoids instantiating template
specializations that will never actually be needed.

Backport from mainline
2019-04-26  Jonathan Wakely  <jwakely@redhat.com>

* config/abi/pre/gnu.ver (GLIBCXX_3.4): Replace wildcard that matches
wstring::_M_replace_dispatch with more specific patterns.
* include/bits/fs_path.h (path::_S_convert_loc<_InputIterator>):
Create const std::string to avoid redundant call to _S_convert_loc
with non-const pointers.
* include/bits/locale_conv.h (__do_str_codecvt): Use if-constexpr to
avoid unnecessary basic_string::assign instantiations.

From-SVN: r272306

6 years agoRemove redundant step in experimental::filesystem::path construction
Jonathan Wakely [Fri, 14 Jun 2019 18:11:26 +0000 (19:11 +0100)] 
Remove redundant step in experimental::filesystem::path construction

Backport from mainline
2019-04-26  Jonathan Wakely  <jwakely@redhat.com>

* include/experimental/bits/fs_path.h
(path::_S_convert_loc<_InputIterator>): Create const std::string to
avoid redundant call to _S_convert_loc with non-const pointers.

From-SVN: r272305

6 years agoPR libstdc++/88881 fix filesystem::symlink_status for Windows
Jonathan Wakely [Fri, 14 Jun 2019 18:11:22 +0000 (19:11 +0100)] 
PR libstdc++/88881 fix filesystem::symlink_status for Windows

The fix for PR 88881 only added a workaround to filesystem::status, but
filesystem::symlink_status is also affected by the _wstat bug and needs
the same workaround.

The recent change to optimize path::parent_path() means that the
workaround can be simplified to just use parent_path().

Backport from mainline
2019-05-29  Jonathan Wakely  <jwakely@redhat.com>

PR libstdc++/88881
* src/c++17/fs_ops.cc [_GLIBCXX_FILESYSTEM_IS_WINDOWS]
(status(const path&, error_code&)): Use parent_path() to remove
trailing slash.
(symlink_status(const path&, error_code&)): Duplicate workaround for
bug in _wstat for paths with trailing slash.
* testsuite/27_io/filesystem/operations/remove_all.cc: Check path
with trailing slash.
* testsuite/27_io/filesystem/operations/status.cc: Likewise.
* testsuite/27_io/filesystem/operations/symlink_status.cc: Likewise.

From-SVN: r272304

6 years agoOptimize filesystem::path::parent_path()
Jonathan Wakely [Fri, 14 Jun 2019 18:11:17 +0000 (19:11 +0100)] 
Optimize filesystem::path::parent_path()

Parsing a complete string is more efficient than appending each
component one-by-one.

Backport from mainline
2019-05-29  Jonathan Wakely  <jwakely@redhat.com>

* src/c++17/fs_path.cc (path::parent_path()): Create whole path at
once instead of building it iteratively.

From-SVN: r272303

6 years agoFix incorrect DR numbers in libstdc++ manual
Jonathan Wakely [Fri, 14 Jun 2019 18:11:13 +0000 (19:11 +0100)] 
Fix incorrect DR numbers in libstdc++ manual

Backport from mainline
2019-05-07  Jonathan Wakely  <jwakely@redhat.com>

* doc/xml/manual/intro.xml: Fix DR 2537 and DR 2566 confusion.

From-SVN: r272302

6 years agoAdd __cpp_lib_bind_front macro to <version> header
Jonathan Wakely [Fri, 14 Jun 2019 18:11:09 +0000 (19:11 +0100)] 
Add __cpp_lib_bind_front macro to <version> header

Backport from mainline
2019-06-14  Jonathan Wakely  <jwakely@redhat.com>

* include/std/version (__cpp_lib_bind_front): Add missing macro.

From-SVN: r272301

6 years agoFix incorrect __cpp_lib_parallel_algorithm macro definitions
Jonathan Wakely [Fri, 14 Jun 2019 18:11:02 +0000 (19:11 +0100)] 
Fix incorrect __cpp_lib_parallel_algorithm macro definitions

Backport from mainline
2019-06-12  Jonathan Wakely  <jwakely@redhat.com>

* include/std/algorithm (__cpp_lib_parallel_algorithm): Fix value.
* include/std/memory (__cpp_lib_parallel_algorithm): Likewise.
* include/std/numeric (__cpp_lib_parallel_algorithm): Likewise.
* testsuite/25_algorithms/pstl/feature_test.cc: New test.

From-SVN: r272300

6 years agoPR libstdc++/90770 fix missing src/debug/Makefile
Jonathan Wakely [Fri, 14 Jun 2019 18:10:57 +0000 (19:10 +0100)] 
PR libstdc++/90770 fix missing src/debug/Makefile

Backport from mainline
2019-06-07  Jonathan Wakely  <jwakely@redhat.com>

PR libstdc++/90770
* src/Makefile.am (stamp-debug): Also test for missing makefile.
* src/Makefile.in: Regenerate.

From-SVN: r272299

6 years agoPR libstdc++/90252 Check TBB version and ability to link with -ltbb
Jonathan Wakely [Fri, 14 Jun 2019 18:10:52 +0000 (19:10 +0100)] 
PR libstdc++/90252 Check TBB version and ability to link with -ltbb

Backport from mainline
2019-05-21  Jonathan Wakely  <jwakely@redhat.com>

PR libstdc++/90252
* testsuite/lib/libstdc++.exp (check_effective_target_tbb-backend):
Use "additional_flags" to pass -ltbb to v3_target_compile command.
Use check_v3_target_prop_cached to cache the result of the test.

Backport from mainline
2019-05-20  Thomas Rodgers  <trodgers@redhat.com>

PR libstdc++/90252
* testsuite/lib/libstdc++.exp (check_effective_target_tbb-backend):
Changed v3_target_compile check from preprocess to executable.
Added "-ltbb" to v3_target_compile flags.

Backport from mainline
2019-05-20  Thomas Rodgers  <trodgers@redhat.com>

* testsuite/lib/libstdc++.exp (check_effective_target_tbb-backend):
Add check for Thread Building Blocks 2018 or later.

From-SVN: r272298

6 years agoUse tabs to indent in ChangeLog
Jonathan Wakely [Fri, 14 Jun 2019 15:40:24 +0000 (16:40 +0100)] 
Use tabs to indent in ChangeLog

From-SVN: r272293

6 years agoFix names of _Lock_policy constants in libstdc++ manual
Jonathan Wakely [Fri, 14 Jun 2019 15:39:51 +0000 (16:39 +0100)] 
Fix names of _Lock_policy constants in libstdc++ manual

Backport from mainline
2019-05-21  Jonathan Wakely  <jwakely@redhat.com>

* doc/xml/manual/shared_ptr.xml: Fix names of lock policy constants.

From-SVN: r272292

6 years agoDaily bump.
GCC Administrator [Fri, 14 Jun 2019 00:16:13 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r272279

6 years agoPR c++/90825 - endless recursion when evaluating sizeof.
Marek Polacek [Thu, 13 Jun 2019 00:56:54 +0000 (00:56 +0000)] 
PR c++/90825 - endless recursion when evaluating sizeof.

PR c++/90832 - endless recursion when evaluating sizeof.
* constexpr.c (cxx_eval_constant_expression): Don't recurse on the
result of fold_sizeof_expr if is returns a SIZEOF_EXPR.
* typeck.c (cxx_sizeof_expr): Only return a SIZEOF_EXPR if the operand
is instantiation-dependent.

* g++.dg/cpp0x/constexpr-sizeof2.C: New test.
* g++.dg/cpp0x/constexpr-sizeof3.C: New test.

From-SVN: r272229

6 years agoDaily bump.
GCC Administrator [Thu, 13 Jun 2019 00:16:12 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r272227

6 years agoPR c++/90736 - bogus error with alignof.
Marek Polacek [Wed, 12 Jun 2019 21:12:00 +0000 (21:12 +0000)] 
PR c++/90736 - bogus error with alignof.

* constexpr.c (adjust_temp_type): Use cv_unqualified type.

* g++.dg/cpp0x/alignof5.C: New test.

From-SVN: r272219

6 years agoDaily bump.
GCC Administrator [Wed, 12 Jun 2019 00:16:11 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r272176

6 years agobackport: re PR fortran/90744 (Bogus length for character temporaries passed to exter...
Thomas Koenig [Tue, 11 Jun 2019 22:04:10 +0000 (22:04 +0000)] 
backport: re PR fortran/90744 (Bogus length for character temporaries passed to external procedures since r268992)

2019-06-11  Thomas Koenig  <tkoenig@gcc.gnu.org>
Tomáš Trnka  <trnka@scm.com>

Backport from trunk
PR fortran/90744
* trans-types.c (get_formal_from_actual_arglist): Unset typespec
flags which make no sense for procedures without explicit
interface.

2019-06-11  Thomas Koenig  <tkoenig@gcc.gnu.org>
Tomáš Trnka  <trnka@scm.com>

Backport from trunk
PR fortran/90744
* gfortran.dg/deferred_character_33.f90: New test.
* gfortran.dg/deferred_character_33a.f90: New test.

Co-Authored-By: Tomáš Trnka <trnka@scm.com>
From-SVN: r272173

6 years agore PR target/90811 ([nvptx] ptxas error on OpenMP offloaded code)
Jakub Jelinek [Tue, 11 Jun 2019 16:43:09 +0000 (18:43 +0200)] 
re PR target/90811 ([nvptx] ptxas error on OpenMP offloaded code)

PR target/90811
* config/nvptx/nvptx.c (nvptx_output_softstack_switch): Use and.b%d
instead of and.u%d.

* testsuite/libgomp.c/pr90811.c: New test.

From-SVN: r272162

6 years agoFix ConstexprIterator requirements tests - No constexpr algorithms!
Edward Smith-Rowland [Tue, 11 Jun 2019 16:36:21 +0000 (16:36 +0000)] 
Fix ConstexprIterator requirements tests - No constexpr algorithms!

2019-06-11  Edward Smith-Rowland  <3dw4rd@verizon.net>

Fix ConstexprIterator requirements tests - No constexpr algorithms!
* testsuite/21_strings/basic_string_view/requirements/constexpr_iter.cc:
Replace copy with hand-rolled loop.
* testsuite/23_containers/array/requirements/constexpr_iter.cc:
Ditto.

From-SVN: r272160

6 years agore PR c++/90810 (Different intrinsics behavior on G++ 7.4 and G++ 8.3)
Jakub Jelinek [Tue, 11 Jun 2019 13:08:47 +0000 (15:08 +0200)] 
re PR c++/90810 (Different intrinsics behavior on G++ 7.4 and G++ 8.3)

PR c++/90810
* init.c (constant_value_1): Handle VECTOR_CST DECL_INITIAL for
!DECL_INITIALIZED_BY_CONSTANT_EXPRESSION_P decls like CONSTRUCTOR.

* g++.dg/ext/vector37.C: New test.

From-SVN: r272154

6 years agotoir.cc (pop_label): Only queue labels in a vector.
Richard Biener [Tue, 11 Jun 2019 08:31:09 +0000 (08:31 +0000)] 
toir.cc (pop_label): Only queue labels in a vector.

2019-06-11  Richard Biener  <rguenthe@suse.de>

d/90778
* toir.cc (pop_label): Only queue labels in a vector.
(cmp_labels): Label decl comparator.
(pop_binding_level): Pop labels in DECL_UID order to avoid
debug info differences.

From-SVN: r272147

6 years agoDaily bump.
GCC Administrator [Tue, 11 Jun 2019 00:16:13 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r272140

6 years agoDaily bump.
GCC Administrator [Mon, 10 Jun 2019 00:16:18 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r272101

6 years agoTest for C++20 p0858 - ConstexprIterator requirements.
Edward Smith-Rowland [Sun, 9 Jun 2019 21:43:55 +0000 (21:43 +0000)] 
Test for C++20 p0858 - ConstexprIterator requirements.

2019-06-09  Edward Smith-Rowland  <3dw4rd@verizon.net>

Test for C++20 p0858 - ConstexprIterator requirements.
* testsuite/21_strings/basic_string_view/requirements/constexpr_iter.cc:
New test.
* testsuite/23_containers/array/requirements/constexpr_iter.cc:
New test.

From-SVN: r272097

6 years agoDaily bump.
GCC Administrator [Sun, 9 Jun 2019 00:16:15 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r272088

6 years agoDaily bump.
GCC Administrator [Sat, 8 Jun 2019 00:16:15 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r272066

6 years agoscanasm.exp (dg-function-on-line): Add pattern for hppa*-*-linux*.
John David Anglin [Fri, 7 Jun 2019 23:22:15 +0000 (23:22 +0000)] 
scanasm.exp (dg-function-on-line): Add pattern for hppa*-*-linux*.

* lib/scanasm.exp (dg-function-on-line): Add pattern for hppa*-*-linux*.

From-SVN: r272062

6 years agore PR target/90751 (-fpatchtable-function-entry broken on hppa-linux-gnu-gcc/hppa64...
John David Anglin [Fri, 7 Jun 2019 23:20:44 +0000 (23:20 +0000)] 
re PR target/90751 (-fpatchtable-function-entry  broken on hppa-linux-gnu-gcc/hppa64-linux-gnu-gcc)

PR target/90751
* config/pa/pa-linux.h (ASM_DECLARE_FUNCTION_NAME): Update comment.
Call pa_output_function_label.
(TARGET_ASM_FUNCTION_PROLOGUE): define.
* config/pa/pa-protos.h (pa_output_function_label): Declare.
* config/pa/pa.c (pa_output_function_prologue): Add ATTRIBUTE_UNUSED
to declaration.
(pa_linux_output_function_prologue): Declare.
(TARGET_ASM_FUNCTION_PROLOGUE): Delete define.
(pa_output_function_label): New.
(pa_output_function_prologue): Revise to use pa_output_function_label.
(pa_linux_output_function_prologue): New.
* config/pa/pa.h (TARGET_ASM_FUNCTION_PROLOGUE): Define.

From-SVN: r272061

6 years agoDaily bump.
GCC Administrator [Fri, 7 Jun 2019 00:16:15 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r272026

6 years ago* sv.po: Update.
Joseph Myers [Thu, 6 Jun 2019 23:15:26 +0000 (00:15 +0100)] 
* sv.po: Update.

From-SVN: r272020

6 years agoBackport PRs 90328, 90402, 90450, 90474
Richard Biener [Thu, 6 Jun 2019 11:06:45 +0000 (11:06 +0000)] 
Backport PRs 90328, 90402, 90450, 90474

2019-06-06  Richard Biener  <rguenther@suse.de>

Backport from mainline
2019-05-22  Richard Biener  <rguenther@suse.de>

PR tree-optimization/90450
* tree-ssa-loop-im.c (struct im_mem_ref): Add ref_decomposed.
(mem_ref_hasher::equal): Check it.
(mem_ref_alloc): Initialize it.
(gather_mem_refs_stmt): Set it.

2019-05-15  Richard Biener  <rguenther@suse.de>

PR c/90474
* c-common.c (c_common_mark_addressable_vec): Also mark
a COMPOUND_LITERAL_EXPR_DECL addressable similar to
c_mark_addressable.

2019-05-13  Richard Biener  <rguenther@suse.de>

PR tree-optimization/90402
* tree-if-conv.c (tree_if_conversion): Value number only
the loop body by making the latch an exit of the region
as well.
* tree-ssa-sccvn.c (process_bb): Add flag whether to skip
processing PHIs.
(do_rpo_vn): Deal with multiple edges into the entry block
that are not backedges inside the region by skipping PHIs
of the entry block.

* gcc.dg/torture/pr90402-1.c: New testcase.

2019-05-06  Richard Biener  <rguenther@suse.de>

PR tree-optimization/90328
* tree-data-ref.h (dr_may_alias_p): Pass in the actual loop nest.
* tree-data-ref.c (dr_may_alias_p): Check whether the clique
is valid in the loop nest before using it.
(initialize_data_dependence_relation): Adjust.
* graphite-scop-detection.c (build_alias_set): Pass the SCOP enclosing
loop as loop-nest to dr_may_alias_p.

* gcc.dg/torture/pr90328.c: New testcase.

From-SVN: r271995

6 years agoDaily bump.
GCC Administrator [Thu, 6 Jun 2019 00:16:14 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r271981

6 years agofold-const.c (extract_muldiv_1): Do not distribute a multiplication by a power-of...
Eric Botcazou [Wed, 5 Jun 2019 14:21:37 +0000 (14:21 +0000)] 
fold-const.c (extract_muldiv_1): Do not distribute a multiplication by a power-of-two value.

* fold-const.c (extract_muldiv_1) <PLUS_EXPR>: Do not distribute a
multiplication by a power-of-two value.
(fold_plusminus_mult_expr): Use pow2p_hwi to spot a power-of-two value
and turn the modulo operation into a masking operation.

From-SVN: r271964

6 years agore PR debug/90733 (ICE in simplify_subreg, at simplify-rtx.c:6440)
Jakub Jelinek [Wed, 5 Jun 2019 12:22:22 +0000 (14:22 +0200)] 
re PR debug/90733 (ICE in simplify_subreg, at simplify-rtx.c:6440)

PR debug/90733
* var-tracking.c (vt_expand_loc_callback): Don't create raw subregs
with VOIDmode inner operands.

* gcc.dg/pr90733.c: New test.

From-SVN: r271960

6 years agobackport: re PR c++/90598 (Return type of explicit destructor call wrong)
Jakub Jelinek [Wed, 5 Jun 2019 12:21:27 +0000 (14:21 +0200)] 
backport: re PR c++/90598 (Return type of explicit destructor call wrong)

Backported from mainline
2019-05-29  Jakub Jelinek  <jakub@redhat.com>

PR c++/90598
* tree.c (lvalue_kind): Return clk_none for expressions with
with VOID_TYPE_P.

* g++.dg/cpp0x/pr90598.C: New test.

2019-05-02  Jonathan Wakely  <jwakely@redhat.com>

* testsuite/experimental/propagate_const/requirements2.cc: Adjust
dg-error.

From-SVN: r271959

6 years agobackport: re PR libgomp/90641 (libgomp.c-c++-common/lastprivate-conditional-1.c etc...
Jakub Jelinek [Wed, 5 Jun 2019 12:19:00 +0000 (14:19 +0200)] 
backport: re PR libgomp/90641 (libgomp.c-c++-common/lastprivate-conditional-1.c etc FAIL)

Backported from mainline
2019-05-27  Jakub Jelinek  <jakub@redhat.com>

PR libgomp/90641
* work.c (gomp_init_work_share): Instead of aligning final ordered
value to multiples of long long alignment, align to that the
first part (ordered team ids) and if inline_ordered_team_ids
is not on a long long alignment boundary within the structure,
use __alignof__ (long long) - 1 pad size always.
* loop.c (GOMP_loop_start): Fix *mem computation if
inline_ordered_team_ids is not aligned on long long alignment boundary
within the structure.
* loop-ull.c (GOMP_loop_ull_start): Likewise.
* sections.c (GOMP_sections2_start): Likewise.

From-SVN: r271958

6 years agobackport: re PR libgomp/90585 (libgomp hsa plugin ftbfs in the x32 multilib variant)
Jakub Jelinek [Wed, 5 Jun 2019 12:18:23 +0000 (14:18 +0200)] 
backport: re PR libgomp/90585 (libgomp hsa plugin ftbfs in the x32 multilib variant)

Backported from mainline
2019-05-24  Jakub Jelinek  <jakub@redhat.com>

PR libgomp/90585
* plugin/plugin-hsa.c (print_kernel_dispatch, run_kernel): Use PRIu64
macro instead of "lu".
(release_kernel_dispatch): Likewise.  Cast shadow->debug to uintptr_t
before casting to void *.

From-SVN: r271957

6 years agobackport documentation for target supports (mfentry availability).
Iain Sandoe [Wed, 5 Jun 2019 08:27:37 +0000 (08:27 +0000)] 
backport documentation for target supports (mfentry availability).

This was missed with the backport of the mfentry changes for
Darwin, and documents the target-supports addition only. (NFC).

Corrected ChangeLog

gcc/

2019-06-05  Iain Sandoe  <iain@sandoe.co.uk>

Backport from mainline.
2019-05-23  Iain Sandoe  <iain@sandoe.co.uk>
* doc/sourcebuild.texi: Document mfentry target support.

From-SVN: r271951

6 years agoDaily bump.
GCC Administrator [Wed, 5 Jun 2019 00:16:16 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r271943

6 years agoDaily bump.
GCC Administrator [Tue, 4 Jun 2019 00:16:13 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r271898

6 years agoPR libstdc++/90700 Fix constructor constraint for std::tuple
Jonathan Wakely [Mon, 3 Jun 2019 22:31:45 +0000 (23:31 +0100)] 
PR libstdc++/90700 Fix constructor constraint for std::tuple

* include/std/tuple
(tuple(allocator_arg_t, const A&, const tuple<UTypes...>&)): Fix
value category of template argument to _TC::_NonNestedTuple.
* testsuite/20_util/tuple/cons/90700.cc: New test.

From-SVN: r271887

6 years ago* sv.po: Update.
Joseph Myers [Mon, 3 Jun 2019 22:22:06 +0000 (23:22 +0100)] 
* sv.po: Update.

From-SVN: r271886

6 years agoPR libstdc++/90686 update C++2a library status docs
Jonathan Wakely [Mon, 3 Jun 2019 14:05:50 +0000 (15:05 +0100)] 
PR libstdc++/90686 update C++2a library status docs

PR libstdc++/90686
* doc/xml/manual/status_cxx2014.xml: Document what's missing from
<experimental/memory_resource>.
* doc/xml/manual/status_cxx2020.xml: Document status of P0777R1,
P0339R6, P0340R3, P1164R1 and P1357R1.
* doc/html/*: Regenerate.

From-SVN: r271872

6 years agoImplement missing piece of P0777R1 for std::make_from_tuple
Jonathan Wakely [Mon, 3 Jun 2019 14:05:46 +0000 (15:05 +0100)] 
Implement missing piece of P0777R1 for std::make_from_tuple

* include/std/tuple (make_from_tuple): Use remove_reference_t instead
of decay_t (P0777R1).

From-SVN: r271871

6 years agoDaily bump.
GCC Administrator [Mon, 3 Jun 2019 00:16:14 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r271851

6 years agoDaily bump.
GCC Administrator [Sun, 2 Jun 2019 00:16:18 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r271842

6 years agoDaily bump.
GCC Administrator [Sat, 1 Jun 2019 00:16:13 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r271831

6 years ago* fi.po, sv.po: Update.
Joseph Myers [Fri, 31 May 2019 00:32:01 +0000 (01:32 +0100)] 
* fi.po, sv.po: Update.

From-SVN: r271797

6 years agoDaily bump.
GCC Administrator [Fri, 31 May 2019 00:16:12 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r271794

6 years ago* lang.opt (ftail-call-workaround): Fix a typo.
Marek Polacek [Thu, 30 May 2019 12:19:40 +0000 (12:19 +0000)] 
* lang.opt (ftail-call-workaround): Fix a typo.

From-SVN: r271778

6 years agoBackport libstdc++ documentation updates from mainline
Jonathan Wakely [Thu, 30 May 2019 10:34:44 +0000 (11:34 +0100)] 
Backport libstdc++ documentation updates from mainline

* doc/xml/manual/status_cxx2017.xml: Fix typo in documentation of
implementation-defined support for [fs.conform.9945].
* doc/xml/manual/status_cxx2020.xml: Add feature-test macro for
P0811R3. Change status of P1353R0.
* doc/html/*: Regenerate.

From-SVN: r271775

6 years agotree-predcom.c (is_inv_store_elimination_chain): Fix a typo - lenght to length.
Jakub Jelinek [Thu, 30 May 2019 09:34:26 +0000 (11:34 +0200)] 
tree-predcom.c (is_inv_store_elimination_chain): Fix a typo - lenght to length.

* tree-predcom.c (is_inv_store_elimination_chain): Fix a typo - lenght
to length.

* lang.opt (ftail-call-workaround=): Fix a typo - lenghts to lengths.

From-SVN: r271771

6 years agoDarwin, x86 - backport fix for mfentry test fails.
Iain Sandoe [Thu, 30 May 2019 08:06:38 +0000 (08:06 +0000)] 
Darwin, x86 - backport fix for mfentry test fails.

This will fix the cases by UNSUPPORTING for any target that cannot
support mfentry (including Linux -fpic -m32).

gcc/

2019-05-30  Iain Sandoe  <iain@sandoe.co.uk>

Backport from mainline.
2019-05-23  Iain Sandoe  <iain@sandoe.co.uk>

* config/i386/darwin.h: Reject -mfentry*.
* doc/sourcebuild.texi: Document mfentry target support.

gcc/testsuite/

2019-05-30  Iain Sandoe  <iain@sandoe.co.uk>

Backport from mainline.
2019-05-23  Iain Sandoe  <iain@sandoe.co.uk>

       * lib/target-supports.exp (check_effective_target_mfentry): New.
       * gcc.target/i386/fentry-override.c: Require effective target mfentry.
       * gcc.target/i386/fentry.c: Likewise
       * gcc.target/i386/fentryname1.c: Likewise
       * gcc.target/i386/fentryname2.c: Likewise
       * gcc.target/i386/fentryname3.c: Likewise
       * gcc.target/i386/nop-mcount.c: Likewise
       * gcc.target/i386/pr82699-2.c: Likewise
       * gcc.target/i386/pr82699-4.c: Likewise
       * gcc.target/i386/pr82699-5.c: Likewise
       * gcc.target/i386/pr82699-6.c: Likewise
       * gcc.target/i386/returninst1.c: Likewise
       * gcc.target/i386/returninst2.c: Likewise
       * gcc.target/i386/returninst3.c : Likewise

From-SVN: r271767

6 years agoDarwin, backport fix for PR82920 part3 (other CET test fixes).
Iain Sandoe [Thu, 30 May 2019 08:00:45 +0000 (08:00 +0000)] 
Darwin, backport fix for PR82920 part3 (other CET test fixes).

gcc/testsuite/

2019-05-30  Iain Sandoe  <iain@sandoe.co.uk>

Backport from mainline.
2019-05-15  Iain Sandoe  <iain@sandoe.co.uk>

PR target/82920
* g++.dg/cet-notrack-1.C: Adjust scan assembler for Darwin.
* gcc.target/i386/cet-notrack-5a.c: Likewise.
* gcc.target/i386/cet-notrack-5b.c: Likewise.
* gcc.target/i386/cet-notrack-6b.c: Likewise.
* gcc.target/i386/cet-notrack-icf-1.c: Likewise.
* gcc.target/i386/cet-notrack-icf-2.c: Likewise.
* gcc.target/i386/cet-notrack-icf-3.c: Likewise.
* gcc.target/i386/cet-notrack-icf-4.c: Likewise.
* gcc.target/i386/cet-sjlj-3.c: Likewise.
* gcc.target/i386/cet-sjlj-5.c: Likewise.

From-SVN: r271766

6 years agoDarwin, backport fix for PR82920 part2 (mx32 is not supported)
Iain Sandoe [Thu, 30 May 2019 07:56:10 +0000 (07:56 +0000)] 
Darwin, backport fix for PR82920 part2 (mx32 is not supported)

gcc/

2019-05-30  Iain Sandoe  <iain@sandoe.co.uk>

Backport from mainline.
2019-05-12  Iain Sandoe  <iain@sandoe.co.uk>

PR target/82920
* config/i386/darwin.h (CC1_SPEC): Report -mx32 as an error for
Darwin.

gcc/testsuite/

2019-05-30  Iain Sandoe  <iain@sandoe.co.uk>

Backport from mainline.
2019-05-14  Iain Sandoe  <iain@sandoe.co.uk>

PR target/82920
* gcc.target/i386/cet-sjlj-6b.c: Require effective target x32.
* gcc.target/i386/pr52146.c: Likewise.
* gcc.target/i386/pr52698.c: Likewise.
* gcc.target/i386/pr52857-1.c: Likewise.
* gcc.target/i386/pr52857-2.c: Likewise.
* gcc.target/i386/pr52876.c: Likewise.
* gcc.target/i386/pr53698.c: Likewise.
* gcc.target/i386/pr54157.c: Likewise.
* gcc.target/i386/pr55049-1.c: Likewise.
* gcc.target/i386/pr55093.c: Likewise.
* gcc.target/i386/pr55116-1.c: Likewise.
* gcc.target/i386/pr55116-2.c: Likewise.
* gcc.target/i386/pr55597.c: Likewise.
* gcc.target/i386/pr59929.c: Likewise.
* gcc.target/i386/pr66470.c: Likewise.

From-SVN: r271765

6 years agoDarwin, backport fix for pr82920 (part1, code)
Iain Sandoe [Thu, 30 May 2019 07:51:32 +0000 (07:51 +0000)] 
Darwin, backport fix for pr82920 (part1, code)

gcc/

2019-05-30  Iain Sandoe  <iain@sandoe.co.uk>

Backport from mainline.
2019-05-12  Iain Sandoe  <iain@sandoe.co.uk>

PR target/82920
* config/i386/i386.c (ix86_output_jmp_thunk_or_indirect): New.
(ix86_output_indirect_branch_via_reg): Use output mechanism
accounting for __USER_LABEL_PREFIX__.
(ix86_output_indirect_branch_via_push): Likewise.
(ix86_output_function_return): Likewise.
(ix86_output_indirect_function_return): Likewise.

gcc/testsuite/

2019-05-30  Iain Sandoe  <iain@sandoe.co.uk>

Backport from mainline.
2019-05-12  Iain Sandoe  <iain@sandoe.co.uk>
    Dominique d'Humieres  <dominiq@gcc.gnu.org>

PR target/82920
* gcc.target/i386/indirect-thunk-1.c: Adjust scan-asms for Darwin,
do not use -fno-pic on Darwin.
* gcc.target/i386/indirect-thunk-2.c: Likewise.
* gcc.target/i386/indirect-thunk-3.c: Likewise.
* gcc.target/i386/indirect-thunk-4.c: Likewise.
* gcc.target/i386/indirect-thunk-7.c: Likewise.
* gcc.target/i386/indirect-thunk-attr-1.c: Likewise.
* gcc.target/i386/indirect-thunk-attr-2.c: Likewise.
* gcc.target/i386/indirect-thunk-attr-3.c: Likewise.
* gcc.target/i386/indirect-thunk-attr-4.c: Likewise.
* gcc.target/i386/indirect-thunk-attr-5.c: Likewise.
* gcc.target/i386/indirect-thunk-attr-6.c: Likewise.
* gcc.target/i386/indirect-thunk-attr-7.c: Likewise.
* gcc.target/i386/indirect-thunk-attr-8.c: Likewise.
* gcc.target/i386/indirect-thunk-extern-1.c: Likewise.
* gcc.target/i386/indirect-thunk-extern-2.c: Likewise.
* gcc.target/i386/indirect-thunk-extern-3.c: Likewise.
* gcc.target/i386/indirect-thunk-extern-4.c: Likewise.
* gcc.target/i386/indirect-thunk-extern-7.c: Likewise.
* gcc.target/i386/indirect-thunk-inline-1.c: Likewise.
* gcc.target/i386/indirect-thunk-inline-2.c: Likewise.
* gcc.target/i386/indirect-thunk-inline-3.c: Likewise.
* gcc.target/i386/indirect-thunk-inline-4.c: Likewise.
* gcc.target/i386/indirect-thunk-inline-7.c: Likewise.
* gcc.target/i386/indirect-thunk-register-1.c: Likewise.
* gcc.target/i386/indirect-thunk-register-2.c: Likewise.
* gcc.target/i386/indirect-thunk-register-3.c: Likewise.
* gcc.target/i386/indirect-thunk-register-4.c: Likewise.
* gcc.target/i386/ret-thunk-1.c: Likewise.
* gcc.target/i386/ret-thunk-10.c: Likewise.
* gcc.target/i386/ret-thunk-11.c: Likewise.
* gcc.target/i386/ret-thunk-12.c: Likewise.
* gcc.target/i386/ret-thunk-13.c: Likewise.
* gcc.target/i386/ret-thunk-14.c: Likewise.
* gcc.target/i386/ret-thunk-15.c: Likewise.
* gcc.target/i386/ret-thunk-16.c: Likewise.
* gcc.target/i386/ret-thunk-2.c: Likewise.
* gcc.target/i386/ret-thunk-22.c: Likewise.
* gcc.target/i386/ret-thunk-23.c: Likewise.
* gcc.target/i386/ret-thunk-24.c: Likewise.
* gcc.target/i386/ret-thunk-3.c: Likewise.
* gcc.target/i386/ret-thunk-4.c: Likewise.
* gcc.target/i386/ret-thunk-5.c: Likewise.
* gcc.target/i386/ret-thunk-6.c: Likewise.
* gcc.target/i386/ret-thunk-7.c: Likewise.
* gcc.target/i386/ret-thunk-8.c: Likewise.
* gcc.target/i386/ret-thunk-9.c: Likewise.

From-SVN: r271764

6 years agoDaily bump.
GCC Administrator [Thu, 30 May 2019 00:16:13 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r271759

6 years agore PR fortran/90329 (Incompatibility between gfortran and C lapack calls)
Jakub Jelinek [Wed, 29 May 2019 15:55:12 +0000 (17:55 +0200)] 
re PR fortran/90329 (Incompatibility between gfortran and C lapack calls)

PR fortran/90329
* lto-streamer.h (LTO_minor_version): Bump to 1.

Backported from mainline
2019-05-29  Jakub Jelinek  <jakub@redhat.com>

PR fortran/90329
* lang.opt (fbroken-callers): Remove.
(ftail-call-workaround, ftail-call-workaround=): New options.
* gfortran.h (struct gfc_namespace): Add implicit_interface_calls.
* interface.c (gfc_procedure_use): Set implicit_interface_calls
for calls to implicit interface procedures.
* trans-decl.c (create_function_arglist): Use flag_tail_call_workaround
instead of flag_broken_callers.  If it is not 2, also require
sym->ns->implicit_interface_calls.
* invoke.texi (fbroken-callers): Remove documentation.
(ftail-call-workaround, ftail-call-workaround=): Document.

2019-05-19  Thomas Koenig  <tkoenig@gcc.gnu.org>

PR fortran/90329
* invoke.texi: Document -fbroken-callers.
* lang.opt: Add -fbroken-callers.
* trans-decl.c (create_function_arglist): Only set
DECL_HIDDEN_STRING_LENGTH if flag_broken_callers is set.

2019-05-16  Jakub Jelinek  <jakub@redhat.com>

PR fortran/90329
* tree-core.h (struct tree_decl_common): Document
decl_nonshareable_flag for PARM_DECLs.
* tree.h (DECL_HIDDEN_STRING_LENGTH): Define.
* calls.c (expand_call): Don't try tail call if caller
has any DECL_HIDDEN_STRING_LENGTH PARM_DECLs that are or might be
passed on the stack and callee needs to pass any arguments on the
stack.
* tree-streamer-in.c (unpack_ts_decl_common_value_fields): Use
else if instead of series of mutually exclusive ifs.  Handle
DECL_HIDDEN_STRING_LENGTH for PARM_DECLs.
* tree-streamer-out.c (pack_ts_decl_common_value_fields): Likewise.

* trans-decl.c (create_function_arglist): Set
DECL_HIDDEN_STRING_LENGTH on hidden string length PARM_DECLs if
len is constant.

From-SVN: r271743

6 years agore PR bootstrap/90543 (Build failure on MINGW for gcc-9.1.0)
Jakub Jelinek [Wed, 29 May 2019 09:35:34 +0000 (11:35 +0200)] 
re PR bootstrap/90543 (Build failure on MINGW for gcc-9.1.0)

PR bootstrap/90543
* optc-save-gen.awk: In cl_optimization_print, use correct condition
for var_opt_string printing.  In cl_optimization_print_diff, print
(null) instead of invoking undefined behavior if one of the
var_opt_string pointers is NULL and use && instead of first || in the
guarding condition.  For var_target_other options, handle const char *
target variables similarly to const char * optimize node variables.

From-SVN: r271737

6 years agoDaily bump.
GCC Administrator [Wed, 29 May 2019 00:16:13 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r271725

6 years agopa.c (hppa_profile_hook): Remove offset adjustment.
John David Anglin [Tue, 28 May 2019 23:28:02 +0000 (23:28 +0000)] 
pa.c (hppa_profile_hook): Remove offset adjustment.

* config/pa/pa.c (hppa_profile_hook): Remove offset adjustment.

From-SVN: r271721

6 years agoPR libstdc++/90634 reduce allocations in filesystem::path construction
Jonathan Wakely [Tue, 28 May 2019 20:48:31 +0000 (21:48 +0100)] 
PR libstdc++/90634 reduce allocations in filesystem::path construction

Backport from mainline
2019-05-28  Jonathan Wakely  <jwakely@redhat.com>

PR libstdc++/90634
* include/experimental/bits/fs_path.h (path::path(path&&)): Only call
_M_split_cmpts() for a path with multiple components.
(path::_S_is_dir_sep()): Add missing 'static' keyword to function.
* src/filesystem/path.cc (path::_M_split_cmpts()): Count number of
components and reserve space in vector. Return early when there is
only one component.
* testsuite/27_io/filesystem/path/construct/90634.cc: New test.
* testsuite/experimental/filesystem/path/construct/90634.cc: New test.

From-SVN: r271719

6 years agoFix C++14-only code in testsuite utility
Jonathan Wakely [Tue, 28 May 2019 20:48:23 +0000 (21:48 +0100)] 
Fix C++14-only code in testsuite utility

* testsuite/util/testsuite_fs.h (compare_paths): Use three-argument
form of std::equals for C++11 compatibility.

From-SVN: r271718

6 years agoPR c++/90548 - ICE with generic lambda and empty pack.
Marek Polacek [Tue, 28 May 2019 14:16:38 +0000 (14:16 +0000)] 
PR c++/90548 - ICE with generic lambda and empty pack.

* pt.c (tsubst_copy_and_build): Handle pack expansion properly.

* g++.dg/cpp1y/lambda-generic-90548.C: New test.

From-SVN: r271708

6 years agotrans.c (lvalue_required_for_attribute_p): Return 0 for 'Size too.
Eric Botcazou [Tue, 28 May 2019 08:25:45 +0000 (08:25 +0000)] 
trans.c (lvalue_required_for_attribute_p): Return 0 for 'Size too.

* gcc-interface/trans.c (lvalue_required_for_attribute_p): Return 0
for 'Size too.
(Identifier_to_gnu): Use the actual subtype for a reference to a
packed array in a return statement.
(Attribute_to_gnu) <Attr_Size>: Do not strip VIEW_CONVERT_EXPRs from
the prefix in every case.

From-SVN: r271692

6 years agotrans.c (gnat_to_gnu): Remove superfluous tests on Backend_Overflow_Checks_On_Target...
Eric Botcazou [Tue, 28 May 2019 08:13:50 +0000 (08:13 +0000)] 
trans.c (gnat_to_gnu): Remove superfluous tests on Backend_Overflow_Checks_On_Target and rework comments.

* gcc-interface/trans.c (gnat_to_gnu): Remove superfluous tests on
Backend_Overflow_Checks_On_Target and rework comments.

From-SVN: r271690

6 years agotrans.c (walk_nesting_tree): New static function.
Eric Botcazou [Tue, 28 May 2019 08:03:08 +0000 (08:03 +0000)] 
trans.c (walk_nesting_tree): New static function.

* gcc-interface/trans.c (walk_nesting_tree): New static function.
(finalize_nrv): Use it to walk the entire nesting tree.

From-SVN: r271686

6 years agodecl.c (gnat_to_gnu_entity): Remove obsolete test on Is_For_Access_Subtype.
Eric Botcazou [Tue, 28 May 2019 07:43:17 +0000 (07:43 +0000)] 
decl.c (gnat_to_gnu_entity): Remove obsolete test on Is_For_Access_Subtype.

* gcc-interface/decl.c (gnat_to_gnu_entity) <E_Record_Subtype>: Remove
obsolete test on Is_For_Access_Subtype.

From-SVN: r271684

6 years agodecl.c (components_to_record): Set a name on the type created for the REP part, if...
Eric Botcazou [Tue, 28 May 2019 07:40:07 +0000 (07:40 +0000)] 
decl.c (components_to_record): Set a name on the type created for the REP part, if any.

* gcc-interface/decl.c (components_to_record): Set a name on the type
created for the REP part, if any.
* gcc-interface/utils.c (finish_record_type): Only take the maximum
when merging sizes for a variant part at offset 0.
(merge_sizes): Rename has_rep parameter into max.

From-SVN: r271682

6 years agoDaily bump.
GCC Administrator [Tue, 28 May 2019 00:16:16 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r271676

6 years agodwarf2out.c (resolve_args_picking_1): Deal with DW_OP_GNU_addr_index and DW_OP_GNU_co...
Eric Botcazou [Mon, 27 May 2019 16:12:41 +0000 (16:12 +0000)] 
dwarf2out.c (resolve_args_picking_1): Deal with DW_OP_GNU_addr_index and DW_OP_GNU_const_index opcodes.

* dwarf2out.c (resolve_args_picking_1): Deal with DW_OP_GNU_addr_index
and DW_OP_GNU_const_index opcodes.

From-SVN: r271665

6 years agotrans.c (Call_to_gnu): Do not initialize the temporary created out of addressability...
Eric Botcazou [Mon, 27 May 2019 11:44:05 +0000 (11:44 +0000)] 
trans.c (Call_to_gnu): Do not initialize the temporary created out of addressability concerns if...

* gcc-interface/trans.c (Call_to_gnu): Do not initialize the temporary
created out of addressability concerns if it's for the _Init parameter
of an initialization procedure.

From-SVN: r271660

6 years agoutils.c (maybe_pad_type): Issue the warning for the specific case of component types...
Eric Botcazou [Mon, 27 May 2019 11:12:57 +0000 (11:12 +0000)] 
utils.c (maybe_pad_type): Issue the warning for the specific case of component types preferably.

* gcc-interface/utils.c (maybe_pad_type): Issue the warning for the
specific case of component types preferably.

From-SVN: r271656

6 years agotrans.c (Identifier_to_gnu): Minor tweaks.
Eric Botcazou [Mon, 27 May 2019 11:07:05 +0000 (11:07 +0000)] 
trans.c (Identifier_to_gnu): Minor tweaks.

* gcc-interface/trans.c (Identifier_to_gnu): Minor tweaks.
(gnat_to_gnu): Do not convert the result if it is a reference to an
unconstrained array used as the prefix of an attribute reference that
requires an lvalue.

From-SVN: r271654

6 years agotrans.c (Gigi_Types_Compatible): New predicate.
Eric Botcazou [Mon, 27 May 2019 10:48:48 +0000 (10:48 +0000)] 
trans.c (Gigi_Types_Compatible): New predicate.

* gcc-interface/trans.c (Gigi_Types_Compatible): New predicate.
(Identifier_to_gnu): Use it to assert that the type of the identifier
and that of its entity are compatible for gigi.  Rename a couple of
local variables and separate the processing of the result type.

From-SVN: r271651

6 years agotrans.c (Call_to_gnu): Use the unpadded type when putting back an intermediate conver...
Eric Botcazou [Mon, 27 May 2019 10:25:17 +0000 (10:25 +0000)] 
trans.c (Call_to_gnu): Use the unpadded type when putting back an intermediate conversion the type of...

* gcc-interface/trans.c (Call_to_gnu): Use the unpadded type when
putting back an intermediate conversion the type of the actuals.

From-SVN: r271648

6 years agoDaily bump.
GCC Administrator [Mon, 27 May 2019 00:16:15 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r271643

6 years agore PR go/90635 (typo in libgo/configure.ac)
Ian Lance Taylor [Mon, 27 May 2019 00:13:52 +0000 (00:13 +0000)] 
re PR go/90635 (typo in libgo/configure.ac)

PR go/90635
    libgo: correct typo in USE_LIBFFI AM_CONDITIONAL

    Only affects the case of passing --without-libffi to configure.

    Fixes https://gcc.gnu.org/PR90635

    Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/178998

From-SVN: r271639

6 years agore PR go/90614 (gcc-9.1.0/libgo/go/syscall/wait.c:54:22: error: unused parameter...
Ian Lance Taylor [Mon, 27 May 2019 00:10:22 +0000 (00:10 +0000)] 
re PR go/90614 (gcc-9.1.0/libgo/go/syscall/wait.c:54:22: error: unused parameter ‘w’ [-Werror=unused-parameter] Continued (uint32_t *w))

PR go/90614
    syscall: avoid unused parameter error if WIFCONTINUED not defined

    Fixes https://gcc.gnu.org/PR90614

    Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/178997

From-SVN: r271637

6 years agolinux-unwind.h (pa32_fallback_frame_state): Add cast.
John David Anglin [Sun, 26 May 2019 15:19:12 +0000 (15:19 +0000)] 
linux-unwind.h (pa32_fallback_frame_state): Add cast.

* config/pa/linux-unwind.h (pa32_fallback_frame_state): Add cast.

From-SVN: r271632

6 years agoDaily bump.
GCC Administrator [Sun, 26 May 2019 00:16:12 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r271626

6 years agoPR c++/90572 - wrong disambiguation in friend declaration.
Marek Polacek [Sat, 25 May 2019 14:46:15 +0000 (14:46 +0000)] 
PR c++/90572 - wrong disambiguation in friend declaration.

* parser.c (cp_parser_constructor_declarator_p): Don't allow missing
typename for friend declarations.

* g++.dg/cpp2a/typename16.C: New test.
* g++.dg/parse/friend13.C: New test.

From-SVN: r271620

6 years agoDaily bump.
GCC Administrator [Sat, 25 May 2019 00:16:13 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r271617

6 years agore PR target/90530 (Invalid SUBREG insn generated by reload)
John David Anglin [Fri, 24 May 2019 23:15:49 +0000 (23:15 +0000)] 
re PR target/90530 (Invalid SUBREG insn generated by reload)

PR target/90530
* config/pa/pa.c (pa_can_change_mode_class): Accept mode changes from
DImode to SImode in floating-point registers on 64-bit target.
* config/pa/pa.md (umulsidi3): Change nonimmediate_operand to
register_operand in xmpyu patterns.

From-SVN: r271612

6 years agoFix std::midpoint(T*, T*) for reversed arguments
Jonathan Wakely [Fri, 24 May 2019 16:09:37 +0000 (17:09 +0100)] 
Fix std::midpoint(T*, T*) for reversed arguments

Backport from mainline
2019-05-24  Jonathan Wakely  <jwakely@redhat.com>

* include/std/numeric (midpoint(T*, T*)): Fix incorrect result.
* testsuite/26_numerics/midpoint/pointer.cc: Change "compile" test
to "run".

From-SVN: r271609

6 years agoFix uses of non-reserved names for template parameters
Jonathan Wakely [Fri, 24 May 2019 16:09:33 +0000 (17:09 +0100)] 
Fix uses of non-reserved names for template parameters

Backport from mainline
2019-05-17  Jonathan Wakely  <jwakely@redhat.com>

* include/bits/random.h (seed_seq::param): Fix non-reserved name.
* include/experimental/type_traits (is_detected_exact)
(is_detected_exact_v): Likewise.
* include/pstl/execution_defs.h (is_execution_policy)
(is_execution_policy_v, __enable_if_execution_policy): Likewise.
* include/pstl/execution_impl.h (__policy_traits): Likewise.
* testsuite/17_intro/names.cc: Check for more non-reserved names.
* testsuite/experimental/names.cc: New test.

From-SVN: r271608

6 years agoPR libstdc++/85965 move is_invocable assertions again
Jonathan Wakely [Fri, 24 May 2019 16:09:28 +0000 (17:09 +0100)] 
PR libstdc++/85965 move is_invocable assertions again

This is another attempt to reduce how often the assertions are
evaluated, so that code which doesn't try to use the function objects
doesn't need them to be invocable.

For _Rb_tree we access the _M_key_compare object directly, so can't put
the assertions in an accessor function for it. However, every invocation
of _M_key_compare is accompanied by a use of _S_key, so the assertions
can be put in there.  For _Hashtable there are member functions that are
consistently used to obtain a hash code or test for equality, so the
assertions can go in those members.

Backport from mainline
2019-05-17  Jonathan Wakely  <jwakely@redhat.com>

PR libstdc++/85965
* include/bits/hashtable.h (_Hashtable::~_Hashtable()): Remove static
assertions from the destructor.
* include/bits/hashtable_policy.h (_Hash_code_base::_M_hash_code):
Move static_assert for hash function to here.
(_Hash_table_base::_M_equals): Move static_assert for equality
predicate to here.
* include/bits/stl_tree.h (_Rb_tree::_S_key(_Const_Link_type)): Move
assertions here. Access the value directly instead of calling _S_value.
(_Rb_tree::_S_key(_Const_Base_ptr)): Do downcast and forward to
_S_key(_Const_Link_type).
* testsuite/23_containers/set/85965.cc: Check construction,
destruction, assignment and size() do not trigger the assertions.
* testsuite/23_containers/unordered_set/85965.cc: Likewise.
* testsuite/23_containers/map/48101_neg.cc: Call find and adjust
expected errors.
* testsuite/23_containers/multimap/48101_neg.cc: Likewise.
* testsuite/23_containers/multiset/48101_neg.cc: Likewise.
* testsuite/23_containers/set/48101_neg.cc: Likewise.
* testsuite/23_containers/unordered_map/48101_neg.cc: Likewise.
* testsuite/23_containers/unordered_multimap/48101_neg.cc: Likewise.
* testsuite/23_containers/unordered_multiset/48101_neg.cc: Likewise.
* testsuite/23_containers/unordered_set/48101_neg.cc: Likewise.

From-SVN: r271607

6 years agoBackport r271548
Martin Liska [Fri, 24 May 2019 07:43:48 +0000 (09:43 +0200)] 
Backport r271548

2019-05-24  Martin Liska  <mliska@suse.cz>

Backport from mainline
2019-05-23  Martin Liska  <mliska@suse.cz>

PR sanitizer/90570
* gimplify.c (gimplify_target_expr): Skip TREE_STATIC target
expression similarly to gimplify_decl_expr.
2019-05-24  Martin Liska  <mliska@suse.cz>

Backport from mainline
2019-05-23  Martin Liska  <mliska@suse.cz>

PR sanitizer/90570
* g++.dg/asan/pr90570.C: New test.

From-SVN: r271593

6 years agoDaily bump.
GCC Administrator [Fri, 24 May 2019 00:16:21 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r271587

6 years agoMake any_cast compare typeinfo as well as function pointers
Jonathan Wakely [Thu, 23 May 2019 14:18:18 +0000 (15:18 +0100)] 
Make any_cast compare typeinfo as well as function pointers

It's possible for the function pointer comparison to fail even though
the type is correct, because the function could be defined multiple
times with different addresses when shared libraries are in use.

Retain the function pointer check for the common case where the check
succeeds, but compare typeinfo (if RTTI is enabled) if the first check
fails.

Backport from mainline
2019-05-23  Jonathan Wakely  <jwakely@redhat.com>

* include/experimental/any (__any_caster): Use RTTI if comparing
addresses fails, to support non-unique addresses in shared libraries.
* include/std/any (__any_caster): Likewise.
* testsuite/experimental/any/misc/any_cast_neg.cc: Use 0 for dg-error
line number.

From-SVN: r271559

6 years agoPR libstdc++/90220 fix experimental::any_cast for non-object types
Jonathan Wakely [Thu, 23 May 2019 14:18:13 +0000 (15:18 +0100)] 
PR libstdc++/90220 fix experimental::any_cast for non-object types

This corresponds to the fixes done for std::any_cast, but has to be done
without if-constexpr. The dummy specialization of _Manager_internal<_Op>
is used to avoid instantiating the real _Manager_internal<T>::_S_manage
function just to compare its address.

Backport from mainline
2019-05-23  Jonathan Wakely  <jwakely@redhat.com>

PR libstdc++/90220
* include/experimental/any (__any_caster): Constrain to only be
callable for object types. Use remove_cv_t instead of decay_t.
If the type decays or isn't copy constructible, compare the manager
function to a dummy specialization.
(__any_caster): Add overload constrained for non-object types.
(any::_Manager_internal<_Op>): Add dummy specialization.
* testsuite/experimental/any/misc/any_cast.cc: Test function types
and array types.

From-SVN: r271558

6 years ago* c-ada-spec.c (compare_node): Compare the DECL_UIDs as a last resort.
Eric Botcazou [Thu, 23 May 2019 10:35:30 +0000 (10:35 +0000)] 
* c-ada-spec.c (compare_node): Compare the DECL_UIDs as a last resort.

From-SVN: r271550

6 years ago* gnat.dg/opt78.ad[sb]: New test.
Eric Botcazou [Thu, 23 May 2019 09:50:21 +0000 (09:50 +0000)] 
* gnat.dg/opt78.ad[sb]: New test.

From-SVN: r271546

6 years agoDaily bump.
GCC Administrator [Thu, 23 May 2019 00:16:14 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r271533

6 years agoPR libstdc++/90557 fix path assignment that alters source
Jonathan Wakely [Wed, 22 May 2019 22:36:21 +0000 (23:36 +0100)] 
PR libstdc++/90557 fix path assignment that alters source

Backport from mainline
2019-05-22  Jonathan Wakely  <jwakely@redhat.com>

PR libstdc++/90557
* src/c++17/fs_path.cc (path::_List::operator=(const _List&)): Fix
reversed arguments to uninitialized_copy_n.
* testsuite/27_io/filesystem/path/assign/copy.cc: Check that source
is unchanged by copy assignment.
* testsuite/util/testsuite_fs.h (compare_paths): Use std::equal to
compare path components.

From-SVN: r271528

6 years agobackport: re PR target/90547 (ICE in gen_lowpart_general, at rtlhooks.c:63)
Uros Bizjak [Wed, 22 May 2019 18:49:22 +0000 (20:49 +0200)] 
backport: re PR target/90547 (ICE in gen_lowpart_general, at rtlhooks.c:63)

Backported from mainline
2019-05-21  Uroš Bizjak  <ubizjak@gmail.com>

* config/i386/cpuid.h (__cpuid): For 32bit targets, zero
%ebx and %ecx bafore calling cpuid with leaf 1 or
non-constant leaf argument.

2019-05-21  Uroš Bizjak  <ubizjak@gmail.com>

PR target/90547
* config/i386/i386.md (anddi_1 to andsi_1_zext splitter):
Avoid calling gen_lowpart with CONST operand.

testsuite/ChangeLog:

Backported from mainline
2019-05-21  Uroš Bizjak  <ubizjak@gmail.com>

PR target/90547
* gcc.target/i386/pr90547.c: New test.

From-SVN: r271516

6 years agoDaily bump.
GCC Administrator [Wed, 22 May 2019 00:16:18 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r271495

6 years agolibfortran/90038: Document new wait=.false. implementation
Janne Blomqvist [Tue, 21 May 2019 15:24:30 +0000 (18:24 +0300)] 
libfortran/90038: Document new wait=.false. implementation

2019-05-21  Janne Blomqvist  <jb@gcc.gnu.org>

       PR libfortran/90038
       * intrinsic.texi (EXECUTE_COMMAND_LINE): Explain new
       wait=.false. implementation.

From-SVN: r271470

6 years ago[RTEMS] Change multilibs for ARM
Sebastian Huber [Tue, 21 May 2019 04:41:23 +0000 (04:41 +0000)] 
[RTEMS] Change multilibs for ARM

Account for Cortex-M3 Errata 602117.  The -mfix-cortex-m3-ldrd option is
enabled by default, if -mcpu=cortex-m3 is used.

gcc/

* config/arm/t-rtems: Replace ARMv7-M multilibs with Cortex-M
multilibs.

From-SVN: r271452

6 years agoDaily bump.
GCC Administrator [Tue, 21 May 2019 00:16:12 +0000 (00:16 +0000)] 
Daily bump.

From-SVN: r271448