-
Notifications
You must be signed in to change notification settings - Fork 0
Description
🐛 Scheduler Skips Time When Reduce Function Is Not np.Max
Description
The scheduler receives a list of machines and jobs. After applying the dilation process and selecting an operation, the scheduler operates on a view of the original machines.
When the selected reduce function is not np.Max, the returned value does not correctly reflect the scheduler’s actual state or capabilities. As a result, the scheduler may incorrectly determine that no valid operations are available and prematurely advance (skip) time.
This leads to unintended scheduling gaps and incorrect execution flow.
Steps to Reproduce
- Provide the scheduler with a list of machines and jobs.
- Apply dilation and select an operation.
- Use a reduce function other than
np.Max. - Observe that:
- The computed value does not match the scheduler’s real availability.
- The scheduler skips time even though valid operations should still be possible.
Expected Behavior
- The reduce function should accurately reflect the scheduler’s current feasible operations.
- The scheduler should not skip time if valid operations are still available.
- Behavior should be consistent regardless of which valid reduce function is selected.
Actual Behavior
- When using a reduce function other than
np.Max, the scheduler misinterprets availability. - It incorrectly assumes no valid operations are possible.
- Time is advanced unnecessarily.
Possible Cause
The scheduler’s decision logic appears to rely on semantics that are only valid when using np.Max. Other reduce functions may produce values that do not properly represent machine readiness or operation feasibility.
Suggested Fix
- Review how the reduce function output is interpreted by the scheduler.
- Ensure all supported reduce functions produce values aligned with scheduling feasibility logic.
- Add validation or safeguards to prevent premature time advancement.
Additional Context
This issue affects scheduling accuracy and may lead to inefficient execution or incorrect simulation results when alternative reduce strategies are used.