fmath.h: Add 'safe' inversesqrt, log, log2, log10, logb

Gathering all the 'safe' (no NaN or Infs returned) versions in one place.