Linux Mastering Development

How scheduling policy of a pthread is related to the kernel’s Completely Fair Scheduler when the thread is actually executing?

I have some doubts about setting the policy of a thread and how that policy is going to be followed while it is executing. Pthread allows setting the scheduling policy of a thread to SCHED_FIFO/SCHED_RR/SCHED_OTHER. I am trying to understand how this user-set-policy works when the Linux kernel uses CFS as the default scheduler policy. Will the user-set-policy is going to be overriden to CFS when it is executing? If so , what is the use of pthread schedling policy?

Leave a Reply

Your email address will not be published. Required fields are marked *