[PATCH v3] tree-optimization/103759: Use sizetype everywhere for object sizes

2021-12-17 Thread Siddhesh Poyarekar
Since all computations in tree-object-size are now done in sizetype and not HOST_WIDE_INT, comparisons with HOST_WIDE_INT based unknown and initval would be incorrect. Instead, use the sizetype trees directly to generate and evaluate initval and unknown size values. gcc/ChangeLog: PR

Re: [PATCH] config.gcc: Obsolete m32c-rtems target

2021-12-17 Thread Jeff Law via Gcc-patches
On 12/17/2021 9:10 AM, Joel Sherrill wrote: --- gcc/config.gcc | 1 + 1 file changed, 1 insertion(+) diff --git a/gcc/config.gcc b/gcc/config.gcc index c8824367b13..fe93a72a16c 100644 --- a/gcc/config.gcc +++ b/gcc/config.gcc @@ -252,6 +252,7 @@ case ${target} in | cr16-*-*

Re: [PATCH, rs6000] Implement mffscrni pattern

2021-12-17 Thread David Edelsohn via Gcc-patches
On Thu, Dec 16, 2021 at 9:43 PM HAO CHEN GUI wrote: > > Hi, >This patch defines a pattern for mffscrni. If the RN is a constant, it can > call > gen_rs6000_mffscrni directly. The "rs6000-builtin-new.def" defines prototype > for builtin arguments. > The pattern "rs6000_set_fpscr_rn" is then

Re: [patch] Future-proof and homogenise handling of darwin versions

2021-12-17 Thread Iain Sandoe
Hi FX, thanks for the patch > On 17 Dec 2021, at 22:23, FX wrote: > > The current GCC branch will become 12.1.0, which will be the stable version > of GCC when the next macOS version is released. There are some places in GCC > that don’t handle darwin22 as a version, so we need to

[PATCH] c-family: Have -Wformat-diag accept "decl-specifier" [PR103758]

2021-12-17 Thread Marek Polacek via Gcc-patches
I'm tired of seeing cp/parser.c:15923:55: warning: misspelled term 'decl' in format; use 'declaration' instead [-Wformat-diag] cp/parser.c:15925:57: warning: misspelled term 'decl' in format; use 'declaration' instead [-Wformat-diag] every time I compile cp/parser.c, which happens...a lot.

[PATCH] c++: Avoid narrowing in make_char_string_pack

2021-12-17 Thread Marek Polacek via Gcc-patches
This fixes gcc/cp/parser.c:4618:41: warning: narrowing conversion of '(char)(*(str + ((sizetype)i)))' from 'char' to 'unsigned char' [-Wnarrowing] 4618 | unsigned char s[3] = { '\'', str[i], '\'' }; |~^ Bootstrapped/regtested on

[PATCH v4] attribs: Fix wrong error with -Wno-attribute=A::b [PR103649]

2021-12-17 Thread Marek Polacek via Gcc-patches
On Fri, Dec 17, 2021 at 02:33:01PM -0500, Jason Merrill wrote: > On 12/17/21 13:14, Marek Polacek wrote: > > @@ -28979,7 +28979,9 @@ cp_parser_std_attribute (cp_parser *parser, tree > > attr_ns) > > /* A GNU attribute that takes an identifier in parameter. */ > > attr_flag =

[GCC-11] [PATCH] libsanitizer: Cherry-pick LLVM release/13.x commit d96358a28193

2021-12-17 Thread H.J. Lu via Gcc-patches
OK for release branches? H.J. --- Cherry-pick from LLVM release/13.x branch: commit d96358a2819399a2abb60ad3b26444ab7b4409cf Author: Michał Górny Date: Mon Dec 13 22:28:26 2021 +0100 [compiler-rt] Increase kDlsymAllocPoolSize to fix test failures Increase kDlsymAllocPoolSize on the

Re: [PATCH] tree-optimization/103759: Truncate unknown to sizetype on compare

2021-12-17 Thread Jakub Jelinek via Gcc-patches
On Sat, Dec 18, 2021 at 02:53:47AM +0530, Siddhesh Poyarekar wrote: > Since all computations in tree-object-size are now done in sizetype and > not HOST_WIDE_INT, comparisons after conversion to HOST_WIDE_INT would > be incorrect. Instead, truncate unknown (object_size_type) to sizetype > to

