From: Juzhe-Zhong <juzhe.zhong@rivai.ai>
To: gcc-patches@gcc.gnu.org
Cc: kito.cheng@gmail.com, kito.cheng@sifive.com,
jeffreyalaw@gmail.com, rdapp.gcc@gmail.com,
Juzhe-Zhong <juzhe.zhong@rivai.ai>
Subject: [PATCH] RISC-V: Remove redundant functions
Date: Mon, 11 Sep 2023 17:19:30 +0800 [thread overview]
Message-ID: <20230911091930.2592988-1-juzhe.zhong@rivai.ai> (raw)
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
next reply other threads:[~2023-09-11 9:19 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-09-11 9:19 Juzhe-Zhong [this message]
2023-09-11 9:25 ` Kito Cheng
2023-09-11 10:28 ` Li, Pan2
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=20230911091930.2592988-1-juzhe.zhong@rivai.ai \
--to=juzhe.zhong@rivai.ai \
--cc=gcc-patches@gcc.gnu.org \
--cc=jeffreyalaw@gmail.com \
--cc=kito.cheng@gmail.com \
--cc=kito.cheng@sifive.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).