Re: PR98974: Fix vectorizable_condition after STMT_VINFO_VEC_STMTS

2021-02-08 Thread Richard Sandiford via Gcc-patches
"Andre Vieira (lists)" writes: > On 05/02/2021 12:47, Richard Sandiford wrote: >> "Andre Vieira (lists)" writes: >>> Hi, >>> >>> As mentioned in the PR, this patch fixes up the nvectors parameter passed >>> to vect_get_loop_mask in vectorizable_condition. >>> Before the STMT_VINFO_VEC_STMTS rewo

RE: [PATCH] tree-optimization/97236 - fix bad use of VMAT_CONTIGUOUS

2021-02-08 Thread Kyrylo Tkachov via Gcc-patches
> -Original Message- > From: Richard Biener > Sent: 05 February 2021 13:51 > To: Kyrylo Tkachov > Cc: gcc-patches@gcc.gnu.org > Subject: RE: [PATCH] tree-optimization/97236 - fix bad use of > VMAT_CONTIGUOUS > > On Fri, 5 Feb 2021, Kyrylo Tkachov wrote: > > > Hi Richard, > > > > > --

RE: [PATCH] tree-optimization/97236 - fix bad use of VMAT_CONTIGUOUS

2021-02-08 Thread Richard Biener
On Mon, 8 Feb 2021, Kyrylo Tkachov wrote: > > > > -Original Message- > > From: Richard Biener > > Sent: 05 February 2021 13:51 > > To: Kyrylo Tkachov > > Cc: gcc-patches@gcc.gnu.org > > Subject: RE: [PATCH] tree-optimization/97236 - fix bad use of > > VMAT_CONTIGUOUS > > > > On Fri, 5

Re: calibrate intervals to avoid zero in futures poll test

