Trace-Driven Simulations of Parallel and Distributed Algorithms in Multiprocessors