Fast comparison use

Map functions now use FASTMAX() and FASTMIN() instead of std::max() and
std::min() (saves about 3 instruction each time, which adds up quite a
bit for inline functions like these).