modified main for benchmarking