Introduction
Discrete Event Simulation (DES) is a critical tool for modeling complex systems where state changes occur at discrete points in virtual time. For these simulations to be scientifically valid, they must be deterministic: identical inputs and models must yield identical results. However, achieving determinism in Parallel Discrete Event Simulations (PDES) is challenging, particularly when multiple events are scheduled for the exact same virtual time.
The Challenge of Event Simultaneity and Bias
In PDES, two primary issues arise when events coincide in virtual time:
- Ordering Bias: Traditional tie-breaking rules often rely on hardware-specific attributes, such as Processor or Logical Process (LP) IDs. This introduces a hidden bias where the simulation outcome depends on the hardware configuration (e.g., the number of ranks used) rather than the model logic.
- Causality Violations in Zero-Offset Events: Some events trigger "zero-offset" child events at the current virtual time. In optimistic parallel protocols like Time Warp, improper handling of these simultaneous events can lead to "causality violations," resulting in infinite rollback loops and simulation stalls.
Proposed Methodology: Lexicographical Random Tie-Breaking
To address these issues, the authors implemented a robust solution within the ROSS (Rensselaer Optimistic Simulation System) engine. The approach rests on three pillars:
Unbiased Random Tie-breaking
Instead of hardware IDs, each event is assigned a random tie-breaking value from a rollback-safe Pseudo-Random Number Generator (PRNG). This ensures that ties are broken fairly and deterministically across any number of processors.
Lexicographical Virtual Time Signatures
To handle zero-offset events, the system treats timestamps as a sequence rather than a single scalar. This uses lexicographical ordering—similar to how words are ordered in a dictionary. A parent event's signature serves as a prefix to its child's signature, ensuring the parent always precedes the child (the "Aardvark" analogy: "A" always comes before "aardvark").
Rollback-Safe PRNGs
In optimistic simulations, processors may need to "undo" work. The system ensures that PRNG states are restored during rollbacks, maintaining the deterministic sequence of tie-breakers regardless of the execution path.
Experimental Validation
The authors evaluated the approach using three models: PHOLD (a standard performance benchmark), and two custom models (Event-Ties and Event-Ties-Stress) designed to be hyper-sensitive to event ordering.
In the Event-Ties model, which uses non-commutative "mean of means" operations, traditional tie-breaking produced inconsistent results as the simulation scaled (e.g., 35.08 on 1 rank vs. 34.40 on 128 ranks). With the new lexicographical mechanism, the results remained identical (34.7264) across all configurations. Furthermore, the overhead in standard benchmarks like PHOLD was found to be negligible.
Conclusion
By extending virtual time into a lexicographical sequence of random tie-breaking values, this method eliminates hardware-induced bias and prevents the performance-degrading stalls associated with simultaneous events. This advancement ensures that PDES results are both deterministic and scientifically reliable, regardless of the underlying parallel architecture.
Summary updated