Interaction Patterns Detection in Message Passing Programs to Support Parallel Program Simulation