Change the metric for the function coercion cost from sum to max

This fixes the previously added ufunc overload testcase that
was failing, and doesn't break any of the other tests.