none
what is SOS_SCHEDULER_YIELD?

    Question

  •  

    what is SOS_SCHEDULER_YIELD?

     

    and when dose  SOS_SCHEDULER_YIELD work?

     

    if having more CPU,  will SOS_SCHEDULER_YIELD  be influenced by?   

     

     

    thanks for reading

    Thursday, June 07, 2007 11:37 AM

Answers

  • Hi,

    The SQL Database engine uses a non-preemptive scheduler internally to increase throuhput; Most threads are expected to yield often. Much more information on this topic can be found on http://blogs.msdn.com/slavao.

    If you are seeing lots of SOS_SCHEDULER_YIELD in your Wait States, that is a very stong indicator of CPU pressure.

    You can run the DMV query to confirm that:

    -- Check SQL Server Schedulers to see if they are waiting on CPU
    SELECT scheduler_id, current_tasks_count, runnable_tasks_count
    FROM sys.dm_os_schedulers
    WHERE scheduler_id < 255

    If you see the runnable tasks count above zero, that is cause for concern, and if you see it in double digits for any length of time, that is cause for extreme concern!


    Regards
    Karna
    Thursday, June 07, 2007 11:43 AM

All replies