Part Number: TDA2
Hi,
Is it possible to switch from vector to scalar in VCOP kernel C? I want to make decisions based on the individual element value, will it be possible?
Regards,
Shruti
This thread has been locked.
If you have a related question, please click the "Ask a related question" button in the top right corner. The newly created question will be automatically linked to this question.
Part Number: TDA2
Hi,
Is it possible to switch from vector to scalar in VCOP kernel C? I want to make decisions based on the individual element value, will it be possible?
Regards,
Shruti
Hi Anshu,
I have a use case wherein, depending on the value of the element I have to set a flag. This flag can range from 0 to 7. Depending on the flag's value, I have to perform some operations.
In normal C this is easy, the flag can be set for a single element, and normal if-else conditions take care of the rest.
But, when using kernel C, 8 elements are processed at a time, and the flag is also a vector. So, all the elements of the flag will be in the range of 0 to 7. And for each element the operation should be different. Is there a way to handle this?
Regards,
Shruti Joshi
Shruti,
Can you look into select instruction of VCOP and see it helps?
Regards,
Anshu