On 2023-08-28 17:27 Kito Cheng <kito.ch...@gmail.com> wrote: > >I would prefer to decouple the shrink-wrap part by checking >flag_shrink_wrap, I mean let disable zcmp code gen if flag_shrink_wrap >is true for now, and a follow up patch series with shrink-wrap.[cc|h] >changes?
OK. some details to be confirmed by you: 1. flag_shrink_wrap_separate seems better than flag_shrink_wrap. 2. to pass the zcmp testcases, i will add fno-shrink-wrap-separate option. BR, Fei > >On Mon, Aug 28, 2023 at 3:48 PM Fei Gao <gao...@eswincomputing.com> wrote: >> >> The first is a helper patch to allow targets to check shrink-wrap-separate >> enabled or not. >> The second is zcmp extension implementation in RISC-V. >> >> Fei Gao (2): >> allow target to check shrink-wrap-separate enabled or not >> support cm.push cm.pop cm.popret in zcmp and resolve confilct with >>shrink-wrap-separate >> >> gcc/config/riscv/iterators.md | 15 + >> gcc/config/riscv/predicates.md | 96 ++ >> gcc/config/riscv/riscv-protos.h | 2 + >> gcc/config/riscv/riscv.cc | 455 ++++++- >> gcc/config/riscv/riscv.h | 25 + >> gcc/config/riscv/riscv.md | 2 + >> gcc/config/riscv/zc.md | 1042 +++++++++++++++++ >> gcc/shrink-wrap.cc | 25 +- >> gcc/shrink-wrap.h | 1 + >> gcc/testsuite/gcc.target/riscv/rv32e_zcmp.c | 256 ++++ >> gcc/testsuite/gcc.target/riscv/rv32i_zcmp.c | 256 ++++ >> .../gcc.target/riscv/zcmp_push_fpr.c | 34 + >> .../riscv/zcmp_shrink_wrap_separate.c | 93 ++ >> .../riscv/zcmp_shrink_wrap_separate2.c | 93 ++ >> .../gcc.target/riscv/zcmp_stack_alignment.c | 24 + >> 15 files changed, 2357 insertions(+), 62 deletions(-) >> create mode 100644 gcc/config/riscv/zc.md >> create mode 100644 gcc/testsuite/gcc.target/riscv/rv32e_zcmp.c >> create mode 100644 gcc/testsuite/gcc.target/riscv/rv32i_zcmp.c >> create mode 100644 gcc/testsuite/gcc.target/riscv/zcmp_push_fpr.c >> create mode 100644 >>gcc/testsuite/gcc.target/riscv/zcmp_shrink_wrap_separate.c >> create mode 100644 >>gcc/testsuite/gcc.target/riscv/zcmp_shrink_wrap_separate2.c >> create mode 100644 gcc/testsuite/gcc.target/riscv/zcmp_stack_alignment.c >> >> -- >> 2.17.1 >>