- Sort Score
- Result 10 results
- Languages All
Results 1 - 2 of 2 for pMask (0.03 sec)
-
src/runtime/runtime2.go
// pidleget may clear the mask before pidleput sets the mask, // corrupting the bitmap. // // N.B., procresize takes ownership of all Ps in stopTheWorldWithSema. idlepMask pMask // Bitmask of Ps that may have a timer, one bit per P. Reads and writes // must be atomic. Length may change at safe points. // // Ideally, the timer mask would be kept immediately consistent on any timer
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Thu May 30 17:57:37 UTC 2024 - 47.9K bytes - Viewed (0) -
src/runtime/proc.go
} return gp } // pMask is an atomic bitstring with one bit per P. type pMask []uint32 // read returns true if P id's bit is set. func (p pMask) read(id uint32) bool { word := id / 32 mask := uint32(1) << (id % 32) return (atomic.Load(&p[word]) & mask) != 0 } // set sets P id's bit. func (p pMask) set(id int32) { word := id / 32
Registered: Wed Jun 12 16:32:35 UTC 2024 - Last Modified: Wed May 29 17:58:53 UTC 2024 - 207.5K bytes - Viewed (0)