Inverse sqrt for fixed point
问题 I am looking for the best inverse square root algorithm for fixed point 16.16 numbers. The code below is what I have so far(but basically it takes the square root and divides by the original number, and I would like to get the inverse square root without a division). If it changes anything, the code will be compiled for armv5te. uint32_t INVSQRT(uint32_t n) { uint64_t op, res, one; op = ((uint64_t)n<<16); res = 0; one = (uint64_t)1 << 46; while (one > op) one >>= 2; while (one != 0) { if (op