Re: [ping][vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2023-04-28 Thread Andre Vieira (lists) via Gcc-patches
On 25/04/2023 13:30, Richard Biener wrote: On Mon, 24 Apr 2023, Richard Sandiford wrote: Richard Biener writes: On Thu, Apr 20, 2023 at 3:24?PM Andre Vieira (lists) via Gcc-patches wrote: Rebased all three patches and made some small changes to the second one: - removed sub and abd opta

Re: [ping][vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2023-04-25 Thread Richard Biener via Gcc-patches
On Mon, 24 Apr 2023, Richard Sandiford wrote: > Richard Biener writes: > > On Thu, Apr 20, 2023 at 3:24?PM Andre Vieira (lists) via Gcc-patches > > wrote: > >> > >> Rebased all three patches and made some small changes to the second one: > >> - removed sub and abd optabs from commutative_optab_p

Re: [ping][vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2023-04-25 Thread Andre Vieira (lists) via Gcc-patches
On 24/04/2023 12:57, Richard Biener wrote: On Thu, Apr 20, 2023 at 3:24 PM Andre Vieira (lists) via Gcc-patches wrote: Rebased all three patches and made some small changes to the second one: - removed sub and abd optabs from commutative_optab_p, I suspect this was a copy paste mistake, - r

Re: [ping][vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2023-04-24 Thread Richard Sandiford via Gcc-patches
Richard Biener writes: > On Thu, Apr 20, 2023 at 3:24 PM Andre Vieira (lists) via Gcc-patches > wrote: >> >> Rebased all three patches and made some small changes to the second one: >> - removed sub and abd optabs from commutative_optab_p, I suspect this >> was a copy paste mistake, >> - removed

Re: [ping][vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2023-04-24 Thread Richard Biener via Gcc-patches
On Thu, Apr 20, 2023 at 3:24 PM Andre Vieira (lists) via Gcc-patches wrote: > > Rebased all three patches and made some small changes to the second one: > - removed sub and abd optabs from commutative_optab_p, I suspect this > was a copy paste mistake, > - removed what I believe to be a superfluou

Re: [ping][vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2023-04-20 Thread Andre Vieira (lists) via Gcc-patches
Rebased all three patches and made some small changes to the second one: - removed sub and abd optabs from commutative_optab_p, I suspect this was a copy paste mistake, - removed what I believe to be a superfluous switch case in vectorizable conversion, the one that was here: + if (code.is_fn_

Re: [ping][vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2023-03-17 Thread Richard Biener via Gcc-patches
On Fri, 17 Mar 2023, Andre Vieira (lists) wrote: > Hi Richard, > > I'm only picking this up now. Just going through your earlier comments and > stuff and I noticed we didn't address the situation with the gimple::build. Do > you want me to add overloaded static member functions to cover all > gim

Re: [ping][vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2023-03-17 Thread Andre Vieira (lists) via Gcc-patches
Hi Richard, I'm only picking this up now. Just going through your earlier comments and stuff and I noticed we didn't address the situation with the gimple::build. Do you want me to add overloaded static member functions to cover all gimple_build_* functions, or just create one to replace vect

RE: [ping][vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2022-07-12 Thread Richard Biener via Gcc-patches
On Thu, 30 Jun 2022, Joel Hutton wrote: > > We can go with a private vect_gimple_build function until we sort out the > > API > > issue to unblock Tamar (I'll reply to Richards reply with further thoughts > > on > > this) > > > > Done. > > > > Similarly are you ok with the use of gimple_extra

RE: [ping][vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2022-06-30 Thread Joel Hutton via Gcc-patches
> We can go with a private vect_gimple_build function until we sort out the API > issue to unblock Tamar (I'll reply to Richards reply with further thoughts on > this) > Done. > > Similarly are you ok with the use of gimple_extract_op? I would lean > towards using it as it is cleaner, but I don'

Re: [ping][vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2022-06-13 Thread Richard Biener via Gcc-patches
On Tue, 7 Jun 2022, Richard Sandiford wrote: > Joel Hutton writes: > >> > Patches attached. They already incorporated the .cc rename, now > >> > rebased to be after the change to tree.h > >> > >> @@ -1412,8 +1412,7 @@ vect_recog_widen_op_pattern (vec_info *vinfo, > >>2, op

RE: [ping][vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2022-06-13 Thread Richard Biener via Gcc-patches
m: Richard Sandiford > > Sent: 07 June 2022 09:18 > > To: Joel Hutton > > Cc: Richard Biener ; gcc-patches@gcc.gnu.org > > Subject: Re: [ping][vect-patterns] Refactor widen_plus/widen_minus as > > internal_fns > > > > Joel Hutton writes: >

[ping][vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2022-06-09 Thread Joel Hutton via Gcc-patches
ocked on this patch. Joel > -Original Message- > From: Joel Hutton > Sent: 07 June 2022 10:02 > To: Richard Sandiford > Cc: Richard Biener ; gcc-patches@gcc.gnu.org > Subject: RE: [ping][vect-patterns] Refactor widen_plus/widen_minus as > internal_fns > > Thank

RE: [ping][vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2022-06-07 Thread Joel Hutton via Gcc-patches
g > Subject: Re: [ping][vect-patterns] Refactor widen_plus/widen_minus as > internal_fns > > Joel Hutton writes: > >> > Patches attached. They already incorporated the .cc rename, now > >> > rebased to be after the change to tree.h > >> > >&

Re: [ping][vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2022-06-07 Thread Richard Sandiford via Gcc-patches
Joel Hutton writes: >> > Patches attached. They already incorporated the .cc rename, now >> > rebased to be after the change to tree.h >> >> @@ -1412,8 +1412,7 @@ vect_recog_widen_op_pattern (vec_info *vinfo, >>2, oprnd, half_type, unprom, vectype); >> >>tree var = vect

RE: [ping][vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2022-06-06 Thread Joel Hutton via Gcc-patches
> > Patches attached. They already incorporated the .cc rename, now > > rebased to be after the change to tree.h > > @@ -1412,8 +1412,7 @@ vect_recog_widen_op_pattern (vec_info *vinfo, >2, oprnd, half_type, unprom, vectype); > >tree var = vect_recog_temp_ssa_var (itype

RE: [ping][vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2022-06-01 Thread Richard Biener via Gcc-patches
On Tue, 31 May 2022, Joel Hutton wrote: > > Can you post an updated patch (after the .cc renaming, and code_helper > > now already moved to tree.h). > > > > Thanks, > > Richard. > > Patches attached. They already incorporated the .cc rename, now rebased to be > after the change to tree.h @@ -1

RE: [ping][vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2022-05-31 Thread Tamar Christina via Gcc-patches
> Sent: Tuesday, May 31, 2022 11:08 AM > To: Richard Biener > Cc: Richard Sandiford ; gcc- > patc...@gcc.gnu.org > Subject: RE: [ping][vect-patterns] Refactor widen_plus/widen_minus as > internal_fns > > > Can you post an updated patch (after the .cc renaming, and c

RE: [ping][vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2022-05-31 Thread Joel Hutton via Gcc-patches
> Can you post an updated patch (after the .cc renaming, and code_helper > now already moved to tree.h). > > Thanks, > Richard. Patches attached. They already incorporated the .cc rename, now rebased to be after the change to tree.h Joel 0001-Refactor-to-allow-internal_fn-s.patch Description:

Re: [ping][vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2022-05-27 Thread Richard Biener via Gcc-patches
Joel > > > -Original Message- > > From: Joel Hutton > > Sent: 13 April 2022 16:53 > > To: Richard Sandiford > > Cc: Richard Biener ; gcc-patches@gcc.gnu.org > > Subject: [vect-patterns] Refactor widen_plus/widen_minus as internal_fns > > >

[ping][vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2022-05-25 Thread Joel Hutton via Gcc-patches
ct: [vect-patterns] Refactor widen_plus/widen_minus as internal_fns > > Hi all, > > These patches refactor the widening patterns in vect-patterns to use > internal_fn instead of tree_codes. > > Sorry about the delay, some changes to master made it a bit messier. > > B

[vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2022-04-13 Thread Joel Hutton via Gcc-patches
Hi all, These patches refactor the widening patterns in vect-patterns to use internal_fn instead of tree_codes. Sorry about the delay, some changes to master made it a bit messier. Bootstrapped and regression tested on aarch64. Joel > > diff --git a/gcc/tree-vect-patterns.c b/gcc/tree-vect-pa

Re: [vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2021-12-02 Thread Richard Sandiford via Gcc-patches
[Review for patch 1] Joel Hutton writes: > From e7b3017b7b5879204e9d61760a85cc84beeb4fe0 Mon Sep 17 00:00:00 2001 > From: Joel Hutton > Date: Wed, 25 Aug 2021 14:31:15 +0100 > Subject: [PATCH 1/3] [vect-patterns] Refactor to allow internal_fn's > > Hi all, > > This refactor allows widening patte

[ping][vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2021-11-25 Thread Joel Hutton via Gcc-patches
Just a quick ping to check this hasn't been forgotten. > -Original Message- > From: Joel Hutton > Sent: 12 November 2021 11:42 > To: Richard Biener > Cc: gcc-patches@gcc.gnu.org; Richard Sandiford > > Subject: RE: [vect-patterns] Refactor widen_plus/wid

RE: [vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2021-11-16 Thread Joel Hutton via Gcc-patches
gt; > Subject: RE: [vect-patterns] Refactor widen_plus/widen_minus as > internal_fns > > > please use #define INCLUDE_MAP before the system.h include instead. Done. > > Is it really necessary to build a new std::map for each optab lookup?! > > That looks quite ugly and

RE: [vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2021-11-12 Thread Joel Hutton via Gcc-patches
> please use #define INCLUDE_MAP before the system.h include instead. > Is it really necessary to build a new std::map for each optab lookup?! > That looks quite ugly and inefficient. We'd usually - if necessary at all - > build > a auto_vec > and .sort () and .bsearch () it. Ok, I'll rework this

Re: [vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2021-11-12 Thread Richard Biener via Gcc-patches
On Thu, 11 Nov 2021, Joel Hutton wrote: > Hi all, > > This refactor allows widening vect patterns (such as widen_plus/widen_minus) > to be represented as > either internal_fns or tree_codes and replaces the current > widen_plus/widen_minus with internal_fn versions. This refactor is split into

[vect-patterns] Refactor widen_plus/widen_minus as internal_fns

2021-11-11 Thread Joel Hutton via Gcc-patches
Hi all, This refactor allows widening vect patterns (such as widen_plus/widen_minus) to be represented as either internal_fns or tree_codes and replaces the current widen_plus/widen_minus with internal_fn versions. This refactor is split into 3 patches. Boostrapped and regression tested on aar