2018-06-25 Richard Biener <rguenther@suse.de>
PR tree-optimization/86304
* tree-vectorizer.c (vectorize_loops): Walk over new possibly
epilogue-if-converted loops as well.
From-SVN: r262017
PR target/84786
* config/i386/sse.md (vshift_count): New mode attr.
(<shift_insn><mode>3<mask_name>): Use <vshift_count>N instead of vN
as last operand's constraint for VI2_AVX2_AVX512BW shifts. Use YvN
instead of vN as last operand's constraint for VI48_AVX2 shifts.
* gcc.target/i386/avx512f-pr84786-3.c: New test.
From-SVN: r262015
2018-06-25 Richard Biener <rguenther@suse.de>
* tree-vect-data-refs.c (vect_find_stmt_data_reference): Modify
DR for SIMD lane accesses here and mark DR with (void *)-1 aux.
(vect_analyze_data_refs): Remove similar code from here and
simplify accordingly.
From-SVN: r262008
2018-06-25 Richard Biener <rguenther@suse.de>
Eric Botcazou <ebotcazou@libertysurf.fr>
* tree-vect-data-refs.c (vect_check_gather_scatter): Fail
for reverse storage order accesses rather than asserting
they cannot happen here.
* gnat.dg/sso9.adb: New testcase.
* gnat.dg/sso9_pkg.ads: Likewise.
From-SVN: r262007
2018-06-25 Tom de Vries <tdevries@suse.de>
PR debug/86257
* config/i386/i386.md (define_insn "*tls_global_dynamic_64_<mode>"):
Use data16 instead of .byte for insn prefix.
* gcc.target/i386/pr86257.c: New test.
From-SVN: r262006
When turning a user-defined numerical literal into an operator
invocation the literal needs to be translated to the execution
character set.
gcc/cp/ChangeLog:
2018-06-25 Andreas Krebbel <krebbel@linux.ibm.com>
PR C++/86082
* parser.c (make_char_string_pack): Pass this literal chars
through cpp_interpret_string.
(cp_parser_userdef_numeric_literal): Check the result of
make_char_string_pack.
gcc/testsuite/ChangeLog:
2018-06-25 Andreas Krebbel <krebbel@linux.ibm.com>
PR C++/86082
* g++.dg/pr86082.C: New test.
From-SVN: r262003
* lto-streamer-out.c (tree_is_indexable): Make LABEL_DECL nonindexable
unless it is forced or nonlocal; assert that we stream no IMPORTED_DECL.
From-SVN: r261995
2018-06-24 Tom de Vries <tdevries@suse.de>
* g++.dg/guality/guality.exp: Don't use which on gdb arg to report_gdb.
* gcc.dg/guality/guality.exp: Same.
* gfortran.dg/guality/guality.exp: Same.
* lib/gcc-gdb-test.exp: Do early out if which gdb fails.
From-SVN: r261988
/cp
2018-06-23 Paolo Carlini <paolo.carlini@oracle.com>
* decl.c (bad_specifiers): Add const location_t* parameter and
use locations in error messages about 'inline' and 'virtual'.
(mark_inline_variable): Add location_t parameter and use it in
error_at and pedwarn messages.
(grokdeclarator): Use declspecs->locations[ds_constexpr],
declspecs->locations[ds_concept], declspecs->locations[ds_virtual],
declspecs->locations[ds_inline] in many error messages; adjust
bad_specifiers and mark_inline_variable calls.
(grokvardecl): Use declspecs->locations[ds_concept] in error message.
/testsuite
2018-06-23 Paolo Carlini <paolo.carlini@oracle.com>
* g++.dg/concepts/locations1.C: New.
* g++.dg/cpp0x/locations1.C: Likewise.
* g++.dg/cpp1z/inline-var2.C: Test locations too.
* g++.dg/cpp1z/inline-var3.C: Likewise.
From-SVN: r261982
USING_SPLIT_STACK is configured as defined/undefined, not 0/1.
Most of the places test USING_SPLIT_STACK with #ifdef, with a
few exceptions. This CL fixes the exceptions.
Reviewed-on: https://go-review.googlesource.com/120596
From-SVN: r261980
2018-06-22 Paul Thomas <pault@gcc.gnu.org>
Rainer Orth <ro@gcc.gnu.org>
PR fortran/86281
* resolve.c (resolve_contained_fntype): Check for the charlen
before testing the length.
2018-06-22 Paul Thomas <pault@gcc.gnu.org>
PR fortran/86281
* gfortran.dg/assumed_charlen_function_7.f90: Add -std=legacy.
Co-Authored-By: Rainer Orth <ro@gcc.gnu.org>
From-SVN: r261975
* constexpr.c (fold_non_dependent_expr): Add complain parm.
* call.c, expr.c, init.c, pt.c, semantics.c, typeck.c, typeck2.c:
Pass it.
* call.c (build_cxx_call): Don't mess with builtins in a template.
* typeck2.c (store_init_value): If fold_non_dependent_expr didn't
produce a constant value, go back to the uninstantiated form.
From-SVN: r261972
* constexpr.c (same_type_ignoring_tlq_and_bounds_p): New.
(cxx_fold_indirect_ref): Use it.
(cxx_eval_constant_expression) [VIEW_CONVERT_EXPR]: Use it.
* cp-tree.h (REF_PARENTHESIZED_P): Allow VIEW_CONVERT_EXPR.
* semantics.c (force_paren_expr): Use VIEW_CONVERT_EXPR instead of
static_cast to reference type.
(maybe_undo_parenthesized_ref): Handle VIEW_CONVERT_EXPR.
From-SVN: r261971
2018-06-22 Tom de Vries <tdevries@suse.de>
* lib/gcc-gdb-test.exp (report_gdb): New proc.
* g++.dg/guality/guality.exp: Use report_gdb.
* gcc.dg/guality/guality.exp: Same.
* gfortran.dg/guality/guality.exp: Same.
From-SVN: r261911
2018-06-22 Olivier Hainque <hainque@adacore.com>
* gimplify.c (gimplify_function_tree): Prevent creation
of a trampoline for the address of the current function
passed to entry/exit instrumentation hooks.
From-SVN: r261908
gcc/testsuite/ChangeLog:
2018-06-22 Carl Love <cel@us.ibm.com>
* gcc.target/powerpc/altivec-7.c: Add qualifiers for counts on AIX
versus Linux. Change checks for xxlnor, xxland and xxlxor to also look
for the vnor, vand and vxor instructions.
* gcc.target/powerpc/builtins-1.c: Move vec_or tests to a new file.
Remove counts for xxlor. Fix match on bl __divdi3 and bl __udivdi3.
* gcc.target/powerpc/builtins-4.c: Fix matching for vsl instructions.
* gcc.target/powerpc/builtins-5.c: New test file for vec_or test cases.
* gcc.target/powerpc/vsx-vector-6.p7.c: Fix xxlnor BE expected count.
Add -dp to dg-options, update expected counts.
From-SVN: r261904
PR libstdc++/86280
* include/experimental/memory_resource
(__resource_adaptor_common::_AlignMgr::_M_token_size): Use type large
enough for result of left shift.
From-SVN: r261888
2018-06-22 Martin Liska <mliska@suse.cz>
PR tree-optimization/86263
* tree-switch-conversion.c (jump_table_cluster::find_jump_tables):
Bail out if is_enabled is false.
* tree-switch-conversion.h (jump_table_cluster::is_enabled):
New declaration.
(jump_table_cluster::is_enabled): New function.
From-SVN: r261886
2018-06-22 Martin Liska <mliska@suse.cz>
* symbol-summary.h (get): Make it pure and inline move
functionality from ::get function.
(get): Remove and inline into ::get and ::get_create.
(get_create): Move code from ::get function.
From-SVN: r261882
The explicit instantiation declarations for std::basic_string are
disabled for C++17 (and later) so that basic_string symbols get
implicitly instantiated in every translation unit that needs them. On
targets that don't support STB_GNU_UNIQUE this leads to multiple copies
of the empty rep symbol for COW strings. In order to detect whether a
COW string needs to deallocate its storage it compares the address with
the empty rep. When there are multiple copies of the empty rep object
the address is not unique, and so string destructors try to delete the
empty rep, which crashes.
In order to guarantee uniqueness of the _S_empty_rep_storage symbol this
patch adds an explicit instantiation declaration for just that symbol.
This means the other symbols are still implicitly instantiated in C++17
code, but for the empty rep the definition in the library gets used.
Separately, there is no need for C++17 code to implicitly instantiate
the I/O functions for strings, so this also restores the explicit
instantiation declarations for those functions.
PR libstdc++/86138
* include/bits/basic_string.tcc:
[__cplusplus > 201402 && !_GLIBCXX_USE_CXX11_ABI]
(basic_string<char>::_Rep::_S_empty_rep_storage)
(basic_string<wchar_t>::_Rep::_S_empty_rep_storage): Add explicit
instantiation declarations.
[__cplusplus > 201402] (operator>>, operator<<, getline): Re-enable
explicit instantiation declarations.
* testsuite/21_strings/basic_string/cons/char/86138.cc: New.
* testsuite/21_strings/basic_string/cons/wchar_t/86138.cc: New.
From-SVN: r261873
2018-06-21 Michael Meissner <meissner@linux.ibm.com>
* gcc.target/powerpc/pack02.c: Use __ibm128 instead of long double
if the long double format is IEEE 128-bit for tests that are
explicitly testing IBM extended double support. Use the
appropriate pack and unpack built-in functions. Change calls from
__builtin_isinfl to __builtin_isinf since the later supports all
floating point types.
* gcc.target/powerpc/pr57150.c: Likewise.
* gcc.target/powerpc/pr60203.c: Likewise.
* gcc.target/powerpc/pr67808.c: Likewise.
* gcc.target/powerpc/pr70117.c: Likewise.
* gcc.target/powerpc/tfmode_off.c: Likewise.
From-SVN: r261872
2018-06-23 Michael Meissner <meissner@linux.ibm.com>
* config/rs6000/rs6000.c (init_float128_ieee): Prevent complex
multiply and divide external functions from being created more
than once.
From-SVN: r261870
2018-06-21 Michael Meissner <meissner@linux.ibm.com>
* config/rs6000/rs6000.md (neg<mode>2_internal): Use the correct
mode to check whether the mode is IBM extended.
From-SVN: r261869