shiyangsheng
Results
1
comments of
shiyangsheng
场景7,本地队列没有g时,是优先从其他P的本地队列窃取还是从全局队列窃取?这里[Scheduling In Go : Part II - Go Scheduler](https://www.ardanlabs.com/blog/2018/08/scheduling-in-go-part2.html)图10~图13我看说的是优先从其它P的本地队列窃取,当其它P也没有g时,才从全局队列窃取。但是有1/61的概率是优先从全局队列获取[stealing work](https://golang.org/src/runtime/proc.go),此时需要加锁。这里没有看太明白,不清楚楼主是否清楚这个是出于什么考虑?