1. 08 Mar, 2019 1 commit
  2. 07 Mar, 2019 22 commits
  3. 06 Mar, 2019 17 commits
    • re PR fortran/71203 (ICE in add_init_expr_to_sym, at fortran/decl.c:1512 and :1564) · a28a8193
      2019-03-06  Harald Anlauf  <anlauf@gmx.de>
      
      	PR fortran/71203
      	* expr.c (simplify_const_ref): Avoid null pointer dereference.
      
      	PR fortran/71203
      	* gfortran.dg/substr_8.f90: New test.
      
      From-SVN: r269444
      Harald Anlauf committed
    • compiler: emit underlying constant in array_type length export · 1c98301f
          
          In Array_type::do_export, when emitting a concrete array length,
          evaluate the length expression to an integer constant and emit that
          constant, instead of calling the more general method for emitting
          expressions. This is to avoid the possibility that we will need
          to emit a conversion, which could confuse the gccgoimporter.
          
          Fixes golang/go#30628.
          
          Reviewed-on: https://go-review.googlesource.com/c/gofrontend/+/165741
      
      From-SVN: r269443
      Ian Lance Taylor committed
    • PR c++/89381 - implicit copy and using-declaration. · 2de5d0ea
      Here the used base<int>::operator= gets into the list of foo's bindings for
      operator=, but it shouldn't make the copy ctor deleted.
      
      	* class.c (classtype_has_move_assign_or_move_ctor_p): Don't consider
      	op= brought in by a using-declaration.
      
      From-SVN: r269442
      Jason Merrill committed
    • re PR c++/87148 (backward compatibility issue to take char [] as incomplete type) · 71b6cb2b
      	PR c++/87148
      	* init.c (build_value_init_noctor): Ignore flexible array members.
      
      	* g++.dg/ext/flexary34.C: New test.
      
      From-SVN: r269434
      Jakub Jelinek committed
    • PR c++/89576 - if constexpr of lambda capture. · 4556c5b3
      Now that we're doing implicit lambda capture in templates, we see x here as
      the lambda capture.  maybe_convert_cond was doing nothing in a template, so
      we never called mark_rvalue_use on x.  As part of the broad move toward
      doing more processing of non-dependent expressions, let's do this
      conversion.
      
      	* semantics.c (maybe_convert_cond): Do convert a non-dependent
      	condition in a template.
      	* typeck.c (condition_conversion): Handle being called in a
      	template.
      
      From-SVN: r269433
      Jason Merrill committed
    • encoding.c (DFmode): #undef before #define. · d135eeb2
      	* encoding.c (DFmode): #undef before #define.
      
      From-SVN: r269429
      Uros Bizjak committed
    • re PR rtl-optimization/88845 (ICE in lra_set_insn_recog_data, at lra.c:1010) · 2713e5db
      gcc/
      	PR rtl-optimization/88845
      	* config/rs6000/rs6000.c (rs6000_emit_move_si_sf_subreg): Enable during
      	LRA.
      	* lra.c (remove_scratches_1): New function.
      	(remove_scratches): Use it.
      	(lra_emit_move): Likewise.
      
      gcc/testsuite/
      	PR rtl-optimization/88845
      	* gcc.target/powerpc/pr88845.c: New test.
      
      From-SVN: r269428
      Peter Bergner committed
    • PR c++/87378 - bogus -Wredundant-move warning. · ec2de569
      	* typeck.c (maybe_warn_pessimizing_move): See if the maybe-rvalue
      	overload resolution would actually succeed.
      
      	* g++.dg/cpp0x/Wredundant-move1.C (fn4): Drop dg-warning.
      	* g++.dg/cpp0x/Wredundant-move7.C: New test.
      
      From-SVN: r269427
      Marek Polacek committed
    • Add feature test macro for bounded array traits · 46610940
      	* include/std/type_traits (__cpp_lib_bounded_array_traits): Define.
      	* include/std/version (__cpp_lib_bounded_array_traits): Likewise.
      	* testsuite/20_util/is_bounded_array/value.cc: Check for macro.
      	* testsuite/20_util/is_unbounded_array/value.cc: Likewise.
      
      From-SVN: r269426
      Jonathan Wakely committed
    • PR libstdc++/86655 - std::assoc_legendre should not constrain · f29a1ef2
      2019-03-06  Edward Smith-Rowland  <3dw4rd@verizon.net>
      
      	PR libstdc++/86655 - std::assoc_legendre should not constrain
      	the value of m (or x).
      	* include/tr1/legendre_function.tcc (__assoc_legendre_p,
      	__sph_legendre): If degree > order Don't throw, return 0.
      	(__legendre_p, __assoc_legendre_p): Don't constrain x either.
      	* testsuite/special_functions/02_assoc_legendre/pr86655.cc: New test.
      	* testsuite/special_functions/20_sph_legendre/pr86655.cc: New test.
      	* testsuite/tr1/5_numerical_facilities/special_functions/
      	02_assoc_legendre/pr86655.cc: New test.
      	* testsuite/tr1/5_numerical_facilities/special_functions/
      	22_sph_legendre/pr86655.cc: New test.
      
      From-SVN: r269423
      Edward Smith-Rowland committed
    • Rewrite variant, also PR libstdc++/85517 · 669a6fdc
      * include/std/variant (__do_visit): New.
      (__variant_cast): Likewise.
      (__variant_cookie): Likewise.
      (__erased_*): Remove.
      (_Variant_storage::_S_vtable): Likewise.
      (_Variant_storage::__M_reset_impl): Adjust to use __do_visit.
      (_Variant_storage::__M_reset): Adjust.
      (__variant_construct): New.
      (_Copy_ctor_base(const _Copy_ctor_base&)): Adjust to use
      __variant_construct.
      (_Move_ctor_base(_Move_ctor_base&&)): Likewise.
      (_Move_ctor_base::__M_destructive_copy): New.
      (_Move_ctor_base::__M_destructive_move): Adjust to use
      __variant_construct.
      (_Copy_assign_base::operator=): Adjust to use __do_visit.
      (_Copy_assign_alias): Adjust to check both copy assignment
      and copy construction for triviality.
      (_Move_assign_base::operator=): Adjust to use __do_visit.
      (_Multi_array): Add support for visitors that accept and return
      a __variant_cookie.
      (__gen_vtable_impl::_S_apply_all_alts): Likewise.
      (__gen_vtable_impl::_S_apply_single_alt): Likewise.
      (__gen_vtable_impl::__element_by_index_or_cookie): New. Generate
      a __variant_cookie temporary for a variant that is valueless and..
      (__gen_vtable_impl::__visit_invoke): ..adjust here.
      (__gen_vtable::_Array_type): Conditionally make space for
      the __variant_cookie visitor case.
      (__variant_construct_by_index): New.
      (get_if): Adjust to use std::addressof.
      (relops): Adjust to use __do_visit.
      (variant): Add __variant_cast and __variant_construct_by_index
      as friends.
      (variant::emplace): Use _M_reset() and __variant_construct_by_index
      instead of self-destruction.
      (variant::swap): Adjust to use __do_visit.
      (visit): Reimplement in terms of __do_visit.
      (__variant_hash_call_base_impl::operator()): Adjust to use __do_visit.
      * testsuite/20_util/variant/compile.cc: Adjust.
      * testsuite/20_util/variant/run.cc: Likewise.
      
      From-SVN: r269422
      Ville Voutilainen committed
    • Add L suffix to __cpp_lib_char8_t value · 99447f70
      	* include/bits/c++config.h (_cpp_lib_char8_t): Add L suffix to
      	constant.
      	* testsuite/experimental/feat-char8_t.cc: Likewise.
      
      From-SVN: r269421
      Jonathan Wakely committed
    • Add C++20 Traits for [Un]bounded Arrays (P1357R1) · 28d85efb
      	 * include/std/type_traits [C++20] (is_bounded_array)
      	 (is_unbounded_array, is_bounded_array_v, is_unbounded_array_v):
      	 Define.
      	 * testsuite/20_util/is_bounded_array/requirements/
      	 explicit_instantiation.cc: New test.
      	 * testsuite/20_util/is_bounded_array/requirements/typedefs.cc: New
      	 test.
      	 * testsuite/20_util/is_bounded_array/value.cc: New test.
      	 * testsuite/20_util/is_unbounded_array/requirements/
      	 explicit_instantiation.cc: New test.
      	 * testsuite/20_util/is_unbounded_array/requirements/typedefs.cc: New
      	 * test.
      	 * testsuite/20_util/is_unbounded_array/value.cc: New test.
      
      From-SVN: r269420
      Jonathan Wakely committed
    • Charry pick libsanitizer r355488 (PR sanitizer/88684). · c24847a5
      2019-03-06  Martin Liska  <mliska@suse.cz>
      
      	PR sanitizer/88684
      	* sanitizer_common/sanitizer_platform.h (defined): Cherry pick.
      	(SANITIZER_NON_UNIQUE_TYPEINFO): Likewise.
      	* ubsan/ubsan_type_hash_itanium.cc (isDerivedFromAtOffset):
      	Likewise.
      
      From-SVN: r269419
      Martin Liska committed
    • Constexpr in std::pointer_traits (P1006R1) · d80f04d6
      	* include/bits/ptr_traits.h [C++20] (pointer_traits<T*>::pointer_to):
      	Add constexpr.
      	* testsuite/20_util/pointer_traits/pointer_to_constexpr.cc: New test.
      
      From-SVN: r269418
      Jonathan Wakely committed
    • [ARC] Fix logic set UNALIGNED_ACCESS · 9f54ba8f
      gcc/
      xxxx-xx-xx  Claudiu Zissulescu  <claziss@synopsys.com>
      
      	* config/arc/arc-c.def (__ARC_UNALIGNED__): Set it on
      	unaligned_access variable.
      	* config/arc/arc.c (arc_override_options): Set unaligned access
      	default on for HS CPUs.
      	* config/arc/arc.h (STRICT_ALIGNMENT): Fix logic.
      
      From-SVN: r269417
      Claudiu Zissulescu committed