speedup of quantile computation