Updated benchmarking code.