I have a sparse array a (mostly zeroes):
a
unsigned char a[1000000];
and I would like to create an array b of inde
b
Although AVX2 instruction set has many GATHER instructions, but its performance is too slow. And the most effective way to do this - to process an array manually.