[PING] [PATCH] get source line for diagnostic from preprocessed file / PR preprocessor/79106

2020-01-02 Thread Bader, Lucas
Happy New Year and a ping for https://gcc.gnu.org/ml/gcc-patches/2019-12/msg01113.html -Original Message- From: Bader, Lucas Sent: Montag, 16. Dezember 2019 12:19 To: gcc-patches@gcc.gnu.org Subject: [PATCH] get source line for diagnostic from preprocessed file / PR preprocessor/79106

[PATCH] Make warn_inline Optimization option.

2020-01-02 Thread Martin Liška
Hi. The patch is about using Optimization for warn_inline as it's affected by -O0. Patch can bootstrap on x86_64-linux-gnu and survives regression tests. Ready to be installed? Thanks, Martin gcc/ChangeLog: 2019-12-11 Martin Liska PR tree-optimization/92860 * common.opt: M

[C++ Patch] Improve build_new locations

2020-01-02 Thread Paolo Carlini
Hi, some rather straightforward bits for build_new / cp_parser_new_expression, almost a clean-up. It would be nice to do better for the diagnostic issued from build_new_1 too but having consistent locations for all the valid_array_size_p and invalid_array_size_error calls isn't trivial, I'd r

Re: [ PATCH ] [ C++ ] [ libstdc++ ] P1208r6 Merge source_location

2020-01-02 Thread Jonathan Wakely
On 27/12/19 22:27 -0500, JeanHeyd Meneide wrote: On Fri, Dec 27, 2019 at 2:33 PM Jakub Jelinek wrote: This will be ABI incompatible between GCC and Clang, that doesn't look like a good idea to me. I thought the plan is to use what you have in the _GLIBCXX_HAVE_BUILTIN_SOURCE_LOCATION case alw

[PATCH] Mark -free as Optimization option.

2020-01-02 Thread Martin Liška
Hi. The flag is set based on optimization option: gcc/common/config/i386/i386-common.c:{ OPT_LEVELS_2_PLUS, OPT_free, NULL, 1 }, and so that it should be also per-function. The only usage of the flag is in gate of a RTL pass, so that it will use on function selection. Patch can bootstrap o

[PATCH] Mark param_min_crossjump_insns with Optimization keyword.

2020-01-02 Thread Martin Liška
Hi. Again, the param is set based on optimize_size: if (opts->x_optimize_size) /* We want to crossjump as much as possible. */ SET_OPTION_IF_UNSET (opts, opts_set, param_min_crossjump_insns, 1); So that, the param should be per-function. The only usage is in cfgcleanup that is done p

[PATCH] Mark param_max_combine_insns with Optimization keyword.

2020-01-02 Thread Martin Liška
Hi. The param is changed here: /* Restrict the amount of work combine does at -Og while retaining most of its useful transforms. */ if (opts->x_optimize_debug) SET_OPTION_IF_UNSET (opts, opts_set, param_max_combine_insns, 2); and so that it should be per-function. The only usage i

Re: [C++ PATCH] PR c++/92745 - bogus error when initializing array of vectors.

