[PATCH] RISC-V: Move function place to make it looks better.

2022-10-10 Thread juzhe . zhong
From: Ju-Zhe Zhong gcc/ChangeLog: * config/riscv/riscv-vector-builtins.cc (rvv_switcher::rvv_switcher): Move down like ARM SVE. (rvv_switcher::~rvv_switcher): Move down like ARM SVE. (mangle_builtin_type): Move down to make it together with other global function.

[committed] [PR rtl-optimization/107182] Clear EDGE_CROSSING for jump->ret optimization

2022-10-10 Thread Jeff Law via Gcc-patches
When turning a jump to a return into a return, we need to clear EDGE_CROSSING of the fallthru edge to prevent a checking failure. I considered not applying the transformation when the edge has EDGE_CROSSING set, but it still seems like we ought to eliminate the unnecessary jump in that

Re: [PATCH][ICE] Fix for PR107193.

2022-10-10 Thread Jeff Law via Gcc-patches
On 10/10/22 18:36, Eugene Rozenfeld via Gcc-patches wrote: The bug was introduced in f30e9fd33e56a5a721346ea6140722e1b193db42. A variable (cur_locus_e) was incorrectly declared inside a loop. I also moved two other declarations (last and locus) down to make the code more clear. Tested on

Re: [PATCH][ICE] Fix for PR107193.

2022-10-10 Thread Jason Merrill via Gcc-patches
On 10/10/22 20:36, Eugene Rozenfeld wrote: The bug was introduced in f30e9fd33e56a5a721346ea6140722e1b193db42. A variable (cur_locus_e) was incorrectly declared inside a loop. I also moved two other declarations (last and locus) down to make the code more clear. Tested on x86_64-pc-linux-gnu.

[PATCH] libstdc++: Implement ranges::repeat_view from P2474R2

2022-10-10 Thread Patrick Palka via Gcc-patches
Tested on x86_64-pc-linux-gnu, does this look OK for trunk? (The paper also makes changes to views::take and views::drop, which will be implemented separately.) libstdc++-v3/ChangeLog: * include/std/ranges (repeat_view): Define. (repeat_view::_Iterator): Define.

Re: [PATCH] RISC-V: move struct vector_type_info from *.h to *.cc and change "user_name" into "name".

2022-10-10 Thread Kito Cheng via Gcc-patches
Committed, thanks :) On Mon, Oct 10, 2022 at 9:58 PM wrote: > > From: Ju-Zhe Zhong > > gcc/ChangeLog: > > * config/riscv/riscv-vector-builtins.cc (struct vector_type_info): > Move from config/riscv/riscv-vector-builtins.h. > (DEF_RVV_TYPE): Change USER_NAME to NAME. >

Re: [PATCH] RISC-V: Add missing vsetvl instruction type.

2022-10-10 Thread Kito Cheng via Gcc-patches
Committed, thanks :) On Mon, Oct 10, 2022 at 9:44 PM wrote: > > From: Ju-Zhe Zhong > > When implementing built-in framework, I notice I missed > vsetvl instruction type, so add it in a single patch > preparing for the following patches. > > gcc/ChangeLog: > > * config/riscv/riscv.md:

Re: [PATCH][ICE] Fix for PR107193.

2022-10-10 Thread H.J. Lu via Gcc-patches
On Mon, Oct 10, 2022 at 5:37 PM Eugene Rozenfeld wrote: > > The bug was introduced in f30e9fd33e56a5a721346ea6140722e1b193db42. > A variable (cur_locus_e) was incorrectly declared inside a loop. > I also moved two other declarations (last and locus) down to make > the code more clear. > > Tested

Re: [EXTERNAL] Re: [PATCH] Set discriminators for call stmts on the same line within the same basic block

2022-10-10 Thread Eugene Rozenfeld via Gcc-patches
I sent a patch that fixes a bug introduced by this patch: https://gcc.gnu.org/pipermail/gcc-patches/2022-October/603203.html What you are seeing could have been caused by the same bug since it involves an uninitialized variable. Eugene On Oct 10, 2022, at 5:54 PM, David Edelsohn wrote: 

Re: [PATCH] Set discriminators for call stmts on the same line within the same basic block

2022-10-10 Thread David Edelsohn via Gcc-patches
This patch causes a bootstrap comparison failure on AIX. It apparently does not cause a failure on PPC64BE Linux with the same ABI, so I suspect that the failure may be related to the way that function aliases are implemented on AIX, which doesn't have ELF symbol alias semantics. "This change

[PATCH][ICE] Fix for PR107193.

2022-10-10 Thread Eugene Rozenfeld via Gcc-patches
The bug was introduced in f30e9fd33e56a5a721346ea6140722e1b193db42. A variable (cur_locus_e) was incorrectly declared inside a loop. I also moved two other declarations (last and locus) down to make the code more clear. Tested on x86_64-pc-linux-gnu. gcc/ChangeLog: PR debug/107193

Re: [RFC] Add support for vectors in comparisons (like the C++ frontend does)

2022-10-10 Thread Joseph Myers
On Mon, 10 Oct 2022, Paul Iannetta via Gcc-patches wrote: > I have a patch to bring this feature to the C front-end as well, and > would like to hear your opinion on it, especially since it may affect > the feature-set of the objc front-end as well. > Currently, this is only a tentative patch

Go patch committed: Treat S("") as a string constant

2022-10-10 Thread Ian Lance Taylor via Gcc-patches
This Go frontend patch treats S("") as a string constant. The compiler neglected to notice that a conversion from a string constant to a string type was a valid string constant. I didn't add a test case because this only caused a compiler failure when compiling without optimization, which is not

