What was the reasoning behind disabling interrupts when searching for the next task to run? I understand that you may want to change the state of a task in an ISR, but by disabling interrupts, you always defer it until the end. It would seem to me that leaving the interrupts disabled would possibly cause a task to be marked running a little bit sooner, but wouldn't cause any other bad side effects.
Thanks,
David Walker