Committed, thanks Jeff and Richard. Pan
-----Original Message----- From: Gcc-patches <[email protected]> On Behalf Of Jeff Law via Gcc-patches Sent: Monday, July 10, 2023 10:08 PM To: [email protected]; [email protected] Cc: [email protected] Subject: Re: [PATCH v2] GCSE: Export 'insert_insn_end_basic_block' as global function On 7/10/23 02:12, [email protected] wrote: > From: Ju-Zhe Zhong <[email protected]> > > Since VSETVL PASS in RISC-V port is using common part of > 'insert_insn_end_basic_block (struct gcse_expr *expr, basic_block bb)' > and we will also this helper function in riscv.cc for the following patches. > > So extract the common part codes of 'insert_insn_end_basic_block (struct > gcse_expr *expr, basic_block bb)', the new function > of the common part is also call 'insert_insn_end_basic_block (rtx_insn *pat, > basic_block bb)' but with different arguments. > And call 'insert_insn_end_basic_block (rtx_insn *pat, basic_block bb)' in > 'insert_insn_end_basic_block (struct gcse_expr *expr, basic_block bb)' > and VSETVL PASS in RISC-V port. > > Remove redundant codes of VSETVL PASS in RISC-V port. > > gcc/ChangeLog: > > * config/riscv/riscv-vsetvl.cc (add_label_notes): Remove it. > (insert_insn_end_basic_block): Ditto. > (pass_vsetvl::commit_vsetvls): Adapt for new helper function. > * gcse.cc (insert_insn_end_basic_block): Export as global function. > * gcse.h (insert_insn_end_basic_block): Ditto. OK. Thanks for remembering to clean this up. jeff