Go patch committed: Only build thunk struct type when needed

2022-10-10 Thread Ian Lance Taylor via Gcc-patches
This patch to the Go frontend delays building the struct type for a go/defer thunk until it is needed. We were building it in the determine_types pass. Now, we delay until the simplify_thunk_statements pass. That ensures that we are consistent in determining whether an argument is constant.

Re: [PATCH] middle-end IFN_ASSUME support [PR106654]

2022-10-10 Thread Jakub Jelinek via Gcc-patches
On Mon, Oct 10, 2022 at 05:09:29PM -0400, Jason Merrill wrote: > On 10/10/22 04:54, Jakub Jelinek via Gcc-patches wrote: > > My earlier patches gimplify the simplest non-side-effects assumptions > > into if (cond) ; else __builtin_unreachable (); and throw the rest > > on the floor. > > The

Re: [PATCH] middle-end IFN_ASSUME support [PR106654]

2022-10-10 Thread Jason Merrill via Gcc-patches
On 10/10/22 04:54, Jakub Jelinek via Gcc-patches wrote: Hi! My earlier patches gimplify the simplest non-side-effects assumptions into if (cond) ; else __builtin_unreachable (); and throw the rest on the floor. The following patch attempts to do something with the rest too. For -O0, it actually

Re: [PATCH RESEND 1/1] p1689r5: initial support

2022-10-10 Thread Jason Merrill via Gcc-patches
On 10/4/22 11:12, Ben Boeckel wrote: This patch implements support for [P1689R5][] to communicate to a build system the C++20 module dependencies to build systems so that they may build `.gcm` files in the proper order. Thanks! Support is communicated through the following three new flags:

Re: [PATCH] c++ modules: lazy loading from within template [PR99377]

2022-10-10 Thread Nathan Sidwell via Gcc-patches
On 10/4/22 13:36, Patrick Palka wrote: Here when lazily loading the binding for f at parse time from the template g, processing_template_decl is set and thus the call to note_vague_linkage_fn from module_state::read_cluster has no effect, and we never push f onto deferred_fns and end up never

Re: [committed] libstdc++: std::make_signed_t should be ill-formed

2022-10-10 Thread Jonathan Wakely via Gcc-patches
On Mon, 10 Oct 2022 at 15:05, Jonathan Wakely wrote: > > On Mon, 10 Oct 2022 at 14:50, Tim Song via Libstdc++ > wrote: > > > > On Mon, Oct 10, 2022 at 8:09 AM Patrick Palka via Libstdc++ > > wrote: > > > > > > On Mon, 10 Oct 2022, Jonathan Wakely via Libstdc++ wrote: > > > > > > > Tested

Re: [PATCH RESEND 0/1] RFC: P1689R5 support

2022-10-10 Thread Jason Merrill via Gcc-patches
On 10/4/22 11:11, Ben Boeckel wrote: This patch adds initial support for ISO C++'s [P1689R5][], a format for describing C++ module requirements and provisions based on the source code. This is required because compiling C++ with modules is not embarrassingly parallel and need to be ordered to

Re: [PATCH] c++: Remove maybe-rvalue OR in implicit move

2022-10-10 Thread Jason Merrill via Gcc-patches
On 9/28/22 17:26, Marek Polacek wrote: This patch removes the two-stage overload resolution when performing implicit move, whereby the compiler does two separate overload resolutions: one treating the operand as an rvalue, and then (if that resolution fails) another one treating the operand as

Re: [patch] configury support for VxWorks shared libraries

2022-10-10 Thread Jonathan Wakely via Gcc-patches
On Mon, 10 Oct 2022 at 19:06, Olivier Hainque via Libstdc++ wrote: > > Sorry, I forgot to cc libstdc++ on > > https://gcc.gnu.org/pipermail/gcc-patches/2022-October/603182.html > > which includes a regen of libstdc++-v3/configure after an update > libtool.m4. OK, thanks for the heads up.

Re: [PATCH v5] c-family: ICE with [[gnu::nocf_check]] [PR106937]

2022-10-10 Thread Jason Merrill via Gcc-patches
On 10/10/22 15:18, Marek Polacek wrote: On Mon, Oct 10, 2022 at 10:49:34AM -0400, Jason Merrill wrote: On 10/7/22 18:16, Marek Polacek wrote: On Fri, Oct 07, 2022 at 05:56:18PM -0400, Jason Merrill wrote: On 10/7/22 17:08, Marek Polacek wrote: On Fri, Oct 07, 2022 at 12:17:34PM -0400, Jason

Re: [PATCH] c++: parser - Support for target address spaces in C++

2022-10-10 Thread Jason Merrill via Gcc-patches
On 10/9/22 12:12, Paul Iannetta wrote: Hi, On Thu, Oct 06, 2022 at 01:34:40PM -0400, Jason Merrill wrote: [snip] Hmm? We mangle __restrict: void f(int *__restrict *p) { } // _Z1fPrPi Indeed, I have overlooked that point. Thank you for pointing it out. but cv-qualifiers (including

Re: [PATCH] c++: Remove maybe-rvalue OR in implicit move

