Exactly what are you looking at? The wait time or numbers of waits? It's quite normal to have a high number of SOS_SCHEDULER_YIELD waits when you have a CPU-intensive process. This is because all code in SQL Server voluntary yields after around 4 ms to permit other tasks to run. But if there is free CPU, the wait should be very short.
CXPACKET and SOS_Scheduler_yeild waits
Sam
1,476
Reputation points
Hi All,
One of the app query is running slow. When I saw the spid's waitype, it is CXPACKET. After digging further one of the thread is waiting for SOS_SCHEDULER_YIELD. question I have is, except this query nothing else is running at that moment. only small other queries coming and exiting. When I observed the windows task manager, Server CPU usage is under 15% utilization. VM has 32 cpus. Why it is had to wait for SOS_SCHEDULER_YIELD.when it is not a high cpu condition on the server? How to troubleshoot and fix such queries?
Regards,
Sam