SOS_SCHEDULER_YIELD due to SpinLock issue.

First of all we can check SQL server version since there is patch regarding bucket count.

https://support.microsoft.com/en-us/kb/3026082

https://support.microsoft.com/en-us/kb/3026083

https://support.microsoft.com/en-us/kb/3175883

Identifying queries with SOS_SCHEDULER_YIELD waits

Advanced SQL Server performance tuning

New whitepapers on latches and spinlocks published

https://blogs.msdn.microsoft.com/repltalk/2011/02/08/what-does-high-wait-in-sos_scheduler_yield-mean/

And here is really good blog about this issue.

https://exadat.co.uk/2015/03/31/spinlocks-when-to-worry-about-them-and-solutions-to-common-problems/