On Linux this is in include/crt/math_functions.hpp, but there the code snippet actually uses ::pow, which comes from the CUDA Math API 3.
As far as I understand, much of the trickery is needed to support half datatypes on Windows due to templating limitations (as the comment suggests) in the compiler.
Best regards
Thomas