Andrew Doran <a...@netbsd.org> wrote: > We have some algorhythms in the scheduler and mutual exclusion code that > aren't designed for large numbers of cores, but I think they should be OK > with 24 CPUs. <...>
I have committed mutex_oncpu patch, so it is O(1) in -current. > <...> (While I'm rambling about this I think the SPINLOCK_BACKOFF > stuff should have some sort of randomness to it perhaps based off curlwp > and cpu_counter() otherwise things could proceeed in lockstep, although > again probably not the issue here). Well, times of acquire attempts by other CPUs would normally differ, so CPUs would start exponential back-off at different times, i.e. randomness is already there. Do you mean wake up path (e.g. cv_broadcast() hit)? -- Mindaugas