• Austin Clements's avatar
    runtime: make stack barrier locking more robust · 22e57c66
    Austin Clements authored
    The stack barrier locking functions use a simple cas lock because they
    need to support trylock, but currently don't increment g.m.locks. This
    is okay right now because they always run on the system stack or the
    signal stack and are hence non-preemtible, but this could lead to
    difficult-to-reproduce deadlocks if these conditions change in the
    future.
    
    Make these functions more robust by incrementing g.m.locks and making
    them nosplit to enforce non-preemtibility.
    
    Change-Id: I73d60a35bd2ad2d81c73aeb20dbd37665730eb1b
    Reviewed-on: https://go-review.googlesource.com/17058
    Run-TryBot: Austin Clements <austin@google.com>
    TryBot-Result: Gobot Gobot <gobot@golang.org>
    Reviewed-by: 's avatarIngo Oeser <nightlyone@googlemail.com>
    Reviewed-by: 's avatarRuss Cox <rsc@golang.org>
    22e57c66
Name
Last commit
Last update
api Loading commit data...
doc Loading commit data...
lib/time Loading commit data...
misc Loading commit data...
src Loading commit data...
test Loading commit data...
.gitattributes Loading commit data...
.gitignore Loading commit data...
AUTHORS Loading commit data...
CONTRIBUTING.md Loading commit data...
CONTRIBUTORS Loading commit data...
LICENSE Loading commit data...
PATENTS Loading commit data...
README.md Loading commit data...
favicon.ico Loading commit data...
robots.txt Loading commit data...