Avoid generating lists in Benchmark.times and move some code around