Re: [PATCH] PR fortran/100950 - ICE in output_constructor_regular_field, at varasm.c:5514

2021-06-10 Thread Bernhard Reutner-Fischer via Gcc-patches
On 10 June 2021 20:52:12 CEST, Harald Anlauf wrote: >> I think the mpz_set_si args above fit on one line. > >That's true. > >Since this block is exactly the same as for constant strings, >which is handled in the first condition, I've thought some more >and am convinced now that these two can be f

[PATCH] Add statistics counting to PHI-OPT

2021-06-10 Thread apinski--- via Gcc-patches
From: Andrew Pinski This should have been done before I started to work on connecting PHI-OPT to match-and-simplify to see quickly if we miss anything but it is better late than never. Anyways there was no statistics counting in PHI-OPT before so adding it is the right thing to do. OK? Bootstrap

Re: [PATCH] c++: Failure to delay noexcept parsing with ptr-operator [PR100752]

2021-06-10 Thread Jason Merrill via Gcc-patches
On 6/10/21 5:19 PM, Marek Polacek wrote: On Thu, Jun 10, 2021 at 03:09:29PM -0400, Jason Merrill wrote: On 6/8/21 8:25 PM, Marek Polacek wrote: We weren't passing 'flags' to the recursive call to cp_parser_declarator in the ptr-operator case and as an effect, delayed parsing of noexcept didn't

Re: [PATCH v2] c++: Extend std::is_constant_evaluated in if warning [PR100995]

2021-06-10 Thread Jason Merrill via Gcc-patches
On 6/10/21 7:04 PM, Marek Polacek wrote: On Thu, Jun 10, 2021 at 10:27:44AM -0400, Jason Merrill wrote: On 6/9/21 9:46 PM, Marek Polacek wrote: Jakub pointed me at which shows that our existing warning coul

Re: GCC documentation: porting to Sphinx

2021-06-10 Thread Martin Sebor via Gcc-patches
On 6/10/21 7:18 AM, Martin Liška wrote: On 6/10/21 11:07 AM, Martin Liška wrote: Doing that, one has 2 unique links, that would be needed for get_option_url function. Plus, both :option:`-Wfoo` and :option:`-Wno-foo` references are going to work. And I've actually did the transformation and

[PATCH 4/4] remove %G and %K support from pretty printer and -Wformat (PR 98512)

