Dear all,
I would appriciate any input you may have on how to optimize this line which appears in my most inner loop:
*pG=(short)(((i nt)w1*V1+w2*V2+ w3*V3+w4*V4)/(w1+w2+w3+w4));
w1,w2,w3,w4,V1, V2,V3,V4 are all short and the result is also short.
If it makes any difference, all variables are positive and smaller than 4095.
Thanks for any input,
Eli.
I would appriciate any input you may have on how to optimize this line which appears in my most inner loop:
*pG=(short)(((i nt)w1*V1+w2*V2+ w3*V3+w4*V4)/(w1+w2+w3+w4));
w1,w2,w3,w4,V1, V2,V3,V4 are all short and the result is also short.
If it makes any difference, all variables are positive and smaller than 4095.
Thanks for any input,
Eli.
Comment