Skip to content

GitLab

  • Menu
Projects Groups Snippets
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in / Register
  • pygolang pygolang
  • Project information
    • Project information
    • Activity
    • Labels
    • Members
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
  • Issues 0
    • Issues 0
    • List
    • Boards
    • Service Desk
    • Milestones
  • Merge requests 1
    • Merge requests 1
  • Deployments
    • Deployments
    • Releases
  • Monitor
    • Monitor
    • Incidents
  • Analytics
    • Analytics
    • Value stream
    • Repository
  • Snippets
    • Snippets
  • Activity
  • Graph
  • Create a new issue
  • Commits
  • Issue Boards
Collapse sidebar
  • nexedi
  • pygolangpygolang
  • Repository

Switch branch/tag
  • pygolang
  • golang
  • _sync.pxd
Find file BlameHistoryPermalink
  • Kirill Smelkov's avatar
    sync.RWMutex: Teach it to downgrade from write-locked into read-locked state · a9345a98
    Kirill Smelkov authored Feb 20, 2020
    Go version does not provide this, but the topic of sync.RWMutex
    downgrading was raised up several times, at least
    
    	https://github.com/golang/go/issues/4026
    	https://github.com/golang/go/issues/23513
    	https://groups.google.com/forum/#!topic/golang-nuts/MmIDUzl8HA0
    	...
    
    Atomic downgrading is often useful to avoid race window in between
    Unlock and RLock and, as consequence, having the need to recheck things
    after RLock.
    
    We can put this complexity and logic into well-defined RWMutex primitive
    instead of throwing it to be solved by every RWMutex user.
    a9345a98

Replace _sync.pxd

Attach a file by drag & drop or click to upload


Cancel
GitLab will create a branch in your fork and start a merge request.
GitLab Nexedi Edition | About GitLab | About Nexedi | 沪ICP备2021021310号-2 | 沪ICP备2021021310号-7