2021-06-10 Thread Martin Sebor via Gcc-patches
This final diff removes the handlers for %G and %K from the pretty printer and the support for the directives from c-format.c so that using them will be diagnosed. gcc/c-family/ChangeLog: * c-format.c (gcc_tdiag_char_table): Remove support for %G and %K. (gcc_cdiag_char_table): Same. (gcc_cx

[PATCH 3/4] remove %K from error() calls in the aarch64/arm back ends (PR 98512)

2021-06-10 Thread Martin Sebor via Gcc-patches
This patch removes the uses of %K from error() calls in the aarch64 and arm back ends. I tested this change only by building a cross- compiler but I can't easily run the tests so I'd appreciate some help validating it. The fallout from the change should be limited to changes to error messages so

[PATCH 2/4] remove %G and %K from calls in front end and middle end (PR 98512)

2021-06-10 Thread Martin Sebor via Gcc-patches
This diff removes the uses of %G and %K from all warning_at() calls throughout GCC front end and middle end. The inlining context is included in diagnostic output whenever it's present. Improve warning suppression for inlined functions. Resolves: PR middle-end/98871 - Cannot silence -Wmaybe-unin

[PATCH 1/4] introduce diagnostic infrastructure changes (PR 98512)

2021-06-10 Thread Martin Sebor via Gcc-patches
This diff introduces the diagnostic infrastructure changes to support controlling warnings at any call site in the inlining stack and printing the inlining context without the %K and %G directives. Improve warning suppression for inlined functions. Resolves: PR middle-end/98871 - Cannot silence -

[PATCH 0/4] improve warning suppression for inlined functions (PR 98512)

2021-06-10 Thread Martin Sebor via Gcc-patches
David, this is a revised patch set based on your feedback below and our discussion. It works with the existing warning_at() interface without introducing any new overloads (for now). It resolves PR middle-end/98871 and 98512. PR 98465 was handled in GCC 11 differently so this has no impact on t

Re: [PATCH v2] c++: Extend std::is_constant_evaluated in if warning [PR100995]

2021-06-10 Thread Marek Polacek via Gcc-patches
On Thu, Jun 10, 2021 at 10:27:44AM -0400, Jason Merrill wrote: > On 6/9/21 9:46 PM, Marek Polacek wrote: > > Jakub pointed me at > > > > which shows that our existing warning could be extended to handle more >

Re: Aligning stack offsets for spills

2021-06-10 Thread Jeff Law via Gcc-patches
On 6/8/2021 8:55 AM, Jakub Jelinek wrote: On Tue, Jun 08, 2021 at 08:47:26AM -0600, Jeff Law wrote: Why is the machinery involving STACK_SLOT_ALIGNMENT and spill_slot_alignment() (for spilling) or get_stack_local_alignment() (for backing stack slots) not working for you? If everything is set

Re: [PATCH] libgccjit: add some reflection functions in the jit C api

2021-06-10 Thread David Malcolm via Gcc-patches
On Thu, 2021-05-27 at 21:51 -0400, Antoni Boucher wrote: > I chose option A, so everything is a size_t, now. > I also renamed the dyncast functions. > Here's the new patch. Thanks, sorry again about the delays in reviewing your work. You didn't specify how you tested the patch; are you running th

[PATCH] i386: Add V8QI and other 64bit vector permutations [PR89021]

2021-06-10 Thread Uros Bizjak via Gcc-patches
In addition to V8QI permutations, several other missing permutations are added for 64bit vector modes for TARGET_SSSE3 and TARGET_SSE4_1 targets. 2021-06-10 Uroš Bizjak gcc/ PR target/89021 * config/i386/i386-expand.c (ix86_split_mmx_punpck): Handle V2SF mode. Emit SHUFPS to fixup

libgo patch committed: Update libgo to Go 1.16.5

2021-06-10 Thread Ian Lance Taylor via Gcc-patches
This patch updates libgo to the Go 1.16.5 release. Bootstrapped and tested on x86_64-pc-linux-gnu. Committed to tip and GCC 11 branch. Ian a7d86ad16c5afdbbbae5218c012e1bbf6966bf1d diff --git a/gcc/go/gofrontend/MERGE b/gcc/go/gofrontend/MERGE index 1f38c9110ba..f16fb9facc3 100644 --- a/gcc/go/go

Re: Aligning stack offsets for spills

2021-06-10 Thread Segher Boessenkool
On Thu, Jun 10, 2021 at 02:28:34PM -0500, Peter Bergner via Gcc-patches wrote: > On 6/7/21 2:00 PM, Jeff Law wrote: > > I can't divulge many of the details right now, but one of the quirks of our > > architecture is that reg+d addressing modes for our vector loads/stores > > require > > the displa

Re: [PATCH] c++: Failure to delay noexcept parsing with ptr-operator [PR100752]

2021-06-10 Thread Marek Polacek via Gcc-patches
On Thu, Jun 10, 2021 at 03:09:29PM -0400, Jason Merrill wrote: > On 6/8/21 8:25 PM, Marek Polacek wrote: > > We weren't passing 'flags' to the recursive call to cp_parser_declarator > > in the ptr-operator case and as an effect, delayed parsing of noexcept > > didn't work as advertised. The follow

Re: [PATCH][version 3]add -ftrivial-auto-var-init and variable attribute "uninitialized" to gcc

2021-06-10 Thread Qing Zhao via Gcc-patches
Hi, Richard, I need more discussion on the following comments you raised: > On May 26, 2021, at 6:18 AM, Richard Biener wrote: > > +/* Expand the IFN_DEFERRED_INIT function according to its second > argument. */ > +static void > +expand_DEFERRED_INIT (internal_fn, gcall *stmt) > +{ > + tree

Re: [PATCH] rs6000: Add new __builtin_vsx_build_pair and __builtin_mma_build_acc built-ins

2021-06-10 Thread Segher Boessenkool
On Thu, Jun 10, 2021 at 10:43:05AM -0500, Peter Bergner wrote: > On 6/9/21 4:38 PM, Segher Boessenkool wrote: > > I think this reads simpler as > > /* The ASSEMBLE builtin source operands are reversed in little-endian > > mode, so reorder them. */ > > if (fcode == VSX_BUILTIN_ASSE

Re: [PATCH] c++: normalization of non-templated return-type-req [PR100946]

2021-06-10 Thread Jason Merrill via Gcc-patches
On 6/10/21 4:17 PM, Patrick Palka wrote: On Thu, 10 Jun 2021, Jason Merrill wrote: On 6/9/21 3:34 PM, Patrick Palka wrote: Here the satisfaction cache is conflating the satisfaction value of the two return-type-requirements because the corresponding constrained 'auto's have level 2, but they c

Re: [PATCH] c++: normalization of non-templated return-type-req [PR100946]

2021-06-10 Thread Patrick Palka via Gcc-patches
On Thu, 10 Jun 2021, Jason Merrill wrote: > On 6/9/21 3:34 PM, Patrick Palka wrote: > > Here the satisfaction cache is conflating the satisfaction value of the > > two return-type-requirements because the corresponding constrained > > 'auto's have level 2, but they capture an empty current_templat

Re: [PATCH] c++: matching deduced template template parameters [PR67829]

2021-06-10 Thread Jason Merrill via Gcc-patches
On 6/10/21 3:45 PM, Patrick Palka wrote: On Thu, 10 Jun 2021, Jason Merrill wrote: On 6/9/21 3:34 PM, Patrick Palka wrote: During deduction, when the template of a BOUND_TEMPLATE_TEMPLATE_PARM is a template template parameter, we need to consider the TEMPLATE_TEMPLATE_PARAMETER rather than the

Re: [PATCH] c++: matching deduced template template parameters [PR67829]

2021-06-10 Thread Patrick Palka via Gcc-patches
On Thu, 10 Jun 2021, Jason Merrill wrote: > On 6/9/21 3:34 PM, Patrick Palka wrote: > > During deduction, when the template of a BOUND_TEMPLATE_TEMPLATE_PARM is > > a template template parameter, we need to consider the > > TEMPLATE_TEMPLATE_PARAMETER rather than the TEMPLATE_DECL thereof, > > bec

[PATCH] PR tree-optimization/96392 Optimize x+0.0 if x is an integer

2021-06-10 Thread Roger Sayle
The patch implements a missed optimization enhancement. Under usual IEEE rules, x+0.0 can't be simplified to x when x might potentially be an IEEE minus zero (-0.0). The current logic in the middle-end checks whether the type of x should honor signed zeros, but with this patch we introduce tree_

Re: Aligning stack offsets for spills

2021-06-10 Thread Peter Bergner via Gcc-patches
On 6/7/21 2:00 PM, Jeff Law wrote: > I can't divulge many of the details right now, but one of the quirks of our > architecture is that reg+d addressing modes for our vector loads/stores > require > the displacement to be aligned. This is an artifact of how these instructions > are encoded. Give

Re: [PATCH] c++: matching deduced template template parameters [PR67829]

2021-06-10 Thread Jason Merrill via Gcc-patches
On 6/9/21 3:34 PM, Patrick Palka wrote: During deduction, when the template of a BOUND_TEMPLATE_TEMPLATE_PARM is a template template parameter, we need to consider the TEMPLATE_TEMPLATE_PARAMETER rather than the TEMPLATE_DECL thereof, because the canonical form of a template template parameter in

Re: [PATCH] c++: Failure to delay noexcept parsing with ptr-operator [PR100752]

2021-06-10 Thread Jason Merrill via Gcc-patches
On 6/8/21 8:25 PM, Marek Polacek wrote: We weren't passing 'flags' to the recursive call to cp_parser_declarator in the ptr-operator case and as an effect, delayed parsing of noexcept didn't work as advertised. The following change passes more than just CP_PARSER_FLAGS_DELAY_NOEXCEPT but that do

Re: [PATCH] c++: normalization of non-templated return-type-req [PR100946]

2021-06-10 Thread Jason Merrill via Gcc-patches
On 6/9/21 3:34 PM, Patrick Palka wrote: Here the satisfaction cache is conflating the satisfaction value of the two return-type-requirements because the corresponding constrained 'auto's have level 2, but they capture an empty current_template_parms. This ultimately causes the satisfaction cache

Re: [PATCH] c++: Add C++23 consteval if support - P1938R3 [PR100974]

2021-06-10 Thread Jason Merrill via Gcc-patches
On 6/10/21 10:44 AM, Jakub Jelinek wrote: On Thu, Jun 10, 2021 at 10:09:26AM -0400, Jason Merrill wrote: --- gcc/cp/parser.c.jj 2021-06-09 21:54:39.482193853 +0200 +++ gcc/cp/parser.c 2021-06-10 10:09:23.753052980 +0200 @@ -10902,6 +10902,11 @@ cp_parser_lambda_expression (cp_parser*

Re: [PATCH] rs6000: Add new __builtin_vsx_build_pair and __builtin_mma_build_acc built-ins

2021-06-10 Thread Peter Bergner via Gcc-patches
On 6/10/21 10:43 AM, Peter Bergner wrote: > On 6/9/21 4:38 PM, Segher Boessenkool wrote: >> Okay for trunk and 11 with at least that space fixed. Thanks! > > Ok, I'll retest with the above (but still removing the assemble > built-in documentation) and push it if it's clean. Thanks! Testing was

Re: [PATCH] PR fortran/100950 - ICE in output_constructor_regular_field, at varasm.c:5514

2021-06-10 Thread Harald Anlauf via Gcc-patches
Hi Bernhard, > > +static bool > > +substring_has_constant_len (gfc_expr *e) > > +{ > > + ptrdiff_t istart, iend; > > + size_t length; > > + bool equal_length = false; > > + > > + if (e->ts.type != BT_CHARACTER > > + || !(e->ref && e->ref->type == REF_SUBSTRING) > > iff we ever can get her

[committed] d: Fix ICE in TypeInfoDeclaration, at dmd/declaration.c (PR100967)

2021-06-10 Thread Iain Buclaw via Gcc-patches
Hi, This patch fixes an ICE in the constructor of TypeInfoDeclaration from within the D language front-end. Generates a stub TypeInfo class even if the root Object class is missing. The front-end will take care of issuing an error and abort the compilation when running semantic on constructed Ty

Re: [RFC] mask out mult expr ctz bits from nonzero bits

2021-06-10 Thread Jeff Law via Gcc-patches
On 1/27/2021 6:47 AM, Alexandre Oliva wrote: While looking into the possibility of introducing setmemM patterns on RISC-V to undo the transformation from loops of word writes into memset, I was disappointed to find out that get_nonzero_bits would take into account the range of the length passe

[GCC-9][committed] PR d/90651 (ICE in FuncDeclaration::semantic3, at d/dmd/func.c:1524)

2021-06-10 Thread Iain Buclaw via Gcc-patches
Hi, When looking into fixing PR100967, I noticed that the gcc-9 release branch first needed a patch to address another issue that didn't originally get backported from GCC-10. This fixes segmentation fault in FuncDeclaration::semantic3. Bootstrapped and regression tested on x86_64-linux-gnu/-m32

Re: [PATCH] c++: Add C++23 consteval if support - P1938R3 [PR100974]

2021-06-10 Thread Jakub Jelinek via Gcc-patches
On Thu, Jun 10, 2021 at 04:44:09PM +0200, Jakub Jelinek wrote: > > Maybe use cp_parser_compound_statement directly instead of this and checking > > CPP_OPEN_BRACE above? Either way is fine. > > I thought doing it this way will provide better diagnostics for what I think > can be a common bug - pe

Re: libstdc++ PR 57272 Fancy pointer support in Hashtable

2021-06-10 Thread François Dumont via Gcc-patches
I would like to renew this proposal. I considered all your feedbacks expect: On 02/11/20 3:11 pm, Jonathan Wakely wrote: There's no point doing it if you still use raw pointers. It either has to be done completely, or it's a waste of time and energy. Why ? Can you provide the Standard docu

Re: GCC documentation: porting to Sphinx

2021-06-10 Thread Joseph Myers
On Thu, 10 Jun 2021, Martin Liška wrote: > 1) Can we organize the new documentation in $gccroot/doc folder > similarly to what I have in texi2rst-generated repo? Would be beneficial > as we can have a single Makefile and shared content will be in a same > depth to the individual manuals. Where

RE: [GCC][PATCH] arm: Fix multilib mapping for CDE extensions.

2021-06-10 Thread Srinath Parvathaneni via Gcc-patches
Hi Richard, I have all addressed all your review comments in the trailing in the patch attached. Please review and let me know if it ok for master? Regards, Srinath. > -Original Message- > From: Richard Earnshaw > Sent: 02 June 2021 15:20 > To: Srinath Parvathaneni ; gcc- > patc...@g

[GCC][PATCH] arm: Fix polymorphic variants failing with undefined reference to `__ARM_undef` error.

2021-06-10 Thread Srinath Parvathaneni via Gcc-patches
Hi, This patch fixes the issue mentioned in PR101016, which is mve polymorphic variants failing at linking with undefined reference to "__ARM_undef" error. Regression tested on arm-none-eabi and found no regressions. Ok for master? Regards, Srinath. gcc/ChangeLog: 2021-06-10 Srinath Parvath

Re: [Patch] contrib/gcc-changelog: Check that PR in subject in in changelog

2021-06-10 Thread Jonathan Wakely via Gcc-patches
On Thu, 10 Jun 2021 at 15:08, Tobias Burnus wrote: > > (Moved to gcc-patches, missed this when I replied to the initial email) > > Regarding patch at: https://gcc.gnu.org/pipermail/gcc/2021-June/236357.html > > On 10.06.21 14:45, Jonathan Wakely wrote: > > > As well as the "contrig" typo that Flori

Re: [PATCH] rs6000: Add new __builtin_vsx_build_pair and __builtin_mma_build_acc built-ins

2021-06-10 Thread Peter Bergner via Gcc-patches
On 6/9/21 4:38 PM, Segher Boessenkool wrote: > It is better if you *do* document the old names, but say "use the new > stuff", I think? Or is there so little material with the old names > out there that no one will notice? The latter. There is only one user, but we want all new uses to use the n

Re: [Patch] contrib/gcc-changelog: Check that PR in subject in in changelog

2021-06-10 Thread Tobias Burnus
On 10.06.21 16:46, Martin Liška wrote: Note that flake8 has "plugins". At openSUSE, I install: ... None of those are available on Ubuntu – I probably should nag doko or start using my private computer for the tests ... Updated as suggested and with you flake8-fix patch applied on top. Tobias

[PATCH] rs6000: Fix *TItype_ppc

2021-06-10 Thread Segher Boessenkool
The *TItype_ppc definitions are guarded by _ARCH_PPC64, so all declarations using it should do so as well. This fixes it. Committed to trunk. Segher 2021-06-10 Segher Boessenkool libgcc/ * config/rs6000/quad-float128.h: Guard all uses of [U]TItype_ppc by _ARCH_PPC64 . ---

Re: [PATCH] Modula-2 into the GCC tree on master

2021-06-10 Thread Gaius Mulley via Gcc-patches
Matthias Klose writes: > On 1/18/21 2:55 PM, Gaius Mulley via Gcc-patches wrote: >> Richard Biener writes: >>> I've just done ./configure --enable-languages=m2; make -j24 >>> >>> I would suggest to not rush this in now during stage4 >>> but instead take the opportunity of this "quiet" phase >>>

Re: [PATCH] Use auto_vec in ssa_equiv_stack.

2021-06-10 Thread Jeff Law via Gcc-patches
On 6/10/2021 2:46 AM, Aldy Hernandez via Gcc-patches wrote: There is a mismatch between the new and the delete for the ssa_equiv_stack class. The correct idiom should have been delete[]. It has been pointed out that perhaps a better alternative is to use an auto_vec which does everything auto

Re: [Patch] contrib/gcc-changelog: Check that PR in subject in in changelog

2021-06-10 Thread Martin Liška
On 6/10/21 4:42 PM, Tobias Burnus wrote: On 10.06.21 16:24, Martin Liška wrote: I'm sending a small update that handles some flake8 issues and as defined in setup.cfg, line limit for the file is 120 characters. Aha, the known issue that Ubuntu 20.04 has a too old flake8 such that I only see a

Re: [PATCH] c++: Add C++23 consteval if support - P1938R3 [PR100974]

2021-06-10 Thread Jakub Jelinek via Gcc-patches
On Thu, Jun 10, 2021 at 10:09:26AM -0400, Jason Merrill wrote: > > --- gcc/cp/parser.c.jj 2021-06-09 21:54:39.482193853 +0200 > > +++ gcc/cp/parser.c 2021-06-10 10:09:23.753052980 +0200 > > @@ -10902,6 +10902,11 @@ cp_parser_lambda_expression (cp_parser* > > bool discarded = in_discarded

Re: [Patch] contrib/gcc-changelog: Check that PR in subject in in changelog

2021-06-10 Thread Tobias Burnus
On 10.06.21 16:24, Martin Liška wrote: I'm sending a small update that handles some flake8 issues and as defined in setup.cfg, line limit for the file is 120 characters. Aha, the known issue that Ubuntu 20.04 has a too old flake8 such that I only see a subset of the errors ... I have one quest

Re: [PATCH] libstdc++: Skip atomic instructions in _Sp_counted_base::_M_release when both counts are 1

2021-06-10 Thread Maged Michael via Gcc-patches
Would appreciate any comments on this proposed patch. Thanks, Maged On Thu, Dec 17, 2020 at 3:49 PM Maged Michael wrote: > Please find a proposed patch for _Sp_counted_base::_M_release to skip the > two atomic instructions that decrement each of the use count and the weak > count when both are

Re: [PATCH] c++: Extend std::is_constant_evaluated in if warning [PR100995]

2021-06-10 Thread Jason Merrill via Gcc-patches
On 6/9/21 9:46 PM, Marek Polacek wrote: Jakub pointed me at which shows that our existing warning could be extended to handle more cases. This patch implements that. A minor annoyance was handling macros, i

Re: [Patch] contrib/gcc-changelog: Check that PR in subject in in changelog

2021-06-10 Thread Martin Liška
On 6/10/21 4:07 PM, Tobias Burnus wrote: (Moved to gcc-patches, missed this when I replied to the initial email) Regarding patch at: https://gcc.gnu.org/pipermail/gcc/2021-June/236357.html On 10.06.21 14:45, Jonathan Wakely wrote: As well as the "contrig" typo that Florian noticed, the subjec

Re: [PATCH] c++: Add C++23 consteval if support - P1938R3 [PR100974]

2021-06-10 Thread Jason Merrill via Gcc-patches
On 6/10/21 4:34 AM, Jakub Jelinek wrote: Hi! The following patch implements consteval if support. Great! There is a new IF_STMT_CONSTEVAL_P flag on IF_STMT and IF_COND is boolean_false_node to match the non-manifestly constant evaluation behavior, while constexpr evaluation special-cases it.

Re: [Patch] contrib/gcc-changelog: Check that PR in subject in in changelog

2021-06-10 Thread Tobias Burnus
(Moved to gcc-patches, missed this when I replied to the initial email) Regarding patch at: https://gcc.gnu.org/pipermail/gcc/2021-June/236357.html On 10.06.21 14:45, Jonathan Wakely wrote: As well as the "contrig" typo that Florian noticed, the subject says "in in" which should be "is in". An

Re: GCC documentation: porting to Sphinx

2021-06-10 Thread Martin Liška
On 6/2/21 7:27 PM, Joseph Myers wrote: On Mon, 31 May 2021, Martin Liška wrote: https://splichal.eu/scripts/sphinx/ Looking at some examples there: https://splichal.eu/scripts/sphinx/gcc/_build/html/c-implementation-defined-behavior/preprocessing-directives.html has some conversion problems:

[committed] Use memory loads and extensions for cmp/test elimination on H8

2021-06-10 Thread Jeff Law via Gcc-patches
In today's episode of optimizing a dead architecture we're using memory loads and extensions to eliminate redundant test/compare instructions.  Memory loads are very straightforward, they set ZN in the expected way, but weren't recognized by h8300_select_cc_mode and were thus not used. Triviall

Re: [PATCH 2/2] arm: Auto-vectorization for MVE: add pack/unpack patterns

2021-06-10 Thread Christophe Lyon via Gcc-patches
On Thu, 10 Jun 2021 at 11:50, Christophe Lyon wrote: > > On Tue, 8 Jun 2021 at 14:10, Richard Sandiford > wrote: > > > > Christophe Lyon writes: > > > This patch adds vec_unpack_hi_, vec_unpack_lo_, > > > vec_pack_trunc_ patterns for MVE. > > > > > > It does so by moving the unpack patterns from

Re: GCC documentation: porting to Sphinx

2021-06-10 Thread Martin Liška
On 6/10/21 11:07 AM, Martin Liška wrote: Doing that, one has 2 unique links, that would be needed for get_option_url  function. Plus, both :option:`-Wfoo` and :option:`-Wno-foo` references are going to work. And I've actually did the transformation and one can see it e.g. here: https://splichal

Re: [PATCH, v3, OpenMP 5.0, libgomp] Structure element mapping for OpenMP 5.0

2021-06-10 Thread Jakub Jelinek via Gcc-patches
On Mon, May 31, 2021 at 09:36:41PM +0800, Chung-Lin Tang wrote: > this is a v3 version of my OpenMP 5.0 structure element mapping patch, > v2 was here: > https://gcc.gnu.org/pipermail/gcc-patches/2020-December/561139.html > > This v3 adds a small bug fix, where the initialization of the refcount

Re: [PATCH] PR fortran/100950 - ICE in output_constructor_regular_field, at varasm.c:5514

2021-06-10 Thread Bernhard Reutner-Fischer via Gcc-patches
On Thu, 10 Jun 2021 12:24:35 +0200 Bernhard Reutner-Fischer wrote: > On Wed, 9 Jun 2021 23:39:45 +0200 > Harald Anlauf via Gcc-patches wrote: > > +/* Check for constant length of a substring. */ > > + > > +static bool > > +substring_has_constant_len (gfc_expr *e) > > +{ > > + ptrdiff_t istart

Re: [PATCH] OpenACC: Separate enter/exit data APIs

2021-06-10 Thread Thomas Schwinge
Hi! On 2020-09-25T16:22:47+0100, Andrew Stubbs wrote: > On 30/07/2020 12:10, Andrew Stubbs wrote: >> On 29/07/2020 15:05, Andrew Stubbs wrote: >>> This patch does not implement anything new, but simply separates >>> OpenACC 'enter data' and 'exit data' into two libgomp API functions. >>> The orig

[RFC][ivopts] Generate better code for IVs with uses outside the loop

2021-06-10 Thread Andre Vieira (lists) via Gcc-patches
On 08/06/2021 16:00, Andre Simoes Dias Vieira via Gcc-patches wrote: Hi Bin, Thank you for the reply, I have some questions, see below. On 07/06/2021 12:28, Bin.Cheng wrote: On Fri, Jun 4, 2021 at 12:35 AM Andre Vieira (lists) via Gcc-patches wrote: Hi Andre, I didn't look into the details

Re: [OpenACC] declare directive

2021-06-10 Thread Thomas Schwinge
Hi! While working on something else... ;-) On 2015-10-27T15:18:00-0500, James Norris wrote: > --- a/libgomp/oacc-parallel.c > +++ b/libgomp/oacc-parallel.c > +GOACC_declare (int device, size_t mapnum, > +void **hostaddrs, size_t *sizes, unsigned short *kinds) > +{ > + int i; > + >

[PUSHED] Adjust variable names and comments in value-query.*

2021-06-10 Thread Aldy Hernandez via Gcc-patches
Now that range_of_expr can take arbitrary tree expressions, not just SSA names or constants, the method names and comments are slightly out of date. This patch adjusts them to reflect reality. Pushed. gcc/ChangeLog: * value-query.cc (value_query::value_on_edge): Rename name to e

Re: [PATCH 09/13] OpenACC 2.6 deep copy: C and C++ front-end parts

2021-06-10 Thread Thomas Schwinge
Hi! While working on something else... ;-) On 2019-12-17T22:03:49-0800, Julian Brown wrote: > --- /dev/null > +++ b/gcc/testsuite/c-c++-common/goacc/mdc-1.c > @@ -0,0 +1,55 @@ > +[...] > +#pragma acc acc enter data attach(s.e) > +[...] ... I noticed 'acc acc'. > --- /dev/null > +++ b/gcc/test

Re: [PATCH] Expose stable sort algorithm to gcc_sort_r and add vec::stablesort

2021-06-10 Thread Alexander Monakov via Gcc-patches
On Thu, 10 Jun 2021, Richard Biener wrote: > This makes it possible to apply GCCs stable sort algorithm to vec<> > and also use it with the qsort_r compatible interface. > > Alex, any comments? I'm afraid the patch is not correct, see below; (I'll also point out errors in comments while at it).

Re: [PATCH] rs6000: Support more short/char to float conversion

2021-06-10 Thread Segher Boessenkool
Hi! On Thu, Jun 10, 2021 at 05:32:23PM +0800, Kewen.Lin wrote: > +/* { dg-do compile { target lp64 } } */ One final thing: what requires lp64 here? Could you try without please? Okay for trunk with that considered. Thanks! Segher

Re: [PATCH] c++: Add C++23 consteval if support - P1938R3 [PR100974]

2021-06-10 Thread Jonathan Wakely via Gcc-patches
On Thu, 10 Jun 2021 at 11:34, Jakub Jelinek wrote: > > On Thu, Jun 10, 2021 at 11:24:43AM +0100, Jonathan Wakely wrote: > > > And I'm not changing the libstdc++ side, where perhaps we could change > > > std::is_constant_evaluated definition for > > > #ifdef __cpp_if_consteval > > > case to if const

Re: [PATCH] c++: Add C++23 consteval if support - P1938R3 [PR100974]

2021-06-10 Thread Jakub Jelinek via Gcc-patches
On Thu, Jun 10, 2021 at 11:24:43AM +0100, Jonathan Wakely wrote: > > And I'm not changing the libstdc++ side, where perhaps we could change > > std::is_constant_evaluated definition for > > #ifdef __cpp_if_consteval > > case to if consteval { return true; } else { return false; } > > but we need to

Re: RFC: Sphinx for GCC documentation

2021-06-10 Thread Martin Liška
On 6/7/21 4:19 PM, Tobias Burnus wrote: On 07.06.21 15:28, Martin Liška wrote: * I note that we write before the argument index, that those are without -/-- prefix    but that's not true. Something to fix after the conversation. Can you please show me a few examples of it? * https://splicha

Re: [PATCH] c++: Add C++23 consteval if support - P1938R3 [PR100974]

2021-06-10 Thread Jonathan Wakely via Gcc-patches
On Thu, 10 Jun 2021 at 09:34, Jakub Jelinek wrote: > Also, the paper doesn't contain the exact __cpp_if_consteval value, Right, proposals aren't supposed to, because the value gets set when the proposal is voted into the working draft (which the proposal author doesn't control). > but https://git

Re: [PATCH] PR fortran/100950 - ICE in output_constructor_regular_field, at varasm.c:5514

2021-06-10 Thread Bernhard Reutner-Fischer via Gcc-patches
On Wed, 9 Jun 2021 23:39:45 +0200 Harald Anlauf via Gcc-patches wrote: > diff --git a/gcc/fortran/simplify.c b/gcc/fortran/simplify.c > index c27b47aa98f..016ec259518 100644 > --- a/gcc/fortran/simplify.c > +++ b/gcc/fortran/simplify.c > @@ -4512,6 +4512,60 @@ gfc_simplify_leadz (gfc_expr *e) >

Re: [PATCH 2/2] arm: Auto-vectorization for MVE: add pack/unpack patterns

2021-06-10 Thread Christophe Lyon via Gcc-patches
On Tue, 8 Jun 2021 at 14:10, Richard Sandiford wrote: > > Christophe Lyon writes: > > This patch adds vec_unpack_hi_, vec_unpack_lo_, > > vec_pack_trunc_ patterns for MVE. > > > > It does so by moving the unpack patterns from neon.md to > > vec-common.md, while adding them support for MVE. The pa

[PATCH] Expose stable sort algorithm to gcc_sort_r and add vec::stablesort

2021-06-10 Thread Richard Biener
This makes it possible to apply GCCs stable sort algorithm to vec<> and also use it with the qsort_r compatible interface. Alex, any comments? Bootstrapped & tested on x86_64-unknown-linux-gnu (with some not here included changes to actually use stablesort) 2021-06-10 Richard Biener

Re: [PATCH] rs6000: Support more short/char to float conversion

2021-06-10 Thread Kewen.Lin via Gcc-patches
Hi Segher, Thanks for the review! on 2021/6/10 上午7:23, Segher Boessenkool wrote: > Hi! > > On Fri, May 07, 2021 at 10:30:38AM +0800, Kewen.Lin wrote: >> For some cases that when we load unsigned char/short values from >> the appropriate unsigned char/short memories and convert them to >> double/

Re: GCC documentation: porting to Sphinx

2021-06-10 Thread Martin Liška
On 6/4/21 5:10 PM, Martin Sebor wrote: On 6/3/21 4:56 AM, Martin Liška wrote: On 6/2/21 10:41 PM, Martin Sebor wrote: On 5/31/21 7:25 AM, Martin Liška wrote: Hello. I've made quite some progress with the porting of the documentation and I would like to present it to the community now: https:/

[PATCH] Use auto_vec in ssa_equiv_stack.

2021-06-10 Thread Aldy Hernandez via Gcc-patches
There is a mismatch between the new and the delete for the ssa_equiv_stack class. The correct idiom should have been delete[]. It has been pointed out that perhaps a better alternative is to use an auto_vec which does everything automatically. Plus, it is more consistent with m_stack which is alr

[PATCH] tree-optimization/101003 - use pattern defs when linearizing

2021-06-10 Thread Richard Biener
We of course have to use pattern stmt defs for the linearized chain operands which is what I failed to ensure. Bootstrapped and tested on x86_64-unknown-linux-gnu, pushed. 2021-06-10 Richard Biener PR tree-optimization/101003 * tree-vect-slp.c (vect_build_slp_tree_2): Appropri

[PATCH] c++: Add C++23 consteval if support - P1938R3 [PR100974]

2021-06-10 Thread Jakub Jelinek via Gcc-patches
Hi! The following patch implements consteval if support. There is a new IF_STMT_CONSTEVAL_P flag on IF_STMT and IF_COND is boolean_false_node to match the non-manifestly constant evaluation behavior, while constexpr evaluation special-cases it. Perhaps cleaner would be to set the condition to __b

[committed] testsuite: Uncomment __cpp_consteval test

2021-06-10 Thread Jakub Jelinek via Gcc-patches
Hi! The __cpp_consteval macro and corresponding test have been initially commented out because the consteval support didn't have virtual consteval method support. The r11-1789-ge6321c4508b2a85c21246c1c06a8208e2a151e48 change enabled the macro but didn't enable the corresponding test. Bootstrappe

Re: [PATCH] rs6000: Support doubleword swaps removal in rot64 load store [PR100085]

2021-06-10 Thread Xionghu Luo via Gcc-patches
On 2021/6/10 00:24, Segher Boessenkool wrote: > On Wed, Jun 09, 2021 at 11:20:20AM +0800, Xionghu Luo wrote: >> On 2021/6/9 04:11, Segher Boessenkool wrote: >>> On Fri, Jun 04, 2021 at 09:40:58AM +0800, Xionghu Luo wrote: >> rejecting combination of insns 6 and 7 >> original costs 4 + 4