Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Time Slicing Diagram #48

Open
amrear opened this issue Sep 22, 2023 · 0 comments
Open

Time Slicing Diagram #48

amrear opened this issue Sep 22, 2023 · 0 comments

Comments

@amrear
Copy link

amrear commented Sep 22, 2023

Chapter 2 discusses how target latency works and provides a diagram for clarification. According to the explanation:

The target latency is the time it takes for a process to resume execution after being preempted...

Based on this explanation, shouldn't the target latency in the diagram start from the beginning of Process 2 and finish at the end of Process 3 designated by the following image?

linux-scheduler-target-latency

It also presents an approach to calculate the timeslices based on a specific target latency:

Timeslices are calculated by dividing the target latency by the total number of tasks.

Suppose we have 3 processes, and the target latency is 9ms, meaning there can be a 9-millisecond gap between the bursts of each process. Using the given method, we divide 9 by 3 and realize that each process can run for 3 milliseconds and therefore must wait for the subsequent processes for 6 milliseconds. This contradicts the definition of the target latency.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant