Re: [PATCH] c++: Fix tsubst ICE with invalid static_cast [PR95728]

2020-06-17 Thread Jason Merrill via Gcc-patches
On 6/17/20 8:10 PM, Marek Polacek wrote: Since r11-423 tsubst_copy_and_build/TREE_LIST uses tsubst_tree_list instead of open coding it. While the latter could return an error node wrapped in a TREE_LIST, the former can return a naked error node. That broke in tsubst_copy_and_build/NEW_EXPR:

Re: drop -aux{dir,base}, revamp -dump{dir,base}

2020-06-17 Thread Alexandre Oliva
On Jun 17, 2020, Tobias Burnus wrote: > I hope it helps. Thanks! Not quite as much as I'd hoped, because I forgot much of the arg passing in lto land is through @files, but I think I've got enough to take a shot at fixing this. Two questions that come to mind: - do we wish to preserve the

[PATCH V2] PING^2 correct COUNT and PROB for unrolled loop

2020-06-17 Thread Jiufu Guo via Gcc-patches
Jiufu Guo writes: Gentle ping. https://gcc.gnu.org/legacy-ml/gcc-patches/2020-02/msg00927.html BR, Jiufu Guo > Jiufu Guo via Gcc-patches writes: > > Hi, > > I would like to reping this, hope to get approval for this patch. > https://gcc.gnu.org/legacy-ml/gcc-patches/2020-02/msg00927.html > >

[PATCH] c++: Fix tsubst ICE with invalid static_cast [PR95728]

2020-06-17 Thread Marek Polacek via Gcc-patches
Since r11-423 tsubst_copy_and_build/TREE_LIST uses tsubst_tree_list instead of open coding it. While the latter could return an error node wrapped in a TREE_LIST, the former can return a naked error node. That broke in tsubst_copy_and_build/NEW_EXPR: tree placement = RECUR (TREE_OPERAND (t,

Re: [PATCH] vectorizer: add _bb_vec_info::const_iterator

2020-06-17 Thread Jonathan Wakely via Gcc-patches
On 18/06/20 00:59 +0100, Jonathan Wakely wrote: On 18/06/20 00:55 +0100, Jonathan Wakely wrote: On 16/06/20 15:14 +0100, Richard Sandiford wrote: Martin Li?ka writes: On 6/16/20 10:50 AM, Richard Sandiford wrote: Hmm, sounds like a nice abstraction but I see 2 problems with that: 1) How can

Re: [PATCH] vectorizer: add _bb_vec_info::const_iterator

2020-06-17 Thread Jonathan Wakely via Gcc-patches
On 18/06/20 00:55 +0100, Jonathan Wakely wrote: On 16/06/20 15:14 +0100, Richard Sandiford wrote: Martin Li?ka writes: On 6/16/20 10:50 AM, Richard Sandiford wrote: Hmm, sounds like a nice abstraction but I see 2 problems with that: 1) How can I define a constructor of the iterator_pair when

Re: [PATCH] vectorizer: add _bb_vec_info::const_iterator

2020-06-17 Thread Jonathan Wakely via Gcc-patches
On 16/06/20 15:14 +0100, Richard Sandiford wrote: Martin Li?ka writes: On 6/16/20 10:50 AM, Richard Sandiford wrote: Hmm, sounds like a nice abstraction but I see 2 problems with that: 1) How can I define a constructor of the iterator_pair when I need something like: iterator_pair

Re: [PATCH] avoid false positives due to compute_objsize (PR 95353)

2020-06-17 Thread Jakub Jelinek via Gcc-patches
On Wed, Jun 17, 2020 at 04:37:54PM -0600, Jeff Law wrote: > On Wed, 2020-06-17 at 10:04 +0200, Jakub Jelinek via Gcc-patches wrote: > > On Wed, Jun 17, 2020 at 09:13:25AM +0200, Richard Biener via Gcc-patches > > wrote: > > > > Not doing the transformation I suggest at all, or not doing it in > >

Re: [PATCH] avoid false positives due to compute_objsize (PR 95353)

2020-06-17 Thread Jeff Law via Gcc-patches
On Wed, 2020-06-17 at 10:04 +0200, Jakub Jelinek via Gcc-patches wrote: > On Wed, Jun 17, 2020 at 09:13:25AM +0200, Richard Biener via Gcc-patches > wrote: > > > Not doing the transformation I suggest at all, or not doing it in > > > cases when the member does match the source? > > > > We are

Re: [OpenMP, gimplifier] 'inform' after 'error' diagnostic

2020-06-17 Thread Jakub Jelinek via Gcc-patches
On Thu, Jun 18, 2020 at 12:26:06AM +0200, Thomas Schwinge wrote: > Hi! > > On 2020-04-30T12:14:39+0200, Jakub Jelinek via Gcc-patches > wrote: > > On Thu, Apr 30, 2020 at 12:07:32PM +0200, Thomas Schwinge wrote: > >> Is the attached OK for master branch, in next stage 1? [...] > > > > Ok for

Re: [OpenMP, gimplifier] 'inform' after 'error' diagnostic

2020-06-17 Thread Thomas Schwinge
Hi! On 2020-04-30T12:14:39+0200, Jakub Jelinek via Gcc-patches wrote: > On Thu, Apr 30, 2020 at 12:07:32PM +0200, Thomas Schwinge wrote: >> Is the attached OK for master branch, in next stage 1? [...] > > Ok for stage1, thanks. Thanks. I've now pushed "[OpenMP, gimplifier] 'inform' after

