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.

SK-TDA4VM: Impact of dividing by zero on the C7X

Part Number: SK-TDA4VM

Hi,

I'm currently developing a kernel where I'm computing the average of an array this way:

float16 values;
float16 validCount;
float16 average = values / validCount;

My concern is when some elements of validCount are at 0, which is a valid usecase for me. I did some testing and the C7X doesn't seem to have a problem dividing by zero, it just results in a +inf value and __get_FSR(float16)::DIV0 gets set.

My questions are:

1- Is there a performance drop for dividing by zero?

2- Does __get_FSR(float16)::DIV0 ever get reset? I can't seem to get the bit to go back to zero.

3- Is it harmful that __get_FSR(float16)::DIV0 is always set?

Thanks,

Fred