2022-10-10 Thread Marek Polacek via Gcc-patches
Ping. On Wed, Sep 28, 2022 at 05:26:34PM -0400, Marek Polacek via Gcc-patches wrote: > This patch removes the two-stage overload resolution when performing > implicit move, whereby the compiler does two separate overload resolutions: > one treating the operand as an rvalue, and then (if that

[PATCH v5] c-family: ICE with [[gnu::nocf_check]] [PR106937]

2022-10-10 Thread Marek Polacek via Gcc-patches
On Mon, Oct 10, 2022 at 10:49:34AM -0400, Jason Merrill wrote: > On 10/7/22 18:16, Marek Polacek wrote: > > On Fri, Oct 07, 2022 at 05:56:18PM -0400, Jason Merrill wrote: > > > On 10/7/22 17:08, Marek Polacek wrote: > > > > On Fri, Oct 07, 2022 at 12:17:34PM -0400, Jason Merrill wrote: > > > > >

Re: [PATCH v2 0/9] fortran: clobber fixes [PR41453]

2022-10-10 Thread Mikael Morin
Le 23/09/2022 à 09:54, Mikael Morin a écrit : Le 22/09/2022 à 22:42, Harald Anlauf via Fortran a écrit : This LGTM.  It also fixes a regression introduced with r9-3030 :-) If you think that this set (1-3) is backportable, feel free to do so. Yes, 2 and 3 are worth backporting, I will see how

[PATCH] Avoid calling tracer.trailer() twice.

