ALGORITHM 3.
Steps for processing a RB-message, tail refers to the element with the greatest timestamp in a queue
Input: The RB-message rb |
if rb.channel.ICPQ.tail.st < rb.st then |
Remove events with send time greater than or equal to rb.st in ICEQ and LPEQ; |
for event es in SubmitTrack do |
if es.channel == rb.channel & es.st ≥ rb.st then |
Remove es in TEQ; |
end |
end |
if rb.channel.submit.st ≥ rb.st then |
rb.channel submits its smallest event to upper level queue and updates submit; |
end |
else |
Search cut-point ecut in rb.channel.ICPQ; |
rbt = −1; |
if ecut is not NIL then |
rbt = ecut.rt; |
else |
rbt = rb.st; |
end |
rb.targetLP rolls back to a time point prior to rbt according to algorithm 4; |
end |
smallest = the smallest event in LPEQ; |
if submitTrack is empty | smallest.rt < submitTrack.top.rt then |
Submit smallest to TEQ and push it to submitTrack; |
end |