public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: Kito Cheng <kito.cheng@gmail.com>
To: juzhe.zhong@rivai.ai
Cc: gcc-patches@gcc.gnu.org, palmer@dabbelt.com,
	jeffreyalaw@gmail.com,  rdapp.gcc@gmail.com
Subject: Re: [PATCH V3] RISC-V: Enable basic RVV auto-vectorization support.
Date: Fri, 5 May 2023 21:23:14 +0800	[thread overview]
Message-ID: <CA+yXCZDQyPuiLYjxejV_=W6-pj0XK_+PzeW5Ud996Q=9-kPU1g@mail.gmail.com> (raw)
In-Reply-To: <20230504054544.203366-1-juzhe.zhong@rivai.ai>

Just one minor comment otherwise LGTM.

> diff --git a/gcc/config/riscv/riscv.cc b/gcc/config/riscv/riscv.cc
> index 45a63cab9c9..1a35e02796d 100644
> --- a/gcc/config/riscv/riscv.cc
> +++ b/gcc/config/riscv/riscv.cc
> @@ -3793,6 +3793,14 @@ riscv_get_arg_info (struct riscv_arg_info *info, const CUMULATIVE_ARGS *cum,
>
>    if (named)
>      {
> +      /* TODO: Currently, it will produce ICE for --param
> +        riscv-autovec-preference=fixed-vlmax. So, we just return NULL_RTX here
> +        let GCC genearte loads/stores. Ideally, GCC should either report
> +        Warning message to tell user do not use RVV vector type in function
> +        arg, or GCC just support function arg calling convention for RVV
> +        directly.  */
> +      if (riscv_v_ext_mode_p (mode))
> +       return NULL_RTX;

Plz move this outside the if block become something like:

/* Your comment here.  */
if (riscv_v_ext_mode_p (mode))
  return NULL_RTX;
if (named)
  {


>        riscv_aggregate_field fields[2];
>        unsigned fregno = fpr_base + info->fpr_offset;
>        unsigned gregno = gpr_base + info->gpr_offset;

  reply	other threads:[~2023-05-05 13:23 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-05-04  5:45 juzhe.zhong
2023-05-05 13:23 ` Kito Cheng [this message]
2023-05-05 14:20 ` Robin Dapp

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='CA+yXCZDQyPuiLYjxejV_=W6-pj0XK_+PzeW5Ud996Q=9-kPU1g@mail.gmail.com' \
    --to=kito.cheng@gmail.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=jeffreyalaw@gmail.com \
    --cc=juzhe.zhong@rivai.ai \
    --cc=palmer@dabbelt.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).