Just wondering if we can add additional condition below
https://golang.org/src/runtime/lock_futex.gofunc lock2(l *mutex) {
gp := getg()
52
...
// Try for lock, rescheduling.
for i := 0; i < passive_spin; i++ {
We may need to improve this by stubbing the ownership information say M id into
lock, that way we can decide to spin or sleep if G is running on M currently.
Just a thought.
Starting now on go runtime...thinking a loud here.
Thanks & Regards,
Uday Kiran