From: Richard Sandiford <richard.sandiford@arm.com>
To: 钟居哲 <juzhe.zhong@rivai.ai>
Cc: gcc-patches <gcc-patches@gcc.gnu.org>, rguenther <rguenther@suse.de>
Subject: Re: [PATCH V12] VECT: Add decrement IV iteration loop control by variable amount support
Date: Wed, 24 May 2023 15:57:23 +0100 [thread overview]
Message-ID: <mpt8rddg4ks.fsf@arm.com> (raw)
In-Reply-To: <06E734ABE7B3641F+2023052422100415521814@rivai.ai> (=?utf-8?B?IumSn+WxheWTsiIncw==?= message of "Wed, 24 May 2023 22:10:04 +0800")
钟居哲 <juzhe.zhong@rivai.ai> writes:
>>> Both approaches are fine. I'm not against one or the other.
>
>>> What I didn't understand was why your patch only reuses existing IVs
>>> for max_nscalars_per_iter == 1. Was it to avoid having to do a
>>> multiplication (well, really a shift left) when moving from one
>>> rgroup to another? E.g. if one rgroup had;
>
>>> nscalars_per_iter == 2 && factor == 1
>
>>> and another had:
>
>>> nscalars_per_iter == 4 && factor == 1
>
>>> then we would need to mulitply by 2 when going from the first rgroup
>>> to the second.
>
>>> If so, avoiding a multiplication seems like a good reason for the choice
>>> you were making in the path. But we then need to check
>>> max_nscalars_per_iter == 1 for both the source rgroup and the
>>> destination rgroup, not just the destination. And I think the
>>> condition for “no multiplication needed” should be that:
>
> Oh, I didn't realize such complicated problem. Frankly, I didn't understand well
> rgroup. Sorry about that :).
>
> I just remember last time you said I need to handle multiple-rgroup
> not only for SLP but also non-SLP (which is vec_pack_trunk that I tested).
> Then I asked you when is non-SLP, you said max_nscalars_per_iter == 1.
Yeah, max_nscalars_per_iter == 1 is the right way of checking for non-SLP.
But I'm never been convinced that SLP vs. non-SLP is a meaningful
distinction for this patch (that is, the parts that don't use
SELECT_VL).
SLP vs. non-SLP matters for SELECT_VL. But the rgroup abstraction
should mean that SLP vs. non-SLP doesn't matter otherwise.
Thanks,
Richard
next prev parent reply other threads:[~2023-05-24 14:57 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-05-22 8:38 juzhe.zhong
2023-05-23 12:32 ` juzhe.zhong
2023-05-24 11:23 ` Richard Sandiford
2023-05-24 11:52 ` 钟居哲
2023-05-24 12:41 ` Richard Sandiford
2023-05-24 12:51 ` Richard Biener
2023-05-24 13:27 ` 钟居哲
2023-05-24 13:26 ` 钟居哲
2023-05-24 14:01 ` Richard Sandiford
2023-05-24 14:10 ` 钟居哲
2023-05-24 14:57 ` Richard Sandiford [this message]
2023-05-24 14:58 ` 钟居哲
[not found] ` <2023052422100415521814@rivai.ai>
2023-05-24 14:11 ` 钟居哲
2023-05-24 14:22 ` 钟居哲
2023-05-24 14:35 ` 钟居哲
2023-05-24 12:19 ` 钟居哲
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=mpt8rddg4ks.fsf@arm.com \
--to=richard.sandiford@arm.com \
--cc=gcc-patches@gcc.gnu.org \
--cc=juzhe.zhong@rivai.ai \
--cc=rguenther@suse.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).