public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Jeff Law <jeffreyalaw@gmail.com>
To: Robin Dapp <rdapp.gcc@gmail.com>,
	gcc-patches <gcc-patches@gcc.gnu.org>,
	palmer <palmer@dabbelt.com>, Kito Cheng <kito.cheng@gmail.com>,
	"juzhe.zhong@rivai.ai" <juzhe.zhong@rivai.ai>,
	"Li, Pan2" <pan2.li@intel.com>
Subject: Re: [PATCH] RISC-V: Split VF iterators for Zvfh(min).
Date: Sat, 24 Jun 2023 10:38:30 -0600	[thread overview]
Message-ID: <cc6e4b77-2309-9cb2-7c0f-26f4120ba990@gmail.com> (raw)
In-Reply-To: <c6f011d2-6629-9acb-4a4e-f3f079678f12@gmail.com>



On 6/22/23 07:03, Robin Dapp wrote:
> Hi,
> 
> when working on FP widening/narrowing I realized the Zvfhmin handling
> is not ideal right now:  We use the "enabled" insn attribute to disable
> instructions not available with Zvfhmin (but only with Zvfh).
> 
> However, "enabled == 0" only disables insn alternatives, in our case all
> of them when the mode is a HFmode.  The insn itself remains available
> (e.g. for combine to match) and we end up with an insn without alternatives
> that reload cannot handle --> ICE.
> 
> The proper solution is to disable the instruction for the respective
> mode altogether.  This patch achieves this by splitting the VF as well
> as VWEXTF iterators into variants with TARGET_ZVFH and
> TARGET_VECTOR_ELEN_FP_16 (which is true when either TARGET_ZVFH or
> TARGET_ZVFHMIN are true).  Also, VWCONVERTI, VHF and VHF_LMUL1 need
> adjustments.
> 
> Regards
>   Robin
> 
> gcc/ChangeLog:
> 
> 	* config/riscv/autovec.md: VF_AUTO -> VF.
> 	* config/riscv/vector-iterators.md: Introduce VF_ZVFHMIN,
> 	VWEXTF_ZVFHMIN and use TARGET_ZVFH in VWCONVERTI, VHF and
> 	VHF_LMUL1.
> 	* config/riscv/vector.md: Use new iterators.
OK for the trunk.  Thanks for walking everyone through the issues here.

jeff

      parent reply	other threads:[~2023-06-24 16:38 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-06-22 13:03 Robin Dapp
2023-06-22 13:14 ` 钟居哲
2023-06-22 13:22   ` Robin Dapp
2023-06-22 13:25     ` 钟居哲
2023-06-22 13:32       ` Robin Dapp
2023-06-22 13:37         ` 钟居哲
2023-06-22 13:45           ` Li, Pan2
2023-06-22 14:30             ` Robin Dapp
2023-06-23 12:54               ` Li, Pan2
2023-06-23 19:27                 ` Jeff Law
2023-06-24 16:38 ` Jeff Law [this message]

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=cc6e4b77-2309-9cb2-7c0f-26f4120ba990@gmail.com \
    --to=jeffreyalaw@gmail.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=juzhe.zhong@rivai.ai \
    --cc=kito.cheng@gmail.com \
    --cc=palmer@dabbelt.com \
    --cc=pan2.li@intel.com \
    --cc=rdapp.gcc@gmail.com \
    /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).