2022-10-10 Thread Aldy Hernandez via Gcc-patches
[Andrew, you OK with this? I can't tell whether the trailer() call was actually needed.] logical_combine is calling tracer.trailer() one too many times causing the second trailer() call to subtract a 0 indent by 2, yielding an indent of SOMETHING_REALLY_BIG :). You'd be surprised how many tools

Ping: [PATCH] elf: ELF toolchain --without-{headers, newlib} should provide stdint.h

2022-10-10 Thread Arsen Arsenović via Gcc-patches
Evening, Ping on this patch, it should fix some configuration issues we get on ELF targets (especially in libstdc++). https://gcc.gnu.org/pipermail/gcc-patches/2022-October/602751.html Thanks, -- Arsen Arsenović signature.asc Description: This is a digitally signed message part.

Re: [patch] configury support for VxWorks shared libraries

2022-10-10 Thread Olivier Hainque via Gcc-patches
Sorry, I forgot to cc libstdc++ on https://gcc.gnu.org/pipermail/gcc-patches/2022-October/603182.html which includes a regen of libstdc++-v3/configure after an update libtool.m4. Not committed yet. With Kind Regards, Olivier > On 10 Oct 2022, at 19:05, Olivier Hainque wrote: > > Hello,

Re: [PATCH v2] LoongArch: Libvtv add loongarch support.

2022-10-10 Thread Caroline Tice via Gcc-patches
On Tue, Sep 27, 2022 at 3:04 AM Lulu Cheng wrote: > > v1 - > v2: > > 1. When the macro __loongarch_lp64 is defined, the VTV_PAGE_SIZE is set to > 64K. > 2. In the vtv_malloc.cc file __vtv_malloc_init function, it does not check >whether VTV_PAGE_SIZE is equal to the system page size, if the

[patch] configury support for VxWorks shared libraries

2022-10-10 Thread Olivier Hainque via Gcc-patches
Hello, This change introduces configury infrastructure allowing the production of shared libraries for VxWorks, amenable to use with non-static rtps (linked with "-non-static"). The ability to produce PIC code is not a given on all VxWorks configurations, so activating this has to be explicitly

Re: Adding a new thread model to GCC

2022-10-10 Thread LIU Hao via Gcc-patches
在 2022-10-04 20:44, LIU Hao 写道: Attached are revised patches. These are exported from trunk. Revised further. The patch for libgfortran has been committed to trunk today, so I include only the other two. * In the second patch, a space character has been inserted after `(int)` for

Re: [PATCH] Add new target hook: simplify_modecc_const.

2022-10-10 Thread H.J. Lu via Gcc-patches
On Thu, Jul 28, 2022 at 5:40 AM Richard Sandiford via Gcc-patches wrote: > > Seems this thread has become a bit heated, so I'll try to proceed > with caution :-) > > In the below, I'll use "X-mode const_int" to mean "a const_int that > is known from context to represent an X-mode value". Of

Re: [RFC] Add support for vectors in comparisons (like the C++ frontend does)

2022-10-10 Thread Iain Sandoe
Hi Paul, > On 10 Oct 2022, at 16:20, Paul Iannetta wrote: > On Mon, Oct 10, 2022 at 03:37:24PM +0100, Iain Sandoe wrote: >> Hi Paul, >> >> Not a review of the patch - but a couple of observations. >> >>> On 10 Oct 2022, at 15:11, Paul Iannetta via Gcc-patches >>> wrote: >> >>> I am trying

[PATCH] 15/19 modula2 front end: cc1gm2 additional non modula2 source files

2022-10-10 Thread Gaius Mulley via Gcc-patches
This patch set contains the .h, .cc and .flex files found in gcc/m2. The files are tightly coupled with the gimple interface (see 04-gimple-interface) and built using the rules found in (01-03-make). --8<--8<--8<--8<--8<--8< diff -ruw

[PATCH] 16/19 modula2 front end: bootstrap and documentation tools

2022-10-10 Thread Gaius Mulley via Gcc-patches
This patch set contains the bootstrap linking tool as well as python3 scripts to automatically generate texi libraries section of the gm2 documentation. In the fullness of time this will be changed to emit sphinx. --8<--8<--8<--8<--8<--8<

[PATCH] 11/19 modula2 front end: gimple interface *[a-d]*.cc

2022-10-10 Thread Gaius Mulley via Gcc-patches
This patchset contains the gimple interface. --8<--8<--8<--8<--8<--8< diff -ruw /dev/null gcc-git-devel-modula2/gcc/m2/gm2-gcc/m2assert.cc --- /dev/null 2022-08-24 16:22:16.88870 +0100 +++ gcc-git-devel-modula2/gcc/m2/gm2-gcc/m2assert.cc

[PATCH] 4/19 modula2 front end: libgm2/libm2pim contents

2022-10-10 Thread Gaius Mulley via Gcc-patches
This patch set consists of the makefiles, autoconf sources necessary to build the various libgm2/libm2pim libraries. The c/c++/h files are included in the patch set. The modula-2 sources are found in gcc/m2/ as they are used by the compiler.

[PATCH] 5/19 modula2 front end: libgm2/libm2iso contents

2022-10-10 Thread Gaius Mulley via Gcc-patches
This patch set consists of the makefiles, autoconf sources necessary to build the various libgm2/libm2iso libraries. The c/c++/h files are also included in the patch set. The modula-2 sources are found in gcc/m2. --8<--8<--8<--8<--8<--8<

[PATCH] 17/19 modula2 front end: dejagnu expect library scripts

2022-10-10 Thread Gaius Mulley via Gcc-patches
Here are the dejagnu expect library scripts for the gm2 testsuite. --8<--8<--8<--8<--8<--8< diff -ruw /dev/null gcc-git-devel-modula2/gcc/testsuite/lib/gm2.exp --- /dev/null 2022-08-24 16:22:16.88870 +0100 +++

[PATCH] 13/19 modula2 front end: gimple interface *[g-m]*.cc

2022-10-10 Thread Gaius Mulley via Gcc-patches
This patchset contains the gimple interface. --8<--8<--8<--8<--8<--8< diff -ruw /dev/null gcc-git-devel-modula2/gcc/m2/gm2-gcc/m2linemap.cc --- /dev/null 2022-08-24 16:22:16.88870 +0100 +++

[PATCH] 9/19 modula2 front end: plugin source files

2022-10-10 Thread Gaius Mulley via Gcc-patches
This patchset contains the modula2 plugin which detects some runtime errors at compiletime. --8<--8<--8<--8<--8<--8< diff -ruw /dev/null gcc-git-devel-modula2/gcc/m2/plugin/m2rte.cc --- /dev/null 2022-08-24 16:22:16.88870 +0100 +++

[PATCH] 14/19 modula2 front end: gimple interface remainder

2022-10-10 Thread Gaius Mulley via Gcc-patches
This patchset contains the gimple interface. --8<--8<--8<--8<--8<--8< diff -ruw /dev/null gcc-git-devel-modula2/gcc/m2/gm2-gcc/init.cc --- /dev/null 2022-08-24 16:22:16.88870 +0100 +++ gcc-git-devel-modula2/gcc/m2/gm2-gcc/init.cc

[PATCH] 1/19 modula2 front end: changes outside gcc/m2, libgm2 and gcc/testsuite.

2022-10-10 Thread Gaius Mulley via Gcc-patches
This patch set contains the non machine generated changes found in / for example the language die and documentation changes. It also contains the changes to the top level build Makefile infastructure and the install.texi sourcebuild.texi documentation.

[PATCH] 8/19 modula2 front end: libgm2 contents

2022-10-10 Thread Gaius Mulley via Gcc-patches
This patch set consists of the libgm2 makefile, autoconf sources necessary to build the libm2pim, libm2iso, libm2min, libm2cor and libm2log. --8<--8<--8<--8<--8<--8< diff -ruw /dev/null gcc-git-devel-modula2/libgm2/ChangeLog --- /dev/null

[PATCH] 2/19 modula2 front end: Make-lang.in

2022-10-10 Thread Gaius Mulley via Gcc-patches
The makefile fragment for modula2 which builds the gm2 driver and cc1gm2. --8<--8<--8<--8<--8<--8< diff -ruw /dev/null gcc-git-devel-modula2/gcc/m2/Make-lang.in --- /dev/null 2022-08-24 16:22:16.88870 +0100 +++

[PATCH] 6/19 modula2 front end: libgm2/libm2min contents

2022-10-10 Thread Gaius Mulley via Gcc-patches
This patch set consists of the makefiles, autoconf and a few C sources to build the libgm2/libm2min libraries. --8<--8<--8<--8<--8<--8< diff -ruw /dev/null gcc-git-devel-modula2/libgm2/libm2min/Makefile.am --- /dev/null 2022-08-24

[PATCH] 3/19 modula2 front end: gm2 driver files.

2022-10-10 Thread Gaius Mulley via Gcc-patches
This patchset contains the c++, h and option related files necessary to build the driver program gm2. The patch also consists of the autoconf/configure related build infastructure sources found in gcc/m2. The reviewer might need to look at the 01-02-make patchset. The gm2 driver is heavily

[PATCH] 7/19 modula2 front end: libgm2/libm2log contents

2022-10-10 Thread Gaius Mulley via Gcc-patches
This patch set consists of the makefiles, autoconf sources necessary to build the various libgm2 libraries. The c/c++/h files are included in the patch set. The modula-2 sources are found in gcc/m2. --8<--8<--8<--8<--8<--8< diff -ruw

[PATCH] 0/19 modula-2 front end patches overview

2022-10-10 Thread Gaius Mulley via Gcc-patches
Here are the latest modula-2 front end patches for review. The status of the patches and their contents are also contained at: https://splendidisolation.ddns.net/public/modula2/patchsummary.html where they are also broken down into topic groups. In summary the high level changes from the

Re: [PATCH][GCC 12] arm: Fix constant immediates predicates and constraints for some MVE builtins

2022-10-10 Thread Christophe Lyon via Gcc-patches
ping^2 ? On 10/5/22 16:55, Christophe Lyon via Gcc-patches wrote: ping? On 9/12/22 10:13, Christophe Lyon via Gcc-patches wrote: Hi! On 9/9/22 11:33, Christophe Lyon wrote: This is a backport from trunk to gcc-12. Several MVE builtins incorrectly use the same predicate/constraint pair

Re: [RFC] Add support for vectors in comparisons (like the C++ frontend does)

2022-10-10 Thread Paul Iannetta via Gcc-patches
Hi Ian, Observations are also very welcomed, thank you! On Mon, Oct 10, 2022 at 03:37:24PM +0100, Iain Sandoe wrote: > Hi Paul, > > Not a review of the patch - but a couple of observations. > > > On 10 Oct 2022, at 15:11, Paul Iannetta via Gcc-patches > > wrote: > > > I am trying to bridge

Re: [PATCH] libstdc++: Allow emergency EH alloc pool size to be tuned [PR68606]

2022-10-10 Thread Jonathan Wakely via Gcc-patches
On Mon, 10 Oct 2022 at 12:17, Jonathan Wakely wrote: > > On Mon, 10 Oct 2022 at 07:18, Richard Biener > wrote: > > > > On Fri, Oct 7, 2022 at 5:55 PM Jonathan Wakely via Gcc-patches > > wrote: > > > > > > This needs a little more documentation (see the TODO in the manual), > > > rather than

Re: [PATCH v4] c-family: ICE with [[gnu::nocf_check]] [PR106937]

2022-10-10 Thread Jason Merrill via Gcc-patches
On 10/7/22 18:16, Marek Polacek wrote: On Fri, Oct 07, 2022 at 05:56:18PM -0400, Jason Merrill wrote: On 10/7/22 17:08, Marek Polacek wrote: On Fri, Oct 07, 2022 at 12:17:34PM -0400, Jason Merrill wrote: On 10/6/22 22:12, Marek Polacek wrote: On Thu, Oct 06, 2022 at 05:42:41PM -0400, Jason

Re: [RFC] Add support for vectors in comparisons (like the C++ frontend does)

2022-10-10 Thread Iain Sandoe
Hi Paul, Not a review of the patch - but a couple of observations. > On 10 Oct 2022, at 15:11, Paul Iannetta via Gcc-patches > wrote: > I am trying to bridge the gap between the extensions supported by the C > and C++ front-ends. When it comes to vector extensions, C++ supports > vectors in

Re: Restore default 'sorry' 'TARGET_ASM_CONSTRUCTOR', 'TARGET_ASM_DESTRUCTOR' (was: [PATCH 1/3] STABS: remove -gstabs and -gxcoff functionality)

2022-10-10 Thread Tom de Vries via Gcc-patches
On 10/10/22 16:19, Thomas Schwinge wrote: With that, OK to push? FWIW, nvptx change looks in the obvious category to me. Thanks, - Tom

Restore default 'sorry' 'TARGET_ASM_CONSTRUCTOR', 'TARGET_ASM_DESTRUCTOR' (was: [PATCH 1/3] STABS: remove -gstabs and -gxcoff functionality)

2022-10-10 Thread Thomas Schwinge
Hi! On 2022-09-01T12:05:23+0200, Martin Liška wrote: > Patch can bootstrap on x86_64-linux-gnu and survives regression tests. > > I've also built all cross compilers. First: thanks for that: clean up plus "built all cross compilers"! But yet, I've now tracked down an issue related to these

[RFC] Add support for vectors in comparisons (like the C++ frontend does)

2022-10-10 Thread Paul Iannetta via Gcc-patches
Hi, I am trying to bridge the gap between the extensions supported by the C and C++ front-ends. When it comes to vector extensions, C++ supports vectors in comparisons and within conditional expressions whereas the C front-end does not. I have a patch to bring this feature to the C front-end as

Re: Re: [PATCH][RFT] Vectorization of first-order recurrences

2022-10-10 Thread 钟居哲
RVV also doesn't have a two-input permutation instructions (unlike ARM SVE has tbl instructions) and RVV needs about 4 instructions to handle this permutation, it still improve performance a lot. I think backend should handle this. Because this first-order recurrence loop vectorizer always

Re: [committed] libstdc++: std::make_signed_t should be ill-formed

2022-10-10 Thread Jonathan Wakely via Gcc-patches
On Mon, 10 Oct 2022 at 14:50, Tim Song via Libstdc++ wrote: > > On Mon, Oct 10, 2022 at 8:09 AM Patrick Palka via Libstdc++ > wrote: > > > > On Mon, 10 Oct 2022, Jonathan Wakely via Libstdc++ wrote: > > > > > Tested powerpc64le-linux. Pushed to trunk. > > > > > > -- >8 -- > > > > > > Currently

Re: [PATCH] RISC-V: move struct vector_type_info from *.h to *.cc.

2022-10-10 Thread 钟居哲
Ignore this patch plz. It's not finished. The correct && full patch is this: https://gcc.gnu.org/pipermail/gcc-patches/2022-October/603148.html Thanks. juzhe.zh...@rivai.ai From: juzhe.zhong Date: 2022-10-10 21:49 To: gcc-patches CC: kito.cheng; Ju-Zhe Zhong Subject: [PATCH] RISC-V: move

Re: [PATCH] rs6000: Rework option -mpowerpc64 handling [PR106680]

2022-10-10 Thread Segher Boessenkool
On Mon, Oct 10, 2022 at 10:15:58AM +0800, Kewen.Lin wrote: > on 2022/10/4 05:15, Segher Boessenkool wrote: > > Right. If If mpowerpc64 is enabled while OS_MISSING_POWERPC64, warn for > > that; > > Currently if option powerpc64 is enabled explicitly while > OS_MISSING_POWERPC64, > there is no

Re: [PATCH][RFT] Vectorization of first-order recurrences

2022-10-10 Thread Andrew Stubbs
On 10/10/2022 12:03, Richard Biener wrote: The following picks up the prototype by Ju-Zhe Zhong for vectorizing first order recurrences. That solves two TSVC missed optimization PRs. There's a new scalar cycle def kind, vect_first_order_recurrence and it's handling of the backedge value

[PATCH] RISC-V: move struct vector_type_info from *.h to *.cc and change "user_name" into "name".

2022-10-10 Thread juzhe . zhong
From: Ju-Zhe Zhong gcc/ChangeLog: * config/riscv/riscv-vector-builtins.cc (struct vector_type_info): Move from config/riscv/riscv-vector-builtins.h. (DEF_RVV_TYPE): Change USER_NAME to NAME. (register_vector_type): Change user_name to name. *

Re: [committed] libstdc++: std::make_signed_t should be ill-formed

2022-10-10 Thread Tim Song via Gcc-patches
On Mon, Oct 10, 2022 at 8:09 AM Patrick Palka via Libstdc++ wrote: > > On Mon, 10 Oct 2022, Jonathan Wakely via Libstdc++ wrote: > > > Tested powerpc64le-linux. Pushed to trunk. > > > > -- >8 -- > > > > Currently we only reject std::make_signed_t but not cv bool. > > Similarly for

[PATCH] RISC-V: move struct vector_type_info from *.h to *.cc.

2022-10-10 Thread juzhe . zhong
From: Ju-Zhe Zhong gcc/ChangeLog: * config/riscv/riscv-vector-builtins.cc (struct vector_type_info): Move from riscv-vector-builtins.h. * config/riscv/riscv-vector-builtins.h (struct vector_type_info): Move to riscv-vector-builtins.cc. ---

[PATCH] RISC-V: Add missing vsetvl instruction type.

2022-10-10 Thread juzhe . zhong
From: Ju-Zhe Zhong When implementing built-in framework, I notice I missed vsetvl instruction type, so add it in a single patch preparing for the following patches. gcc/ChangeLog: * config/riscv/riscv.md: Add vsetvl instruction type. --- gcc/config/riscv/riscv.md | 3 ++- 1 file

Re: [committed] RISC-V: Add riscv_vector.h wrapper in testsuite to prevent pull in stdint.h from C library

2022-10-10 Thread 钟居哲
LGTM. juzhe.zh...@rivai.ai From: Kito Cheng Date: 2022-10-10 21:14 To: gcc-patches; kito.cheng; christoph.muellner; juzhe.zhong CC: Kito Cheng Subject: [committed] RISC-V: Add riscv_vector.h wrapper in testsuite to prevent pull in stdint.h from C library For RISC-V linux/glibc toolchain will

Re: [committed] RISC-V: Adjust testcase for rvv/base/user-1.c

2022-10-10 Thread 钟居哲
LGTM. juzhe.zh...@rivai.ai From: Kito Cheng Date: 2022-10-10 21:14 To: gcc-patches; kito.cheng; christoph.muellner; juzhe.zhong CC: Kito Cheng Subject: [committed] RISC-V: Adjust testcase for rvv/base/user-1.c The -march option check isn't precise enough, -march=rv*v* also mach any zve

Re: [PATCH] Don't ICE running selftests if errors were raised [PR99723]

2022-10-10 Thread Andrea Corallo via Gcc-patches
Jeff Law via Gcc-patches writes: > On 9/27/22 09:12, Andrea Corallo via Gcc-patches wrote: >> Hi all >> >> this is to address PR 99723. >> >> In the PR GCC crashes as the initialization of common trees is not >> performed as no compilation is happening, this is because we raise an >> error

[committed] RISC-V: Add riscv_vector.h wrapper in testsuite to prevent pull in stdint.h from C library

2022-10-10 Thread Kito Cheng
For RISC-V linux/glibc toolchain will got header file not found when including stdint.h if multilib is not enabled, it because some header file will try to include gnu/stubs-.h from the system, however it only generated when multilib enabled. In order to prevent that, we introduce a wrapper for

[committed] RISC-V: Adjust testcase for rvv/base/user-1.c

2022-10-10 Thread Kito Cheng
The -march option check isn't precise enough, -march=rv*v* also mach any zve extensions. gcc/testsuite/ChangeLog: * gcc.target/riscv/rvv/base/user-1.c: Add dg-options and drop dg-skip-if. Reported-by: Christoph Müllner Tested-by: Christoph Müllner Reviewed-by: Ju-Zhe Zhong

[committed] RISC-V: Add newline to the end of file [NFC]

2022-10-10 Thread Kito Cheng
gcc/ChangeLog: * config/riscv/riscv-c.cc: Add newline to the end of file. gcc/testsuite/ChangeLog: * gcc.target/riscv/rvv/base/pragma-1.c: Add newline to the end of file. * gcc.target/riscv/rvv/base/pragma-2.c: Ditto. * gcc.target/riscv/rvv/base/pragma-3.c:

Re: [committed] libstdc++: std::make_signed_t should be ill-formed

2022-10-10 Thread Patrick Palka via Gcc-patches
On Mon, 10 Oct 2022, Jonathan Wakely via Libstdc++ wrote: > Tested powerpc64le-linux. Pushed to trunk. > > -- >8 -- > > Currently we only reject std::make_signed_t but not cv bool. > Similarly for std::make_unsigned_t. > > As well as making those ill-formed, this adds a requires-clause to the

[COMMITTED] Return non-legacy ranges in range.h.

2022-10-10 Thread Aldy Hernandez via Gcc-patches
int_range<1> is a legacy range (think anti ranges, legacy VRP, etc). There is a penalty for converting anything built with <1> to non-legacy. Since most of the uses of these functions are now ranger, we can save a miniscule amount of time by converting them to non-legacy. gcc/ChangeLog:

[COMMITTED] Add frange::maybe_isnan (bool sign).

2022-10-10 Thread Aldy Hernandez via Gcc-patches
It is useful to know if there's the possiblity of a NAN with a given sign. This is to complement maybe_isnan(void) which returns TRUE for a NAN of any sign. A follow-up patch implementing ABS will make use of this. gcc/ChangeLog: * value-range.h (frange::maybe_isnan): New. ---

[COMMITTED] x UNORD x should set NAN on the TRUE side (and !NAN on the FALSE side).

2022-10-10 Thread Aldy Hernandez via Gcc-patches
gcc/ChangeLog: * range-op-float.cc (foperator_unordered::op1_range): Set NAN when operands are equal and result is TRUE. --- gcc/range-op-float.cc | 10 +++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/gcc/range-op-float.cc b/gcc/range-op-float.cc index

[COMMITTED] The true side of x != x should set NAN.

2022-10-10 Thread Aldy Hernandez via Gcc-patches
gcc/ChangeLog: * range-op-float.cc (foperator_not_equal::op1_range): Set NAN on TRUE side for x != x. --- gcc/range-op-float.cc | 7 +-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/gcc/range-op-float.cc b/gcc/range-op-float.cc index 91833d3f855..5ffe38da53a

[COMMITTED] Make range-op-float entries public.

2022-10-10 Thread Aldy Hernandez via Gcc-patches
gcc/ChangeLog: * range-op-float.cc (class foperator_identity): Make members public. (class foperator_equal): Same. (class foperator_not_equal): Same. (class foperator_lt): Same. (class foperator_le): Same. (class foperator_gt): Same. (class

[committed] libstdc++: std::make_signed_t should be ill-formed

2022-10-10 Thread Jonathan Wakely via Gcc-patches
Tested powerpc64le-linux. Pushed to trunk. -- >8 -- Currently we only reject std::make_signed_t but not cv bool. Similarly for std::make_unsigned_t. As well as making those ill-formed, this adds a requires-clause to the make_signed and make_unsigned primary templates. This makes non-integral,

Re: [PATCH] libstdc++: Allow emergency EH alloc pool size to be tuned [PR68606]

2022-10-10 Thread Jonathan Wakely via Gcc-patches
On Mon, 10 Oct 2022 at 07:18, Richard Biener wrote: > > On Fri, Oct 7, 2022 at 5:55 PM Jonathan Wakely via Gcc-patches > wrote: > > > > This needs a little more documentation (see the TODO in the manual), > > rather than just the comments in the source. This isn't final, but I > > think it's the

Re: [PATCH][RFT] Vectorization of first-order recurrences

2022-10-10 Thread juzhe.zh...@rivai.ai
Thank you so much. I will apply this patch and test it in downstream RVV GCC (12.2.0) juzhe.zh...@rivai.ai From: Richard Biener Date: 2022-10-10 19:03 To: gcc-patches CC: richard.sandiford; ams; juzhe.zhong Subject: [PATCH][RFT] Vectorization of first-order recurrences The following picks up

[PATCH][RFT] Vectorization of first-order recurrences

2022-10-10 Thread Richard Biener via Gcc-patches
The following picks up the prototype by Ju-Zhe Zhong for vectorizing first order recurrences. That solves two TSVC missed optimization PRs. There's a new scalar cycle def kind, vect_first_order_recurrence and it's handling of the backedge value vectorization is complicated by the fact that the

Re: Extend fold_vec_perm to fold VEC_PERM_EXPR in VLA manner

2022-10-10 Thread Prathamesh Kulkarni via Gcc-patches
On Fri, 30 Sept 2022 at 21:38, Richard Sandiford wrote: > > Richard Sandiford via Gcc-patches writes: > > Prathamesh Kulkarni writes: > >> Sorry to ask a silly question but in which case shall we select 2nd vector > >> ? > >> For num_poly_int_coeffs == 2, > >> a1 /trunc n1 == (a1 + 0x) /

Re: [PATCH v4 4/4] OpenMP/OpenACC: Unordered/non-constant component offset struct mapping

2022-10-10 Thread Jakub Jelinek via Gcc-patches
On Sun, Oct 09, 2022 at 02:51:37PM -0700, Julian Brown wrote: > This patch adds support for non-constant component offsets in "map" > clauses for OpenMP (and the equivalants for OpenACC), which are not able > to be sorted into order at compile time. Normally struct accesses in > such clauses are

Require fgraphite effective target for pr107153.c test [PR107153]

2022-10-10 Thread Jakub Jelinek via Gcc-patches
Hi! On Fri, Oct 07, 2022 at 02:26:56PM +0200, Richard Biener via Gcc-patches wrote: > * gcc.dg/autopar/pr107153.c: New testcase. The test uses -floop-parallelize-all which emits a sorry when graphite isn't configured in. Tested on x86_64-linux and i686-linux, committed to trunk as

Re: [RFC] Add op1_range for __builtin_signbit.

2022-10-10 Thread Aldy Hernandez via Gcc-patches
I have committed this patch, as the __builtin_signbit range-op entry is correct. I'd still like clarification on the folding). Aldy On Thu, Oct 6, 2022 at 12:51 PM Aldy Hernandez wrote: > > This is the op1_range range-op entry for __builtin_signbit. It allows > us to wind back through a call

[PATCH] middle-end IFN_ASSUME support [PR106654]

2022-10-10 Thread Jakub Jelinek via Gcc-patches
Hi! My earlier patches gimplify the simplest non-side-effects assumptions into if (cond) ; else __builtin_unreachable (); and throw the rest on the floor. The following patch attempts to do something with the rest too. For -O0, it actually throws even the simplest assumptions on the floor, we

Re: [PATCH v2 00/10] Introduce strub: machine-independent stack scrubbing

2022-10-10 Thread Richard Biener via Gcc-patches
On Fri, Jul 29, 2022 at 8:36 AM Alexandre Oliva wrote: > > On Jul 29, 2022, Alexandre Oliva wrote: > > > This patch adds the strub attribute for function and variable types, > > command-line options, passes and adjustments to implement it, > > documentation, and tests. > > The entire patch, and

[patch] Tighten VXWORKS_LIBGCC_SPEC wrt libgcc_eh

2022-10-10 Thread Olivier Hainque via Gcc-patches
Hello, VxWorks has a custom definition of LIBGCC_SPEC to accommodate the variety of "modules" a user can build (dkm, sharedlib (-shared), static rtp, or rtp depending on shared libs (-non-static)) This change reworks that spec to better support configurations with shared libraries enabled (patch

[GCC][PATCH] arm: Add cde feature support for Cortex-M55 CPU.

2022-10-10 Thread Srinath Parvathaneni via Gcc-patches
Hi, This patch adds cde feature (optional) support for Cortex-M55 CPU, please refer [1] for more details. To use this feature we need to specify +cdecpN (e.g. -mcpu=cortex-m55+cdecp), where N is the coprocessor number 0 to 7. Bootstrapped for arm-none-linux-gnueabihf target, regression tested

[committed] openmp, fortran: Fix up IFN_ASSUME call

2022-10-10 Thread Jakub Jelinek via Gcc-patches
On Thu, Oct 06, 2022 at 06:15:52PM +0200, Tobias Burnus wrote: > Like as attached? – It did survive regtesting. Like in other spots in trans-openmp.cc that create a TARGET_EXPR, the slot has to be created with create_tmp_var_raw, because gfc_create_var adds the var to BLOCK_VARS and that ICEs

[committed 4/5] arc: Remove Rcq constraint.

2022-10-10 Thread Claudiu Zissulescu via Gcc-patches
gcc/ * config/arc/arc.cc (arc_check_short_reg_p): New function. (arc_address_cost): Replace satisfies_constraint_Rcq with the above new function. (arc_output_addsi): Likewise. (split_addsi): Likewise. (split_subsi): Likewise. *

[committed 3/5] arc: Remove Rcw constraint

2022-10-10 Thread Claudiu Zissulescu via Gcc-patches
gcc/Changelog: * config/arc/arc.md (smaxsi3): Remove Rcw. (sminsi3): Likewise. (addsi3_mixed): Likewise. (add_f_2): Likewise. (subsi3_insn): Likewise. (sub_f): Likewise. (sub_n): Likewise. (bset): Likewise. (bxor): Likewise.

[committed 5/5] arc: Remove obsolete mRcq and mRcw options.

2022-10-10 Thread Claudiu Zissulescu via Gcc-patches
gcc/ * common/config/arc/arc-common.cc (arc_option_optimization_table): Remove Rcq and Rcw options. * config/arc/arc.opt (mRcq): Ignore option, preserve it for backwards compatibility. (mRcw): Likewise. * doc/invoke.texi (mRcw, mRcq): Update

[committed 2/5] arc: Remove Rcr constraint

2022-10-10 Thread Claudiu Zissulescu via Gcc-patches
gcc/ChangeLog: * config/arc/arc.md(mulsi3_700): Remove Rcr. (mulsi3_highpart): Likewise. (umulsi3_highpart_i): Likewise. (umulsi3_highpart_int): Likewise. (macd): Likewise. (macdu): Likewise. * config/arc/constraints.md (Rcr): Remove it.

[committed 1/5] arc: Fix enter pattern instruction's offsets

2022-10-10 Thread Claudiu Zissulescu via Gcc-patches
The enter pattern instruction contains the necessary information for the dwarf machinery to generate the appropriate dwarf code. This patch is fixing the register offsets related to CFA, and adds a test. gcc/ * config/arc/arc.cc (arc_save_callee_enter): Use negative offsets.

Re: [PATCH] [x86] Fix unrecognizable insn of cvtss2si.

2022-10-10 Thread Uros Bizjak via Gcc-patches
On Mon, Oct 10, 2022 at 3:26 AM liuhongt via Gcc-patches wrote: > > Adjust lrintmn2 operand preidcates according to real instructions. > > Bootstrapped and regtested on x86_64-pc-linux-gnu{-m32,}. > Ok as an obvious fix? > > gcc/ChangeLog: > > PR target/107185 > *

Re: [PATCH] libstdc++: Allow emergency EH alloc pool size to be tuned [PR68606]

2022-10-10 Thread Richard Biener via Gcc-patches
On Fri, Oct 7, 2022 at 5:55 PM Jonathan Wakely via Gcc-patches wrote: > > This needs a little more documentation (see the TODO in the manual), > rather than just the comments in the source. This isn't final, but I > think it's the direction I want to take. > > -- >8 -- > > Implement a

  1   2   >