2021-02-08 Thread Christophe Lyon via Gcc-patches
On Thu, 14 Jan 2021 at 19:57, Alexandre Oliva wrote: > > On Jan 14, 2021, Jonathan Wakely wrote: > > >> + /* Got for some 10 cycles, but we're already past that and still > > > I can't parse "Got for some 10 cycles". If that's just a typo > > Yeah, I meant "Go for ... but if ..." and managed

[PATCH] lto/96591 - walk VECTOR_CST elements in walk_tree

2021-02-08 Thread Richard Biener
This implements walking of VECTOR_CST elements in walk_tree, mimicing the walk of COMPLEX_CST elements. Without this free-lang-data fails to see some types in case they are only refered to via tree constants used only as VECTOR_CST elements. LTO bootstrapped, testing on x86_64-unknown-linux-gnu i

Re: [PATCH] opts: fix handling of -fpatchable-function-entries option

2021-02-08 Thread Richard Biener via Gcc-patches
On Fri, Feb 5, 2021 at 2:49 PM Martin Liška wrote: > > Hello. > > As seen the flag -fpatchable-function-entry is properly marked as > Optimization. > However, it's the argument is parsed early and stored into the following > tuple: > > ; How many NOP insns to place at each function entry by defa

Re: [PATCH] document BLOCK_ABSTRACT_ORIGIN et al.

2021-02-08 Thread Richard Biener via Gcc-patches
On Sat, Feb 6, 2021 at 8:11 PM Martin Sebor wrote: > > On 2/4/21 1:48 AM, Richard Biener wrote: > > On Wed, Feb 3, 2021 at 6:12 PM Martin Sebor wrote: > >> > >> On 2/3/21 5:01 AM, Richard Biener wrote: > >>> On Mon, Feb 1, 2021 at 5:20 PM Martin Sebor wrote: > > I have pushed the tree.

[PATCH 0/8 RFC] unbreak --with-included-gettext, and other configury stuff

2021-02-08 Thread Nick Alcock via Gcc-patches
Most of this series serves one goal: fixing problems Stephen Casner reported with a binutils built --with-included-gettext or built on a platform that doesn't have a gettext in a system libintl or in libc. This has long been broken in binutils. Firstly, two commits from last year that allow intl/

[PATCH 3/8] intl: always picify

2021-02-08 Thread Nick Alcock via Gcc-patches
libintl is included in several shared libraries (at least libinproctrace.so and libctf.so): unconditionally picify with code borrowed from libiberty configure. (It's not performance-critical, so don't bother making separate PIC and non-PIC libraries like libiberty does.) Cc: gcc-patc...@gnu.org

[PATCH 4/8] intl: turn LIBINTL into -L / -l form

2021-02-08 Thread Nick Alcock via Gcc-patches
This variable currently refers directly, not to a .la file, but to an .a file. This produces wrong results when building into a library on some platforms: so convert it to the general form "-L${top_builddir}../intl -lintl ..." ... so that both libtool and non-libtool builds will always do the righ

Re: [PATCH] mklog: automatically fill in generated entries

2021-02-08 Thread Martin Liška
On 2/7/21 9:20 PM, Mike Frysinger via Gcc-patches wrote: contrib/ChangeLog: * mklog.py (generated_files): New set. (generate_changelog): Add entries based on generated_files. --- contrib/mklog.py | 5 + 1 file changed, 5 insertions(+) diff --git a/contrib/mklog.py b/contr

Re: [PATCH, rs6000, expand, hooks]: Fix PR98872, handle uninitialized opaque mode variables

2021-02-08 Thread Richard Sandiford via Gcc-patches
Peter Bergner writes: > Adding Richard since he's reviewed the generic opaque mode code in > the past and this patch contains some more eneric support. > > GCC handles pseudos that are used uninitialized, by emitting a > (set (reg: ) CONST0_RTX(regmode)) before their uninitialized > pseudo usage.

[PATCH] x86: Always save and restore shadow stack pointer

2021-02-08 Thread H.J. Lu via Gcc-patches
When the SHSTK feature is not available or not enabled, RDSSP is a NOP, always save and restore shadow stack pointer to support compiling source codes, containing __builtin_setjmp and __builtin_longjmp, with different -fcf-protection options. PR target/98997 * config/i386/i386.md (

[RFC] ldist: Recognize rawmemchr loop patterns

2021-02-08 Thread Stefan Schulze Frielinghaus via Gcc-patches
This patch adds support for recognizing loops which mimic the behaviour of function rawmemchr, and replaces those with an internal function call in case a target provides them. In contrast to the original rawmemchr function, this patch also supports different instances where the memory pointed to

Re: [PATCH, rs6000, expand, hooks]: Fix PR98872, handle uninitialized opaque mode variables

2021-02-08 Thread Segher Boessenkool
Hi! On Mon, Feb 08, 2021 at 12:38:01PM +, Richard Sandiford wrote: > Peter Bergner writes: > > Adding Richard since he's reviewed the generic opaque mode code in > > the past and this patch contains some more eneric support. > > > > GCC handles pseudos that are used uninitialized, by emitting

Re: [PATCH 3/4] openacc: Fix lowering for derived-type mappings through array elements

2021-02-08 Thread Tobias Burnus
On 06.02.21 11:49, Julian Brown wrote: if (n->expr) for (gfc_ref *ref = n->expr->ref; ref; ref = ref->next) - if (ref->type == REF_COMPONENT || ref->type == REF_ARRAY) + if (ref->type == REF_COMPONENT) lastref = ref; +

[PATCH, OG10, committed] Support A->B expressions in map clause

2021-02-08 Thread Chung-Lin Tang
This patch tries to allow map(A->ptr) to be properly handled the same way as map(B.ptr) expressions. map(struct:*A) clauses are now produced during gimplify. Julian, I'm CCing you since IIRC you seemed to be the author of this area of code. Would appreciate if you gave a look if you have time, th

[PING] Add conversions between _Float128 and Decimal.

2021-02-08 Thread Michael Meissner via Gcc-patches
Ping patch. This really needs to go in to allow switching the long double type to IEEE 128-bit. https://gcc.gnu.org/pipermail/gcc-patches/2021-January/564486.html | Subject: [PATCH] Add conversions between _Float128 and Decimal. | Message-ID: <20210129024208.ga25...@ibm-toto.the-meissners.org> -

[pushed] c++: Fix typo in CLASSTYPE_TI_TEMPLATE comment.

2021-02-08 Thread Marek Polacek via Gcc-patches
gcc/cp/ChangeLog: * cp-tree.h (CLASSTYPE_TI_TEMPLATE): Fix typo. --- gcc/cp/cp-tree.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gcc/cp/cp-tree.h b/gcc/cp/cp-tree.h index 970ed5e77bb..41472a895b5 100644 --- a/gcc/cp/cp-tree.h +++ b/gcc/cp/cp-tree.h @@ -3775,8

PR 96391? Can we fix it for gcc11?

2021-02-08 Thread Qing Zhao via Gcc-patches
Hi, The bug https://gcc.gnu.org/bugzilla/show_bug.cgi?id=96391 Bug 96391 - [10/11 Regression] internal compiler error: in linemap_compare_locations, at libcpp/line-map.c:1359 has been opened on 7/30/2020, and multiple users reported the sa

RE: [AArch64] Fix vector multiplication costs

2021-02-08 Thread Kyrylo Tkachov via Gcc-patches
> -Original Message- > From: Andre Vieira (lists) > Sent: 03 February 2021 17:59 > To: gcc-patches@gcc.gnu.org > Cc: Kyrylo Tkachov > Subject: [AArch64] Fix vector multiplication costs > > This patch introduces a vect.mul RTX cost and decouples the vector > multiplication costing from

[Patch] Fortran: %re/%im fixes for OpenMP/OpenACC + gfc_is_simplify_contiguous

2021-02-08 Thread Tobias Burnus
Found when looking at Julian's 3/4 OpenACC patch, which has not yet been committed (and needs still to be revised a bit.) The fix (a) avoids an ICE when Julian's patch has been applied. The patch (b) just makes one error message less confusing. The testcase shows that only %re/%im run reach the

[PATCH 1/4] c++: Avoid building garbage trees from tsubst_requires_expr

2021-02-08 Thread Patrick Palka via Gcc-patches
Since we no longer partially instantiate REQUIRES_EXPRs, we don't need to rebuild its requirements during tsubst_requires_expr. gcc/cp/ChangeLog: * constraint.cc (tsubst_simple_requirement): Just return boolean_true_node on success. (tsubst_type_requirement): Likewise.

[PATCH 2/4] c++: Preparatory type canonicalization fixes

2021-02-08 Thread Patrick Palka via Gcc-patches
The subsequent patches revealed some latent type canonicalization issues during normalization and satisfaction: 1. In tsubst_parameter_mapping, we're canonicalizing the arguments of a TYPE_ARGUMENT_PACK only if 'arg' wasn't a TYPE_ARGUMENT_PACK to begin with. 2. We currently set DECL_CONTEX

[PATCH 3/4] c++: Delay normalizing nested requirements until satisfaction

2021-02-08 Thread Patrick Palka via Gcc-patches
This sets up the functionality for controlling the initial set of template parameters to pass to normalization when dealing with a constraint-expression that is not associated with some constrained declaration, for instance when normalizing a nested requirement of a requires expression, or the cons

[PATCH 4/4] c++: dependent constraint on placeholder 'auto' [PR96443]

2021-02-08 Thread Patrick Palka via Gcc-patches
This fixes the way we check satisfaction of constraints on placeholder types in various contexts, and in particular when the constraint is dependent. Firstly, when evaluating the return type requirement of a compound requirement, we currently substitute the outer template arguments into the constr

Re: [PATCH] adjust "partly out of bounds" warning (PR 98503)

2021-02-08 Thread Jeff Law via Gcc-patches
On 2/3/21 3:45 PM, Martin Sebor wrote: > On 2/3/21 2:57 PM, Jeff Law wrote: >> >> >> On 1/28/21 4:03 PM, Martin Sebor wrote: >>> The GCC 11 -Warray-bounds enhancement to diagnose accesses whose >>> leading offset is in bounds but whose trailing offset is not has >>> been causing some confusion. 

Re: [PATCH 4/4] c++: dependent constraint on placeholder 'auto' [PR96443]

2021-02-08 Thread Patrick Palka via Gcc-patches
On Mon, 8 Feb 2021, Patrick Palka wrote: > This fixes the way we check satisfaction of constraints on placeholder > types in various contexts, and in particular when the constraint is > dependent. > > Firstly, when evaluating the return type requirement of a compound > requirement, we currently s

Re: [PATCH] avoid -Warray-bounds checks for vtable assignments (PR 98266)

2021-02-08 Thread Jeff Law via Gcc-patches
On 1/19/21 5:56 PM, Martin Sebor via Gcc-patches wrote: > Similar to the problem reported for -Wstringop-overflow in pr98266 > and already fixed, -Warray-bounds is also susceptible to false > positives in assignments and copies involving virtual inheritance. > Because the two warnings don't shar

Re: [PATCH][Bug libstdc++/70303] Value-initialized debug iterators

2021-02-08 Thread François Dumont via Gcc-patches
On 01/02/21 8:09 pm, Jonathan Wakely wrote: On 01/02/21 19:30 +0100, François Dumont via Libstdc++ wrote: On 01/02/21 6:43 pm, Jonathan Wakely wrote: On 31/01/21 16:59 +0100, François Dumont via Libstdc++ wrote: After the debug issue has been fixed in PR 98466 the problem was not in the debug

[PATCH] don't enable DWARF5 by default on Windows (PR98860)

2021-02-08 Thread Mikael Pettersson via Gcc-patches
PR98860 is a gcc-11 regression where bootstrap fails on Windows since the switch to enable DWARF5 by default. The symptoms are that executables generated by the stage1 compiler fail to run with "Exec format error", which confuses subsequent configure steps and causes hard errors. This happens even

Re: [PATCH] avoid -Warray-bounds checks for vtable assignments (PR 98266)

2021-02-08 Thread Martin Sebor via Gcc-patches
On 2/8/21 12:59 PM, Jeff Law wrote: On 1/19/21 5:56 PM, Martin Sebor via Gcc-patches wrote: Similar to the problem reported for -Wstringop-overflow in pr98266 and already fixed, -Warray-bounds is also susceptible to false positives in assignments and copies involving virtual inheritance. Becau

Re: [PING] Add conversions between _Float128 and Decimal.

2021-02-08 Thread Segher Boessenkool
On Mon, Feb 08, 2021 at 11:32:19AM -0500, Michael Meissner wrote: > Ping patch. This really needs to go in to allow switching the long double > type > to IEEE 128-bit. Please send a version that incorporates fixes to Will's nits? Especially fix the copyright dates. Segher

Re: [PATCH] avoid -Warray-bounds checks for vtable assignments (PR 98266)

2021-02-08 Thread Jeff Law via Gcc-patches
On 2/8/21 2:56 PM, Martin Sebor wrote: > On 2/8/21 12:59 PM, Jeff Law wrote: >> >> >> On 1/19/21 5:56 PM, Martin Sebor via Gcc-patches wrote: >>> Similar to the problem reported for -Wstringop-overflow in pr98266 >>> and already fixed, -Warray-bounds is also susceptible to false >>> positives in

Re: [PATCH] libstdc++: Don't use reserved identifiers in simd headers

2021-02-08 Thread Jonathan Wakely via Gcc-patches
On 01/02/21 13:21 +0100, Rainer Orth wrote: Two simd tests FAIL on Solaris, both SPARC and x86: FAIL: experimental/simd/standard_abi_usable.cc -msse2 -O2 -Wno-psabi (test for excess errors) FAIL: experimental/simd/standard_abi_usable_2.cc -msse2 -O2 -Wno-psabi (test for excess errors) This ha

Re: [PATCH] mklog: automatically fill in generated entries

2021-02-08 Thread Joseph Myers
On Sun, 7 Feb 2021, Mike Frysinger via Gcc-patches wrote: > +# NB: Makefile.in isn't listed as it's not always generated. > +generated_files = {'aclocal.m4', 'config.h.in', 'configure'} libiberty/aclocal.m4 isn't a generated file either. -- Joseph S. Myers jos...@codesourcery.com

Re: [PATCH] avoid -Warray-bounds checks for vtable assignments (PR 98266)

2021-02-08 Thread Martin Sebor via Gcc-patches
On 2/8/21 3:26 PM, Jeff Law wrote: On 2/8/21 2:56 PM, Martin Sebor wrote: On 2/8/21 12:59 PM, Jeff Law wrote: On 1/19/21 5:56 PM, Martin Sebor via Gcc-patches wrote: Similar to the problem reported for -Wstringop-overflow in pr98266 and already fixed, -Warray-bounds is also susceptible to

Re: [PATCH] adjust "partly out of bounds" warning (PR 98503)

2021-02-08 Thread Martin Sebor via Gcc-patches
On 2/8/21 12:09 PM, Jeff Law wrote: On 2/3/21 3:45 PM, Martin Sebor wrote: On 2/3/21 2:57 PM, Jeff Law wrote: On 1/28/21 4:03 PM, Martin Sebor wrote: The GCC 11 -Warray-bounds enhancement to diagnose accesses whose leading offset is in bounds but whose trailing offset is not has been causi

Re: [PATCH] avoid -Warray-bounds checks for vtable assignments (PR 98266)

2021-02-08 Thread Jeff Law via Gcc-patches
On 2/8/21 3:44 PM, Martin Sebor wrote: > On 2/8/21 3:26 PM, Jeff Law wrote: >> >> >> On 2/8/21 2:56 PM, Martin Sebor wrote: >>> On 2/8/21 12:59 PM, Jeff Law wrote: On 1/19/21 5:56 PM, Martin Sebor via Gcc-patches wrote: > Similar to the problem reported for -Wstringop-overflow

Re: [PATCH] run -Wnonnull later (PR 87489)

2021-02-08 Thread Jeff Law via Gcc-patches
On 1/31/21 5:31 PM, Martin Sebor via Gcc-patches wrote: > The initial -Wnonnull implementation in the middle end took place > too late in the pipeline (just before expansion), and as a result > was prone to false positives (bug 78817).  In an attempt to avoid > the worst of those, the warning wa

Re: [PATCH] adjust "partly out of bounds" warning (PR 98503)

2021-02-08 Thread Jeff Law via Gcc-patches
On 2/8/21 4:07 PM, Martin Sebor wrote: > On 2/8/21 12:09 PM, Jeff Law wrote: >> >> >> On 2/3/21 3:45 PM, Martin Sebor wrote: >>> On 2/3/21 2:57 PM, Jeff Law wrote: On 1/28/21 4:03 PM, Martin Sebor wrote: > The GCC 11 -Warray-bounds enhancement to diagnose accesses whose >

Re: [PATCH] mklog: automatically fill in generated entries

2021-02-08 Thread Mike Frysinger via Gcc-patches
On 08 Feb 2021 22:44, Joseph Myers wrote: > On Sun, 7 Feb 2021, Mike Frysinger via Gcc-patches wrote: > > +# NB: Makefile.in isn't listed as it's not always generated. > > +generated_files = {'aclocal.m4', 'config.h.in', 'configure'} > > libiberty/aclocal.m4 isn't a generated file either. that is

[pushed] c++: constexpr, union, and no_unique_address [PR98994]

2021-02-08 Thread Jason Merrill via Gcc-patches
My second patch for 97566 omits nested CONSTRUCTORs for empty fields, but we do want them for empty union members. Tested x86_64-pc-linux-gnu, applying to trunk. gcc/cp/ChangeLog: PR c++/98994 PR c++/97566 * constexpr.c (cxx_eval_store_expression): Only skip empty fields

[pushed] c++: generic lambda, fn* conv, empty class [PR98326]

2021-02-08 Thread Jason Merrill via Gcc-patches
Here, in the thunk returned from the captureless lambda conversion to pointer-to-function, we try to pass through invisible reference parameters by reference, without doing a copy. The empty class copy optimization was messing that up. Tested x86_64-pc-linux-gnu, applying to trunk. gcc/cp/Change

[pushed] c++: consteval and explicit instantiation [PR96905]

2021-02-08 Thread Jason Merrill via Gcc-patches
Normally, an explicit instantiation means we want to write out the instantiation. But not for a consteval function. Tested x86_64-pc-linux-gnu, applying to trunk. gcc/cp/ChangeLog: PR c++/96905 * pt.c (mark_decl_instantiated): Exit early if consteval. gcc/testsuite/ChangeLog:

Re: [PATCH] c++: Private parent access check for using decls [PR19377]

2021-02-08 Thread Jason Merrill via Gcc-patches
On 2/5/21 12:28 PM, Anthony Sharp wrote: Hi Marek, + if ((TREE_CODE (parent_field) == USING_DECL) This first term doesn't need to be wrapped in (). I normally wouldn't use the (), but I think that's how Jason likes it so that's why I did it. I guess it makes it more readable. Ah, no,

Re: [PATCH 1/4] c++: Avoid building garbage trees from tsubst_requires_expr

2021-02-08 Thread Jason Merrill via Gcc-patches
On 2/8/21 2:03 PM, Patrick Palka wrote: Since we no longer partially instantiate REQUIRES_EXPRs, we don't need to rebuild its requirements during tsubst_requires_expr. OK. gcc/cp/ChangeLog: * constraint.cc (tsubst_simple_requirement): Just return boolean_true_node on success.

Re: [PATCH 2/4] c++: Preparatory type canonicalization fixes

2021-02-08 Thread Jason Merrill via Gcc-patches
On 2/8/21 2:03 PM, Patrick Palka wrote: The subsequent patches revealed some latent type canonicalization issues during normalization and satisfaction: 1. In tsubst_parameter_mapping, we're canonicalizing the arguments of a TYPE_ARGUMENT_PACK only if 'arg' wasn't a TYPE_ARGUMENT_PACK to begi

Re: [PATCH] don't enable DWARF5 by default on Windows (PR98860)

2021-02-08 Thread Richard Biener via Gcc-patches
On February 8, 2021 10:44:26 PM GMT+01:00, Mikael Pettersson via Gcc-patches wrote: >PR98860 is a gcc-11 regression where bootstrap fails on Windows since >the switch to enable DWARF5 by default. The symptoms are that >executables generated by the stage1 compiler fail to run with "Exec >format er

[PATCH, V2] Add conversions between _Float128 and Decimal.

2021-02-08 Thread Michael Meissner via Gcc-patches
[PATCH V2] Add conversions between _Float128 and Decimal. This patch implements conversions between _Float128 and the 3 Decimal floating types. It does this by extendending the dfp-bit conversions to add a new binary floating point type (KF), and doing the conversions in the same manner as the ot

Re: [PATCH] adjust "partly out of bounds" warning (PR 98503)

2021-02-08 Thread Richard Biener via Gcc-patches
On Tue, Feb 9, 2021 at 1:04 AM Martin Sebor via Gcc-patches wrote: > > On 2/8/21 12:09 PM, Jeff Law wrote: > > > > > > On 2/3/21 3:45 PM, Martin Sebor wrote: > >> On 2/3/21 2:57 PM, Jeff Law wrote: > >>> > >>> > >>> On 1/28/21 4:03 PM, Martin Sebor wrote: > The GCC 11 -Warray-bounds enhanceme