Steven G. Kargl [Fri, 23 Feb 2018 18:59:38 +0000 (18:59 +0000)]
re PR fortran/84511 (Internal compiler error from directly printing return of C_LOC)
2018-02-23 Steven G. Kargl <kargl@gcc.gnu.org>
PR fortran/84511
* trans-io.c (transfer_expr): Deal with C_LOC in transfer statement.
From-SVN: r257943
Steven G. Kargl [Fri, 23 Feb 2018 18:57:41 +0000 (18:57 +0000)]
re PR fortran/84346 (Statement functions should not accept keywords)
2018-02-23 Steven G. Kargl <kargl@gcc.gnu.org>
PR fortran/84346
* interface.c (compare_actual_formal): Issue error if keyword is
used in a statement function.
2018-02-23 Steven G. Kargl <kargl@gcc.gnu.org>
PR fortran/84346
* gfortran.dg/statement_function_1.f90: Update test.
From-SVN: r257942
Jerry DeLisle [Fri, 23 Feb 2018 18:40:14 +0000 (18:40 +0000)]
re PR fortran/84506 (INQUIRE(pos=) always sets pos=0 with -fdefault-integer-8)
2018-02-23 Jerry DeLisle <jvdelisle@gcc.gnu.org>
PR fortran/84506
* trans-io.c (set_parameter_value_inquire): Adjust range check of
negative unit values for kind=8 units to the kind=4 negative limit.
* gfortran.dg/inquire_19.f90: New test.
From-SVN: r257941
Jakub Jelinek [Fri, 23 Feb 2018 18:27:28 +0000 (19:27 +0100)]
ipa-prop.c (ipa_vr_ggc_hash_traits::hash): Hash p->min and p->max as pointers rather than using iterative_hash_expr.
* ipa-prop.c (ipa_vr_ggc_hash_traits::hash): Hash p->min and
p->max as pointers rather than using iterative_hash_expr.
From-SVN: r257940
Jan Hubicka [Fri, 23 Feb 2018 18:18:07 +0000 (19:18 +0100)]
* lto-partition.c (lto_balanced_map): Watch overflow.
From-SVN: r257939
Paul Thomas [Fri, 23 Feb 2018 17:55:13 +0000 (17:55 +0000)]
re PR fortran/83149 ([6- and 7-branches] Missing test for sym->ns->proc_name: crash_signal in toplev.c:325)
2018-02-23 Paul Thomas <pault@gcc.gnu.org>
PR fortran/83149
* trans-types.c (gfc_sym_type): Test sym->ns->proc_name before
accessing its components.
2018-02-23 Paul Thomas <pault@gcc.gnu.org>
PR fortran/83149
* gfortran.dg/pr83149_b.f90: New test.
* gfortran.dg/pr83149_a.f90: Additional source for previous.
From-SVN: r257938
Carl Love [Fri, 23 Feb 2018 17:22:10 +0000 (17:22 +0000)]
rs6000-builtin.def: Change VSIGNED2 and VUNSIGNED2 macro expansions from BU_VSX_2 to BU_P8V_VSX_2...
gcc/ChangeLog:
2018-02-23 Carl Love <cel@us.ibm.com>
* config/rs6000/rs6000-builtin.def: Change VSIGNED2 and VUNSIGNED2
macro expansions from BU_VSX_2 to BU_P8V_VSX_2 and BU_VSX_OVERLOAD_2 to
BU_P8V_OVERLOAD_2.
* config/rs6000/rs6000-c.c: Change VSX_BUILTIN_VEC_VSIGNED2 to
P8V_BUILTIN_VEC_VSIGNED2. Change VSX_BUILTIN_VEC_VUNSIGNED2 to
P8V_BUILTIN_VEC_VUNSIGNED2.
gcc/testsuite/ChangeLog:
2018-02-23 Carl Love <cel@us.ibm.com>
* gcc.target/powerpc/builtins-3-runnable.c: Move tests for vec_float2,
vec_signed2 and vec_unsigned2 to new Power 8 test file.
* gcc.target/powerpc/builtins-3-runnable-p8.c: New test file for
Power 8 tests.
From-SVN: r257937
Will Schmidt [Fri, 23 Feb 2018 16:50:58 +0000 (16:50 +0000)]
pr80695-p8.c: Update dg-requires stanza.
[testsuite]
2018-02-23 Will Schmidt <will_schmidt@vnet.ibm.com>
* gcc.target/powerpc/pr80695-p8.c: Update dg-requires stanza.
* gcc.target/powerpc/pr80695-p9.c: Update dg-requires stanza.
From-SVN: r257936
Will Schmidt [Fri, 23 Feb 2018 16:46:00 +0000 (16:46 +0000)]
[testsuite]
2018-02-23 Will Schmidt <will_schmidt@vnet.ibm.com>
* fold-vec-mult-int128-p9.c: Add maddld insn to expected output.
From-SVN: r257935
Paul Thomas [Fri, 23 Feb 2018 16:22:28 +0000 (16:22 +0000)]
re PR fortran/83149 ([6- and 7-branches] Missing test for sym->ns->proc_name: crash_signal in toplev.c:325)
2018-02-23 Paul Thomas <pault@gcc.gnu.org>
PR fortran/83149
* trans-decl.c (gfc_finish_var_decl): Test sym->ns->proc_name
before accessing its components.
2018-02-23 Paul Thomas <pault@gcc.gnu.org>
PR fortran/83149
* gfortran.dg/pr83149_1.f90: New test.
* gfortran.dg/pr83149.f90: Additional source for previous.
From-SVN: r257934
Segher Boessenkool [Fri, 23 Feb 2018 14:17:35 +0000 (15:17 +0100)]
Fix tsan race_on_mutex.c testcase (PR80551)
The testcase did not match the glibc internal names while it should.
This fixes it.
gcc/testsuite/
PR testsuite/80551
* c-c++-common/tsan/race_on_mutex.c: Change regexp to allow
__GI___pthread_mutex_init as well.
From-SVN: r257932
Jason Merrill [Fri, 23 Feb 2018 13:32:41 +0000 (08:32 -0500)]
PR c++/70468 - ICE with constructor delegation via typedef.
* pt.c (tsubst_initializer_list): Check for other mem-initializers
with constructor delegation.
From-SVN: r257931
Paul Thomas [Fri, 23 Feb 2018 12:35:30 +0000 (12:35 +0000)]
re PR fortran/83148 (ICE: crash_signal from toplev.c:325)
2018-02-23 Paul Thomas <pault@gcc.gnu.org>
PR fortran/83148
* trans-const.c : Clean up some whitespace issues.
* trans-expr.c (gfc_conv_initializer): If an iso_c_binding
derived type has a kind value of zero, set it to the default
integer kind.
2018-02-23 Paul Thomas <pault@gcc.gnu.org>
PR fortran/83148
* gfortran.dg/class_68.f90: New test.
From-SVN: r257930
Janne Blomqvist [Fri, 23 Feb 2018 09:33:27 +0000 (11:33 +0200)]
ChangeLog entry for r257928
From-SVN: r257929
Janne Blomqvist [Fri, 23 Feb 2018 09:07:24 +0000 (11:07 +0200)]
PR 84519 Handle optional QUIET specifier for STOP and ERROR STOP
Fortran 2018 adds a new QUIET specifier for the STOP and ERROR STOP
statements, in order to suppress the printing of signaling FP
exceptions and the stop code. This patch adds the necessary library
changes, but for now the new specifier is not parsed and the frontend
unconditionally adds a false value for the new argument.
Regtested on x86_64-pc-linux-gnu.
gcc/fortran/ChangeLog:
2018-02-23 Janne Blomqvist <jb@gcc.gnu.org>
PR fortran/84519
* trans-decl.c (gfc_build_builtin_function_decls): Add bool
argument to stop and error stop decls.
* trans-stmt.c (gfc_trans_stop): Add false value to argument
lists.
libgfortran/ChangeLog:
2018-02-23 Janne Blomqvist <jb@gcc.gnu.org>
PR fortran/84519
* caf/libcaf.h (_gfortran_caf_stop_numeric): Add bool argument.
(_gfortran_caf_stop_str): Likewise.
(_gfortran_caf_error_stop_str): Likewise.
(_gfortran_caf_error_stop): Likewise.
* caf/mpi.c (_gfortran_caf_error_stop_str): Handle new argument.
(_gfortran_caf_error_stop): Likewise.
* caf/single.c (_gfortran_caf_stop_numeric): Likewise.
(_gfortran_caf_stop_str): Likewise.
(_gfortran_caf_error_stop_str): Likewise.
(_gfortran_caf_error_stop): Likewise.
(_gfortran_caf_lock): Likewise.
(_gfortran_caf_unlock): Likewise.
* libgfortran.h (stop_string): Add bool argument.
* runtime/pause.c (do_pause): Add false argument.
* runtime/stop.c (stop_numeric): Handle new argument.
(stop_string): Likewise.
(error_stop_string): Likewise.
(error_stop_numeric): Likewise.
From-SVN: r257928
GCC Administrator [Fri, 23 Feb 2018 00:16:14 +0000 (00:16 +0000)]
Daily bump.
From-SVN: r257927
Jason Merrill [Thu, 22 Feb 2018 22:50:37 +0000 (17:50 -0500)]
PR c++/84424 - ICE with constexpr and __builtin_shuffle.
* constexpr.c (reduced_constant_expression_p): Handle CONSTRUCTOR of
VECTOR_TYPE.
From-SVN: r257924
Thomas Koenig [Thu, 22 Feb 2018 22:01:53 +0000 (22:01 +0000)]
re PR fortran/59781 ([F03] Incorrect initialisation of derived type)
2018-02-22 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/59781
* gfortran.dg/derived_init_5.f90: New test.
From-SVN: r257917
Jakub Jelinek [Thu, 22 Feb 2018 21:27:44 +0000 (22:27 +0100)]
re PR target/82851 (g++.dg/vect/slp-pr56812.cc, i386/avx2-vpaddq-3.c, i386/avx2-vpsubq-3.c fails)
PR target/82851
* gcc.target/i386/avx2-vpaddq-3.c: Add -mtune=generic to dg-options.
* gcc.target/i386/avx2-vpsubq-3.c: Likewise.
From-SVN: r257916
Vladimir Makarov [Thu, 22 Feb 2018 21:17:51 +0000 (21:17 +0000)]
re PR target/81572 (gcc-7 regression: unnecessary vector regmove on compare)
2018-02-22 Vladimir Makarov <vmakarov@redhat.com>
PR target/81572
* lra-int.h (LRA_UNKNOWN_ALT, LRA_NON_CLOBBERED_ALT): New macros.
* lra.c (lra_set_insn_recog_data, lra_update_insn_recog_data): Use
LRA_UNKNOWN_ALT.
* lra-constraints.c (curr_insn_transform): Set up
LRA_NON_CLOBBERED_ALT for moves processed on the fast path. Use
LRA_UNKNOWN_ALT.
(remove_inheritance_pseudos): Use LRA_UNKNOWN_ALT.
* lra-eliminations.c (spill_pseudos): Ditto.
(process_insn_for_elimination): Ditto.
* lra-lives.c (reg_early_clobber_p): Use the new macros.
* lra-spills.c (spill_pseudos): Use LRA_UNKNOWN_ALT and
LRA_NON_CLOBBERED_ALT.
2018-02-22 Vladimir Makarov <vmakarov@redhat.com>
PR target/81572
* gcc.target/powerpc/pr81572.c: New.
From-SVN: r257915
Andreas Schwab [Thu, 22 Feb 2018 19:49:04 +0000 (19:49 +0000)]
re PR go/84484 (libgo configure tests fail to find -latomic)
PR go/84484
libgo: add support for riscv64
Patch by Andreas Schwab.
Reviewed-on: https://go-review.googlesource.com/96377
* go.test/go-test.exp (go-set-goarch): Recognize riscv64-*-*.
From-SVN: r257914
Ian Lance Taylor [Thu, 22 Feb 2018 18:52:33 +0000 (18:52 +0000)]
runtime: funcfileline: get missing function name from symbol table
Copy the idea of https://golang.org/cl/92756 to funcfileline, which is
used by runtime.FuncForPC, runtime.(*Frames).Next, and others.
Reviewed-on: https://go-review.googlesource.com/96175
From-SVN: r257913
Ian Lance Taylor [Thu, 22 Feb 2018 18:49:33 +0000 (18:49 +0000)]
libgo: add -L option for libatomic when using -pthread
Fixes https://gcc.gnu.org/PR84484
Reviewed-on: https://go-review.googlesource.com/95436
From-SVN: r257911
Martin Sebor [Thu, 22 Feb 2018 17:35:29 +0000 (17:35 +0000)]
PR tree-optimization/84480 - bogus -Wstringop-truncation despite assignment with an inlined string literal
gcc/ChangeLog:
PR tree-optimization/84480
* gimple-fold.c (gimple_fold_builtin_strcpy): Move warnings
to maybe_diag_stxncpy_trunc. Call it.
* tree-ssa-strlen.c (maybe_diag_stxncpy_trunc): Integrate warnings
from gimple_fold_builtin_strcpy. Print inlining stack.
(handle_builtin_stxncpy): Print inlining stack.
* tree-ssa-strlen.h (maybe_diag_stxncpy_trunc): Declare.
gcc/testsuite/ChangeLog:
PR tree-optimization/84480
* c-c++-common/Wstringop-truncation.c: Adjust text of expected warnings.
* g++.dg/warn/Wstringop-truncation-1.C: New test.
From-SVN: r257910
H.J. Lu [Thu, 22 Feb 2018 17:09:06 +0000 (17:09 +0000)]
i386: Add __x86_indirect_thunk_nt_reg for -fcf-protection -mcet
nocf_check attribute can be used with -fcf-protection -mcet to disable
control-flow check by adding NOTRACK prefix before indirect branch.
When -mindirect-branch=thunk-extern -mindirect-branch-register is added,
indirect branch via register, "notrack call/jmp reg", is converted to
call/jmp __x86_indirect_thunk_nt_reg
When running on machines with CET enabled, __x86_indirect_thunk_nt_reg
can be updated to
notrack jmp reg
at run-time to restore NOTRACK prefix in the original indirect branch.
Since we don't support -mindirect-branch=thunk-extern, CET and MPX at
the same time, -mindirect-branch=thunk-extern is disallowed with
-fcf-protection=branch and -fcheck-pointer-bounds.
Tested on i686 and x86-64.
gcc/
PR target/84176
* config/i386/i386.c (ix86_set_indirect_branch_type): Issue an
error when -mindirect-branch=thunk-extern, -fcf-protection=branch
and -fcheck-pointer-bounds are used together.
(indirect_thunk_prefix): New enum.
(indirect_thunk_need_prefix): New function.
(indirect_thunk_name): Replace need_bnd_p with need_prefix. Use
"_nt" instead of "_bnd" for NOTRACK prefix.
(output_indirect_thunk): Replace need_bnd_p with need_prefix.
(output_indirect_thunk_function): Likewise.
(): Likewise.
(ix86_code_end): Update output_indirect_thunk_function calls.
(ix86_output_indirect_branch_via_reg): Replace
ix86_bnd_prefixed_insn_p with indirect_thunk_need_prefix.
(ix86_output_indirect_branch_via_push): Likewise.
(ix86_output_function_return): Likewise.
* doc/invoke.texi: Document -mindirect-branch=thunk-extern is
incompatible with -fcf-protection=branch and
-fcheck-pointer-bounds.
gcc/testsuite/
PR target/84176
* gcc.target/i386/indirect-thunk-11.c: New test.
* gcc.target/i386/indirect-thunk-12.c: Likewise.
* gcc.target/i386/indirect-thunk-attr-12.c: Likewise.
* gcc.target/i386/indirect-thunk-attr-13.c: Likewise.
* gcc.target/i386/indirect-thunk-attr-14.c: Likewise.
* gcc.target/i386/indirect-thunk-attr-15.c: Likewise.
* gcc.target/i386/indirect-thunk-attr-16.c: Likewise.
* gcc.target/i386/indirect-thunk-extern-10.c: Likewise.
* gcc.target/i386/indirect-thunk-extern-8.c: Likewise.
* gcc.target/i386/indirect-thunk-extern-9.c: Likewise.
From-SVN: r257909
Steve Ellcey [Thu, 22 Feb 2018 17:08:10 +0000 (17:08 +0000)]
re PR target/83335 ([aarch64,ilp32] gcc.target/aarch64/asm-2.c ICEs since 255481)
2018-02-22 Steve Ellcey <sellcey@cavium.com>
PR target/83335
* gcc/testsuite/gcc.target/aarch64/asm-2.c: Add dg-error for
ILP32 mode.
* gcc/testsuite/gcc.target/aarch64/asm-4.c: New test.
From-SVN: r257908
Steve Ellcey [Thu, 22 Feb 2018 17:06:31 +0000 (17:06 +0000)]
re PR target/83335 ([aarch64,ilp32] gcc.target/aarch64/asm-2.c ICEs since 255481)
2018-02-22 Steve Ellcey <sellcey@cavium.com>
PR target/83335
* config/aarch64/aarch64.c (aarch64_print_address_internal):
Change gcc_assert call to output_operand_lossage.
From-SVN: r257907
Steve Ellcey [Thu, 22 Feb 2018 16:49:28 +0000 (16:49 +0000)]
extend.texi (__builtin_extend_pointer): Document builtin.
2018-02-22 Steve Ellcey <sellcey@cavium.com>
* doc/extend.texi (__builtin_extend_pointer): Document builtin.
From-SVN: r257906
DJ Delorie [Thu, 22 Feb 2018 16:36:48 +0000 (11:36 -0500)]
rx.c (rx_rtx_costs): New function.
gcc/
* config/rx/rx.c (rx_rtx_costs): New function.
(TARGET_RTX_COSTS): Override to use rx_rtx_costs.
Co-Authored-By: Oleg Endo <olegendo@gcc.gnu.org>
Co-Authored-By: Sebastian Perta <sebastian.perta@renesas.com>
From-SVN: r257905
Thomas Preud'homme [Thu, 22 Feb 2018 16:31:56 +0000 (16:31 +0000)]
[ARM] Multilib mapping for Armv8-R
Due to there being no multilib mapping for Armv8-R, default multilib
builts for -march=armv4t with softfloat floating-point arithmetic is
being used. This patch maps it instead to the existing Armv7 multilibs.
Note that mapping for single-precision Armv8-R has been left out due to
there being no Arm implementation of that architecture variant.
2018-02-22 Thomas Preud'homme <thomas.preudhomme@arm.com>
gcc/
* config/arm/t-multilib: Map Armv8-R to Armv7 multilibs.
gcc/testsuite/
* gcc.target/arm/multilib.exp: Add tests for Armv8-R multilib mappings.
From-SVN: r257904
Janne Blomqvist [Thu, 22 Feb 2018 16:14:21 +0000 (18:14 +0200)]
PR 78534, 84509 Fix libgfortran API for PAUSE statement
This patch changes the libgfortran API for the PAUSE statement. By
passing a GFC_INTEGER_8 it handles -fdefault-integer-8, and for the
character version passing the length as a size_t.
Regtested on x86_64-pc-linux-gnu, committed as obvious.
gcc/fortran/ChangeLog:
2018-02-22 Janne Blomqvist <jb@gcc.gnu.org>
PR 78534
PR 84509
* trans-decl.c (gfc_build_builtin_function_decls): Pass
gfc_int8_type node to pause_numeric, size_type_node to
pause_string.
* trans-stmt.c (gfc_trans_pause): Likewise.
libgfortran/ChangeLog:
2018-02-22 Janne Blomqvist <jb@gcc.gnu.org>
PR 78534
PR 84509
* runtime/pause.c (pause_numeric): Modify to take GFC_INTEGER_8
argument.
(pause_string): Modify to take size_t character length argument.
From-SVN: r257903
David Edelsohn [Thu, 22 Feb 2018 16:12:26 +0000 (16:12 +0000)]
inclhack.def (aix_stdlib_vec_malloc): New.
* inclhack.def (aix_stdlib_vec_malloc): New.
(aix_stdlib_vec_calloc): New.
* fixincl.x: Regenerate.
* tests/base/stdlib.h [AIX_STDLIB_VEC_MALLOC]: New test.
[AIX_STDLIB_VEC_CALLOC]: New test.
From-SVN: r257902
Martin Liska [Thu, 22 Feb 2018 12:16:58 +0000 (13:16 +0100)]
Add "native" as a valid option value for -mcpu/-mtune= on arm (PR driver/83193).
2018-02-22 Martin Liska <mliska@suse.cz>
PR driver/83193
* common/config/arm/arm-common.c (arm_print_hint_for_cpu_option):
Add "native" as a possible value.
From-SVN: r257900
Marek Polacek [Thu, 22 Feb 2018 11:18:37 +0000 (11:18 +0000)]
re PR c++/84493 (ICE with invalid cast)
PR c++/84493
* parser.c (cp_parser_braced_list): Use require_open instead of
consume_open.
* g++.dg/parse/error59.C: New test.
From-SVN: r257899
Tom de Vries [Thu, 22 Feb 2018 11:01:16 +0000 (11:01 +0000)]
[testsuite] Require et alloca for pr82210.c
2018-02-22 Tom de Vries <tom@codesourcery.com>
* gcc.c-torture/execute/pr82210.c: Require effective target alloca.
From-SVN: r257898
Paolo Carlini [Thu, 22 Feb 2018 10:44:04 +0000 (10:44 +0000)]
re PR c++/77655 (ICE on invalid c++ code on x86_64-linux-gnu (internal compiler error: Segmentation fault (program cc1plus)))
2018-02-22 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/77655
* g++.dg/cpp0x/pr77655.C: New.
From-SVN: r257896
Jakub Jelinek [Thu, 22 Feb 2018 09:55:32 +0000 (10:55 +0100)]
re PR c++/84496 (Internal compiler error with lambda, static and auto since r236615)
PR c++/84496
* g++.dg/cpp1y/pr84496.C: New test.
From-SVN: r257895
Janne Blomqvist [Thu, 22 Feb 2018 09:44:31 +0000 (11:44 +0200)]
Character length cleanup for Coarray Fortran library
Following the change to use size_t for Fortran character lengths (PR
78534), this patch modifies the Coarray ABI in a similar way. The
single-image implementation that is included in libgfortran is
updated, but this needs corresponding work in the OpenCoarray library
as well for multi-image support. I also fixed the types for the STOP
and ERROR STOP implementation in libgfortran, as the calling of them
is somewhat intertwined with the calling of the corresponding CAF
functions. I'll send the OpenCoarray changes as a separate pull
request to the OpenCoarrays repository.
Regtested on x86_64-pc-linux-gnu.
gcc/fortran/ChangeLog:
2018-02-22 Janne Blomqvist <jb@gcc.gnu.org>
* gfortran.texi: Update Coarray API description.
* trans-decl.c (gfc_build_builtin_function_decls): Use size_t for
character lengths, int for exit codes.
(generate_coarray_sym_init): Use size_t for character length.
* trans-intrinsic.c (conv_co_collective): Likewise.
* trans-stmt.c (gfc_trans_lock_unlock): Likewise.
(gfc_trans_event_post_wait): Likewise.
(gfc_trans_sync): Likewise.
(gfc_trans_stop): Use size_t for character lengths, int for exit
codes.
libgfortran/ChangeLog:
2018-02-22 Janne Blomqvist <jb@gcc.gnu.org>
* libgfortran.h (stop_string): Use size_t for character length.
* runtime/stop.c (stop_string): Likewise.
(error_stop_string): Likewise.
(stop_numeric): Use int for exit code.
(error_stop_numeric): Likewise.
* caf/libcaf.h: Remove stdint.h include.
(_gfortran_caf_register): Use size_t for character length.
(_gfortran_caf_deregister): Likewise.
(_gfortran_caf_sync_all): Likewise.
(_gfortran_caf_sync_memory): Likewise.
(_gfortran_caf_sync_images): Likewise.
(_gfortran_caf_stop_numeric): Use int for exit code.
(_gfortran_caf_stop_str): Use size_t for character length.
(_gfortran_caf_error_stop_str): Likewise.
(_gfortran_caf_error_stop): Use int for exit code.
(_gfortran_caf_co_broadcast): Use size_t for character length.
(_gfortran_caf_co_sum): Likewise.
(_gfortran_caf_co_min): Likewise.
(_gfortran_caf_co_max): Likewise.
(_gfortran_caf_co_reduce): Likewise.
(_gfortran_caf_lock): Likewise.
(_gfortran_caf_unlock): Likewise.
(_gfortran_caf_event_post): Likewise.
(_gfortran_caf_event_wait): Likewise.
* caf/mpi.c (_gfortran_caf_register): Update implementation to
match prototype.
(_gfortran_caf_deregister): Likewise.
(_gfortran_caf_sync_all): Likewise.
(_gfortran_caf_sync_images): Likewise.
(_gfortran_caf_error_stop_str): Likewise.
(_gfortran_caf_error_stop): Likewise.
* caf/single.c (caf_internal_error): Likewise.
(_gfortran_caf_register): Likewise.
(_gfortran_caf_deregister): Likewise.
(_gfortran_caf_sync_all): Likewise.
(_gfortran_caf_sync_memory): Likewise.
(_gfortran_caf_sync_images): Likewise.
(_gfortran_caf_stop_numeric): Likewise.
(_gfortran_caf_stop_str): Likewise.
(_gfortran_caf_error_stop_str): Likewise.
(_gfortran_caf_error_stop): Likewise.
(_gfortran_caf_co_broadcast): Likewise.
(_gfortran_caf_co_sum): Likewise.
(_gfortran_caf_co_min): Likewise.
(_gfortran_caf_co_max): Likewise.
(_gfortran_caf_co_reduce): Likewise.
(_gfortran_caf_event_post): Likewise.
(_gfortran_caf_event_wait): Likewise.
(_gfortran_caf_lock): Likewise.
(_gfortran_caf_unlock): Likewise.
From-SVN: r257894
Martin Liska [Thu, 22 Feb 2018 08:50:41 +0000 (09:50 +0100)]
Add "native" as a valid option value for -march= on i386 (PR driver/83193).
2018-02-22 Martin Liska <mliska@suse.cz>
PR driver/83193
* config/i386/i386.c (ix86_option_override_internal):
Add "native" as a possible value for -march and -mtune.
From-SVN: r257893
Jakub Jelinek [Thu, 22 Feb 2018 08:29:56 +0000 (09:29 +0100)]
re PR c++/84502 (Argument corruption when passing empty templated struct)
PR target/84502
* stor-layout.c (finalize_type_size): Propagate TYPE_EMPTY_P flag
to all type variants.
* g++.dg/torture/pr84502.C: New test.
From-SVN: r257892
Jakub Jelinek [Thu, 22 Feb 2018 08:28:42 +0000 (09:28 +0100)]
re PR tree-optimization/84503 (store-merging miscompilation on powerpc64 with -O3 since r241789)
PR tree-optimization/84503
* gimple-ssa-store-merging.c (merged_store_group::merge_into): Compute
width as info->bitpos + info->bitsize - start.
(merged_store_group::merge_overlapping): Simplify width computation.
(check_no_overlap): New function.
(imm_store_chain_info::try_coalesce_bswap): Compute expected
start + width and last_order of the group, fail if check_no_overlap
fails.
(imm_store_chain_info::coalesce_immediate_stores): Don't merge info
to group if check_no_overlap fails.
* gcc.dg/pr84503-1.c: New test.
* gcc.dg/pr84503-2.c: New test.
From-SVN: r257891
Segher Boessenkool [Thu, 22 Feb 2018 01:09:18 +0000 (02:09 +0100)]
rs6000: Delete meaningless arguments to define_{expand,split,peephole2}
This removes the (usually empty) constraint arguments to define_expand,
define_split, and define_peephole2: this argument is meaningless and
just noise.
* config/rs6000/altivec.md: Delete contraint arguments to
define_expand, define_split, and define_peephole2, and in
define_insn_and_split if always unused.
* config/rs6000/darwin.md: Ditto.
* config/rs6000/dfp.md: Ditto.
* config/rs6000/rs6000.md: Ditto.
* config/rs6000/sync.md: Ditto.
* config/rs6000/vector.md: Ditto.
* config/rs6000/vsx.md: Ditto.
From-SVN: r257890
Segher Boessenkool [Thu, 22 Feb 2018 01:08:02 +0000 (02:08 +0100)]
rs6000: Use brace blocks in define_insn
This patch changes the remaining cases in our machine description files
to use brace blocks instead of double-quoted strings as the output
control string. This increases readability by making the blocks look
more like normal C code, mostly because backslash quoting is no longer
needed. It also removes such quoting where it was still there (usually
harmless but always confusing). and it writes "\n\t" as "\;" in one
place where we didn't already.
* config/rs6000/altivec.md: Write output control strings as braced
blocks instead of double-quoted strings.
* config/rs6000/darwin.md: Ditto.
* config/rs6000/rs6000.md: Ditto.
* config/rs6000/vector.md: Ditto.
* config/rs6000/vsx.md: Ditto.
From-SVN: r257889
GCC Administrator [Thu, 22 Feb 2018 00:16:25 +0000 (00:16 +0000)]
Daily bump.
From-SVN: r257887
Jason Merrill [Wed, 21 Feb 2018 22:12:08 +0000 (17:12 -0500)]
PR c++/84314 - ICE with templates and fastcall attribute.
* attribs.c (build_type_attribute_qual_variant): Remove assert.
From-SVN: r257883
Jan Hubicka [Wed, 21 Feb 2018 20:11:15 +0000 (21:11 +0100)]
* ipa-cp.c (determine_versionability): Fix comment typos.
From-SVN: r257878
Jan Hubicka [Wed, 21 Feb 2018 19:05:30 +0000 (20:05 +0100)]
re PR c/84229 (A valid code rejected with -flto)
PR c/84229
* ipa-cp.c (determine_versionability): Do not version functions caling
va_arg_pack.
From-SVN: r257877
Jason Merrill [Wed, 21 Feb 2018 14:25:54 +0000 (09:25 -0500)]
PR c++/84454 - ICE with pack expansion in signature.
* error.c (find_typenames_r): Also stop on EXPR_PACK_EXPANSION.
From-SVN: r257875
Martin Liska [Wed, 21 Feb 2018 14:05:45 +0000 (15:05 +0100)]
Add "native" as a valid option value for -march= on aarch64 (PR driver/83193).
2018-02-21 Martin Liska <mliska@suse.cz>
PR driver/83193
* config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch):
Add "native" as a possible value.
* config/aarch64/aarch64.h (HAVE_LOCAL_CPU_DETECT): Define
the macro when native cpu detection is available.
From-SVN: r257874
Martin Liska [Wed, 21 Feb 2018 14:05:17 +0000 (15:05 +0100)]
Add "native" as a valid option value for -march= on arm (PR driver/83193).
2018-02-21 Martin Liska <mliska@suse.cz>
PR driver/83193
* common/config/arm/arm-common.c (arm_print_hint_for_arch_option):
Add "native" as a possible value.
* config/arm/arm.h (HAVE_LOCAL_CPU_DETECT): Define the macro
when native cpu detection is available.
From-SVN: r257873
Jakub Jelinek [Wed, 21 Feb 2018 10:35:46 +0000 (11:35 +0100)]
re PR tree-optimization/84478 (pdftex miscompilation on i386)
PR tree-optimization/84478
* gimple-fold.h (get_range_strlen): Add a bool argument defaulted to
false.
* gimple-fold.c (get_range_strlen): Make minlen const and assume it
can't be NULL. Change FUZZY from bool to int, for 1 add PHI/COND_EXPR
support which is conservatively correct, for 2 only stay conservative
for maxlen. Formatting and comment capitalization fixes. Add STRICT
argument to the 2 argument get_range_strlen, adjust 6 arg
get_range_strlen caller and clear minmaxlen[0] and [1] if it returned
false.
(get_maxval_strlen): Adjust 6 arg get_range_strlen caller.
(gimple_fold_builtin_strlen): Pass true as last argument to
get_range_strlen.
* gcc.c-torture/execute/pr84478.c: New test.
Co-Authored-By: Martin Sebor <msebor@redhat.com>
From-SVN: r257870
Martin Liska [Wed, 21 Feb 2018 07:57:52 +0000 (08:57 +0100)]
Add IntegerRange for Wcatch-value= option.
2018-02-21 Martin Liska <mliska@suse.cz>
* c.opt (Wcatch-value=): Add IntegerRange.
From-SVN: r257869
GCC Administrator [Wed, 21 Feb 2018 00:16:25 +0000 (00:16 +0000)]
Daily bump.
From-SVN: r257868
Max Filippov [Tue, 20 Feb 2018 20:55:56 +0000 (20:55 +0000)]
libgcc: xtensa: fix build with -mtext-section-literals
libgcc/
2018-02-20 Max Filippov <jcmvbkbc@gmail.com>
* config/xtensa/ieee754-df.S (__adddf3_aux): Add
.literal_position directive.
* config/xtensa/ieee754-sf.S (__addsf3_aux): Likewise.
From-SVN: r257862
François Dumont [Tue, 20 Feb 2018 20:51:44 +0000 (20:51 +0000)]
aligned_buffer.h [...] (template<> __aligned_buffer): Define as __aligned_membuf alias.
2018-02-20 François Dumont <fdumont@gcc.gnu.org>
* include/ext/aligned_buffer.h [_GLIBCXX_INLINE_VERSION]
(template<> __aligned_buffer): Define as __aligned_membuf alias.
From-SVN: r257861
Martin Sebor [Tue, 20 Feb 2018 20:22:01 +0000 (20:22 +0000)]
PR middle-end/84095 - false-positive -Wrestrict warnings for memcpy within array
gcc/ChangeLog:
PR middle-end/84095
* gimple-ssa-warn-restrict.c (builtin_memref::extend_offset_range): New.
(builtin_memref::set_base_and_offset): Same. Handle inner references.
(builtin_memref::builtin_memref): Factor out parts into
set_base_and_offset and call it.
gcc/testsuite/ChangeLog:
PR middle-end/84095
* c-c++-common/Warray-bounds-3.c: Adjust text of expected warnings.
* c-c++-common/Wrestrict.c: Same.
* gcc.dg/Wrestrict-6.c: Same.
* gcc.dg/Warray-bounds-27.c: New test.
* gcc.dg/Wrestrict-8.c: New test.
* gcc.dg/Wrestrict-9.c: New test.
* gcc.dg/pr84095.c: New test.
From-SVN: r257860
Thomas Koenig [Tue, 20 Feb 2018 19:53:42 +0000 (19:53 +0000)]
structure_constructor_14.f90: Adjust STOP number.
2018-02-20 Thomas Koenig <tkoenig@gcc.gnu.org>
* gfortran.dg/structure_constructor_14.f90: Adjust STOP number.
From-SVN: r257859
Richard Sandiford [Tue, 20 Feb 2018 19:11:34 +0000 (19:11 +0000)]
re PR target/84406 ([MSP430] ICE on valid code in find_widening_optab_handler_and_mode, at optabs-query.c:476)
PR middle-end/84406
* optabs-query.c (find_widening_optab_handler_and_mode): If from_mode
is a scalar_int_mode, assert that to_mode is a scalar_int_mode with
greater precision. If to_mode is a MODE_PARTIAL_INT, stop the
search at the associated MODE_INT.
From-SVN: r257858
Jeff Law [Tue, 20 Feb 2018 18:59:22 +0000 (11:59 -0700)]
re PR middle-end/82123 (spurious -Wformat-overflow warning for converted vars)
PR middle-end/82123
PR tree-optimization/81592
PR middle-end/79257
* gimple-ssa-sprintf.c (format_integer): Query EVRP range analyzer
for range data rather than using global data.
* gcc.dg/pr81592.c: New test.
* gcc.dg/pr82123.c: New test.
From-SVN: r257857
Thomas Koenig [Tue, 20 Feb 2018 18:57:34 +0000 (18:57 +0000)]
re PR fortran/48890 ([F95] Wrong length of a character component of named constant derived-type)
2018-02-20 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/48890
PR fortran/83823
* primary.c (gfc_convert_to_structure_constructor):
For a constant string constructor, make sure the length
is correct.
2018-02-20 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/48890
PR fortran/83823
* gfortran.dg/structure_constructor_14.f90: New test.
From-SVN: r257856
Jeff Law [Tue, 20 Feb 2018 18:56:56 +0000 (11:56 -0700)]
re PR middle-end/82123 (spurious -Wformat-overflow warning for converted vars)
PR middle-end/82123
PR tree-optimization/81592
PR middle-end/79257
* gimple-ssa-sprintf.c (get_int_range): Query EVRP range analyzer for
range data rather than using global data.
From-SVN: r257855
Jeff Law [Tue, 20 Feb 2018 18:56:01 +0000 (11:56 -0700)]
re PR middle-end/82123 (spurious -Wformat-overflow warning for converted vars)
PR middle-end/82123
PR tree-optimization/81592
PR middle-end/79257
* gimple-ssa-sprintf.c (get_int_range): Accept vr_values parameter
pass it to children as needed.
(struct directive::fmtresult): Similarly.
(struct directive::set_width): Similarly.
(struct directive::set_precision): Similarly.
(format_integer, format_directive, parse_directive): Similarly.
(format_none): Accept unnamed vr_values parameter.
(format_percent, format_floating, format_character): Similarly.
(format_string, format_plain): Similarly.
From-SVN: r257854
Jeff Law [Tue, 20 Feb 2018 18:53:29 +0000 (11:53 -0700)]
re PR middle-end/82123 (spurious -Wformat-overflow warning for converted vars)
PR middle-end/82123
PR tree-optimization/81592
PR middle-end/79257
* gimple-ssa-sprintf.c (sprintf_dom_walker::handle_gimple_call): Query
the EVRP range analyzer for range data rather than using global data.
From-SVN: r257853
Jeff Law [Tue, 20 Feb 2018 18:52:07 +0000 (11:52 -0700)]
re PR middle-end/82123 (spurious -Wformat-overflow warning for converted vars)
PR middle-end/82123
PR tree-optimization/81592
PR middle-end/79257
* gimple-ssa-sprintf.c: Include alloc-pool.h, vr-values.h and
gimple-ssa-evrp-analyze.h
(class sprintf_dom_walker): Add after_dom_children member function.
Add evrp_range_analyzer member.
(sprintf_dom_walker::before_dom_children): Call into the EVRP
range analyzer as needed.
(sprintf_dom_walker::after_dom_children): New member function.
* gcc.dg/builtin-unreachable-6.c: Turn off VRP.
From-SVN: r257852
Jeff Law [Tue, 20 Feb 2018 18:49:46 +0000 (11:49 -0700)]
re PR middle-end/82123 (spurious -Wformat-overflow warning for converted vars)
PR middle-end/82123
PR tree-optimization/81592
PR middle-end/79257
* gimple-ssa-evrp-analyze.c (evrp_range_analyzer::enter): Do nothing
if not optimizing.
(evrp_range_analyzer::record_ranges_from_stmt): Likewise.
(evrp_range_analyzer::pop_to_marker): Likewise.
From-SVN: r257851
Jakub Jelinek [Tue, 20 Feb 2018 17:00:23 +0000 (18:00 +0100)]
re PR c++/84488 (Incorrect "set but not used" warning for static_cast<Enum>(double))
PR c++/84488
* g++.dg/warn/Wunused-var-30.C: New test.
From-SVN: r257850
Carl Love [Tue, 20 Feb 2018 16:48:39 +0000 (16:48 +0000)]
The removal of file fold-vec-neg-int.p7.c in commit 257812 didn't get commited.
Removing the file.
From-SVN: r257849
Ian Lance Taylor [Tue, 20 Feb 2018 15:30:31 +0000 (15:30 +0000)]
runtime: allow preemption in fast syscall return
Let a fast syscall return be a preemption point. This helps with
tight loops that make system calls, as in BenchmarkSyscallExcessWork.
Reviewed-on: https://go-review.googlesource.com/94895
From-SVN: r257848
Richard Sandiford [Tue, 20 Feb 2018 14:44:24 +0000 (14:44 +0000)]
Fix incorrect TARGET_MEM_REF alignment (PR 84419)
expand_call_mem_ref checks for TARGET_MEM_REFs that have compatible
type, but it didn't then go on to install the specific type we need,
which might have different alignment due to:
if (TYPE_ALIGN (type) != align)
type = build_aligned_type (type, align);
This was causing masked stores to be incorrectly marked as
aligned on AVX512.
2018-02-20 Richard Sandiford <richard.sandiford@linaro.org>
gcc/
PR tree-optimization/84419
* internal-fn.c (expand_call_mem_ref): Create a TARGET_MEM_REF
with the required type if its current type is compatible but
different.
gcc/testsuite/
PR tree-optimization/84419
* gcc.dg/vect/pr84419.c: New test.
From-SVN: r257847
Jakub Jelinek [Tue, 20 Feb 2018 13:56:00 +0000 (14:56 +0100)]
re PR middle-end/82004 (SPEC CPU2017 628.pop2_s miscompare)
PR middle-end/82004
* match.pd (pow(C,x) -> exp(log(C)*x)): Delay all folding until
after vectorization.
* gfortran.dg/pr82004.f90: New test.
From-SVN: r257846
Ian Lance Taylor [Tue, 20 Feb 2018 13:52:56 +0000 (13:52 +0000)]
compiler: look through aliases for type compatibility
Aliases are supposed to be identical to the type being aliased, so
questions about type compatibility need to always ignore aliases,
except for error messages involving the type name.
The test case for this is https://golang.org/cl/94995.
Fixes golang/go#23912
Reviewed-on: https://go-review.googlesource.com/94996
From-SVN: r257845
Martin Liska [Tue, 20 Feb 2018 12:18:07 +0000 (13:18 +0100)]
Fix missing info for -march and -mtune wrong values on aarch64 (PR driver/83193).
2018-02-20 Martin Liska <mliska@suse.cz>
PR driver/83193
* config/aarch64/aarch64.c (aarch64_print_hint_for_core_or_arch): Print
possible values if we don't have a hint.
From-SVN: r257844
Siddhesh Poyarekar [Tue, 20 Feb 2018 11:11:31 +0000 (11:11 +0000)]
c++: Fix spurious fallthrough warning on break
The C++ frontend generates a break that results in the fallthrough
warning misfiring in nested switch blocks where cases in the inner
switch block return, rendering the break pointless. The fallthrough
detection in finish_break_stmt does not work either because the
condition is encoded as an IF_STMT and not a COND_EXPR.
Fix this by adding a condition for IF_STMT in the
langhooks.block_may_fallthru for C++. Fix tested on x86_64.
gcc/cp
* cp-objcp-common.c (cxx_block_may_fallthru): Add case for
IF_STMT.
gcc/testsuite
* g++.dg/nested-switch.C: New test case.
From-SVN: r257843
Martin Liska [Tue, 20 Feb 2018 10:04:13 +0000 (11:04 +0100)]
Add limit for maximal alignment options (PR c/84310).
2018-02-20 Martin Liska <mliska@suse.cz>
PR c/84310
PR target/79747
* final.c (shorten_branches): Build align_tab array with one
more element.
* opts.c (finish_options): Add alignment option limit check.
(MAX_CODE_ALIGN): Likewise.
(MAX_CODE_ALIGN_VALUE): Likewise.
* doc/invoke.texi: Document maximum allowed option value for
all -falign-* options.
2018-02-20 Martin Liska <mliska@suse.cz>
PR c/84310
PR target/79747
* gcc.target/i386/pr84310.c: New test.
* gcc.target/i386/pr84310-2.c: Likewise.
From-SVN: r257842
Paolo Carlini [Tue, 20 Feb 2018 09:02:12 +0000 (09:02 +0000)]
re PR c++/84446 (ICE with broken lambda)
/cp
2018-02-20 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/84446
* parser.c (cp_parser_init_declarator): Don't call start_lambda_scope
on error_mark_node.
/testsuite
2018-02-20 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/84446
* g++.dg/cpp0x/lambda/lambda-ice27.C: New.
From-SVN: r257841
Jakub Jelinek [Tue, 20 Feb 2018 08:22:31 +0000 (09:22 +0100)]
re PR c++/84445 (ICE with __builtin_launder and virtual function)
PR c++/84445
* class.c (fixed_type_or_null) <case CALL_EXPR>: Only test
TREE_HAS_CONSTRUCTOR if instance is not an internal function call.
* g++.dg/cpp1z/launder7.C: New test.
From-SVN: r257840
Jakub Jelinek [Tue, 20 Feb 2018 08:21:36 +0000 (09:21 +0100)]
re PR c++/84449 (ICE with constexpr and deleted destructor)
PR c++/84449
* tree.c (bot_manip): If build_cplus_new or break_out_target_exprs
returns error_mark_node, return it immediately.
(break_out_target_exprs): If cp_walk_tree with bot_manip returns
error_mark_node, return error_mark_node.
* g++.dg/cpp0x/constexpr-84449.C: New test.
From-SVN: r257839
Jakub Jelinek [Tue, 20 Feb 2018 08:20:37 +0000 (09:20 +0100)]
re PR c++/84455 (ICE in build_call_a at gcc/cp/call.c:389 during error reporting)
PR c++/84455
* pt.c (tsubst_lambda_expr): If not nested, increment temporarily
function_depth to avoid GC during finish_lambda_function.
* g++.dg/cpp0x/lambda/lambda-ice26.C: New test.
From-SVN: r257838
Jason Merrill [Tue, 20 Feb 2018 03:39:37 +0000 (22:39 -0500)]
PR c++/84429 - ICE capturing VLA.
* lambda.c (build_capture_proxy): Handle reference refs.
From-SVN: r257836
GCC Administrator [Tue, 20 Feb 2018 00:16:13 +0000 (00:16 +0000)]
Daily bump.
From-SVN: r257835
Paul Thomas [Mon, 19 Feb 2018 22:09:13 +0000 (22:09 +0000)]
re PR fortran/83344 (Use of uninitialized memory with ASSOCIATE and strings)
2018-02-19 Paul Thomas <pault@gcc.gnu.org>
PR fortran/83344
PR fortran/83975
* resolve.c (resolve_assoc_var): Rearrange the logic for the
determination of the character length of associate names. If
the associate name is missing a length expression or the length
expression is not a constant and the target is not a variable,
make the associate name allocatable and deferred length.
* trans-decl.c (gfc_get_symbol_decl): Null the character length
backend_decl for deferred length associate names that are not
variables. Set 'length' to gfc_index_zero_node for character
associate names, whose character length is a PARM_DECL.
2018-02-19 Paul Thomas <pault@gcc.gnu.org>
PR fortran/83344
PR fortran/83975
* gfortran.dg/associate_22.f90: Enable commented out test.
* gfortran.dg/associate_36.f90: New test.
From-SVN: r257827
Jakub Jelinek [Mon, 19 Feb 2018 21:58:04 +0000 (22:58 +0100)]
re PR target/84146 (ICE with -mcet in dwarf2out_var_location, involving sigsetjmp)
PR target/84146
* reg-notes.def (REG_CALL_ARG_LOCATION): New reg note.
* insn-notes.def (NOTE_INSN_CALL_ARG_LOCATION): Remove.
* var-tracking.c (emit_note_insn_var_location): Remove all references
to NOTE_INSN_CALL_ARG_LOCATION.
(emit_notes_in_bb): Emit arguments as REG_CALL_ARG_LOCATION note on
the CALL_INSN rather than separate NOTE_INSN_CALL_ARG_LOCATION note.
Use copy_rtx_if_shared.
* dwarf2out.c (gen_subprogram_die): Use XEXP with 0 instead of
NOTE_VAR_LOCATION on ca_loc->call_arg_loc_note.
(dwarf2out_var_location): Remove handling of
NOTE_INSN_CALL_ARG_LOCATION, instead handle REG_CALL_ARG_LOCATION note
on call_insn.
* final.c (final_scan_insn): Remove all references to
NOTE_INSN_CALL_ARG_LOCATION.
(rest_of_clean_state): Likewise. Remove REG_CALL_ARG_LOCATION notes
before dumping final insns.
* except.c (emit_note_eh_region_end): Remove all references to
NOTE_INSN_CALL_ARG_LOCATION.
* config/alpha/alpha.c (alpha_pad_function_end): Likewise.
* config/c6x/c6x.c (c6x_gen_bundles): Likewise.
* config/arc/arc.c (hwloop_optimize): Likewise.
* config/arm/arm.c (create_fix_barrier): Likewise.
* config/s390/s390.c (s390_chunkify_start): Likewise.
* config/sh/sh.c (find_barrier): Likewise.
* config/i386/i386.c (rest_of_insert_endbranch,
ix86_seh_fixup_eh_fallthru): Likewise.
* config/xtensa/xtensa.c (hwloop_optimize): Likewise.
* config/iq2000/iq2000.c (final_prescan_insn): Likewise.
* config/frv/frv.c (frv_function_prologue): Likewise.
* emit-rtl.c (try_split): Likewise. Copy over REG_CALL_ARG_LOCATION
reg note.
(note_outside_basic_block_p): Remove all references to
NOTE_INSN_CALL_ARG_LOCATION.
* gengtype.c (adjust_field_rtx_def): Likewise.
* print-rtl.c (rtx_writer::print_rtx_operand_code_0, print_insn):
Likewise.
* jump.c (cleanup_barriers, delete_related_insns): Likewise.
* cfgrtl.c (force_nonfallthru_and_redirect): Likewise.
* gcc.target/i386/pr84146.c: Add -fcompare-debug to dg-options.
From-SVN: r257826
Uros Bizjak [Mon, 19 Feb 2018 20:43:06 +0000 (21:43 +0100)]
pr70023.c (dg-do): Compile only for target int128.
* gcc.target/i386/pr70023.c (dg-do): Compile only for target int128.
(dg-options): Use -mavx instead of -w.
From-SVN: r257824
Jakub Jelinek [Mon, 19 Feb 2018 19:36:41 +0000 (20:36 +0100)]
re PR c++/84444 (ICE with __builtin_launder and cast)
PR c++/84444
* builtins.c (builtin_mathfn_code): Don't check if CALL_EXPR_FN (t)
is ADDR_EXPR.
* g++.dg/cpp1z/launder8.C: New test.
From-SVN: r257822
Jakub Jelinek [Mon, 19 Feb 2018 19:16:26 +0000 (20:16 +0100)]
re PR c++/84448 (ICE with broken condition in parallel for loop)
PR c++/84448
* parser.c (cp_parser_binary_expression): For no_toplevel_fold_p, if
either operand is error_mark_node, set current.lhs to that instead of
creating a binary op with error_mark_node operands.
* g++.dg/gomp/pr84448.C: New test.
From-SVN: r257821
Jakub Jelinek [Mon, 19 Feb 2018 19:12:14 +0000 (20:12 +0100)]
re PR c++/84430 (ICE with #pragma omp simd in lambda)
PR c++/84430
* constexpr.c (potential_constant_expression_1): Handle OMP_SIMD.
* g++.dg/gomp/pr84430.C: New test.
From-SVN: r257820
Jakub Jelinek [Mon, 19 Feb 2018 18:58:13 +0000 (19:58 +0100)]
re PR tree-optimization/84452 (ICE in expand_simd_clones at gcc/omp-simd-clone.c:1612)
PR tree-optimization/84452
* tree-vect-patterns.c (vect_recog_pow_pattern): Don't call
expand_simd_clones if targetm.simd_clone.compute_vecsize_and_simdlen
is NULL.
* gcc.dg/pr84452.c: New test.
From-SVN: r257819
Jakub Jelinek [Mon, 19 Feb 2018 18:49:21 +0000 (19:49 +0100)]
re PR c++/79064 (Cannot overload member function templates on type of literal)
PR c++/79064
* g++.dg/template/overload15.C (f): Use 0u - 1ll instead of 0u - 1l.
From-SVN: r257818
Martin Liska [Mon, 19 Feb 2018 18:30:31 +0000 (19:30 +0100)]
Put pass_sancov_O0 before pass_lower_switch with -O0 (PR sanitizer/82183).
2018-02-19 Martin Liska <mliska@suse.cz>
PR sanitizer/82183
* passes.def: Put pass_sancov_O0 before pass_lower_switch with -O0.
From-SVN: r257817
Martin Liska [Mon, 19 Feb 2018 18:29:52 +0000 (19:29 +0100)]
Fix ubsan in gimple-fold.c (PR tree-optimization/82491).
2018-02-19 Martin Liska <mliska@suse.cz>
Richard Sandiford <richard.sandiford@linaro.org>
PR tree-optimization/82491
* gimple-fold.c (get_base_constructor): Make earlier bail out
to prevent ubsan.
Co-Authored-By: Richard Sandiford <richard.sandiford@linaro.org>
From-SVN: r257816
Martin Liska [Mon, 19 Feb 2018 18:29:20 +0000 (19:29 +0100)]
Do not use bit and for conjunction of predicates (PR c/81272).
2018-02-19 Martin Liska <mliska@suse.cz>
PR c/81272
* decNumber.c (decCompareOp): Do not use bit and
for conjunction of predicates.
From-SVN: r257815
Thomas Koenig [Mon, 19 Feb 2018 18:21:45 +0000 (18:21 +0000)]
re PR fortran/35339 (Improve translation of implied do loop in transfer)
2018-02-19 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/35339
* frontend-passes.c (traverse_io_block): Remove workaround for
PR 80945.
2018-02-19 Thomas Koenig <tkoenig@gcc.gnu.org>
PR fortran/35339
* gfortran.dg/implied_do_io_4.f90: New test.
From-SVN: r257814
Andre Vehreschild [Mon, 19 Feb 2018 17:30:57 +0000 (18:30 +0100)]
gfortran.texi: Document additional src/dst_type.
gcc/fortran/ChangeLog:
2018-02-19 Andre Vehreschild <vehre@gcc.gnu.org>
* gfortran.texi: Document additional src/dst_type. Fix some typos.
* trans-decl.c (gfc_build_builtin_function_decls): Declare the new
argument of _caf_*_by_ref () with * e { get, send, sendget }.
* trans-intrinsic.c (gfc_conv_intrinsic_caf_get): Add the type of the
data referenced when generating a call to caf_get_by_ref ().
(conv_caf_send): Same but for caf_send_by_ref () and
caf_sendget_by_ref ().
gcc/testsuite/ChangeLog:
2018-02-19 Andre Vehreschild <vehre@gcc.gnu.org>
* gfortran.dg/coarray_alloc_comp_6.f08: New test.
* gfortran.dg/coarray_alloc_comp_7.f08: New test.
* gfortran.dg/coarray_alloc_comp_8.f08: New test.
libgfortran/ChangeLog:
2018-02-19 Andre Vehreschild <vehre@gcc.gnu.org>
* caf/libcaf.h: Add type parameters to the caf_*_by_ref prototypes.
* caf/single.c (get_for_ref): Simplifications and now respecting
the type argument.
(_gfortran_caf_get_by_ref): Added source type handing to get_for_ref().
(send_by_ref): Simplifications and respecting the dst_type now.
(_gfortran_caf_send_by_ref): Added destination type hand over to
send_by_ref().
(_gfortran_caf_sendget_by_ref): Added general support and fixed stack
corruption. The function is now really usable.
From-SVN: r257813
Carl Love [Mon, 19 Feb 2018 17:27:39 +0000 (17:27 +0000)]
rs6000-builtin.def: Change NEG macro expansions from BU_ALTIVEC_A to BU_P8V_AV_1 and...
gcc/ChangeLog:
2018-02-19 Carl Love <cel@us.ibm.com>
* config/rs6000/rs6000-builtin.def: Change NEG macro expansions from
BU_ALTIVEC_A to BU_P8V_AV_1 and BU_ALTIVEC_OVERLOAD_1 to
BU_P8V_OVERLOAD_1.
* config/rs6000/rs6000-c.c: Change ALTIVEC_BUILTIN_VEC_NEG to
P8V_BUILTIN_VEC_NEG.
gcc/testsuite/ChangeLog:
2018-02-19 Carl Love <cel@us.ibm.com>
* gcc.target/powerpc/fold-vec-neg-int.p7.c: Remove test file.
From-SVN: r257812
Sebastian Peryt [Mon, 19 Feb 2018 16:28:39 +0000 (17:28 +0100)]
re PR target/84460 (gcc.target/i386/pr57193.c fail)
2018-01-16 Sebastian Peryt <sebastian.peryt@intel.com>
PR target/84460
* gcc.target/i386/pr57193.c: Add -mtune=generic.
From-SVN: r257810
Igor Tsimbalist [Mon, 19 Feb 2018 16:25:49 +0000 (17:25 +0100)]
CET shouldn't be enabled in 32-bit run-time libraries by defualt
ENDBR32 and RDSSPD are multi-byte NOPs on x86-64 processors and
newer x86 processors, starting Pentium Pro. They are UD on older
32-bit processors. Detect this at configure time and adjust the
default value for enable_cet. GCC will enable CET in 32-bit run-time
libraries in any case if --enable-cet is used to configure GCC.
PR target/84148
* config/cet.m4: Check if target support multi-byte NOPS (SSE).
* libatomic/configure: Regenerate.
* libbacktrace/configure: Likewise.
* libgcc/configure: Likewise.
* libgfortran/configure: Likewise.
* libgomp/configure: Likewise.
* libitm/configure: Likewise.
* libmpx/configure: Likewise.
* libobjc/configure: Likewise.
* libquadmath/configure: Likewise.
* libsanitizer/configure: Likewise.
* libssp/configure: Likewise.
* libstdc++-v3/configure: Likewise.
* libvtv/configure: Likewise.
From-SVN: r257809
Sebastian Perta [Mon, 19 Feb 2018 15:15:07 +0000 (15:15 +0000)]
rl78.md (movdf): New define expand.
2018-02-19 Sebastian Perta <sebastian.perta@renesas.com>
* config/rl78/rl78.md (movdf): New define expand.
From-SVN: r257807
Martin Liska [Mon, 19 Feb 2018 09:54:09 +0000 (10:54 +0100)]
Fix documentation typos (PR other/80589).
2018-02-19 Martin Liska <mliska@suse.cz>
PR other/80589
* doc/invoke.texi: Fix typo.
* params.def (PARAM_MAX_LOOP_HEADER_INSNS): Likewise.
From-SVN: r257803
Paolo Carlini [Mon, 19 Feb 2018 08:49:30 +0000 (08:49 +0000)]
re PR c++/84348 (ICE with invalid friend declaration)
/cp
2018-02-19 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/84348
* decl.c (grokdeclarator): Early return error_mark_node upon
ill-formed friend declaration.
/testsuite
2018-02-19 Paolo Carlini <paolo.carlini@oracle.com>
PR c++/84348
* g++.dg/cpp0x/auto50.C: New.
* g++.dg/parse/friend12.C: Adjust.
From-SVN: r257802
Yury Gribov [Mon, 19 Feb 2018 08:03:17 +0000 (08:03 +0000)]
Respect TMPDIR in contrib scripts.
2018-02-18 Yury Gribov <tetra2005@gmail.com>
contrib/
* compare_tests: Use TMPDIR when set.
* dg-cmp-results.sh: Ditto.
* warn_summary: Ditto.
From-SVN: r257801