ios - Speed up summing components in a vector -


i create array array summing components in blocks of four, e.g.:

float invector[256]; float outvector[64];  for(int i=0; i<64; i++){   for(int j=0; j<4; j++){     int k = 4*i + j;     outvector[i] += invector[k];   } } 

i accelerate this. have looked in available libraries in ios vdsp , vforce, haven't found fits. closest candidate has been vdsp_vswsum, doesn't want. have tip how speed up?

you're trying decimate vector. vdsp_sve n=4 speed inner loop. if want average of 4 values, vdsp_mean.


Comments

Popular posts from this blog

how to proxy from https to http with lighttpd -

android - Automated my builds -

python - Flask migration error -