Re: [Patch, Fortran] OpenMP/OpenACC – fix more issues with OPTIONAL

2020-06-17 Thread Thomas Schwinge
Hi! On 2020-04-29T16:01:56+0200, Tobias Burnus wrote: > See: https://gcc.gnu.org/bugzilla/show_bug.cgi?id=94848 > > The problem is a generated static array variable in the > device function: >static integer(kind=4) A.12[3] = {1, 2, 3}; > used as >_26 = A.12[S.13_67]; > > [...] ..., and

Re: [PATCH][GCC]: Fix for PR94880: Failure to recognize andn pattern

2020-06-17 Thread Marc Glisse
(It would be nice to convince your mailer that a patch is not just Application/OCTET-STREAM) Aren't you missing :cs on bit_ior? On Wed, 17 Jun 2020, Przemyslaw Wirkus wrote: Hi, Pattern "(x | y) - y" can be optimized to simple "(x & ~y)" andn pattern. Bootstrapped and tested on

Re: [PATCH] hurd: libgcc unwinding support over signal trampolines

2020-06-17 Thread Thomas Schwinge
Hi! On 2020-06-08T13:49:55+0200, Samuel Thibault wrote: > Samuel Thibault, le lun. 08 juin 2020 13:36:55 +0200, a ecrit: >> Thomas Schwinge, le lun. 08 juin 2020 12:15:12 +0200, a ecrit: >> > Which GCC branches would you like this on? >> >> Ideally it's be backported to gcc 9 and 10, so that it

[HSA] Avoid ICE when "HSA does not implement indirect calls" (was: [PATCH 4/4] Back-end and IPA bits of hsa branch merge)

2020-06-17 Thread Thomas Schwinge
Hi! It's been a while... ;-) On 2016-11-13T23:22:26+0100, Martin Jambor wrote: > --- a/gcc/hsa-gen.c > +++ b/gcc/hsa-gen.c > @@ -5068,6 +5102,12 @@ gen_hsa_insns_for_call (gimple *stmt, hsa_bb *hbb) >if (!gimple_call_builtin_p (stmt, BUILT_IN_NORMAL)) > { >tree function_decl

[committed] libstdc++: Avoid stack overflow in std::vector (PR 94540)

2020-06-17 Thread Jonathan Wakely via Gcc-patches
The std::__uninitialized_default_n algorithm used by std::vector creates an initial object as a local variable then copies that into the destination range. If the object is too large for the stack this crashes. We should create the first object directly into the destination and then copy it from

Re: [PATCH ping 2] ppc64 check for incompatible setting of minimal-toc

2020-06-17 Thread Douglas B Rupp
Greetings again, Could you please look at this patch when convenient? --Doug On 6/1/20 10:13 AM, Douglas B Rupp wrote: Greetings, Curious if you've had a chance to look at this patch yet? --Doug On 5/18/20 4:02 PM, Douglas B Rupp wrote: Greetings, The attached patch is proposed for

Re: [PATCH][documentation] Fix typo in access function attribute example

2020-06-17 Thread Martin Sebor via Gcc-patches
On 6/16/20 3:21 AM, Forrest Timour via Gcc-patches wrote: Hi, This patch fixes an off-by-one typo in the documentation example of the access function attribute. This is my first contribution and I don't have write access, so I will need somebody to submit for me on approval. Thank you! I've

Re: [pushed] c++: Fix consteval operator handling.

2020-06-17 Thread Iain Sandoe via Gcc-patches
Hi Jason Jason Merrill via Gcc-patches wrote: We were crashing trying to find the CALL_EXPR in the result of a call to a consteval operator. Tested x86_64-pc-linux-gnu, applying to trunk. gcc/cp/ChangeLog: * call.c (build_new_op_1): Don't look for a CALL_EXPR when I suspect that

Re: [PATCH] libstdc++: Handle non-integral sizes in std::uninitialized_fill_n

2020-06-17 Thread Jonathan Wakely via Gcc-patches
On 17/06/20 21:10 +0100, Jonathan Wakely wrote: On 17/06/20 20:55 +0100, Jonathan Wakely wrote: +struct Value +{ + int value = 0x1234; +}; Oops, I modified this test, and it no longer tests the right code. This type isn't trivial, so doesn't use the fill_n optimization anyway. I'll fix the

Re: [PATCH] vectorizer: add _bb_vec_info::const_iterator

2020-06-17 Thread Richard Sandiford
(Sorry, sent my previous message before seeing this one.) Martin Sebor writes: > Since the iterator_pair template is being added as a foundational > type I'd suggest fleshing out the design a bit more. There is > little difference between iterator_pair and std::pair, but since > the class is

Re: [PATCH] libstdc++: Handle non-integral sizes in std::uninitialized_fill_n

2020-06-17 Thread Jonathan Wakely via Gcc-patches
On 17/06/20 20:55 +0100, Jonathan Wakely wrote: +struct Value +{ + int value = 0x1234; +}; Oops, I modified this test, and it no longer tests the right code. This type isn't trivial, so doesn't use the fill_n optimization anyway. I'll fix the test.

Re: [PATCH] vectorizer: add _bb_vec_info::const_iterator

