Created
March 25, 2014 18:11
-
-
Save liuliu/9767719 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
static inline float cbrt_5_f32(float f) | |
{ | |
const uint32_t b1 = 709921077; | |
uint32_t* p = (uint32_t*)(&f); | |
*p = *p / 3 + b1; | |
return f; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment