https://gcc.gnu.org/bugzilla/show_bug.cgi?id=112450
--- Comment #7 from JuzheZhong <juzhe.zhong at rivai dot ai> --- breakpoint. vect_record_loop_mask (loop_vinfo, masks, ncopies * vec_num, (gdb) p vectype->type_common.mode $1 = E_V64HImode Form my observation. It seems to be V64HImode. I tried you patch locally, it fixes the ICE now. Thanks!