2020-06-17 Thread Richard Sandiford
Martin Liška writes: > On 6/16/20 4:14 PM, Richard Sandiford wrote: >> Martin Liška writes: >>> Hmm, sounds like a nice abstraction but I see 2 problems with that: >>> >>> 1) How can I define a constructor of the iterator_pair when I need >>> something like: >>> iterator_pair (region_begin,

[PATCH] libstdc++: Handle non-integral sizes in std::uninitialized_fill_n

2020-06-17 Thread Jonathan Wakely via Gcc-patches
The std::uninitialized_fill_n algorithm uses sd::fill_n for trivial types, but that algorithm has a stronger requirement that the Size parameter is convertible to an integral type. As the new test shows, there are types which are valid for std::uninitialized_fill_n but which produce a different

[PATCH 28/28] rs6000: Add comments to help with transition

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-builtin.def: Add comments. * config/rs6000/rs6000-call.c: Likewise. --- gcc/config/rs6000/rs6000-builtin.def | 15 +++ gcc/config/rs6000/rs6000-call.c | 166 +++ 2 files changed, 181 insertions(+)

[PATCH 13/28] rs6000: Parsing of overload input file

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-gen-builtins.c (ovld_stanza): New struct. (MAXOVLDSTANZAS): New defined constant. (ovld_stanzas): New filescope variable. (curr_ovld_stanza): Likewise. (MAXOVLDS): New defined constant. (ovlddata):

[PATCH 11/28] rs6000: Parsing built-in input file, part 2 of 3

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-gen-builtins.c (parse_args): New function. (parse_prototype): Implement. --- gcc/config/rs6000/rs6000-gen-builtins.c | 144 1 file changed, 144 insertions(+) diff --git

[PATCH 08/28] rs6000: Red-black tree implementation for balanced tree search

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rbtree.c: New file. * config/rs6000/rbtree.h: New file. --- gcc/config/rs6000/rbtree.c | 233 + gcc/config/rs6000/rbtree.h | 51 2 files changed, 284 insertions(+) create mode 100644

[PATCH 00/28] rs6000: Auto-generate builtins from descriptions

2020-06-17 Thread Bill Schmidt via Gcc-patches
I posted a version of these patches back in stage 4 (February), but we agreed that holding off until stage 1 was a better idea. Since then I've made more progress and reorganized the patches accordingly. This group of patches lays groundwork, but does not actually change GCC's behavior yet, other

[PATCH 27/28] rs6000: Add remaining builtins

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-builtin-new.def: Add MASK_FLOAT128_HW, MASK_DFP, MASK_CRYPTO, and MASK_HTM builtins. --- gcc/config/rs6000/rs6000-builtin-new.def | 217 +++ 1 file changed, 217 insertions(+) diff --git

[PATCH 26/28] rs6000: Add MASK_P9_VECTOR and MASK_P9_MISC builtins

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-builtin-new.def: Add MASK_P9_VECTOR and MASK_P9_MISC builtins. --- gcc/config/rs6000/rs6000-builtin-new.def | 353 +++ 1 file changed, 353 insertions(+) diff --git a/gcc/config/rs6000/rs6000-builtin-new.def

[PATCH 25/28] rs6000: Add MASK_P8_VECTOR builtins

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-builtin-new.def: Add MASK_P8_VECTOR builtins. --- gcc/config/rs6000/rs6000-builtin-new.def | 417 +++ 1 file changed, 417 insertions(+) diff --git a/gcc/config/rs6000/rs6000-builtin-new.def

[PATCH 22/28] rs6000: Add MASK_VSX builtins

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-builtin-new.def: Add VSX builtins. --- gcc/config/rs6000/rs6000-builtin-new.def | 840 +++ 1 file changed, 840 insertions(+) diff --git a/gcc/config/rs6000/rs6000-builtin-new.def

[PATCH 24/28] rs6000: Add Power7 builtins

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-builtin-new.def: Add MASK_POPCNTD builtins. --- gcc/config/rs6000/rs6000-builtin-new.def | 39 1 file changed, 39 insertions(+) diff --git a/gcc/config/rs6000/rs6000-builtin-new.def

[PATCH 21/28] rs6000: Add remaining MASK_ALTIVEC builtins

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-builtin-new.def: Add remaining MASK_ALTIVEC builtins. --- gcc/config/rs6000/rs6000-builtin-new.def | 843 +++ 1 file changed, 843 insertions(+) diff --git a/gcc/config/rs6000/rs6000-builtin-new.def

[PATCH 23/28] rs6000: Add available-everywhere and ancient builtins

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-builtin-new.def: Add MASK_PPC_GFXOPT, MASK_POPCNTB, and MASK_CMPB builtins. --- gcc/config/rs6000/rs6000-builtin-new.def | 78 1 file changed, 78 insertions(+) diff --git

[PATCH 20/28] rs6000: Incorporate new builtins code into the build machinery

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config.gcc (powerpc*-*-*): Add rs6000-builtins.o to extra_objs. * config/rs6000/t-rs6000 (rs6000-gen-builtins.o): New target. (rbtree.o): Likewise. (rs6000-gen-builtins): Likewise. (rs6000-builtins.c): Likewise.

[PATCH 19/28] rs6000: Write output to the builtins init file, part 3 of 3

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-gen-builtins.c (typemap): New struct. (TYPE_MAP_SIZE): New defined constant. (type_map): New filescope variable; initialize. (map_token_to_type_node): New function. (write_type_node): New function.

[PATCH 18/28] rs6000: Write output to the builtins init file, part 2 of 3

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-gen-builtins.c (write_init_bif_table): Implement. --- gcc/config/rs6000/rs6000-gen-builtins.c | 166 1 file changed, 166 insertions(+) diff --git a/gcc/config/rs6000/rs6000-gen-builtins.c

[PATCH 16/28] rs6000: Write output to the builtins header file

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-gen-builtins.c (write_autogenerated_header): New function. (write_bif_enum): Likewise. (write_ovld_enum): Likewise. (write_decls): Likewise. (write_extern_fntype): Likewise.

[PATCH 17/28] rs6000: Write output to the builtins init file, part 1 of 3

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-gen-builtins.c (write_fntype): New function. (write_fntype_init): New stub function. (write_init_bif_table): Likewise. (write_init_ovld_table): New function. (write_init_file): Implement. ---

[PATCH 15/28] rs6000: Write output to the vector definition include file

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-gen-builtins.c (write_defines_file): Implement. --- gcc/config/rs6000/rs6000-gen-builtins.c | 4 1 file changed, 4 insertions(+) diff --git a/gcc/config/rs6000/rs6000-gen-builtins.c b/gcc/config/rs6000/rs6000-gen-builtins.c

[PATCH 14/28] rs6000: Build and store function type identifiers

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-gen-builtins.c (complete_vector_type): New function. (complete_base_type): Likewise. (construct_fntype_id): Likewise. (parse_bif_entry): Call construct_fntype_id. (parse_ovld_entry): Likewise. ---

[PATCH 05/28] rs6000: Add functions for matching types, part 1 of 3

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-gen-builtins.c (void_status): New enum. (basetype): Likewise. (typeinfo): New struct. (handle_pointer): New function. (match_basetype): New stub function. (match_const_restriction): Likewise.

[PATCH 09/28] rs6000: Main function with stubs for parsing and output

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-gen-builtins.c (rbtree.h): New #include. (num_bif_stanzas): New filescope variable. (num_bifs): Likewise. (num_ovld_stanzas): Likewise. (num_ovlds): Likewise. (exit_codes): Add more enum values.

[PATCH 12/28] rs6000: Parsing built-in input file, part 3 of 3

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-gen-builtins.c (parse_bif_attrs): Implement. --- gcc/config/rs6000/rs6000-gen-builtins.c | 84 + 1 file changed, 84 insertions(+) diff --git a/gcc/config/rs6000/rs6000-gen-builtins.c

[PATCH 10/28] rs6000: Parsing built-in input file, part 1 of 3

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-gen-builtins.c (MAXBIFSTANZAS): New defined constant. (bif_stanzas): New filescope variable. (curr_bif_stanza): Likewise. (fnkinds): New enum. (typelist): New struct. (attrinfo): Likewise.

[PATCH 04/28] rs6000: Add helper functions for parsing

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-gen-builtins.c (MININT): New defined constant. (exit_codes): New enum. (consume_whitespace): New function. (advance_line): Likewise. (safe_inc_pos): Likewise. (match_identifier): Likewise.

[PATCH 02/28] rs6000: Add initial input files

2020-06-17 Thread Bill Schmidt via Gcc-patches
This patch adds a tiny subset of the built-in and overload descriptions. 2020-06-17 Bill Schmidt * config/rs6000/rs6000-builtin-new.def: New. * config/rs6000/rs6000-overload.def: New. --- gcc/config/rs6000/rs6000-builtin-new.def | 178 +++

[PATCH 07/28] rs6000: Add functions for matching types, part 3 of 3

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-gen-builtins.c (restriction): New enum. (typeinfo): Add restriction field. (match_const_restriction): Implement. --- gcc/config/rs6000/rs6000-gen-builtins.c | 136 1 file changed, 136 insertions(+)

[PATCH 03/28] rs6000: Add file support and functions for diagnostic support

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-gen-builtins.c (bif_file): New filescope variable. (ovld_file): Likewise. (header_file): Likewise. (init_file): Likewise. (defines_file): Likewise. (pgm_path): Likewise. (bif_path):

[PATCH 06/28] rs6000: Add functions for matching types, part 2 of 3

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-gen-builtins.c (match_basetype): Implement. --- gcc/config/rs6000/rs6000-gen-builtins.c | 49 + 1 file changed, 49 insertions(+) diff --git a/gcc/config/rs6000/rs6000-gen-builtins.c

[PATCH 01/28] rs6000: Initial create of rs6000-gen-builtins.c

2020-06-17 Thread Bill Schmidt via Gcc-patches
2020-06-17 Bill Schmidt * config/rs6000/rs6000-gen-builtins.c: New. --- gcc/config/rs6000/rs6000-gen-builtins.c | 142 1 file changed, 142 insertions(+) create mode 100644 gcc/config/rs6000/rs6000-gen-builtins.c diff --git

Re: [PATCH] vectorizer: add _bb_vec_info::const_iterator

2020-06-17 Thread Martin Sebor via Gcc-patches
On 6/17/20 11:05 AM, Martin Liška wrote: On 6/16/20 4:14 PM, Richard Sandiford wrote: Martin Liška writes: On 6/16/20 10:50 AM, Richard Sandiford wrote: Martin Liška writes: Also, one minor formatting nit, sorry: the other functions instead indent the “{” block by the same amount as the

Re: [PATCH] c++: Fix bogus "does not declare anything" warning (PR 66159)

2020-06-17 Thread Jonathan Wakely via Gcc-patches
On 17/06/20 12:56 -0400, Jason Merrill wrote: On 6/17/20 12:49 PM, Jonathan Wakely wrote: On 17/06/20 12:32 -0400, Jason Merrill wrote: On 6/15/20 3:40 PM, Jonathan Wakely wrote: Ping ... G++ gives a bogus warning for 'struct A; using B = struct ::A;' complaining that the

[PATCH] PR fortran/95707 - ICE in finish_equivalences, at fortran/trans-common.c:1319

2020-06-17 Thread Harald Anlauf
Another corner case of buffer overflows during name mangling found by Gerhard. We now check that the new buffer sizes suffice. The patch is on top of the patches for PRs 95687, 95688, 95689. Regtested on x86_64-pc-linux-gnu. OK for master / backports? Thanks, Harald PR fortran/95707 - ICE

Re: [PATCH PR95199 v2] vect: CSE for bump and offset in strided load/store operations

2020-06-17 Thread Richard Sandiford
"zhoukaipeng (A)" writes: > Bootstrapped and tested on aarch64-linux-gnu & x86_64-linux-gnu. Could you > please help install this patch? Thanks for the patch, now pushed. Richard

[pushed] c++: implicit operator== adjustments from P2002.

2020-06-17 Thread Jason Merrill via Gcc-patches
P2002R1, adopted at the February C++ meeting, made several refinements to the wording for operator<=>. This implements clarifications in how the implicit operator== is declared: as a duplicate of the operator<=>, with only the return type and name changed. To that end I factored out the

[pushed] c++: Treat in-class default/delete as definitions.

2020-06-17 Thread Jason Merrill via Gcc-patches
We were complaining about a constrained defaulted non-template friend in a template class because funcdef_flag wasn't set. grokdeclarator would set it for default/delete, but grokfield wasn't passing the 'initialized' values needed. Fixing that revealed some errors in existing tests that we

[pushed] c++: Add test for C++20 NB comment CA107.

2020-06-17 Thread Jason Merrill via Gcc-patches
We already implemented this, but it's good to have a test. gcc/testsuite/ChangeLog: * g++.dg/cpp2a/concepts-ca107.C: New test. --- gcc/testsuite/g++.dg/cpp2a/concepts-ca107.C | 33 + 1 file changed, 33 insertions(+) create mode 100644

[pushed] c++: Fix consteval operator handling.

2020-06-17 Thread Jason Merrill via Gcc-patches
We were crashing trying to find the CALL_EXPR in the result of a call to a consteval operator. Tested x86_64-pc-linux-gnu, applying to trunk. gcc/cp/ChangeLog: * call.c (build_new_op_1): Don't look for a CALL_EXPR when calling a consteval function. gcc/testsuite/ChangeLog:

[PATCH] PR fortran/95687 - ICE in get_unique_hashed_string, at fortran/class.c:508

2020-06-17 Thread Harald Anlauf
Dominique reported a flaw in my initial patch (thanks!): I used XALLOCAVEC where I should have used XNEWVEC. This is rectified in the attached patch. > And yet ABRBG (another one by Gerhard) provoking a buffer overflow. > > Sigh. At least this time we caught it on master. > > Regtested on

[PATCH][GCC]: Fix for PR94880: Failure to recognize andn pattern

2020-06-17 Thread Przemyslaw Wirkus
Hi, Pattern "(x | y) - y" can be optimized to simple "(x & ~y)" andn pattern. Bootstrapped and tested on aarch64-none-linux-gnu. OK for master ? Cheers, Przemyslaw gcc/ChangeLog: PR tree-optimization/94880 * match.pd (A | B) - B -> (A & ~B): New simplification.

Re: [PATCH] c-family: check qualifiers of arguments to __atomic built-ins (PR 95378)

2020-06-17 Thread Joseph Myers
On Tue, 16 Jun 2020, Jonathan Wakely via Gcc-patches wrote: > Currently the __atomic_{load,store,exchange,compare_exchange} built-ins > will happily store values through pointers to const, or use pointers to > volatile as the input and output arguments. This patch ensures that any > pointer that

[PATCH][GCC-10 Backport] arm: Fix the MVE ACLE vaddq_m polymorphic variants.

2020-06-17 Thread Srinath Parvathaneni
Hello, This patch fixes the MVE ACLE vaddq_m polymorphic variants by modifying the corresponding intrinsic parameters and vaddq_m polymorphic variant's _Generic case entries in "arm_mve.h" header file. Regression tested on arm-none-eabi and found no regressions. Ok for gcc-10 branch? Thanks,

Re: [PATCH][RFC] Do not stream all zeros for gcda files.

2020-06-17 Thread Martin Liška
On 6/17/20 2:57 PM, Nathan Sidwell wrote: On 6/17/20 2:44 AM, Martin Liška wrote: Hello. As mentioned in the PR, gcda files tend to occupy a large disk space when each running process streams to its own directory. The test-case in the PR has very low coverage and so that the data file contain

Re: [PATCH] vectorizer: add _bb_vec_info::const_iterator

2020-06-17 Thread Martin Liška
On 6/16/20 4:14 PM, Richard Sandiford wrote: Martin Liška writes: On 6/16/20 10:50 AM, Richard Sandiford wrote: Martin Liška writes: Also, one minor formatting nit, sorry: the other functions instead indent the “{” block by the same amount as the function prototype, which seems more

Re: [PATCH] c++: Fix bogus "does not declare anything" warning (PR 66159)

2020-06-17 Thread Jason Merrill via Gcc-patches
On 6/17/20 12:49 PM, Jonathan Wakely wrote: On 17/06/20 12:32 -0400, Jason Merrill wrote: On 6/15/20 3:40 PM, Jonathan Wakely wrote: Ping ... G++ gives a bogus warning for 'struct A; using B = struct ::A;' complaining that the elaborated-type-specifier doesn't declare anything. That's true,

Re: [PATCH] c++: Fix bogus "does not declare anything" warning (PR 66159)

2020-06-17 Thread Jonathan Wakely via Gcc-patches
On 17/06/20 12:32 -0400, Jason Merrill wrote: On 6/15/20 3:40 PM, Jonathan Wakely wrote: Ping ... G++ gives a bogus warning for 'struct A; using B = struct ::A;' complaining that the elaborated-type-specifier doesn't declare anything. That's true, but it's not trying to declare struct ::A,

Re: [PATCH] avoid false positives due to compute_objsize (PR 95353)

2020-06-17 Thread Richard Biener via Gcc-patches
On Wed, Jun 17, 2020 at 6:31 PM Martin Sebor wrote: > > On 6/17/20 1:13 AM, Richard Biener wrote: > > On Tue, Jun 16, 2020 at 9:35 PM Martin Sebor wrote: > >> > >> On 6/16/20 3:33 AM, Richard Biener wrote: > >>> On Mon, Jun 15, 2020 at 7:11 PM Martin Sebor via Gcc-patches > >>> wrote: > >

Re: [PATCH] c++: Fix bogus "does not declare anything" warning (PR 66159)

2020-06-17 Thread Jason Merrill via Gcc-patches
On 6/15/20 3:40 PM, Jonathan Wakely wrote: Ping ... G++ gives a bogus warning for 'struct A; using B = struct ::A;' complaining that the elaborated-type-specifier doesn't declare anything. That's true, but it's not trying to declare struct ::A, just refer to it unambiguously. Do not emit the

Re: [PATCH] avoid false positives due to compute_objsize (PR 95353)

2020-06-17 Thread Martin Sebor via Gcc-patches
On 6/17/20 1:13 AM, Richard Biener wrote: On Tue, Jun 16, 2020 at 9:35 PM Martin Sebor wrote: On 6/16/20 3:33 AM, Richard Biener wrote: On Mon, Jun 15, 2020 at 7:11 PM Martin Sebor via Gcc-patches wrote: On 6/14/20 12:37 PM, Jeff Law wrote: On Sat, 2020-06-13 at 17:49 -0600, Martin Sebor

[PATCH][GCC-10 Backport] arm: Fix MVE scalar shift intrinsics code-gen.

2020-06-17 Thread Srinath Parvathaneni
Hello, This patch modifies the MVE scalar shift RTL patterns. The current patterns have wrong constraints and predicates due to which the values returned from MVE scalar shift instructions are overwritten in the code-gen. example: $ cat x.c int32_t foo(int64_t acc, int shift) { return

Re: [PATCH] RS6000 Add testlsbb (Test LSB by Byte) operations

2020-06-17 Thread will schmidt via Gcc-patches
On Tue, 2020-05-26 at 11:12 -0500, will schmidt wrote: > Hi, > > Add support for new instructions to test LSB by Byte. > > Tested on powerpc64le-unknown-linux-gnu with no > regressions. (power7BE, power8LE, power8BE, power9LE). > > [gcc] > > 2020-05-26 Will Schmidt > > *

[Committed] IBM Z: Prevent mach optimization on doloop patterns

2020-06-17 Thread Andreas Krebbel via Gcc-patches
on IBM z15. Committed to mainline. 2020-06-17 Andreas Krebbel gcc/ * config/s390/s390.c (s390_fix_long_loop_prediction): Exit early for PARALLELs. gcc/testsuite/ * gcc.target/s390/20200617.c: New test. --- gcc/config/s390/s390.c | 9 +++-- gcc

[PATCH] remove SLP_TREE_TWO_OPERATORS, add SLP permutation node

2020-06-17 Thread Richard Biener
This removes the SLP_TREE_TWO_OPERATORS hack in favor of having explicit SLP nodes for both computations and the blend operation. For this introduce a generic merge + select + permute SLP node (with implementation limits). Building upon earlier patches it adds vect_stmt_dominates_stmt_p and the

[PATCH] Use SLP_TREE_VECTYPE consistently

2020-06-17 Thread Richard Biener
This assigns SLP_TREE_VECTYPE to all SLP nodes and uses it when analyzing def operands. It does not deal with mismatches between SLP_TREE_VECTYPE and STMT_VINFO_VECTYPE yet - those cases are still rejected until I get to clean up the interaction with data reference groups. Bootstrapped on

[committed] Fix use of inaccessible member in pr85503.C [PR95716]

2020-06-17 Thread Patrick Palka via Gcc-patches
The recent PR41437 fix exposed a latent use of an inaccessible member in the below testcase. Committed as obvious after verifying that the testcase no longer fails to compile due to the reported access error. gcc/testsuite/ChangeLog: PR testsuite/95716 * g++.dg/ext/pr85503.C:

Re: [stage1][PATCH] Lower VEC_COND_EXPR into internal functions.

2020-06-17 Thread Richard Biener via Gcc-patches
On Wed, Jun 17, 2020 at 10:50 AM Richard Biener wrote: > > On Mon, Jun 15, 2020 at 2:20 PM Martin Liška wrote: > > > > On 6/15/20 1:59 PM, Richard Biener wrote: > > > On Mon, Jun 15, 2020 at 1:19 PM Martin Liška wrote: > > >> > > >> On 6/15/20 9:14 AM, Richard Biener wrote: > > >>> On Fri, Jun

Re: [patch] fix PR lto/95604, -flto and -fcf-protection

2020-06-17 Thread Richard Biener
On Wed, 17 Jun 2020, H.J. Lu wrote: > On Wed, Jun 17, 2020 at 5:33 AM Richard Biener wrote: > > > > On Wed, 17 Jun 2020, H.J. Lu wrote: > > > > > On Wed, Jun 17, 2020 at 5:00 AM Richard Biener wrote: > > > > > > > > On Wed, 17 Jun 2020, H.J. Lu wrote: > > > > > > > > > On Wed, Jun 17, 2020 at

[PATCH] tree-optimization/95717 - fix SSA update for vectorizer epilogue

2020-06-17 Thread Richard Biener
This fixes yet another issue with the custom SSA updating in the vectorizer when we copy from the non-if-converted loop. We must not mess with current defs before we updated the BB copies. Bootstrapped / tested on x86_64-unknown-linux-gnu, applied. 2020-06-17 Richard Biener PR

Re: [PATCH][RFC] Do not stream all zeros for gcda files.

2020-06-17 Thread Nathan Sidwell
On 6/17/20 2:44 AM, Martin Liška wrote: Hello. As mentioned in the PR, gcda files tend to occupy a large disk space when each running process streams to its own directory. The test-case in the PR has very low coverage and so that the data file contain a lot of zero records. The patch is

Re: [PATCH v2] c++: ICE with IMPLICIT_CONV_EXPR in array subscript [PR95508]

2020-06-17 Thread Jason Merrill via Gcc-patches
On 6/16/20 5:10 PM, Marek Polacek wrote: On Thu, Jun 11, 2020 at 02:31:44PM -0400, Jason Merrill wrote: On 6/10/20 5:11 PM, Marek Polacek wrote: Since r10-7096 convert_like, when called in a template, creates an IMPLICIT_CONV_EXPR when we're converting to/from array type. In this test, we

Re: [patch] fix PR lto/95604, -flto and -fcf-protection

2020-06-17 Thread H.J. Lu via Gcc-patches
On Wed, Jun 17, 2020 at 5:33 AM Richard Biener wrote: > > On Wed, 17 Jun 2020, H.J. Lu wrote: > > > On Wed, Jun 17, 2020 at 5:00 AM Richard Biener wrote: > > > > > > On Wed, 17 Jun 2020, H.J. Lu wrote: > > > > > > > On Wed, Jun 17, 2020 at 1:59 AM Richard Biener > > > > wrote: > > > > > > > > >

Re: [patch] fix PR lto/95604, -flto and -fcf-protection

2020-06-17 Thread Richard Biener
On Wed, 17 Jun 2020, H.J. Lu wrote: > On Wed, Jun 17, 2020 at 5:00 AM Richard Biener wrote: > > > > On Wed, 17 Jun 2020, H.J. Lu wrote: > > > > > On Wed, Jun 17, 2020 at 1:59 AM Richard Biener > > > wrote: > > > > > > > > On Mon, Jun 15, 2020 at 5:30 PM Matthias Klose wrote: > > > > > > > > >

Re: [patch] fix PR lto/95604, -flto and -fcf-protection

2020-06-17 Thread H.J. Lu via Gcc-patches
On Wed, Jun 17, 2020 at 5:00 AM Richard Biener wrote: > > On Wed, 17 Jun 2020, H.J. Lu wrote: > > > On Wed, Jun 17, 2020 at 1:59 AM Richard Biener > > wrote: > > > > > > On Mon, Jun 15, 2020 at 5:30 PM Matthias Klose wrote: > > > > > > > > PR lto/95604 was seen when checking for binaries

Re: [patch] fix PR lto/95604, -flto and -fcf-protection

2020-06-17 Thread Richard Biener
On Wed, 17 Jun 2020, H.J. Lu wrote: > On Wed, Jun 17, 2020 at 1:59 AM Richard Biener > wrote: > > > > On Mon, Jun 15, 2020 at 5:30 PM Matthias Klose wrote: > > > > > > PR lto/95604 was seen when checking for binaries without having CET > > > support in a > > > distro archive, for binaries

[PATCH] testsuite: clean up .gcov files in test-suite.

2020-06-17 Thread Martin Liška
Installed to master. There's still bunch of files that correspond to a system header files: ./gcc/testsuite/g++4/new.gcov ./gcc/testsuite/g++4/initializer_list.gcov ./gcc/testsuite/g++4/allocator.h.gcov ./gcc/testsuite/g++4/stl_iterator_base_funcs.h.gcov ... Martin gcc/testsuite/ChangeLog:

Re: [patch] fix PR lto/95604, -flto and -fcf-protection

2020-06-17 Thread H.J. Lu via Gcc-patches
On Wed, Jun 17, 2020 at 1:59 AM Richard Biener wrote: > > On Mon, Jun 15, 2020 at 5:30 PM Matthias Klose wrote: > > > > PR lto/95604 was seen when checking for binaries without having CET support > > in a > > distro archive, for binaries built with LTO optimization. The hardening > > flag > >

Re: drop -aux{dir,base}, revamp -dump{dir,base}

2020-06-17 Thread Tobias Burnus
On 6/11/20 12:24 AM, Alexandre Oliva wrote: Let's see how far I can get by just looking at the code ;-) If I were to get something like a -v compile and link session, from someone all set for offloading compilation, with the command line passed to lto-wrapper and the full commands it runs, I

[PATCH v3] S/390: Improve storing asan frame_pc

2020-06-17 Thread Ilya Leoshkevich via Gcc-patches
Hello, This is a resend of v2 (rebased on the latest master). Previous discussions: v1: https://gcc.gnu.org/pipermail/gcc-patches/2019-July/525016.html v2: https://gcc.gnu.org/pipermail/gcc-patches/2019-July/525069.html Is there anything I need to change (e.g. in the naming area) to get this

Re: [PATCH] gcc-changelog: Support 'Backported from master'.

2020-06-17 Thread Jakub Jelinek via Gcc-patches
On Wed, Jun 17, 2020 at 11:30:26AM +0200, Martin Liška wrote: > On 6/17/20 10:58 AM, Jakub Jelinek wrote: > > On Wed, Jun 17, 2020 at 10:46:19AM +0200, Martin Liška wrote: > > > One minor limitation is that the timestamp (commit date) > > > of the original commit is lost so that's why we print: >

Re: [PATCH] gcc-changelog: Support 'Backported from master'.

2020-06-17 Thread Martin Liška
On 6/17/20 10:58 AM, Jakub Jelinek wrote: On Wed, Jun 17, 2020 at 10:46:19AM +0200, Martin Liška wrote: One minor limitation is that the timestamp (commit date) of the original commit is lost so that's why we print: Why? You have the (cherry picked from commit

[committed] amdgcn: Switch to HSACO v3 binary format

2020-06-17 Thread Andrew Stubbs
This upgrades the compiler to emit HSA Code Object v3 binaries. This means changing the assembler directives, and linker command line options. The gcn-run and libgomp loaders need corresponding alterations. The relocations no longer need to be fixed up manually, and the kernel symbol names

[PATCH][RFC] vector creation from two parts of two vectors produces TBL rather than ins (PR93720)

2020-06-17 Thread Dmitrij Pochepko
The following patch enables vector permutations optimization by trying to use ins instruction instead of slow and generic tbl. example: #define vector __attribute__((vector_size(4*sizeof(float vector float f0(vector float a, vector float b) { return __builtin_shuffle (a, a, (vector

Re: [patch] fix PR lto/95604, -flto and -fcf-protection

2020-06-17 Thread Richard Biener via Gcc-patches
On Mon, Jun 15, 2020 at 5:30 PM Matthias Klose wrote: > > PR lto/95604 was seen when checking for binaries without having CET support > in a > distro archive, for binaries built with LTO optimization. The hardening flag > -fcf-protection=full is passed in CFLAGS, and maybe should be passed in

Re: [PATCH] gcc-changelog: Support 'Backported from master'.

2020-06-17 Thread Jakub Jelinek via Gcc-patches
On Wed, Jun 17, 2020 at 10:46:19AM +0200, Martin Liška wrote: > One minor limitation is that the timestamp (commit date) > of the original commit is lost so that's why we print: Why? You have the (cherry picked from commit 8cff672cb9a132d3d3158c2edfc9a64b55292b80) line, so you can git log -1

[PATCH] gcov*: collapse lisence header to 2 lines in --version. gcc/ChangeLog:

2020-06-17 Thread Martin Liška
Installed as obvious. Martin * gcov-dump.c (print_version): Collapse lisence header to 2 lines in --version. * gcov-tool.c (print_version): Likewise. * gcov.c (print_version): Likewise. --- gcc/gcov-dump.c | 5 ++--- gcc/gcov-tool.c | 5 ++--- gcc/gcov.c |

Re: [stage1][PATCH] Lower VEC_COND_EXPR into internal functions.

2020-06-17 Thread Richard Biener via Gcc-patches
On Mon, Jun 15, 2020 at 2:20 PM Martin Liška wrote: > > On 6/15/20 1:59 PM, Richard Biener wrote: > > On Mon, Jun 15, 2020 at 1:19 PM Martin Liška wrote: > >> > >> On 6/15/20 9:14 AM, Richard Biener wrote: > >>> On Fri, Jun 12, 2020 at 3:24 PM Martin Liška wrote: > > On 6/12/20 11:43

[PATCH] gcc-changelog: Support 'Backported from master'.

2020-06-17 Thread Martin Liška
Hey. Jakub asked me to add 'Backported from master' heading to backports that were created from git cherry-pick -x. So it will newly generate: git gcc-verify e1d68582022cfa2b1dc76646724b397ba2739439 -p Checking e1d68582022cfa2b1dc76646724b397ba2739439: OK -- gcc/ChangeLog -- 2020-06-12

  1   2   >