A scalable network simulator