public inbox for gcc-patches@gcc.gnu.org
 help / color / mirror / Atom feed
From: "Li, Pan2" <pan2.li@intel.com>
To: Kito Cheng <kito.cheng@sifive.com>, Juzhe-Zhong <juzhe.zhong@rivai.ai>
Cc: "gcc-patches@gcc.gnu.org" <gcc-patches@gcc.gnu.org>,
	"kito.cheng@gmail.com" <kito.cheng@gmail.com>
Subject: RE: [PATCH] RISC-V: Remove redundant functions
Date: Mon, 11 Sep 2023 10:28:27 +0000	[thread overview]
Message-ID: <MW5PR11MB59085E033D770772839A812DA9F2A@MW5PR11MB5908.namprd11.prod.outlook.com> (raw)
In-Reply-To: <CALLt3Thk7je2=Bax6AfVFSK3fy4HLM8BeTkemsFFSZ7-bYPXFA@mail.gmail.com>

Committed, thanks Kito.

Pan

-----Original Message-----
From: Gcc-patches <gcc-patches-bounces+pan2.li=intel.com@gcc.gnu.org> On Behalf Of Kito Cheng via Gcc-patches
Sent: Monday, September 11, 2023 5:26 PM
To: Juzhe-Zhong <juzhe.zhong@rivai.ai>
Cc: gcc-patches@gcc.gnu.org; kito.cheng@gmail.com
Subject: Re: [PATCH] RISC-V: Remove redundant functions

LGTM

On Mon, Sep 11, 2023 at 5:20 PM Juzhe-Zhong <juzhe.zhong@rivai.ai> wrote:
>
> I just finished V2 version of LMUL cost model.
> Turns out we don't these redundant functions.
>
> Remove them.
>
> gcc/ChangeLog:
>
>         * config/riscv/riscv-protos.h (get_all_predecessors): Remove.
>         (get_all_successors): Ditto.
>         * config/riscv/riscv-v.cc (get_all_predecessors): Ditto.
>         (get_all_successors): Ditto.
>
> ---
>  gcc/config/riscv/riscv-protos.h |  2 --
>  gcc/config/riscv/riscv-v.cc     | 48 ---------------------------------
>  2 files changed, 50 deletions(-)
>
> diff --git a/gcc/config/riscv/riscv-protos.h b/gcc/config/riscv/riscv-protos.h
> index 46d77ef927c..e91a55ec057 100644
> --- a/gcc/config/riscv/riscv-protos.h
> +++ b/gcc/config/riscv/riscv-protos.h
> @@ -498,8 +498,6 @@ enum floating_point_rounding_mode get_frm_mode (rtx);
>  opt_machine_mode vectorize_related_mode (machine_mode, scalar_mode,
>                                          poly_uint64);
>  unsigned int autovectorize_vector_modes (vec<machine_mode> *, bool);
> -hash_set<basic_block> get_all_predecessors (basic_block);
> -hash_set<basic_block> get_all_successors (basic_block);
>  bool cmp_lmul_le_one (machine_mode);
>  bool cmp_lmul_gt_one (machine_mode);
>  }
> diff --git a/gcc/config/riscv/riscv-v.cc b/gcc/config/riscv/riscv-v.cc
> index 3cd1f61de0e..4d95bd773a2 100644
> --- a/gcc/config/riscv/riscv-v.cc
> +++ b/gcc/config/riscv/riscv-v.cc
> @@ -3388,54 +3388,6 @@ expand_fold_extract_last (rtx *ops)
>    emit_label (end_label);
>  }
>
> -hash_set<basic_block>
> -get_all_predecessors (basic_block bb)
> -{
> -  hash_set<basic_block> blocks;
> -  auto_vec<basic_block> work_list;
> -  hash_set<basic_block> visited_list;
> -  work_list.safe_push (bb);
> -
> -  while (!work_list.is_empty ())
> -    {
> -      basic_block new_bb = work_list.pop ();
> -      visited_list.add (new_bb);
> -      edge e;
> -      edge_iterator ei;
> -      FOR_EACH_EDGE (e, ei, new_bb->preds)
> -       {
> -         if (!visited_list.contains (e->src))
> -           work_list.safe_push (e->src);
> -         blocks.add (e->src);
> -       }
> -    }
> -  return blocks;
> -}
> -
> -hash_set<basic_block>
> -get_all_successors (basic_block bb)
> -{
> -  hash_set<basic_block> blocks;
> -  auto_vec<basic_block> work_list;
> -  hash_set<basic_block> visited_list;
> -  work_list.safe_push (bb);
> -
> -  while (!work_list.is_empty ())
> -    {
> -      basic_block new_bb = work_list.pop ();
> -      visited_list.add (new_bb);
> -      edge e;
> -      edge_iterator ei;
> -      FOR_EACH_EDGE (e, ei, new_bb->succs)
> -       {
> -         if (!visited_list.contains (e->dest))
> -           work_list.safe_push (e->dest);
> -         blocks.add (e->dest);
> -       }
> -    }
> -  return blocks;
> -}
> -
>  /* Return true if the LMUL of comparison less than or equal to one.  */
>  bool
>  cmp_lmul_le_one (machine_mode mode)
> --
> 2.36.3
>

      reply	other threads:[~2023-09-11 10:28 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-09-11  9:19 Juzhe-Zhong
2023-09-11  9:25 ` Kito Cheng
2023-09-11 10:28   ` Li, Pan2 [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=MW5PR11MB59085E033D770772839A812DA9F2A@MW5PR11MB5908.namprd11.prod.outlook.com \
    --to=pan2.li@intel.com \
    --cc=gcc-patches@gcc.gnu.org \
    --cc=juzhe.zhong@rivai.ai \
    --cc=kito.cheng@gmail.com \
    --cc=kito.cheng@sifive.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).