Re: [PATCH] doc: clarify the situation with pointer arithmetic

2020-01-22 Thread Richard Biener
On Wed, 22 Jan 2020, Joseph Myers wrote: > On Tue, 21 Jan 2020, Richard Biener wrote: > > > Second. Fact is RTL does not distinguish between pointers and > > integers and thus any attempt to make something valid when you > > use integers and invalid when you use pointers is not going to work. >

Re: [PATCH] Prune invalid filename due to makefile syntax.

2020-01-22 Thread Richard Biener
On Tue, Jan 21, 2020 at 5:40 PM Nathan Sidwell wrote: > > On 1/21/20 11:26 AM, Richard Biener wrote: > > On January 21, 2020 4:37:00 PM GMT+01:00, Jan Hubicka > > wrote: > > >> I would say we want to fix that... Even GCC gets idea to put # info > >> filenames and I am sure except for HHVM there

[PATCH 3/4] [ARC] Save mlo/mhi registers when ISR.

2020-01-22 Thread Claudiu Zissulescu
ARC600 when configured with mul64 instructions uses mlo and mhi registers to store the 64 result of the multiplication. In the ARC600 ISA documentation we have the next register configuration when ARC600 is configured only with mul64 extension: Register | Name | Use -+--+--

[PATCH 1/4] [ARC] Make libgcc compatible with ARC's reduced register set config.

2020-01-22 Thread Claudiu Zissulescu
ARC processors can work with a reduced register set (i.e. registers r4-r9 and r16-r25 are not available). This option can be enabled passing -mrf16 option to the compiler, or by using -mcpu=em_mini CPU configuration. Using RF16 config requires all the hand-made assembly files used in libgcc to have

[PATCH 2/4] [ARC] Propagate uncached type attribute.

2020-01-22 Thread Claudiu Zissulescu
Like `packed` type attribute, the ARC's `uncached` type attribute needs to be propagated to each member of the struct where it is used. Fix this behavior and add a test. gcc/ -xx-xx Claudiu Zissulescu * config/arc/arc.c (arc_is_uncached_mem_p): Check struct attributes if ne

[PATCH 4/4] [ARC] Update ARC600 multiplication cost.

2020-01-22 Thread Claudiu Zissulescu
The ARC's 600 multiplication instruction can accept signed 12 bit instructions. gcc/ -xx-xx Claudiu Zissulescu * config/arc/arc.c (arc_rtx_costs): Update mul64 cost. --- gcc/config/arc/arc.c | 6 ++ 1 file changed, 6 insertions(+) diff --git a/gcc/config/arc/arc.c b/gcc/confi

Re: Fix updating of call_stmt_site_hash

2020-01-22 Thread Richard Biener
On Tue, Jan 21, 2020 at 8:09 PM Jan Hubicka wrote: > > > On January 21, 2020 4:37:31 PM GMT+01:00, Jan Hubicka > > wrote: > > >Hi, > > >this patch fixes ICE causes by call stmt site hash going out of sync. > > >For > > >speculative edges it is assumed to contain a direct call so if we are > > >r

Re: [PATCH] powerpc: Fix ICE with fp conditional move (PR target/93073)

