On 7/12/23 17:30, 钟居哲 wrote:
I notice vectorizable_call in Loop Vectorizer.
It's vectorizing CALL function for example like fmax/fmin.
From my understanding, we dont have RVV instruction for fmax/fmin?
So for now, I don't need to support builtin call function vectorization
for RVV.
Am I right?
Yes, you are correct.
I am wondering whether we do have some kind of builtin function call
vectorization by using RVV instructions.
It can be advantageous, even if the call doesn't collapse down to a
single vector instruction. Consider libmvec which is an API to provide
things like sin, cos, exp, log, etc in vector form.
Once the library routines are written, those can then be exposed to the
compiler in turn allowing vectorization of loops with a subset of calls
such as sin, cos, pow, log, etc.
jeff