[PATCH v2] tree-optimization/103759: Truncate unknown to sizetype on compare

2021-12-17 Thread Siddhesh Poyarekar
Since all computations in tree-object-size are now done in sizetype and not HOST_WIDE_INT, comparisons after conversion to HOST_WIDE_INT would be incorrect. Instead, truncate unknown (object_size_type) to sizetype to compare with the computed size to evaluate if it is unknown. gcc/ChangeLog:

[PATCH] tree-optimization/103759: Truncate unknown to sizetype on compare

2021-12-17 Thread Siddhesh Poyarekar
Since all computations in tree-object-size are now done in sizetype and not HOST_WIDE_INT, comparisons after conversion to HOST_WIDE_INT would be incorrect. Instead, truncate unknown (object_size_type) to sizetype to compare with the computed size to evaluate if it is unknown. gcc/ChangeLog:

Re: [PATCH] c++: don't ICE on NAMESPACE_DECL inside FUNCTION_DECL

2021-12-17 Thread Jason Merrill via Gcc-patches
On 12/15/21 03:53, Matthias Kretz wrote: OK for trunk? This fixes several modules.exp failures for me. OK. ── ✂ ── Code like void swap() { namespace __variant = __detail::__variant; ... } create a NAMESPACE_DECL where the

Re: [PATCH] Add VxWorks fixincludes hack, kernel math.h FP_ constants

2021-12-17 Thread Olivier Hainque via Gcc-patches
> On 17 Dec 2021, at 20:16, Olivier Hainque wrote: > >> Don't you also need to add an fpclassify() macro? There's a >> >> checking for ISO C99 support in for C++98 >> >> which checks whether math.h supplies (among others) fpclassify(). > > We have a separate "fix" for a set of such

Re: [PATCH] config.gcc: Obsolete m32c-rtems target

2021-12-17 Thread Joel Sherrill
On Fri, Dec 17, 2021 at 12:53 PM Eric Gallager wrote: > > On Fri, Dec 17, 2021 at 11:11 AM Joel Sherrill wrote: > > > > --- > > gcc/config.gcc | 1 + > > 1 file changed, 1 insertion(+) > > > > diff --git a/gcc/config.gcc b/gcc/config.gcc > > index c8824367b13..fe93a72a16c 100644 > > ---

[r12-6030 Regression] FAIL: gcc.dg/builtin-object-size-2.c execution test on Linux/x86_64

2021-12-17 Thread sunil.k.pandey via Gcc-patches
On Linux/x86_64, 422f9eb7011b76c12ff00ffaee2bcc9cdddf16d5 is the first bad commit commit 422f9eb7011b76c12ff00ffaee2bcc9cdddf16d5 Author: Siddhesh Poyarekar Date: Fri Dec 17 07:07:18 2021 +0530 tree-object-size: Use trees and support negative offsets caused FAIL:

[r12-6031 Regression] FAIL: gcc.dg/builtin-dynamic-object-size-2.c execution test on Linux/x86_64

2021-12-17 Thread sunil.k.pandey via Gcc-patches
On Linux/x86_64, 79a89108dd352cd9288f5de35481b1280c7588a5 is the first bad commit commit 79a89108dd352cd9288f5de35481b1280c7588a5 Author: Siddhesh Poyarekar Date: Fri Dec 17 09:34:44 2021 +0530 __builtin_dynamic_object_size: Recognize builtin caused FAIL:

Re: [PATCH v4 0/6] __builtin_dynamic_object_size

2021-12-17 Thread Siddhesh Poyarekar
On 12/18/21 00:59, David Edelsohn wrote: Siddhesh, This patch series seems to have caused testsuite regressions for memcpy-chk, etc. in 32 bit mode (i386, x86-64 -m32 and -mx32, AIX 32 bit). I have opened PR 103759. Thanks, I've assigned it to myself. I'll take a look. Siddhesh

[GCC-WWWDocs v1] htdocs/gcc-12/changes.html: Obsolete m32c-*-rtems*

2021-12-17 Thread Joel Sherrill
--- htdocs/gcc-12/changes.html | 4 1 file changed, 4 insertions(+) diff --git a/htdocs/gcc-12/changes.html b/htdocs/gcc-12/changes.html index b1c88670..c69b301e 100644 --- a/htdocs/gcc-12/changes.html +++ b/htdocs/gcc-12/changes.html @@ -66,6 +66,10 @@ a work-in-progress. The

