VSETVLIInfos right after VLEFF/VLSEGFF are unkown since they modify VL. Unknown
VSETVLIInfos make next vector operations needed to be inserted VSET(I)VLI.
Take the below C code as an example,
vint8m4_t vec_src1 = vle8ff_v_i8m4(str1, &new_vl, vl); vbool2_t mask1 = vmseq_vx_i8m4_b2(vec_src1, 0, new_vl);
Vsetvli insertion adds a redundant vsetvli for that,
vsetvli a2,a2,e8,m4,ta,mu vle8ff.v v28,(a0) csrr a3,vl ; redundant vsetvli zero,a3,e8,m4,ta,mu ; redundant vmseq.vi v25,v28,0
The patch uses PseudoReadVL to get the VSETVLIInfos at the location. It may
prevent vsetvli insertion from inserting redundant VSET(I)VLI.
Maybe no need to save a pointer in the VSETVLIInfo? I think that we only care about if the previous VSETVLIInfo is from a VL modified MI and the current AVL is read from the result of the modified VL. I think maybe we could use a local pointer in emitVSETVLIs or somewhere you would like to use it.