DRILL-320: Reword math functions to use code gen;