public inbox for gcc-cvs@sourceware.org help / color / mirror / Atom feed
From: Kito Cheng <kito@gcc.gnu.org> To: gcc-cvs@gcc.gnu.org Subject: [gcc r13-5678] RISC-V: Remove unnecessary register class. Date: Fri, 3 Feb 2023 07:15:50 +0000 (GMT) [thread overview] Message-ID: <20230203071550.89A733857352@sourceware.org> (raw) https://gcc.gnu.org/g:167b04b9b8a2becfd23b8ccf7f09016bbd013e12 commit r13-5678-g167b04b9b8a2becfd23b8ccf7f09016bbd013e12 Author: Monk Chiang <monk.chiang@sifive.com> Date: Fri Feb 3 12:58:51 2023 +0800 RISC-V: Remove unnecessary register class. Avoid VL_REGS, VTYPE_REGS join register allocation. gcc/ChangeLog: * config/riscv/riscv.h: Remove VL_REGS, VTYPE_REGS class. * config/riscv/riscv.cc: Ditto. Diff: --- gcc/config/riscv/riscv.cc | 8 +------- gcc/config/riscv/riscv.h | 8 +------- 2 files changed, 2 insertions(+), 14 deletions(-) diff --git a/gcc/config/riscv/riscv.cc b/gcc/config/riscv/riscv.cc index 209d9a53e7b..3b7804b7501 100644 --- a/gcc/config/riscv/riscv.cc +++ b/gcc/config/riscv/riscv.cc @@ -293,7 +293,7 @@ const enum reg_class riscv_regno_to_class[FIRST_PSEUDO_REGISTER] = { FP_REGS, FP_REGS, FP_REGS, FP_REGS, FP_REGS, FP_REGS, FP_REGS, FP_REGS, FP_REGS, FP_REGS, FP_REGS, FP_REGS, - FRAME_REGS, FRAME_REGS, VL_REGS, VTYPE_REGS, + FRAME_REGS, FRAME_REGS, NO_REGS, NO_REGS, NO_REGS, NO_REGS, NO_REGS, NO_REGS, NO_REGS, NO_REGS, NO_REGS, NO_REGS, NO_REGS, NO_REGS, NO_REGS, NO_REGS, @@ -5831,12 +5831,6 @@ riscv_class_max_nregs (reg_class_t rclass, machine_mode mode) if (reg_class_subset_p (rclass, V_REGS)) return riscv_hard_regno_nregs (V_REG_FIRST, mode); - if (reg_class_subset_p (rclass, VL_REGS)) - return 1; - - if (reg_class_subset_p (rclass, VTYPE_REGS)) - return 1; - return 0; } diff --git a/gcc/config/riscv/riscv.h b/gcc/config/riscv/riscv.h index 0ab739bd6eb..faffd5a77fe 100644 --- a/gcc/config/riscv/riscv.h +++ b/gcc/config/riscv/riscv.h @@ -462,8 +462,6 @@ enum reg_class GR_REGS, /* integer registers */ FP_REGS, /* floating-point registers */ FRAME_REGS, /* arg pointer and frame pointer */ - VL_REGS, /* vl register */ - VTYPE_REGS, /* vtype register */ VM_REGS, /* v0.t registers */ VD_REGS, /* vector registers except v0.t */ V_REGS, /* vector registers */ @@ -487,8 +485,6 @@ enum reg_class "GR_REGS", \ "FP_REGS", \ "FRAME_REGS", \ - "VL_REGS", \ - "VTYPE_REGS", \ "VM_REGS", \ "VD_REGS", \ "V_REGS", \ @@ -514,12 +510,10 @@ enum reg_class { 0xffffffff, 0x00000000, 0x00000000, 0x00000000 }, /* GR_REGS */ \ { 0x00000000, 0xffffffff, 0x00000000, 0x00000000 }, /* FP_REGS */ \ { 0x00000000, 0x00000000, 0x00000003, 0x00000000 }, /* FRAME_REGS */ \ - { 0x00000000, 0x00000000, 0x00000004, 0x00000000 }, /* VL_REGS */ \ - { 0x00000000, 0x00000000, 0x00000008, 0x00000000 }, /* VTYPE_REGS */ \ { 0x00000000, 0x00000000, 0x00000000, 0x00000001 }, /* V0_REGS */ \ { 0x00000000, 0x00000000, 0x00000000, 0xfffffffe }, /* VNoV0_REGS */ \ { 0x00000000, 0x00000000, 0x00000000, 0xffffffff }, /* V_REGS */ \ - { 0xffffffff, 0xffffffff, 0x0000000f, 0xffffffff } /* ALL_REGS */ \ + { 0xffffffff, 0xffffffff, 0x00000003, 0xffffffff } /* ALL_REGS */ \ } /* A C expression whose value is a register class containing hard
reply other threads:[~2023-02-03 7:15 UTC|newest] Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
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=20230203071550.89A733857352@sourceware.org \ --to=kito@gcc.gnu.org \ --cc=gcc-cvs@gcc.gnu.org \ /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: linkBe 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).