2020-01-22 Thread Iain Sandoe
Segher Boessenkool wrote: On Mon, Jan 20, 2020 at 11:52:55PM +0100, Jakub Jelinek wrote: PR target/93073 * config/rs6000/rs6000.c (rs6000_emit_cmove): Punt for compare_mode other than SFmode or DFmode. "If using fsel, punt for..." etc. + /* Don't allow compare_mode other th

[PATCH] aarch64: Fix aarch64_expand_subvti constant handling [PR93335]

2020-01-22 Thread Jakub Jelinek
Hi! The two patterns that call aarch64_expand_subvti ensure that {low,high}_in1 is a register, while {low,high}_in2 can be a register or immediate. subdi3_compare1_imm uses the aarch64_plus_immediate predicate for its last two operands (the value and negated value), but aarch64_expand_subvti calls

[wwwdocs] Improve the presentation of our instructions on checksuming.

2020-01-22 Thread Gerald Pfeifer
On the way remove a note about binary snapshots that's been commented for a while. Pushed. Gerald --- htdocs/snapshots.html | 14 -- 1 file changed, 4 insertions(+), 10 deletions(-) diff --git a/htdocs/snapshots.html b/htdocs/snapshots.html index 6567a857..7776d95e 100644 --- a/htdo

[committed] openmp: Teach omp_code_to_statement about rest of OpenMP statements (PR93329)

2020-01-22 Thread Jakub Jelinek
Hi! The omp_code_to_statement function added with the initial OpenACC support only handled small subset of the OpenMP statements, leading to ICE if any other OpenMP directive appeared inside of OpenACC directive. The following patch teaches it to handle the rest and adds testcase that verifies th

[committed] openmp: Fix up !$omp target parallel handling

2020-01-22 Thread Jakub Jelinek
Hi! The PR93329 fix revealed we ICE on !$omp target parallel, this change fixes that. Another case where some OpenMP 4.5 support has been added, but I didn't have time to add corresponding testsuite coverage yet (~ backports of the C/C++ patches added when the C/C++ support has been added). Boot

Re: [PATCH, v2] wwwdocs: e-mail subject lines for contributions

2020-01-22 Thread Jakub Jelinek
On Tue, Jan 21, 2020 at 06:50:13PM +, Richard Earnshaw (lists) wrote: > > Doesn't this use of [] have the same problem with git am? > > No, because only 'leading' [] blocks are removed - git mailinfo --help I've used openmp: Teach omp_code_to_statement about rest of OpenMP statements [PR93329

[wwwdocs] Remove svn.html which is not referenced internally any longer.

2020-01-22 Thread Gerald Pfeifer
Not only have I cleaned up all internal references, there's also a redirect from svn.html to git.html in place, so users should never get a 404. Pushed. Gerald --- htdocs/svn.html | 1219 --- 1 file changed, 1219 deletions(-) delete mode 100644 htdocs/

Re: [wwwdocs] Add GCC10 IPA/LTO changes

2020-01-22 Thread Jan Hubicka
> Hi, > here are some of changes of LTO/IPA done in GCC10. There is also > recursive cloning and some other stuff I will add incrementally as well > as some data on overall compile time/memory use improvements as we > reported in past years. I am still running tests and fixing bugs in this > area.

Re: [PATCH, v2] wwwdocs: e-mail subject lines for contributions

2020-01-22 Thread Richard Earnshaw (lists)
On 22/01/2020 09:07, Jakub Jelinek wrote: On Tue, Jan 21, 2020 at 06:50:13PM +, Richard Earnshaw (lists) wrote: Doesn't this use of [] have the same problem with git am? No, because only 'leading' [] blocks are removed - git mailinfo --help I've used openmp: Teach omp_code_to_statement a

Re: [PATCH, v2] wwwdocs: e-mail subject lines for contributions

2020-01-22 Thread Jakub Jelinek
On Wed, Jan 22, 2020 at 09:35:31AM +, Richard Earnshaw (lists) wrote: > On 22/01/2020 09:07, Jakub Jelinek wrote: > > On Tue, Jan 21, 2020 at 06:50:13PM +, Richard Earnshaw (lists) wrote: > > > > Doesn't this use of [] have the same problem with git am? > > > > > > No, because only 'leadin

Re: [wwwdocs] Add GCC10 IPA/LTO changes

2020-01-22 Thread Gerald Pfeifer
On Mon, 30 Dec 2019, Jan Hubicka wrote: > here are some of changes of LTO/IPA done in GCC10. Quite a bit! :-) > +The following GCC command line options have been introduced or > improved. ...command-line... > + href="https://gcc.gnu.org/onlinedocs/gcc-10.1.0/gcc/Optimize-Options.html#index-

Re: [PATCH, v2] wwwdocs: e-mail subject lines for contributions

2020-01-22 Thread Richard Earnshaw (lists)
On 21/01/2020 19:26, Segher Boessenkool wrote: Hi! Thanks for doing this. On Tue, Jan 21, 2020 at 02:52:00PM +, Richard Earnshaw (lists) wrote: This patch proposes some new (additional) rules for email subject lines when contributing to GCC. The goal is to make sure that, as far as possib

Re: [patch] contrib: script to create a new vendor branch

2020-01-22 Thread Richard Earnshaw (lists)
On 21/01/2020 23:23, Hans-Peter Nilsson wrote: From: "Richard Earnshaw (lists)" Date: Tue, 21 Jan 2020 14:36:32 +0100 Correction, the branch should be named /, so the push should be git push vendors/ / For example, for the ARM vendor, the push would be git push vendors/ARM ARM/ R. will

Re: [patch] contrib: script to create a new vendor branch

2020-01-22 Thread Richard Earnshaw (lists)
On 22/01/2020 10:04, Richard Earnshaw (lists) wrote: On 21/01/2020 23:23, Hans-Peter Nilsson wrote: From: "Richard Earnshaw (lists)" Date: Tue, 21 Jan 2020 14:36:32 +0100 Correction, the branch should be named /, so the push should be git push vendors/ / For example, for the ARM vendor, th

Re: [RFC c-common PATCH] PR c++/40752 - useless -Wconversion with short +=.

2020-01-22 Thread Martin Liška
Hi. Just for the record, after the change 526.blender_r fails due to: blender/source/blender/blenlib/intern/math_color.c: In function 'rgb_float_to_uchar': blender/source/blender/blenlib/BLI_utildefines.h:251:22: error: conversion from 'float' to 'unsigned char' may change value [-Werror=float

Re: Define HAVE_ for math long double functions declared in vxworks headers

2020-01-22 Thread Jonathan Wakely
On 21/01/20 21:50 -0300, Alexandre Oliva wrote: On Jan 3, 2020, Jonathan Wakely wrote: +#include +#ifdef HAVE_IEEEFP_H +# include +#endif +], [ + void (*f)(void) = (void (*)(void))$1; I wondered whether using ($1) here instead of just $1 would give any benefit. It would mean that functi

Re: Define HAVE_ for math long double functions declared in vxworks headers

2020-01-22 Thread Andreas Schwab
On Dez 25 2019, Alexandre Oliva wrote: > +dnl # Different versions and execution modes implement different > +dnl # subsets of these functions. Instead of hard-coding, test for C > +dnl # declarations in headers. The C primitives could be defined as > +dnl # macros, in which case the tests might

Re: tolerate padding in mbstate_t

2020-01-22 Thread Jonathan Wakely
On 21/01/20 23:04 -0300, Alexandre Oliva wrote: On Jan 21, 2020, Jonathan Wakely wrote: On 21/01/20 21:36 -0300, Alexandre Oliva wrote: Padding in mbstate_t objects may get the memcmp to fail. Attempt to avoid the failure with zero initialization. Regstrapped on x86_64-linux-gnu, and also

Add News-feed item for git transition

2020-01-22 Thread Richard Earnshaw (lists)
We're missing a statement on the main news feed about the git transition. diff --git a/htdocs/index.html b/htdocs/index.html index 41bcfe18..ef85cc97 100644 --- a/htdocs/index.html +++ b/htdocs/index.html @@ -54,6 +54,10 @@ mission statement. News +GCC source repository converted to git. +

Re: [PATCH] aarch64: Fix aarch64_expand_subvti constant handling [PR93335]

2020-01-22 Thread Richard Sandiford
Jakub Jelinek writes: > Hi! > > The two patterns that call aarch64_expand_subvti ensure that {low,high}_in1 > is a register, while {low,high}_in2 can be a register or immediate. > subdi3_compare1_imm uses the aarch64_plus_immediate predicate for its last > two operands (the value and negated value

Re: [patch, fortran] Fix PR 85781, ICE on valid

2020-01-22 Thread Tobias Burnus
Hi Thomas, hi all, first, I have now attached a different fix for PR 85781 (= original bug). Can you have a look? I have the feeling (but didn't check) that your patch does not handle the following variant of the test case: "print *, x(m:n)" (i.e. the lower bound is not known at compile time

[PATCH] cfgexpand: Update partition size when merging variables

2020-01-22 Thread Richard Sandiford
cfgexpand sorts variables by decreasing size, so when merging a later variable into an earlier one, there's usually no need to update the merged size. But for poly_int sizes, the sort function just uses a lexicographical comparison of the coefficients, so e.g. 2X+2 comes before 0X+32. Which is big

Re: [PATCH] Relax invalidation of TOP N counters in PGO.

2020-01-22 Thread Martin Liška
Hi. I've updated the patch based on Honza's notes and installed it as 5f32f9cf13f99f6295591927950aaf98aa8dba91. Just for the record, there are stats for cc1plus for PGO bootstrap: before: == Stats for gcc == stats for indirect_call: total: 9210 invalid: 760 tracked values: 0 values:

Re: [PATCH] Relax invalidation of TOP N counters in PGO.

2020-01-22 Thread Jan Hubicka
> Hi. > > I've updated the patch based on Honza's notes and installed it > as 5f32f9cf13f99f6295591927950aaf98aa8dba91. Thanks, you omitted the patch, but looking at git log I think there is still problem I commented on in the previous mail: for (unsigned i = 0; i < GCOV_TOPN_VALUES; i++)

[PATCH Coroutines]Fix an ICE case in expanding co_await expression

2020-01-22 Thread bin.cheng
Hi, Though function co_await_expander may need to be further revised, this simple patch fixes an ICE case in co_await_expander, Handle CO_AWAIT_EXPR in conversion in co_await_expander. Function co_await_expander expands CO_AWAIT_EXPR and inserts expanded code before result of c

[PATCH] tree-optimization/93381 fix integer offsetting in points-to analysis

2020-01-22 Thread Richard Biener
We were incorrectly assuming a merge operation is conservative enough for not explicitely handled operations but we also need to consider offsetting within fields when field-sensitive analysis applies. Bootstrapped and tested on x86_64-unknown-linux-gnu, pushed. Richard. 2020-22 Richard Biene

Re: [PATCH] doc: clarify the situation with pointer arithmetic

2020-01-22 Thread Martin Sebor
On 1/22/20 8:32 AM, Richard Biener wrote: On Tue, 21 Jan 2020, Alexander Monakov wrote: On Tue, 21 Jan 2020, Richard Biener wrote: Fourth. That PNVI (I assume it's the whole pointer-provenance stuff) wants to get the "best" of both which can never be done since a compiler needs to have a way

Re: [PATCH] Fix PowerPC -fstack-clash-protection -mprefixed-addr ICE (PR target/93122)

2020-01-22 Thread Jakub Jelinek
Hi! On Mon, Jan 06, 2020 at 02:46:30PM -0600, Segher Boessenkool wrote: > > > Another option would be to: > > > 1) always use gen_add3_insn, but if it returns NULL use the extra > > > emit_move_insn (end_addr, GEN_INT (-rounded_size)); > > > and retry with end_addr instead of rs > > > 2) if the fi

[PATCH] cprop: Don't replace fixed hard regs with pseudos [PR93124]

2020-01-22 Thread Richard Sandiford
One consequence of r276318 was that cselib now preserves sp-based values across function calls. This in turn convinced cprop to replace the clobber in: (set (reg PSUEDO) (reg sp)) ... (call ...) ... (clobber (mem:BLK (reg sp))) with: (clobber (mem:BLK (reg PSEUDO))) But I dou

Re: [PATCH] Relax invalidation of TOP N counters in PGO.

2020-01-22 Thread Martin Liška
On 1/22/20 12:27 PM, Jan Hubicka wrote: Hi. I've updated the patch based on Honza's notes and installed it as 5f32f9cf13f99f6295591927950aaf98aa8dba91. Thanks, you omitted the patch, but looking at git log I think there is still problem I commented on in the previous mail: Whoops, sorry for t

[PATCH] auto-inc-dec: Don't add incs/decs to bare CLOBBERs [PR93124]

2020-01-22 Thread Richard Sandiford
In this PR, auto-inc-dec was trying to turn: (set (reg X) (plus (reg X) (const_int N))) (clobber (mem (reg X))) into: (clobber (mem (pre_modify (reg X) ...))) But bare clobber insns are just there to describe dataflow. They're not supposed to generate any code. This is part 2 of t

Re: [PATCH] Relax invalidation of TOP N counters in PGO.

2020-01-22 Thread Jan Hubicka
> 2020-01-22 Martin Liska > > PR tree-optimization/92924 > * libgcov-profiler.c (__gcov_topn_values_profiler_body): First > try to find an existing value, then find an empty slot > if not found. This looks good, one nit below. > --- > libgcc/libgcov-profiler.c | 46 +++

[committed] Extend r279588 to g++.dg/ext/sve-sizeless-1.C

2020-01-22 Thread Richard Sandiford
In r279588 I'd for some reason only patched g++.dg/ext/sve-sizeless-2.C, even though g++.dg/ext/sve-sizeless-1.C has the same problem. Tested on aarch64-linux-gnu and aarch64_be-elf, applied. Richard 2020-01-22 Richard Sandiford gcc/testsuite/ * g++.dg/ext/sve-sizeless-1.C: Don't ex

[committed] Fix gcc.target/aarch64/sve/sel_3.c for big-endian targets

2020-01-22 Thread Richard Sandiford
A pasto in this test meant that we needed extra reverse instructions for big-endian targets. Tested on aarch64-linux-gnu and aarch64_be-elf, applied. Richard 2020-01-22 Richard Sandiford gcc/testsuite/ * gcc.target/aarch64/sve/sel_3.c (permute_vnx4sf): Take __SVFloat32_t rat

[committed] Skip gcc.target/aarch64/sve/tls_preserve* for emultls targets

2020-01-22 Thread Richard Sandiford
These tests are supposed to be testing the tlsdesc handling and so don't apply to emultls targets. Tested on aarch64-linux-gnu and aarch64_be-elf, applied. Richard 2020-01-22 Richard Sandiford gcc/testsuite/ * gcc.target/aarch64/sve/tls_preserve_1.c: Require tls_native. * gc

Re: [PATCH] Relax invalidation of TOP N counters in PGO.

2020-01-22 Thread Martin Liška
On 1/22/20 1:19 PM, Jan Hubicka wrote: I think you can save an instruction in the loop if you drop "&& empty_counter == -1" My motivation was to find a first empty slot. Which means we'll have less holes, but it's probably a micro-optimization. I'm going to install the patch without the "&& e

Re: [PATCH] Relax invalidation of TOP N counters in PGO.

2020-01-22 Thread Martin Liška
On 1/22/20 12:09 PM, Martin Liška wrote: stats for indirect_call:   total: 9210   invalid: 600   tracked values: 0 values: 6280 times (68.19%) 1 values: 1856 times (20.15%) 2 values:  264 times (2.87%) 3 values:  157 times (1.70%) 4 values:   53 tim

Re: [PATCH] Relax invalidation of TOP N counters in PGO.

2020-01-22 Thread Jan Hubicka
> On 1/22/20 12:09 PM, Martin Liška wrote: > > stats for indirect_call: > >   total: 9210 > >   invalid: 600 > >   tracked values: > > 0 values: 6280 times (68.19%) > > 1 values: 1856 times (20.15%) > > 2 values:  264 times (2.87%) > > 3 values:  157 times (1.

Re: [PATCH, v2] wwwdocs: e-mail subject lines for contributions

2020-01-22 Thread Segher Boessenkool
On Wed, Jan 22, 2020 at 10:00:00AM +, Richard Earnshaw (lists) wrote: > On 21/01/2020 19:26, Segher Boessenkool wrote: > >On Tue, Jan 21, 2020 at 02:52:00PM +, Richard Earnshaw (lists) wrote: > >>+ A brief summary > > > >You could stress that this is the one thing that really matters. And

[PATCH] tree-optimization/93354 FRE redundant store removal validity fix

2020-01-22 Thread Richard Biener
This fixes the validity check for redundant store removal by looking at the actual stmt that represents the last (relevant) change to the TBAA state rather than the imperfectly tracked alias set in the expression hash table which then becomes unused (see a followup change to get rid of that). On

Re: Add News-feed item for git transition

2020-01-22 Thread Gerald Pfeifer
On Wed, 22 Jan 2020, Richard Earnshaw (lists) wrote: > We're missing a statement on the main news feed about the git transition. Lovely, thanks. Gerald PS: Lovely referring to you creating the patch, not the missing announcement. ;-)

Re: [PATCH] Fix PowerPC -fstack-clash-protection -mprefixed-addr ICE (PR target/93122)

2020-01-22 Thread Segher Boessenkool
Hi! On Mon, Jan 06, 2020 at 09:24:10AM +0100, Jakub Jelinek wrote: > 1) always use gen_add3_insn, but if it returns NULL use the extra > emit_move_insn (end_addr, GEN_INT (-rounded_size)); > and retry with end_addr instead of rs > 2) if the first gen_add3_insn returned NULL or if it created more t

Re: [PATCH] cfgexpand: Update partition size when merging variables

2020-01-22 Thread Richard Biener
On Wed, Jan 22, 2020 at 11:59 AM Richard Sandiford wrote: > > cfgexpand sorts variables by decreasing size, so when merging a later > variable into an earlier one, there's usually no need to update the > merged size. > > But for poly_int sizes, the sort function just uses a lexicographical > compa

Re: [PATCH] Fix PowerPC -fstack-clash-protection -mprefixed-addr ICE (PR target/93122)

2020-01-22 Thread Jakub Jelinek
On Wed, Jan 22, 2020 at 08:06:03AM -0600, Segher Boessenkool wrote: > On Mon, Jan 06, 2020 at 09:24:10AM +0100, Jakub Jelinek wrote: > > 1) always use gen_add3_insn, but if it returns NULL use the extra > > emit_move_insn (end_addr, GEN_INT (-rounded_size)); > > and retry with end_addr instead of r

[PATCH] avoid -Wrestrict on sprintf %p with destination as argument (PR 84919)

2020-01-22 Thread Martin Sebor
The early front-end only implementation of -Wrestrict that's still present in GCC 10 issues a false postive for %p arguments that are the same as the destination. Bug 84919 reports an instance of this false positive in the Linux kernel. That attached patch suppresses the front-end warning for th

Re: [patch, fortran] Fix PR 85781, ICE on valid

2020-01-22 Thread Steve Kargl
On Wed, Jan 22, 2020 at 11:59:12AM +0100, Tobias Burnus wrote: > > And, additionally, about missing diagnostic related to (2) bind(c) and > kind=4, > Are you sure there is a missing diagnostic? You need to add -Wc-binding-type or -Wall to your command line. subroutine p(c) bind(c) use iso_c

[C++ Patch] PR 92804 [10 Regression] ICE trying to use concept as a nested-name-specifier

2020-01-22 Thread Paolo Carlini
Hi, in this simple issue we either wrongly talked about variable template-id in c++17 mode or ICEd in c++2a. I think we simply want to handle concept-ids first, both as represented in c++17 mode and as represented in c++2a mode. Tested x86_64-linux. Thanks, Paolo. /// F

[PATCH] gcc: Add new configure options to allow static libraries to be selected

2020-01-22 Thread Andrew Burgess
The motivation behind this change is to make it easier for a user to link against static libraries on a target where dynamic libraries are the default library type (for example GNU/Linux). Further, my motivation is really for linking libraries into GDB, however, the binutils-gdb/config/ directory

wwwdocs: Document the gcc git repository layout

2020-01-22 Thread Richard Earnshaw (lists)
The GCC git repository makes use of some non-standard refs so that by default only the most active and useful branches and tags are fetched by a git clone. This patch documents the additional branch and tag spaces that exist on the server. Joseph, have I got all of these right? R. diff --git

Re: [patch, fortran] Fix PR 85781, ICE on valid

2020-01-22 Thread Tobias Burnus
Hi Steve, On 1/22/20 4:02 PM, Steve Kargl wrote: On Wed, Jan 22, 2020 at 11:59:12AM +0100, Tobias Burnus wrote: And, additionally, about missing diagnostic related to (2) bind(c) and kind=4, Are you sure there is a missing diagnostic? You need to add -Wc-binding-type or -Wall to your command

Re: [patch, fortran] Fix PR 85781, ICE on valid

2020-01-22 Thread Steve Kargl
On Wed, Jan 22, 2020 at 04:43:49PM +0100, Tobias Burnus wrote: > Hi Steve, > > On 1/22/20 4:02 PM, Steve Kargl wrote: > > On Wed, Jan 22, 2020 at 11:59:12AM +0100, Tobias Burnus wrote: > >> And, additionally, about missing diagnostic related to (2) bind(c) and > >> kind=4, > > Are you sure there i

Re: [PATCH, v2] wwwdocs: e-mail subject lines for contributions

2020-01-22 Thread Richard Sandiford
"Richard Earnshaw (lists)" writes: > On 21/01/2020 17:20, Jason Merrill wrote: >> On 1/21/20 10:40 AM, Richard Earnshaw (lists) wrote: >>> On 21/01/2020 15:39, Jakub Jelinek wrote: On Tue, Jan 21, 2020 at 03:33:22PM +, Richard Earnshaw (lists) wrote: >> Some examples would be us

Re: [patch, fortran] Fix PR 85781, ICE on valid

2020-01-22 Thread Tobias Burnus
Hi Steve, On 1/22/20 4:54 PM, Steve Kargl wrote: Supposedly, one can use attr.is_c_interop and attr.is_iso_c to determine if something is interoperable (if it is consistently set) and if it is from the ISO C Binding module. I think this is fixable on two sides: * For the used tree type, one

Re: [PATCH] Fix a couple of memory leaks in the C++ frontend

2020-01-22 Thread Patrick Palka
On Tue, 21 Jan 2020, Jason Merrill wrote: On 1/20/20 8:06 PM, Patrick Palka wrote: The leak in get_mapped_args is due to auto_vec not properly supporting destructible elements, in that auto_vec's destructor doesn't call the destructors of its elements. Hmm, perhaps vec should static_assert __

Re: [C++ Patch] PR 92804 [10 Regression] ICE trying to use concept as a nested-name-specifier

2020-01-22 Thread Jason Merrill
On 1/22/20 10:22 AM, Paolo Carlini wrote: Hi, in this simple issue we either wrongly talked about variable template-id in c++17 mode or ICEd in c++2a. I think we simply want to handle concept-ids first, both as represented in c++17 mode and as represented in c++2a mode. Tested x86_64-linux.

Re: [PATCH, v2] wwwdocs: e-mail subject lines for contributions

2020-01-22 Thread Marek Polacek
On Wed, Jan 22, 2020 at 04:05:37PM +, Richard Sandiford wrote: > "Richard Earnshaw (lists)" writes: > > On 21/01/2020 17:20, Jason Merrill wrote: > >> On 1/21/20 10:40 AM, Richard Earnshaw (lists) wrote: > >>> On 21/01/2020 15:39, Jakub Jelinek wrote: > On Tue, Jan 21, 2020 at 03:33:22PM

Re: [C++ PATCH v2] PR c++/92907 - noexcept does not consider "const" in member functions.

2020-01-22 Thread Marek Polacek
On Tue, Jan 21, 2020 at 10:40:09PM -0500, Jason Merrill wrote: > On 1/21/20 9:08 PM, Marek Polacek wrote: > > Here the problem is that if the noexcept specifier is used in the context > > of a const member function, const is not considered for the member > > variables, > > leading to a bogus error

Re: [PATCH, v2] wwwdocs: e-mail subject lines for contributions

2020-01-22 Thread Richard Earnshaw (lists)
On 22/01/2020 16:28, Marek Polacek wrote: On Wed, Jan 22, 2020 at 04:05:37PM +, Richard Sandiford wrote: "Richard Earnshaw (lists)" writes: On 21/01/2020 17:20, Jason Merrill wrote: On 1/21/20 10:40 AM, Richard Earnshaw (lists) wrote: On 21/01/2020 15:39, Jakub Jelinek wrote: On Tue, Ja

[PATCH] Fix comparison of trees via tree_cmp

2020-01-22 Thread Stefan Schulze Frielinghaus
Hi David, In function `tree_cmp` an invariant [1] is assumed which does not necessarily exist. In case both input trees are finally compared via `strcmp`, then tree_cmp (t1, t2) == -tree_cmp (t2, t1) does not hold in general, since function `strcmp (x, y)` guarantees only that a negative integ

Re: [PATCH] Fix comparison of trees via tree_cmp

2020-01-22 Thread Alexander Monakov
On Wed, 22 Jan 2020, Stefan Schulze Frielinghaus wrote: > Hi David, > > In function `tree_cmp` an invariant [1] is assumed which does not necessarily > exist. In case both input trees are finally compared via `strcmp`, then > > tree_cmp (t1, t2) == -tree_cmp (t2, t1) > > does not hold in g

Re: [C++ PATCH v2] PR c++/92907 - noexcept does not consider "const" in member functions.

2020-01-22 Thread Jason Merrill
On 1/22/20 11:33 AM, Marek Polacek wrote: Here's what I did. Unfortunately it doesn't fix PR79620. No, I wouldn't expect it to, that looks like more of an issue with how is_lambda_ignored_entity skips captures in unevaluated context. + cp_cv_quals quals; + if (DECL_NONSTATIC_MEMBER_FUNCT

Re: [PATCH] Fix a couple of memory leaks in the C++ frontend

2020-01-22 Thread Jason Merrill
On 1/22/20 11:19 AM, Patrick Palka wrote: On Tue, 21 Jan 2020, Jason Merrill wrote: On 1/20/20 8:06 PM, Patrick Palka wrote: The leak in get_mapped_args is due to auto_vec not properly supporting destructible elements, in that auto_vec's destructor doesn't call the destructors of its elements.

Re: [C++ PATCH v3] PR c++/92907 - noexcept does not consider "const" in member functions.

2020-01-22 Thread Marek Polacek
On Wed, Jan 22, 2020 at 12:10:12PM -0500, Jason Merrill wrote: > On 1/22/20 11:33 AM, Marek Polacek wrote: > > Here's what I did. Unfortunately it doesn't fix PR79620. > > No, I wouldn't expect it to, that looks like more of an issue with how > is_lambda_ignored_entity skips captures in unevaluat

Re: [GCC][PATCH][AArch32] ACLE intrinsics bfloat16 vmmla and vfma for AArch32 AdvSIMD

2020-01-22 Thread Delia Burduv
Ping. I have read Richard Sandiford's comments on the AArch64 patches and I will apply what is relevant to this patch as well. Particularly, I will change the tests to use the exact input and output registers and I will change the types of the rtl patterns. On 12/20/19 6:44 PM, Delia Burduv wr

Re: ACLE intrinsics: BFloat16 store (vst{q}_bf16) intrinsics for AArch32

2020-01-22 Thread Delia Burduv
Ping. I will change the tests to use the exact input and output registers as Richard Sandiford suggested for the AArch64 patches. On 12/20/19 6:46 PM, Delia Burduv wrote: > This patch adds the ARMv8.6 ACLE BFloat16 store intrinsics > vst{q}_bf16 as part of the BFloat16 extension. > (https://dev

Re: ACLE intrinsics: BFloat16 load intrinsics for AArch32

2020-01-22 Thread Delia Burduv
Ping. I will change the tests to use the exact input and output registers as Richard Sandiford suggested for the AArch64 patches. On 12/20/19 6:48 PM, Delia Burduv wrote: > This patch adds the ARMv8.6 ACLE BFloat16 load intrinsics vld{q}_bf16 > as part of the BFloat16 extension. > (https://deve

[PATCH, v3] wwwdocs: e-mail subject lines for contributions

2020-01-22 Thread Richard Earnshaw (lists)
[updated based on v2 discussions] This patch proposes some new (additional) rules for email subject lines when contributing to GCC. The goal is to make sure that, as far as possible, the subject for a patch will form a good summary when the message is committed to the repository if applied with

Re: [PATCH] Fix comparison of trees via tree_cmp

2020-01-22 Thread Jakub Jelinek
On Wed, Jan 22, 2020 at 08:08:32PM +0300, Alexander Monakov wrote: > > > On Wed, 22 Jan 2020, Stefan Schulze Frielinghaus wrote: > > > Hi David, > > > > In function `tree_cmp` an invariant [1] is assumed which does not > > necessarily > > exist. In case both input trees are finally compared vi

Re: [RFC c-common PATCH] PR c++/40752 - useless -Wconversion with short +=.

2020-01-22 Thread Jason Merrill
On 1/22/20 5:14 AM, Martin Liška wrote: Hi. Just for the record, after the change 526.blender_r fails due to: blender/source/blender/blenlib/intern/math_color.c: In function 'rgb_float_to_uchar': blender/source/blender/blenlib/BLI_utildefines.h:251:22: error: conversion from 'float' to 'unsig

libgo patch committed: Update runtime_nanotime call

2020-01-22 Thread Ian Lance Taylor
In the update of libgo to Go1.14beta1, the function runtime_nanotime was renamed to runtime_nanotime1. I missed one reference that is not compiled on x86 code. This patch fixes that. This fixes https://golang.org/issue/36694. Bootstrapped and ran Go testsuite on x86_64-pc-linux-gnu. Committed

Re: [PATCH] analyzer: introduce namespace to avoid ODR clashes (PR 93307)

2020-01-22 Thread David Malcolm
On Fri, 2020-01-17 at 16:54 -0500, David Malcolm wrote: > PR analyzer/93307 reports that in an LTO bootstrap, there are ODR > violations between: > - the "region" type: > gcc/analyzer/region-model.h:792 > vs: > gcc/sched-int.h:1443 > - the "constraint" type: > gcc/analyzer/constraint-

[committed] Backports to 9.x branch

2020-01-22 Thread Jakub Jelinek
Hi! I've backported these 15 commits from trunk to 9.x branch, bootstrapped/regtested them on x86_64-linux and i686-linux and committed. Jakub PR c++/92992 * call.c (convert_arg_to_ellipsis): For decltype(nullptr) arguments that have side-effects use cp_build_compo

[committed] analyzer: testsuite fixes for alloca, getpass, and setjmp (PR 93316)

2020-01-22 Thread David Malcolm
PR analyzer/93316 reports various testsuite failures where I accidentally relied on properties of x86_64-pc-linux-gnu. The following patch fixes them on sparc-sun-solaris2.11 (gcc211 in the GCC compile farm), and, I hope, the other configurations showing failures. There may still be other failure

Re: [PATCH] cprop: Don't replace fixed hard regs with pseudos [PR93124]

2020-01-22 Thread Jeff Law
On Wed, 2020-01-22 at 12:02 +, Richard Sandiford wrote: > One consequence of r276318 was that cselib now preserves sp-based > values across function calls. This in turn convinced cprop to > replace the clobber in: > >(set (reg PSUEDO) (reg sp)) >... >(call ...) >... >(clob

Re: [committed] analyzer: testsuite fixes for alloca, getpass, and setjmp (PR 93316)

2020-01-22 Thread Jakub Jelinek
On Wed, Jan 22, 2020 at 02:35:13PM -0500, David Malcolm wrote: > PR analyzer/93316 reports various testsuite failures where I > accidentally relied on properties of x86_64-pc-linux-gnu. > > The following patch fixes them on sparc-sun-solaris2.11 (gcc211 in the > GCC compile farm), and, I hope, the

[committed] analyzer: fix setjmp handling with -g (PR 93378)

2020-01-22 Thread David Malcolm
PR analyzer/93378 reports an ICE at -O1 -g when analyzing a rewind via longjmp to a setjmp call with. The root cause is that the rewind_info_t::get_setjmp_call attempts to locate the setjmp GIMPLE_CALL via within the exploded_node containing it, but the exploded_node has two stmts: a GIMPLE_DEBUG,

Re: [PATCH] auto-inc-dec: Don't add incs/decs to bare CLOBBERs [PR93124]

2020-01-22 Thread Jeff Law
On Wed, 2020-01-22 at 12:11 +, Richard Sandiford wrote: > In this PR, auto-inc-dec was trying to turn: > > (set (reg X) (plus (reg X) (const_int N))) > (clobber (mem (reg X))) > > into: > > (clobber (mem (pre_modify (reg X) ...))) > > But bare clobber insns are just there to des

Re: [PATCH 4/4] [ARC] Update ARC600 multiplication cost.

2020-01-22 Thread Jeff Law
On Wed, 2020-01-22 at 10:14 +0200, Claudiu Zissulescu wrote: > The ARC's 600 multiplication instruction can accept signed 12 bit > instructions. > > gcc/ > -xx-xx Claudiu Zissulescu > > * config/arc/arc.c (arc_rtx_costs): Update mul64 cost. OK jeff >

Re: libgo patch committed: Update to Go1.14beta1

2020-01-22 Thread Rainer Orth
Hi Ian, > I've committed a patch to update libgo to Go 1.14beta1. As usual with > these updates the patch is far too large to include in this e-mail > message. I've included the diffs for gccgo-specific files. > Bootstrapped and ran Go tests on x86_64-pc-linux-gnu. Committed to > mainline. the

Re: [PATCH 3/4] [ARC] Save mlo/mhi registers when ISR.

2020-01-22 Thread Jeff Law
On Wed, 2020-01-22 at 10:14 +0200, Claudiu Zissulescu wrote: > ARC600 when configured with mul64 instructions uses mlo and mhi > registers to store the 64 result of the multiplication. In the ARC600 > ISA documentation we have the next register configuration when ARC600 > is configured only with mu

Re: [C++ Patch] PR 92804 [10 Regression] ICE trying to use concept as a nested-name-specifier

2020-01-22 Thread Paolo Carlini
Hi, On 22/01/20 17:27, Jason Merrill wrote: On 1/22/20 10:22 AM, Paolo Carlini wrote: Hi, in this simple issue we either wrongly talked about variable template-id in c++17 mode or ICEd in c++2a. I think we simply want to handle concept-ids first, both as represented in c++17 mode and as rep

Re: [PATCH] avoid -Wrestrict on sprintf %p with destination as argument (PR 84919)

2020-01-22 Thread Jeff Law
On Wed, 2020-01-22 at 15:59 +0100, Martin Sebor wrote: > The early front-end only implementation of -Wrestrict that's still > present in GCC 10 issues a false postive for %p arguments that are > the same as the destination. Bug 84919 reports an instance of this > false positive in the Linux kernel

[committed] analyzer: fix usage of "_setjmp" in test for PR 93378

2020-01-22 Thread David Malcolm
On Wed, 2020-01-22 at 14:56 -0500, David Malcolm wrote: > PR analyzer/93378 reports an ICE at -O1 -g when analyzing a rewind > via > longjmp to a setjmp call with. > > The root cause is that the rewind_info_t::get_setjmp_call attempts to > locate the setjmp GIMPLE_CALL via within the exploded_node

Re: [PATCH] Allow tree-ssa.exp to be run by itself

2020-01-22 Thread Jeff Law
On Tue, 2020-01-21 at 17:56 -0800, apin...@marvell.com wrote: > From: Andrew Pinski > > tree-ssa testcases sometimes check autovect effective target > but does not set it up. On MIPS, those testcases fail with > some TCL error messages. This fixes the issue by calling > check_vect_support_and_s

Re: [PATCH] testsuite: Add target/xfail argument to check-function-bodies

2020-01-22 Thread Jeff Law
On Tue, 2020-01-21 at 14:59 +, Richard Sandiford wrote: > check-function-bodies allows individual function tests to be > annotated with target/xfail selectors, but sometimes it's > useful to have the same selector for all functions. > > Tested on aarch64-linux-gnu and x86_64-linux-gnu, and wit

Re: [PATCH] Fix PR 93242: patchable-function-entry broken on MIPS

2020-01-22 Thread Jeff Law
On Mon, 2020-01-20 at 09:42 +0100, Richard Biener wrote: > On Sat, Jan 18, 2020 at 1:47 AM wrote: > > From: Andrew Pinski > > > > On MIPS, .set noreorder/reorder needs to emitted around > > the nop. The template for the nop instruction uses %(/%) to > > do that. But default_print_patchable_fun

Re: [PATCH] gcc: Add new configure options to allow static libraries to be selected

2020-01-22 Thread Jeff Law
On Wed, 2020-01-22 at 15:39 +, Andrew Burgess wrote: > The motivation behind this change is to make it easier for a user to > link against static libraries on a target where dynamic libraries are > the default library type (for example GNU/Linux). > > Further, my motivation is really for linki

Re: [PATCH 1/4] [ARC] Make libgcc compatible with ARC's reduced register set config.

2020-01-22 Thread Jeff Law
On Wed, 2020-01-22 at 10:14 +0200, Claudiu Zissulescu wrote: > ARC processors can work with a reduced register set (i.e. registers > r4-r9 and r16-r25 are not available). This option can be enabled > passing -mrf16 option to the compiler, or by using -mcpu=em_mini CPU > configuration. Using RF16 co

Re: [PATCH] avoid -Wrestrict on sprintf %p with destination as argument (PR 84919)

2020-01-22 Thread Martin Sebor
On 1/22/20 9:35 PM, Jeff Law wrote: On Wed, 2020-01-22 at 15:59 +0100, Martin Sebor wrote: The early front-end only implementation of -Wrestrict that's still present in GCC 10 issues a false postive for %p arguments that are the same as the destination. Bug 84919 reports an instance of this fal

Re: [PATCH] Fix PR 93242: patchable-function-entry broken on MIPS

2020-01-22 Thread Andrew Pinski
On Wed, Jan 22, 2020 at 12:48 PM Jeff Law wrote: > > On Mon, 2020-01-20 at 09:42 +0100, Richard Biener wrote: > > On Sat, Jan 18, 2020 at 1:47 AM wrote: > > > From: Andrew Pinski > > > > > > On MIPS, .set noreorder/reorder needs to emitted around > > > the nop. The template for the nop instruct

[PATCH] libsanitizer: Add missign file and regen Makefile.in

2020-01-22 Thread Andreas Tobler
Hi all, I'm digginig out old patches and I want to complete the libasan support for FreeBSD x86_64. The below one was not that obvious when you have been away for the past years. In the last import the sanitizer_platform_limits_freebsd.cpp got forgotten. Fix this. Ok for trunk once it's open

[PATCH]: gcc: Enable bits for sanitizer support on FreeBSD x86_64

2020-01-22 Thread Andreas Tobler
Hi all, this patch adds the necessary bits to enable asan support on FreeBSD x86_64. Results will be produced over night. Ok for trunk once it is open again? TIA, Andreas gcc/ * config/i386/i386.h: Define a new macro: SUBTARGET_SHADOW_OFFSET. * config/i386/i386.c (ix86_asan_shadow_offset):

[PATCH] testsuite: Enable asan tests on FreeBSD x86_64

2020-01-22 Thread Andreas Tobler
Hi all, and here the tests which should succeed now. Ok for trunk (as usual if open...) TIA, Andreas testsuite: * gcc.dg/asan/pr87930.c: Enable on x86_64 FreeBSD. * c-c++-common/asan/asan-interface-1.c: Likewise. * c-c++-common/asan/clone-test-1.c: Likewise. *

  1   2   >