Re: [PATCH v3] attribs: Fix wrong error with -Wno-attribute=A::b [PR103649]

2021-12-17 Thread Jason Merrill via Gcc-patches
On 12/17/21 13:14, Marek Polacek wrote: On Thu, Dec 16, 2021 at 08:06:43PM -0500, Jason Merrill wrote: On 12/16/21 19:52, Marek Polacek wrote: --- /dev/null +++ b/gcc/testsuite/c-c++-common/Wno-attributes-6.c @@ -0,0 +1,14 @@ +/* PR c/103649 */ +/* { dg-do compile { target { c || c++11 } } }

Re: [PATCH v4 0/6] __builtin_dynamic_object_size

2021-12-17 Thread David Edelsohn via Gcc-patches
Siddhesh, This patch series seems to have caused testsuite regressions for memcpy-chk, etc. in 32 bit mode (i386, x86-64 -m32 and -mx32, AIX 32 bit). I have opened PR 103759. Thanks, David

Re: [PATCH] Add VxWorks fixincludes hack, kernel math.h FP_ constants

2021-12-17 Thread Olivier Hainque via Gcc-patches
Hi again Rasmus, > On 17 Dec 2021, at 14:03, Rasmus Villemoes wrote: > > On 17/12/2021 13.10, Olivier Hainque wrote: >> Hello, >> >> The attached patch adds a fixincludes add for VxWorks >> to add missing FP_ constant definition to math.h, intended >> for old versions of the kernel math.h

Re: [PATCH] config.gcc: Obsolete m32c-rtems target

2021-12-17 Thread Eric Gallager via Gcc-patches
On Fri, Dec 17, 2021 at 11:11 AM Joel Sherrill wrote: > > --- > gcc/config.gcc | 1 + > 1 file changed, 1 insertion(+) > > diff --git a/gcc/config.gcc b/gcc/config.gcc > index c8824367b13..fe93a72a16c 100644 > --- a/gcc/config.gcc > +++ b/gcc/config.gcc > @@ -252,6 +252,7 @@ case ${target} in >

Re: [PATCH 2/2] rs6000: Update darn testcases

2021-12-17 Thread Bill Schmidt via Gcc-patches
Hi! On 12/17/21 11:36 AM, Segher Boessenkool wrote: > Make the darn testcases work (and be tested) in 32-bit mode as well. > They used to ICE, but they no longer do. > > > 2021-12-17 Segher Boessenkool > > gcc/testsuite/ > PR target/103624 > * gcc.target/powerpc/darn-0.c: Remove

Re: [PATCH 1/2] rs6000: Redo darn (PR103624)

2021-12-17 Thread Bill Schmidt via Gcc-patches
Hi! On 12/17/21 11:36 AM, Segher Boessenkool wrote: > The builtins now all return "long". The patterns have :GPR as the > output mode, so they can be 32-bit as well (the instruction makes sense > in 32 bit just fine). The builtins expand to the DImode version > normally, but to the SImode if

[PATCH v3] attribs: Fix wrong error with -Wno-attribute=A::b [PR103649]

2021-12-17 Thread Marek Polacek via Gcc-patches
On Thu, Dec 16, 2021 at 08:06:43PM -0500, Jason Merrill wrote: > On 12/16/21 19:52, Marek Polacek wrote: > > --- /dev/null > > +++ b/gcc/testsuite/c-c++-common/Wno-attributes-6.c > > @@ -0,0 +1,14 @@ > > +/* PR c/103649 */ > > +/* { dg-do compile { target { c || c++11 } } } */ > > +/* {

Re: [PATCH] Add -mdejagnu-cpu=power9 to dg-options for pr97142.c

2021-12-17 Thread Olivier Hainque via Gcc-patches
> On 17 Dec 2021, at 16:17, Segher Boessenkool > wrote: > >> In this instance, it's simple enough to be quoted directly: > > You may want to look into git send-email :-) Eh, indeed. >> --- a/gcc/testsuite/gcc.target/powerpc/pr97142.c >> +++ b/gcc/testsuite/gcc.target/powerpc/pr97142.c >>

[PATCH v2] c++: Improve diagnostic for class tmpl/class redecl [PR103749]

2021-12-17 Thread Marek Polacek via Gcc-patches
On Thu, Dec 16, 2021 at 08:13:01PM -0500, Jason Merrill wrote: > On 12/16/21 17:36, Marek Polacek wrote: > > + if (DECL_CLASS_TEMPLATE_P (decl) > > + && !template_header_p > > + && how == TAG_how::CURRENT_ONLY) > > +{ > > + error ("%qD was declared as template but no template

[PATCH 2/2] rs6000: Update darn testcases

2021-12-17 Thread Segher Boessenkool
Make the darn testcases work (and be tested) in 32-bit mode as well. They used to ICE, but they no longer do. 2021-12-17 Segher Boessenkool gcc/testsuite/ PR target/103624 * gcc.target/powerpc/darn-0.c: Remove target clause. * gcc.target/powerpc/darn-1.c: Remove target

[PATCH 1/2] rs6000: Redo darn (PR103624)

2021-12-17 Thread Segher Boessenkool
The builtins now all return "long". The patterns have :GPR as the output mode, so they can be 32-bit as well (the instruction makes sense in 32 bit just fine). The builtins expand to the DImode version normally, but to the SImode if {32bit} is true. 2021-12-17 Segher Boessenkool PR

Re: [PATCH] [1/2] arm: Implement cortex-M return signing address codegen

2021-12-17 Thread Andrea Corallo via Gcc-patches
Richard Earnshaw writes: > On 17/12/2021 15:52, Andrea Corallo wrote: >> Hi Richard, >> thanks for reviewing! Some comments inline. >> Richard Earnshaw writes: >>> On 05/11/2021 08:52, Andrea Corallo via Gcc-patches wrote: Hi all, this patch enables address return signature and

Re: [PATCH] coroutines, c++: Find lambda-ness from the ramp function [PR 96517].

2021-12-17 Thread Iain Sandoe
Hi Jason, > On 5 Nov 2021, at 21:53, Jason Merrill wrote: > > On 11/5/21 17:16, Iain Sandoe wrote: >> Hi Jason, >>> On 5 Nov 2021, at 20:50, Jason Merrill via Gcc-patches >>> wrote: >>> >>> On 11/5/21 12:01, Iain Sandoe wrote: +|| (DECL_DECLARES_FUNCTION_P (DECL_CONTEXT (decl))

Re: [PATCH] [1/2] arm: Implement cortex-M return signing address codegen

2021-12-17 Thread Richard Earnshaw via Gcc-patches
On 17/12/2021 15:52, Andrea Corallo wrote: Hi Richard, thanks for reviewing! Some comments inline. Richard Earnshaw writes: On 05/11/2021 08:52, Andrea Corallo via Gcc-patches wrote: Hi all, this patch enables address return signature and verification based on Armv8.1-M Pointer

Re: [2/3 PATCH]AArch64 use canonical ordering for complex mul, fma and fms

2021-12-17 Thread Richard Sandiford via Gcc-patches
Richard Sandiford writes: > Tamar Christina writes: >> Hi All, >> >> After the first patch in the series this updates the optabs to expect the >> canonical sequence. >> >> Bootstrapped Regtested on aarch64-none-linux-gnu and no issues. >> >> Ok for master? and backport along with the first

[COMMITTED] rs6000: Fix fake vec_promote overload

2021-12-17 Thread Bill Schmidt via Gcc-patches
Hi! rs6000-overload.def defines one instance of vec_promote so that it can be registered with the front end. Actual expansion of the vec_promote overload is done with special-case code in rs6000-c.c. During another cleanup, I observed that the fake instance has the wrong number of arguments.

Re: [vect] Re-analyze all modes for epilogues

2021-12-17 Thread Andre Vieira (lists) via Gcc-patches
Made the suggested changes. Regarding the name change to partial vectors, I agree in the name change since that is the terminology we are using in the loop_vinfo members too, but is there an actual difference between predication/masking and partial vectors that I am missing? OK for trunk?

Re: [2/3 PATCH]AArch64 use canonical ordering for complex mul, fma and fms

2021-12-17 Thread Richard Sandiford via Gcc-patches
Tamar Christina writes: > Hi All, > > After the first patch in the series this updates the optabs to expect the > canonical sequence. > > Bootstrapped Regtested on aarch64-none-linux-gnu and no issues. > > Ok for master? and backport along with the first patch? > > Thanks, > Tamar > >

Re: [1/3 PATCH]middle-end vect: Simplify and extend the complex numbers validation routines.

2021-12-17 Thread Richard Sandiford via Gcc-patches
Just a comment on the documentation: Tamar Christina via Gcc-patches writes: > diff --git a/gcc/doc/md.texi b/gcc/doc/md.texi > index > 9ec051e94e10cca9eec2773e1b8c01b74b6ea4db..60dc5b3ea6087c2824ad1467bc66e9cfebe9dcfc > 100644 > --- a/gcc/doc/md.texi > +++ b/gcc/doc/md.texi > @@ -6325,12

[PATCH] config.gcc: Obsolete m32c-rtems target

2021-12-17 Thread Joel Sherrill
--- gcc/config.gcc | 1 + 1 file changed, 1 insertion(+) diff --git a/gcc/config.gcc b/gcc/config.gcc index c8824367b13..fe93a72a16c 100644 --- a/gcc/config.gcc +++ b/gcc/config.gcc @@ -252,6 +252,7 @@ case ${target} in | cr16-*-*\ | hppa[12]*-*-hpux10*

Re: [PATCH] [1/2] arm: Implement cortex-M return signing address codegen

2021-12-17 Thread Andrea Corallo via Gcc-patches
Hi Richard, thanks for reviewing! Some comments inline. Richard Earnshaw writes: > On 05/11/2021 08:52, Andrea Corallo via Gcc-patches wrote: >> Hi all, >> this patch enables address return signature and verification based >> on >> Armv8.1-M Pointer Authentication [1]. >> To sign the return

[3/3 PATCH][AArch32] use canonical ordering for complex mul, fma and fms

2021-12-17 Thread Tamar Christina via Gcc-patches
Hi All, After the first patch in the series this updates the optabs to expect the canonical sequence. Bootstrapped Regtested on arm-none-linux-gnueabihf and no issues. Ok for master? and backport along with the first patch? Thanks, Tamar gcc/ChangeLog: PR tree-optimization/102819

[2/3 PATCH]AArch64 use canonical ordering for complex mul, fma and fms

2021-12-17 Thread Tamar Christina via Gcc-patches
Hi All, After the first patch in the series this updates the optabs to expect the canonical sequence. Bootstrapped Regtested on aarch64-none-linux-gnu and no issues. Ok for master? and backport along with the first patch? Thanks, Tamar gcc/ChangeLog: PR tree-optimization/102819

[1/3 PATCH]middle-end vect: Simplify and extend the complex numbers validation routines.

2021-12-17 Thread Tamar Christina via Gcc-patches
Hi All, This patch boosts the analysis for complex mul,fma and fms in order to ensure that it doesn't create an incorrect output. Essentially it adds an extra verification to check that the two nodes it's going to combine do the same operations on compatible values. The reason it needs to do

Re: [PATCH] Add -mdejagnu-cpu=power9 to dg-options for pr97142.c

2021-12-17 Thread Segher Boessenkool
On Fri, Dec 17, 2021 at 03:04:19PM +0100, Olivier Hainque wrote: > > On 17 Dec 2021, at 13:58, Segher Boessenkool > > wrote: > > Please use p7 instead of p9. > > Sure. > > > Also, you attached some binary, so I cannot reply to it easily. > > Ah, sorry. I did remember you told me this in the

Re: [PATCH] Add VxWorks fixincludes hack, open posix API

2021-12-17 Thread Olivier Hainque via Gcc-patches
> On 17 Dec 2021, at 15:33, Rasmus Villemoes wrote: > > On 17/12/2021 15.12, Olivier Hainque wrote: >> Hi Rasmus >> >>> On 17 Dec 2021, at 13:49, Rasmus Villemoes >>> wrote: >> >>> I'm not sure what to do. But this patch will definitely break our build >>> - primarily because we've done a

Re: [PATCH] Add VxWorks fixincludes hack, open posix API

2021-12-17 Thread Rasmus Villemoes via Gcc-patches
On 17/12/2021 15.12, Olivier Hainque wrote: > Hi Rasmus > >> On 17 Dec 2021, at 13:49, Rasmus Villemoes >> wrote: > >> I'm not sure what to do. But this patch will definitely break our build >> - primarily because we've done a private workaround. > > I don't think we can reasonably cope with

Re: [GCC-10 PATCH] aarch64: enable Ampere-1 CPU

2021-12-17 Thread Richard Sandiford via Gcc-patches
Philipp Tomsich writes: > This adds support and a basic tuning model for the Ampere Computing > "Ampere-1" CPU. > > The Ampere-1 implements the ARMv8.6 architecture in A64 mode and is > modelled as a 4-wide issue (as with all modern micro-architectures, > the chosen issue rate is a compromise

Re: [PATCH] middle-end/57245 - honor -frounding-math in real truncation

2021-12-17 Thread H.J. Lu via Gcc-patches
On Thu, Oct 28, 2021 at 2:23 AM Jakub Jelinek via Gcc-patches wrote: > > On Thu, Oct 28, 2021 at 10:11:36AM +0200, Richard Biener wrote: > > 2021-10-27 Richard Biener > > > > PR middle-end/57245 > > * fold-const.c (fold_convert_const_real_from_real): Honor > > -frounding-math

Re: [PATCH] Add VxWworks fixincludes hack, prevent #include_next yvals.h

2021-12-17 Thread Olivier Hainque via Gcc-patches
> On 17 Dec 2021, at 14:16, Rasmus Villemoes wrote: > > There's no yvals.h header in VxWorks 5.5, so I'm not sure I need to have > an opinion on this one. I wasn't sure about the situation on 5.5 but the fix just wont apply if there's no yvals.h around anyway. Cheers, Olivier

Re: [PATCH] Add VxWorks fixincludes hack, open posix API

2021-12-17 Thread Olivier Hainque via Gcc-patches
Hi Rasmus > On 17 Dec 2021, at 13:49, Rasmus Villemoes wrote: > I'm not sure what to do. But this patch will definitely break our build > - primarily because we've done a private workaround. I don't think we can reasonably cope with private changes to system headers. Can't you just undo your

Re: [PATCH] Add -mdejagnu-cpu=power9 to dg-options for pr97142.c

2021-12-17 Thread Olivier Hainque via Gcc-patches
> On 17 Dec 2021, at 13:58, Segher Boessenkool > wrote: > > Hi Olivier, > > Thanks for the patch! > > Please use p7 instead of p9. Sure. > Also, you attached some binary, so I cannot reply to it easily. Ah, sorry. I did remember you told me this in the past and renamed the file .diff to

Re: [pushed] Darwin, ppc: Additional change for r12-5974.

2021-12-17 Thread Bill Schmidt via Gcc-patches
Iain, thanks very much for fixing this, and I'm very sorry for the oversight! Bill On 12/17/21 3:46 AM, Iain Sandoe via Gcc-patches wrote: > This adds a missed change from r12-5974-g926d64906af. > The builin_decls array has been renamed to drop the trailing > _x that was used during the main

[PATCH][pushed] docs: Fix spelling issues in -fipa-strict-aliasing.

2021-12-17 Thread Martin Liška
Installed as obvious. gcc/ChangeLog: * doc/invoke.texi: Fix spelling issues. --- gcc/doc/invoke.texi | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/gcc/doc/invoke.texi b/gcc/doc/invoke.texi index 37836a7d614..8f69e53e68e 100644 --- a/gcc/doc/invoke.texi +++

Re: [PATCH] Add VxWworks fixincludes hack, prevent #include_next yvals.h

2021-12-17 Thread Rasmus Villemoes via Gcc-patches
On 17/12/2021 13.14, Olivier Hainque wrote: > Hello, > > yvals.h on VxWorks expects the toolchain to provide its own > version of the header, which we don't do. > > The attached patch adds a fixincludes hack to arrange to fallback > on the common system definitions instead. > > We were able to

Re: [PATCH] Add VxWorks fixincludes hack, kernel math.h FP_ constants

2021-12-17 Thread Rasmus Villemoes via Gcc-patches
On 17/12/2021 13.10, Olivier Hainque wrote: > Hello, > > The attached patch adds a fixincludes add for VxWorks > to add missing FP_ constant definition to math.h, intended > for old versions of the kernel math.h header. Don't you also need to add an fpclassify() macro? There's a checking for

Re: [PATCH] Add -mdejagnu-cpu=power9 to dg-options for pr97142.c

2021-12-17 Thread Segher Boessenkool
Hi Olivier, On Fri, Dec 17, 2021 at 12:43:32PM +0100, Olivier Hainque wrote: > gcc.target/powerpc/pr97142.c scans the output assembly > for specific instructions which our toolchain configured > to default to -mcpu=604 doesn't produce. > > The PR refers to a power9 configuration for the original

Re: [PATCH] Add VxWorks fixincludes hack, open posix API

2021-12-17 Thread Rasmus Villemoes via Gcc-patches
On 17/12/2021 13.01, Olivier Hainque wrote: > Hello, > > The attach patch adds a fixincludes "hack" for VxWorks > to expose a more flexible (varargs) function prototype for 'open', > able to accept calls with 2 or 3 arguments as we observe > during libraries builds for powerpc vxworks 6.9. > >

Re: [AArch64] Enable generation of FRINTNZ instructions

2021-12-17 Thread Richard Sandiford via Gcc-patches
"Andre Vieira (lists) via Gcc-patches" writes: > On 22/11/2021 11:41, Richard Biener wrote: >> >>> On 18/11/2021 11:05, Richard Biener wrote: This is a good shout and made me think about something I hadn't before... I thought I could handle the vector forms later, but the problem is if

[PATCH] Add VxWworks fixincludes hack, prevent #include_next yvals.h

2021-12-17 Thread Olivier Hainque via Gcc-patches
Hello, yvals.h on VxWorks expects the toolchain to provide its own version of the header, which we don't do. The attached patch adds a fixincludes hack to arrange to fallback on the common system definitions instead. We were able to get a successful complete build with c++ and libstdc++ after

[PATCH] Add VxWorks fixincludes hack, kernel math.h FP_ constants

2021-12-17 Thread Olivier Hainque via Gcc-patches
Hello, The attached patch adds a fixincludes add for VxWorks to add missing FP_ constant definition to math.h, intended for old versions of the kernel math.h header. As the other patches in the series, this helps libstdc++ build failures for old versions of VxWorks, 6.9 in particular for which

[PATCH] Add VxWorks fixincludes hack, open posix API

2021-12-17 Thread Olivier Hainque via Gcc-patches
Hello, The attach patch adds a fixincludes "hack" for VxWorks to expose a more flexible (varargs) function prototype for 'open', able to accept calls with 2 or 3 arguments as we observe during libraries builds for powerpc vxworks 6.9. We have been using this for a while in-house. I could still

[PATCH] Adjust VxWorks fixincludes hack for mkdir to work for C++

2021-12-17 Thread Olivier Hainque via Gcc-patches
Hello, The attached patch adjusts a very old fixincludes hack for VxWorks, to expose a varargs function prototype for "mkdir" instead of a varargs macro (!). The function version is more amenable to calls from C++ like std::mkdir(arg1, arg2). This helps libstdc++ build failures for old

[PATCH] Add -mdejagnu-cpu=power9 to dg-options for pr97142.c

2021-12-17 Thread Olivier Hainque via Gcc-patches
Hello, gcc.target/powerpc/pr97142.c scans the output assembly for specific instructions which our toolchain configured to default to -mcpu=604 doesn't produce. The PR refers to a power9 configuration for the original report, so the attached patch is a suggestion to add a -mdejagnu-cpu=power9 to

Re: [1/2] PR96463 - aarch64 specific changes

2021-12-17 Thread Richard Sandiford via Gcc-patches
Prathamesh Kulkarni writes: > Hi, > The patch folds: > lhs = svld1rq ({-1, -1, -1, ...}, [0]) > into: > lhs = vec_perm_expr > and expands above vec_perm_expr using aarch64_expand_sve_dupq. > > With patch, for following test: > #include > #include > > svint32_t > foo (int32x4_t x) > { > return

[PING] Fix size of static array in gcc.dg/vect/vect-simd-20.c

2021-12-17 Thread Olivier Hainque via Gcc-patches
Hello, Ping for https://gcc.gnu.org/pipermail/gcc-patches/2021-November/583222.html please ? Thanks in advance! With Kind Regards, Olivier > On 3 Nov 2021, at 15:54, Olivier Hainque wrote: > > Hello, > > This fixes the definition of the "p" static array in > gcc.dg/vect/vect-simd-20.c to

Re: [2/2] PR96463 -- changes to type checking vec_perm_expr in middle end

2021-12-17 Thread Richard Sandiford via Gcc-patches
Prathamesh Kulkarni writes: > Hi, > The attached patch rearranges order of type-check for vec_perm_expr > and relaxes type checking for > lhs = vec_perm_expr > > when: > rhs1 == rhs2, > lhs is variable length vector, > rhs1 is fixed length vector, > TREE_TYPE (lhs) == TREE_TYPE (rhs1) > > I am

Re: [PATCH]middle-end slp: check that the operation we're combing is a boolean operation [PR103741]

2021-12-17 Thread Richard Sandiford via Gcc-patches
Tamar Christina writes: > Hi All, > > It seems I forgot to check that the operation we're combing when masking the > predicated together are actually predicates types. > > Without it we end up accidentally trying to combine a value and a mask. > > Bootstrapped Regtested on aarch64-none-linux-gnu

[pushed] libgcc, Darwin: Add missing build dependencies.

2021-12-17 Thread Iain Sandoe via Gcc-patches
There was a race condition where the link for the new shared EH library (only used on earlier Darwin) could fail because the new crts had not been copied to the gcc directory. This can cause a build failure (although currently only seen on powerpc-darwin). Fixed by adding specific dependency on

[2/2] PR96463 -- changes to type checking vec_perm_expr in middle end

2021-12-17 Thread Prathamesh Kulkarni via Gcc-patches
Hi, The attached patch rearranges order of type-check for vec_perm_expr and relaxes type checking for lhs = vec_perm_expr when: rhs1 == rhs2, lhs is variable length vector, rhs1 is fixed length vector, TREE_TYPE (lhs) == TREE_TYPE (rhs1) I am not sure tho if this check is correct ? My intent was

[PATCH]middle-end slp: check that the operation we're combing is a boolean operation [PR103741]

2021-12-17 Thread Tamar Christina via Gcc-patches
Hi All, It seems I forgot to check that the operation we're combing when masking the predicated together are actually predicates types. Without it we end up accidentally trying to combine a value and a mask. Bootstrapped Regtested on aarch64-none-linux-gnu and no issues. Ok for master?

[1/2] PR96463 - aarch64 specific changes

2021-12-17 Thread Prathamesh Kulkarni via Gcc-patches
Hi, The patch folds: lhs = svld1rq ({-1, -1, -1, ...}, [0]) into: lhs = vec_perm_expr and expands above vec_perm_expr using aarch64_expand_sve_dupq. With patch, for following test: #include #include svint32_t foo (int32x4_t x) { return svld1rq (svptrue_b8 (), [0]); } it generates following

Re: [gcc r12-6020] Fixed typo

2021-12-17 Thread Martin Liška
On 12/16/21 19:43, Joseph Myers wrote: On Thu, 16 Dec 2021, Martin Liška wrote: Hello. Oh, sorry, it was me and I forgot to send the patch to the mailing list. I've basically taken it as: https://github.com/gcc-mirror/gcc/pull/57. Should I revert the change? Updating both config.sub and

[pushed] Darwin, Driver: Avoid a link line for empty commands.

2021-12-17 Thread Iain Sandoe via Gcc-patches
We were pushing a spec value for weak_reference_mismatches unconditionally which is not needed (the value was the default) and the side-effect of this was that we appeared to need to drive a link command; leading to unexpected diagnostics for cases where gcc was invoked with an empty command line.

[pushed] Darwin, ppc: Additional change for r12-5974.

2021-12-17 Thread Iain Sandoe via Gcc-patches
This adds a missed change from r12-5974-g926d64906af. The builin_decls array has been renamed to drop the trailing _x that was used during the main changes to the builtins. This fixes bootstrap for powerpc-darwin9, tested there, pushed to master, thanks, Iain Signed-off-by: Iain Sandoe

Re: [PATCH] i386: simplify cpu_feature handling

2021-12-17 Thread Martin Liška
On 12/16/21 21:58, Stefan Kneifel wrote: Am 15.12.21 um 10:57 schrieb Martin Liška: On 12/14/21 17:12, Jakub Jelinek wrote: I'd use INT_TYPE_SIZE - 1 instead of 31. Otherwise LGTM. Installed with that change, thanks. Moreover, I'm suggesting a simplification: The patch removes unneeded