Review Board 2.0.15


inorder: replace schedEvent() code with reschedule().

Review Request #369 - Created Jan. 4, 2011 and submitted

Information
Steve Reinhardt
gem5
Reviewers
Default
ali, gblack, nate, stever
inorder: replace schedEvent() code with reschedule().
There were several copies of similar functions that looked
like they all replicated reschedule(), so I replaced them
with direct calls.  Keeping this separate from the previous
cset since there may be some subtle functional differences
if the code ever reschedules an event that is scheduled but
not squashed (though none were detected in the regressions).

   
Ship it!
Posted (Jan. 4, 2011, 6:42 a.m.)
Looks good.  I assume it works.
Ship it!
Posted (Jan. 4, 2011, 8:56 a.m.)
My only question is does it work? it seems like the if statements don't translate exactly, but that could just be over-specifying the if (e.g. can you ever fall out with out any action?).
  1. You're right, the issue is that the old code would silently do nothing if the event was already scheduled and not squashed, where the new code will forcibly reschedule a scheduled event whether it's squashed or not.  I discussed this with Korey and he thought it was an oversight, but I since added 'assert(!scheduled() || squashed());' to each of these functions and re-ran the quick regressions with no ill effects.  So by that limited definition, yes, it works...