introduction to time management siddharth misra background distributed simulation which is nothing...
TRANSCRIPT
Introduction To Introduction To Time ManagementTime Management
Siddharth MisraSiddharth Misra
BackgroundBackground
Distributed Simulation which is nothing but Distributed Simulation which is nothing but simulation on LAN became a popular tool simulation on LAN became a popular tool for the military to train personnel's and for the military to train personnel's and simulate combat.simulate combat.
MotivationMotivation The order of events arriving in distributed The order of events arriving in distributed
simulation cannot be guaranteed i.e. the simulation cannot be guaranteed i.e. the events may not arrive in the order of cause and events may not arrive in the order of cause and effect due to delays in network traffics and effect due to delays in network traffics and processing.processing.
Logical Sequence of Events
Fired Missile at time 0 seconds.
Target destroyed at time 3 seconds.
Fired Missile at time 0 seconds.
Missile fired at time 0 seconds.
Contd…Contd…
Target destroyed at time 3 seconds.
Communication Delay of 3 seconds.
No Communication Delay.
Target Destroyed before it has been fired upon
Missile fired at time 0 seconds.
No Communication Delay.
PurposePurpose
Time management services is therefore Time management services is therefore used to ensure that events arrive at each used to ensure that events arrive at each federate in correct order.federate in correct order.
Also, it is used to ensure that another Also, it is used to ensure that another execution of same simulation results in execution of same simulation results in the same ordering.the same ordering.
Time Management Time Management SchemesSchemes
The two time management schemes for The two time management schemes for the advance in time of a simulation the advance in time of a simulation discussed here are –discussed here are –
1.1. Conservative Synchronization.Conservative Synchronization.
2.2. Optimistic Synchronization. Optimistic Synchronization.
Conservative Conservative SynchronizationSynchronization
is a scheme where none of the is a scheme where none of the simulations advances its time until it is simulations advances its time until it is sure that it cannot receive any events in sure that it cannot receive any events in the past.the past.
49
7811
15
DisadvantagesDisadvantages
Pessimistic approach in the sense it Pessimistic approach in the sense it processes only those events that are processes only those events that are considered to be safe. considered to be safe.
49
7812
As there is no event after time 12 therefore the event at 12 is not safe as the simulation can expect some event before time 12.
Blocked
Contd…Contd…
This scheme also introduces deadlocks.This scheme also introduces deadlocks.
cycle
35 37 39
Optimistic Optimistic SynchronizationSynchronization
is a scheme in which a simulation is a scheme in which a simulation processes events as they arrive;processes events as they arrive;
possibility that a simulation may possibility that a simulation may receive events in its past causing it to receive events in its past causing it to perform roll back operations which perform roll back operations which make the simulation go back to a state make the simulation go back to a state which it has saved.which it has saved.
Contd…Contd…
11
SB
13
SD
18
SB
22
SC
25
SD
28
SC
36
SB
32
SD
SA
processed!
SB
SA
SC
SD
11 13 18 22 25 28 3632
late messages cause roll back
32
DisadvantagesDisadvantages
A critical problem faced here is whether A critical problem faced here is whether the system spends most of its time the system spends most of its time executing incorrect computations and executing incorrect computations and rolling them back.rolling them back.
Another problem faced here is the need Another problem faced here is the need to save states which incurs huge memory to save states which incurs huge memory overheads.overheads.
SummarySummary
Both the approaches discussed here Both the approaches discussed here have their own pros & cons and one have their own pros & cons and one might be better suited than another for an might be better suited than another for an application depending on the type of application depending on the type of application.application.
Based on the disadvantages of the above Based on the disadvantages of the above a third approach will be presented a third approach will be presented shortly.shortly.