bug 676: maxloc, use crternlogi to reduce op count