https://gcc.gnu.org/bugzilla/show_bug.cgi?id=109535
--- Comment #9 from JuzheZhong <juzhe.zhong at rivai dot ai> --- Confirm it is VSETVL pass bug in RISC-V port backend. Fix patch here: https://gcc.gnu.org/pipermail/gcc-patches/2023-April/615882.html Hopefully, it will be merged soon.