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-patches@gcc.gnu.org>
Subject: Re: [PATCH] RISC-V: Add RVV registers in TARGET_CONDITION_AL_REGISTER_USAGE
Date: Thu, 1 Sep 2022 10:13:46 +0800	[thread overview]
Message-ID: <CA+yXCZCVdFAtz1AuxFw0rRxcfXPs7JwMyOBqKMRi5wpLWoD6Lw@mail.gmail.com> (raw)
In-Reply-To: <20220830062752.94761-1-juzhe.zhong@rivai.ai>

Committed with title fix, that should be TARGET_CONDITIONAL_REGISTER_USAGE

On Tue, Aug 30, 2022 at 2:28 PM <juzhe.zhong@rivai.ai> wrote:
>
> From: zhongjuzhe <juzhe.zhong@rivai.ai>
>
> gcc/ChangeLog:
>
>         * config/riscv/riscv.cc (riscv_conditional_register_usage): Add RVV registers.
>
> ---
>  gcc/config/riscv/riscv.cc | 9 +++++++++
>  1 file changed, 9 insertions(+)
>
> diff --git a/gcc/config/riscv/riscv.cc b/gcc/config/riscv/riscv.cc
> index 50de6a83cba..aebe3c0ab6b 100644
> --- a/gcc/config/riscv/riscv.cc
> +++ b/gcc/config/riscv/riscv.cc
> @@ -5439,6 +5439,15 @@ riscv_conditional_register_usage (void)
>        for (int regno = FP_REG_FIRST; regno <= FP_REG_LAST; regno++)
>         call_used_regs[regno] = 1;
>      }
> +
> +  if (!TARGET_VECTOR)
> +    {
> +      for (int regno = V_REG_FIRST; regno <= V_REG_LAST; regno++)
> +       fixed_regs[regno] = call_used_regs[regno] = 1;
> +
> +      fixed_regs[VTYPE_REGNUM] = call_used_regs[VTYPE_REGNUM] = 1;
> +      fixed_regs[VL_REGNUM] = call_used_regs[VL_REGNUM] = 1;
> +    }
>  }
>
>  /* Return a register priority for hard reg REGNO.  */
> --
> 2.36.1
>

      reply	other threads:[~2022-09-01  2:13 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-08-30  6:27 juzhe.zhong
2022-09-01  2:13 ` Kito Cheng [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=CA+yXCZCVdFAtz1AuxFw0rRxcfXPs7JwMyOBqKMRi5wpLWoD6Lw@mail.gmail.com \
    --to=kito.cheng@gmail.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=juzhe.zhong@rivai.ai \
    /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).