For a FFT function I need to permutate or shuffle the elements within an array in a bit-reversed way. That\'s a common task with FFTs because most power of two sized FFT fun
Using a pre-built lookup table to do the mapping seems to be the obvious solution. I guess it depends how big the arrays you will be dealing with are. But even if a direct mapping is not possible, I'd still go for a lookup table, maybe of byte-size patterns that you can use to build the word-sized pattern for the final index.