Fix a bug in benchmark.