2020-01-02 Thread Christophe Lyon
On Fri, 20 Dec 2019 at 21:28, Marek Polacek wrote: > In r268428 I changed reshape_init_r in such a way that when it sees > a nested { } in a CONSTRUCTOR with missing braces, it just returns > the initializer: > + else if (COMPOUND_LITERAL_P (stripped_init) > ... > + ++d->cur; > +

Re: [C++ PATCH] PR c++/92745 - bogus error when initializing array of vectors.

2020-01-02 Thread Jakub Jelinek
On Thu, Jan 02, 2020 at 03:41:30PM +0100, Christophe Lyon wrote: > The new test fails on aarch64: > g++.dg/cpp0x/initlist118.C -std=c++14 (internal compiler error) > g++.dg/cpp0x/initlist118.C -std=c++14 (test for excess errors) > g++.dg/cpp0x/initlist118.C -std=c++17 (internal compi

Re: [C++ PATCH] PR c++/92745 - bogus error when initializing array of vectors.

2020-01-02 Thread Christophe Lyon
On Thu, 2 Jan 2020 at 15:45, Jakub Jelinek wrote: > On Thu, Jan 02, 2020 at 03:41:30PM +0100, Christophe Lyon wrote: > > The new test fails on aarch64: > > g++.dg/cpp0x/initlist118.C -std=c++14 (internal compiler error) > > g++.dg/cpp0x/initlist118.C -std=c++14 (test for excess errors)

[Patch, committed, Fortran] PR68020 – Fix implied-shape handling for rank > 2

2020-01-02 Thread Tobias Burnus
implied-shape: Used with PARAMETER; takes the shape of the RHS and (F2018, R824) "implied-shape-spec  is  assumed-implied-spec, assumed-implied-spec-list" When matching an element in an array spec of this type, i.e. (R821) "assumed-implied-spec is [lower-bound: ] *", the matcher always returns

Re: [C++ PATCH] Fix up building of GCC 8 and earlier with GCC 9/10 (PR c/90677)

2020-01-02 Thread Nathan Sidwell
On 12/31/19 6:05 AM, Jakub Jelinek wrote: Hi! My PR90677 fix actually made building older GCCs with newer ones worse. The problem is that identifier_global_value used earlier returned either the type decl on success or NULL_TREE on failure and the caller in that case just defers handling it unti

Re: [C++ PATCH] Fix up building of GCC 8 and earlier with GCC 9/10 (PR c/90677)

2020-01-02 Thread Jakub Jelinek
On Thu, Jan 02, 2020 at 10:52:38AM -0500, Nathan Sidwell wrote: > On 12/31/19 6:05 AM, Jakub Jelinek wrote: > > My PR90677 fix actually made building older GCCs with newer ones worse. > > The problem is that identifier_global_value used earlier returned either the > > type decl on success or NULL_T

[PATCH][committed] Add myself to MAINTAINERS

2020-01-02 Thread Dennis Zhang
Hi all, This patch is to add myself to the Write After Approval section in MAINTAINERS. Committed with r279837. Cheers Dennis ChangeLog: 2019-01-02 Dennis Zhang * MAINTAINERS (Write After Approval): Add myself. diff --git a/MAINTAINERS b/MAINTAINERS index e3925a82355..e2ef8ae9af1

Re: [PATCH v2] ipa-cp: Fix PGO regression caused by r278808

2020-01-02 Thread Jan Hubicka
> v2 Changes: > 1. Enable proportion orig_sum to the new nodes for self recursive node: >new_sum = (orig_sum + new_sum) \ >* self_recursive_probability * (1 / param_ipa_cp_max_recursive_depth). > 2. Add value range for param_ipa_cp_max_recursive_depth. > > The performance of exchange2 buil

Re: [PATCH][Arm] Enable CLI for Armv8.6-a: armv8.6-a, i8mm and bf16

2020-01-02 Thread Dennis Zhang
Hi Kyrill, On 20/12/2019 15:30, Kyrill Tkachov wrote: > Hi Dennis, > > On 12/12/19 5:30 PM, Dennis Zhang wrote: >> Hi all, >> >> On 22/11/2019 14:33, Dennis Zhang wrote: >> > Hi all, >> > >> > This patch is part of a series adding support for Armv8.6-A features. >> > It enables options including

[Patch, Fortran] PR 92994 – add more ASSOCIATE checks

2020-01-02 Thread Tobias Burnus
Add some more checks for invalid use for the RHS in proc-pointer assignments and for ASSOCIATE targets (which uses the latter if the previous match failed). Build on x86-64-gnu-linux. OK for the trunk? Tobias PR fortran/92994 * primary.c (gfc_match_rvalue): Add some flavor checks gfc_match

Re: [C++ PATCH v2] Don't mangle attributes that have a space in their name

2020-01-02 Thread Jason Merrill
On 12/27/19 11:00 AM, Richard Sandiford wrote: Jason Merrill writes: On 12/18/19 1:24 PM, Richard Sandiford wrote: The SVE port needs to maintain a different type identity for GNU vectors and "SVE vectors" even during LTO, since the types use different ABIs. The easiest way of doing that seem

[Committed] Add two testcases for 1bit bit-field

2020-01-02 Thread Andrew Pinski
Hi, While working an optimization, the optimization would produce wrong code but I noticed there was no testcase for that case at all. Committed as obvious. Thanks, Andrew Pinski ChangeLog: * gcc.c-torture/execute/bitfld-8.c: New testcase. * gcc.c-torture/execute/bitfld-9.c: New testcase. Inde

Re: [Patch, committed, Fortran] PR68020 – Fix implied-shape handling for rank > 2

2020-01-02 Thread Rainer Orth
Hi Tobias, > implied-shape: Used with PARAMETER; takes the shape of the RHS and (F2018, > R824) "implied-shape-spec  is  assumed-implied-spec, > assumed-implied-spec-list" > > When matching an element in an array spec of this type, i.e. (R821) > "assumed-implied-spec is [lower-bound: ] *", the mat

Go patch committed: Split writing of equal and hash functions for types

2020-01-02 Thread Ian Lance Taylor
This patch to the Go frontend splits the writing of equal and hash functions for types, rather than doing them in a single operation. This is almost entirely a pure refactoring in preparation for generating hash functions only for types that are map keys. The only change in generated code is that

Go patch committed: Generate hash functions only for map keys

2020-01-02 Thread Ian Lance Taylor
This patch to the Go frontend and libgo changes the compiler to only generate hash functions for types used as map keys. Right now we generate hash functions for all types, just in case they are used as map keys. That's a lot of wasted effort and binary size for types which will never be used as a

Re: [ PATCH ] [ C++ ] [ libstdc++ ] P1208r6 Merge source_location

2020-01-02 Thread JeanHeyd Meneide
On Thu, Jan 2, 2020 at 5:28 AM Jonathan Wakely wrote: > > Do nothing - compiling with Clang won't define std::source_location at > all. You got it! Patch re-done after discussion here (https://gcc.gnu.org/bugzilla/show_bug.cgi?id=93093) and recommended no-Clang change. 2020-01-02 JeanHeyd "TheP

Re: [ PATCH ] [ C++ ] [ libstdc++ ] P1208r6 Merge source_location

2020-01-02 Thread Jakub Jelinek
On Thu, Jan 02, 2020 at 04:57:01PM -0500, JeanHeyd Meneide wrote: > +#if defined(_GLIBCXX_HAVE_BUILTIN_SOURCE_LOCATION) > +# define __cpp_lib_source_location 201907L > +#elif defined(_GLIBCXX_HAVE_BUILTIN_LINE) && > defined(_GLIBCXX_HAVE_BUILTIN_COLUMN) > +# define __cpp_lib_is_constant_evaluated

[ PATCH ] [ C++ ] [ libstdc++ ] P0674r1 - Extend support for arrays in make/allocate_shared

2020-01-02 Thread JeanHeyd Meneide
Glen Fernandes is already working on a patch, so I decided to finish off my changes and throw them up on the Patch List so that Glen can access the tests parts that I had written (they are not incredibly extensive but do pass). For a small implementation description: the code I use does the sa

Re: [ PATCH ] [ C++ ] [ libstdc++ ] P1208r6 Merge source_location

2020-01-02 Thread JeanHeyd Meneide
On Thu, Jan 2, 2020 at 5:07 PM Jakub Jelinek wrote: > > On Thu, Jan 02, 2020 at 04:57:01PM -0500, JeanHeyd Meneide wrote: > > +#if defined(_GLIBCXX_HAVE_BUILTIN_SOURCE_LOCATION) > > +# define __cpp_lib_source_location 201907L > > +#elif defined(_GLIBCXX_HAVE_BUILTIN_LINE) && > > defined(_GLIBCXX_

[patch, fortran] Fix PR 65428, ICE on nested empty array constructors

2020-01-02 Thread Thomas Koenig
Hello world, the attached patch fixes an ICE where an array constructor containing an empty array constructor with a type didn't get the type from the inner constructor. The solution is to stash the type away in yet another variable and only use it if the constructor turns out to be empty, and t

Re: [Patch, Fortran] PR 92994 – add more ASSOCIATE checks

2020-01-02 Thread Thomas Koenig
Hi Tobias, Build on x86-64-gnu-linux. OK for the trunk? Looks good. Thanks for the patch! Regards Thomas

[PATCH 2/2] analyzer: diagnostic_path: fix up expected analyzer output

2020-01-02 Thread David Malcolm
Successfully bootstrapped & regrtested on x86_64-pc-linux-gnu. Pushed to dmalcolm/analyzer on the GCC git mirror. gcc/testsuite/ChangeLog: * gcc.dg/analyzer/analyzer-verbosity-0.c: Update expected output to remove source code from diagnostic locus, made redundant by path.

[PATCH 1/2] analyzer: diagnostic_path: avoid printing redundant data

2020-01-02 Thread David Malcolm
This patch tweaks the default implementation of diagnostic_path printing (-fdiagnostics-path-format=inline-events) to be less verbose for various common cases. Consider this synthetic diagnostic from the test plugin: test.c: In function 'test': test.c:29:5: error: passing NULL as argument 1 to 'P

Re: [Patch, committed, Fortran] PR68020 – Fix implied-shape handling for rank > 2

2020-01-02 Thread Jakub Jelinek
On Thu, Jan 02, 2020 at 04:43:29PM +0100, Tobias Burnus wrote: > Committed as Rev. 279835 after building an regtesting the attached patch. +UNRESOLVED: gfortran.dg/implied_shape_5.f90 -O0 compilation failed to produce executable +UNRESOLVED: gfortran.dg/implied_shape_5.f90 -O1 compilation f

Fix OpenACC deep-copy-10.c and lib-16-2.f90 test async-safety issues (PR93030)

2020-01-02 Thread Julian Brown
Hi, This patch fixes some unsafe usage of asynchronous operations in a couple of OpenACC tests. I have extracted it from the og9 version of the patch posted here concerning "ephemeral" asynchronous host-to-device copies: https://gcc.gnu.org/ml/gcc-patches/2019-11/msg01482.html The deep-copy-10