strcmp example is wrong
dzaima opened this issue · 0 comments
dzaima commented
examples/rvv_strcmp.c
incorrectly manages vl - the vl of the second load (vl1
) goes completely unused, and thus the function could do all kinds of broken behavior if src1
's loaded element count is greater than that of src2
.
A fix could be to make the second load take & update the vl
of the first load, matching the behavior of the assembly reference.