<feed xmlns='http://www.w3.org/2005/Atom'>
<title>delta/go-git.git/src/runtime/sigqueue.go, branch dev.inline</title>
<subtitle>github.com: golang/go
</subtitle>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/go-git.git/'/>
<entry>
<title>runtime: improve last ditch signal forwarding for Unix libraries</title>
<updated>2016-03-24T19:34:17+00:00</updated>
<author>
<name>Joe Sylve</name>
<email>joe.sylve@gmail.com</email>
</author>
<published>2016-03-23T03:11:42+00:00</published>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/go-git.git/commit/?id=df2b2eb63db3f771c41be4d97ac6fb6b0c5f8c48'/>
<id>df2b2eb63db3f771c41be4d97ac6fb6b0c5f8c48</id>
<content type='text'>
The current runtime attempts to forward signals generated by non-Go
code to the original signal handler.  If it can't call the original
handler directly, it currently attempts to re-raise the signal after
resetting the handler.  In this case, the original context is lost.

This fix prevents that problem by simply returning from the go signal
handler after resetting the original handler.  It only does this when
the original handler is the system default handler, which in all cases
is known to not recover.  The signal is not reset, so it is retriggered
and the original handler takes over with the proper context.

Fixes #14899

Change-Id: Ib1c19dfa4b50d9732d7a453de3784c8141e1cbb3
Reviewed-on: https://go-review.googlesource.com/21006
Reviewed-by: Ian Lance Taylor &lt;iant@golang.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The current runtime attempts to forward signals generated by non-Go
code to the original signal handler.  If it can't call the original
handler directly, it currently attempts to re-raise the signal after
resetting the handler.  In this case, the original context is lost.

This fix prevents that problem by simply returning from the go signal
handler after resetting the original handler.  It only does this when
the original handler is the system default handler, which in all cases
is known to not recover.  The signal is not reset, so it is retriggered
and the original handler takes over with the proper context.

Fixes #14899

Change-Id: Ib1c19dfa4b50d9732d7a453de3784c8141e1cbb3
Reviewed-on: https://go-review.googlesource.com/21006
Reviewed-by: Ian Lance Taylor &lt;iant@golang.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>all: single space after period.</title>
<updated>2016-03-02T00:13:47+00:00</updated>
<author>
<name>Brad Fitzpatrick</name>
<email>bradfitz@golang.org</email>
</author>
<published>2016-03-01T23:21:55+00:00</published>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/go-git.git/commit/?id=5fea2ccc77eb50a9704fa04b7c61755fe34e1d95'/>
<id>5fea2ccc77eb50a9704fa04b7c61755fe34e1d95</id>
<content type='text'>
The tree's pretty inconsistent about single space vs double space
after a period in documentation. Make it consistently a single space,
per earlier decisions. This means contributors won't be confused by
misleading precedence.

This CL doesn't use go/doc to parse. It only addresses // comments.
It was generated with:

$ perl -i -npe 's,^(\s*// .+[a-z]\.)  +([A-Z]),$1 $2,' $(git grep -l -E '^\s*//(.+\.)  +([A-Z])')
$ go test go/doc -update

Change-Id: Iccdb99c37c797ef1f804a94b22ba5ee4b500c4f7
Reviewed-on: https://go-review.googlesource.com/20022
Reviewed-by: Rob Pike &lt;r@golang.org&gt;
Reviewed-by: Dave Day &lt;djd@golang.org&gt;
Run-TryBot: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
The tree's pretty inconsistent about single space vs double space
after a period in documentation. Make it consistently a single space,
per earlier decisions. This means contributors won't be confused by
misleading precedence.

This CL doesn't use go/doc to parse. It only addresses // comments.
It was generated with:

$ perl -i -npe 's,^(\s*// .+[a-z]\.)  +([A-Z]),$1 $2,' $(git grep -l -E '^\s*//(.+\.)  +([A-Z])')
$ go test go/doc -update

Change-Id: Iccdb99c37c797ef1f804a94b22ba5ee4b500c4f7
Reviewed-on: https://go-review.googlesource.com/20022
Reviewed-by: Rob Pike &lt;r@golang.org&gt;
Reviewed-by: Dave Day &lt;djd@golang.org&gt;
Run-TryBot: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>runtime: add nowritebarrierrec to funcs called at signal time</title>
<updated>2016-01-08T17:26:28+00:00</updated>
<author>
<name>Ian Lance Taylor</name>
<email>iant@golang.org</email>
</author>
<published>2016-01-08T04:28:04+00:00</published>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/go-git.git/commit/?id=84a95be922f09ea6b2235da0f67bf7ba490d092a'/>
<id>84a95be922f09ea6b2235da0f67bf7ba490d092a</id>
<content type='text'>
Also nosplit where needed.

Change-Id: I1e3f6f8f76df9ee7e87ed1b8560cef145928314c
Reviewed-on: https://go-review.googlesource.com/18395
Reviewed-by: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
Run-TryBot: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Also nosplit where needed.

Change-Id: I1e3f6f8f76df9ee7e87ed1b8560cef145928314c
Reviewed-on: https://go-review.googlesource.com/18395
Reviewed-by: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
Run-TryBot: Brad Fitzpatrick &lt;bradfitz@golang.org&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>runtime: allow signal.Ignore of user-generated throwing signals</title>
<updated>2016-01-08T15:34:03+00:00</updated>
<author>
<name>Russ Cox</name>
<email>rsc@golang.org</email>
</author>
<published>2016-01-07T15:19:55+00:00</published>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/go-git.git/commit/?id=81adfa508a81e24b8257571dd717845647607cbd'/>
<id>81adfa508a81e24b8257571dd717845647607cbd</id>
<content type='text'>
Today, signal.Ignore(syscall.SIGTRAP) does nothing
while signal.Notify(make(chan os.Signal), syscall.SIGTRAP)
correctly discards user-generated SIGTRAPs.
The same applies to any signal that we throw on.

Make signal.Ignore work for these signals.

Fixes #12906.

Change-Id: Iba244813051e0ce23fa32fbad3e3fa596a941094
Reviewed-on: https://go-review.googlesource.com/18348
Reviewed-by: Ian Lance Taylor &lt;iant@golang.org&gt;
Run-TryBot: Russ Cox &lt;rsc@golang.org&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Today, signal.Ignore(syscall.SIGTRAP) does nothing
while signal.Notify(make(chan os.Signal), syscall.SIGTRAP)
correctly discards user-generated SIGTRAPs.
The same applies to any signal that we throw on.

Make signal.Ignore work for these signals.

Fixes #12906.

Change-Id: Iba244813051e0ce23fa32fbad3e3fa596a941094
Reviewed-on: https://go-review.googlesource.com/18348
Reviewed-by: Ian Lance Taylor &lt;iant@golang.org&gt;
Run-TryBot: Russ Cox &lt;rsc@golang.org&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>runtime: break atomics out into package runtime/internal/atomic</title>
<updated>2015-11-10T17:38:04+00:00</updated>
<author>
<name>Michael Matloob</name>
<email>matloob@golang.org</email>
</author>
<published>2015-11-02T19:09:24+00:00</published>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/go-git.git/commit/?id=67faca7d9c54b367aee5fdeef2d5dd609fcf99d0'/>
<id>67faca7d9c54b367aee5fdeef2d5dd609fcf99d0</id>
<content type='text'>
This change breaks out most of the atomics functions in the runtime
into package runtime/internal/atomic. It adds some basic support
in the toolchain for runtime packages, and also modifies linux/arm
atomics to remove the dependency on the runtime's mutex. The mutexes
have been replaced with spinlocks.

all trybots are happy!
In addition to the trybots, I've tested on the darwin/arm64 builder,
on the darwin/arm builder, and on a ppc64le machine.

Change-Id: I6698c8e3cf3834f55ce5824059f44d00dc8e3c2f
Reviewed-on: https://go-review.googlesource.com/14204
Run-TryBot: Michael Matloob &lt;matloob@golang.org&gt;
Reviewed-by: Russ Cox &lt;rsc@golang.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
This change breaks out most of the atomics functions in the runtime
into package runtime/internal/atomic. It adds some basic support
in the toolchain for runtime packages, and also modifies linux/arm
atomics to remove the dependency on the runtime's mutex. The mutexes
have been replaced with spinlocks.

all trybots are happy!
In addition to the trybots, I've tested on the darwin/arm64 builder,
on the darwin/arm builder, and on a ppc64le machine.

Change-Id: I6698c8e3cf3834f55ce5824059f44d00dc8e3c2f
Reviewed-on: https://go-review.googlesource.com/14204
Run-TryBot: Michael Matloob &lt;matloob@golang.org&gt;
Reviewed-by: Russ Cox &lt;rsc@golang.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>runtime, os/signal: use //go:linkname instead of assembly stubs to get access to runtime functions</title>
<updated>2015-10-16T07:11:04+00:00</updated>
<author>
<name>Michael Hudson-Doyle</name>
<email>michael.hudson@canonical.com</email>
</author>
<published>2015-10-15T20:56:07+00:00</published>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/go-git.git/commit/?id=0b8d583320b2f6247669ef0bb1ba011054ca1c88'/>
<id>0b8d583320b2f6247669ef0bb1ba011054ca1c88</id>
<content type='text'>
os/signal depends on a few unexported runtime functions. This removes the
assembly stubs it used to get access to these in favour of using
//go:linkname in runtime to make the functions accessible to os/signal.

This is motivated by ppc64le shared libraries, where you cannot BR to a symbol
defined in a shared library (only BL), but it seems like an improvment anyway.

Change-Id: I09361203ce38070bd3f132f6dc5ac212f2dc6f58
Reviewed-on: https://go-review.googlesource.com/15871
Run-TryBot: Michael Hudson-Doyle &lt;michael.hudson@canonical.com&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
Reviewed-by: Minux Ma &lt;minux@golang.org&gt;
Reviewed-by: Dave Cheney &lt;dave@cheney.net&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
os/signal depends on a few unexported runtime functions. This removes the
assembly stubs it used to get access to these in favour of using
//go:linkname in runtime to make the functions accessible to os/signal.

This is motivated by ppc64le shared libraries, where you cannot BR to a symbol
defined in a shared library (only BL), but it seems like an improvment anyway.

Change-Id: I09361203ce38070bd3f132f6dc5ac212f2dc6f58
Reviewed-on: https://go-review.googlesource.com/15871
Run-TryBot: Michael Hudson-Doyle &lt;michael.hudson@canonical.com&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
Reviewed-by: Minux Ma &lt;minux@golang.org&gt;
Reviewed-by: Dave Cheney &lt;dave@cheney.net&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>runtime: remove always false comparison in sigsend</title>
<updated>2015-08-26T01:02:55+00:00</updated>
<author>
<name>Todd Neal</name>
<email>todd@tneal.org</email>
</author>
<published>2015-08-25T23:25:42+00:00</published>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/go-git.git/commit/?id=a94e906c41e83b663cd51751cbb74e801a54aba8'/>
<id>a94e906c41e83b663cd51751cbb74e801a54aba8</id>
<content type='text'>
s is a uint32 and can never be zero. It's max value is already tested
against sig.wanted, whose size is derived from _NSIG.  This also
matches the test in signal_enable.

Fixes #11282

Change-Id: I8eec9c7df8eb8682433616462fe51b264c092475
Reviewed-on: https://go-review.googlesource.com/13940
Reviewed-by: Ian Lance Taylor &lt;iant@golang.org&gt;
Run-TryBot: Ian Lance Taylor &lt;iant@golang.org&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
s is a uint32 and can never be zero. It's max value is already tested
against sig.wanted, whose size is derived from _NSIG.  This also
matches the test in signal_enable.

Fixes #11282

Change-Id: I8eec9c7df8eb8682433616462fe51b264c092475
Reviewed-on: https://go-review.googlesource.com/13940
Reviewed-by: Ian Lance Taylor &lt;iant@golang.org&gt;
Run-TryBot: Ian Lance Taylor &lt;iant@golang.org&gt;
TryBot-Result: Gobot Gobot &lt;gobot@golang.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>runtime/cgo: make compatible with race detector</title>
<updated>2015-07-22T20:28:47+00:00</updated>
<author>
<name>Russ Cox</name>
<email>rsc@golang.org</email>
</author>
<published>2015-07-22T19:31:54+00:00</published>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/go-git.git/commit/?id=75d779566b75fc1a09239bfbca40b6dba42000fd'/>
<id>75d779566b75fc1a09239bfbca40b6dba42000fd</id>
<content type='text'>
Some routines run without and m or g and cannot invoke the
race detector runtime. They must be opaque to the runtime.
That used to be true because they were written in C.
Now that they are written in Go, disable the race detector
annotations for those functions explicitly.

Add test.

Fixes #10874.

Change-Id: Ia8cc28d51e7051528f9f9594b75634e6bb66a785
Reviewed-on: https://go-review.googlesource.com/12534
Reviewed-by: Ian Lance Taylor &lt;iant@golang.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Some routines run without and m or g and cannot invoke the
race detector runtime. They must be opaque to the runtime.
That used to be true because they were written in C.
Now that they are written in Go, disable the race detector
annotations for those functions explicitly.

Add test.

Fixes #10874.

Change-Id: Ia8cc28d51e7051528f9f9594b75634e6bb66a785
Reviewed-on: https://go-review.googlesource.com/12534
Reviewed-by: Ian Lance Taylor &lt;iant@golang.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>runtime: if we don't handle a signal on a non-Go thread, raise it</title>
<updated>2015-07-22T20:26:29+00:00</updated>
<author>
<name>Ian Lance Taylor</name>
<email>iant@golang.org</email>
</author>
<published>2015-07-22T05:34:48+00:00</published>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/go-git.git/commit/?id=872b168fe344914550c29b4f1b0cac9f2e70e7fc'/>
<id>872b168fe344914550c29b4f1b0cac9f2e70e7fc</id>
<content type='text'>
In the past badsignal would crash the program.  In
https://golang.org/cl/10757044 badsignal was changed to call sigsend,
to fix issue #3250.  The effect of this was that when a non-Go thread
received a signal, and os/signal.Notify was not being used to check
for occurrences of the signal, the signal was ignored.

This changes the code so that if os/signal.Notify is not being used,
then the signal handler is reset to what it was, and the signal is
raised again.  This lets non-Go threads handle the signal as they
wish.  In particular, it means that a segmentation violation in a
non-Go thread will ordinarily crash the process, as it should.

Fixes #10139.
Update #11794.

Change-Id: I2109444aaada9d963ad03b1d071ec667760515e5
Reviewed-on: https://go-review.googlesource.com/12503
Reviewed-by: Russ Cox &lt;rsc@golang.org&gt;
Run-TryBot: Ian Lance Taylor &lt;iant@golang.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
In the past badsignal would crash the program.  In
https://golang.org/cl/10757044 badsignal was changed to call sigsend,
to fix issue #3250.  The effect of this was that when a non-Go thread
received a signal, and os/signal.Notify was not being used to check
for occurrences of the signal, the signal was ignored.

This changes the code so that if os/signal.Notify is not being used,
then the signal handler is reset to what it was, and the signal is
raised again.  This lets non-Go threads handle the signal as they
wish.  In particular, it means that a segmentation violation in a
non-Go thread will ordinarily crash the process, as it should.

Fixes #10139.
Update #11794.

Change-Id: I2109444aaada9d963ad03b1d071ec667760515e5
Reviewed-on: https://go-review.googlesource.com/12503
Reviewed-by: Russ Cox &lt;rsc@golang.org&gt;
Run-TryBot: Ian Lance Taylor &lt;iant@golang.org&gt;
</pre>
</div>
</content>
</entry>
<entry>
<title>runtime: initialize extra M for cgo during mstart</title>
<updated>2015-03-24T19:39:46+00:00</updated>
<author>
<name>David Crawshaw</name>
<email>crawshaw@golang.org</email>
</author>
<published>2015-03-24T13:22:35+00:00</published>
<link rel='alternate' type='text/html' href='http://trove.baserock.org/cgit/delta/go-git.git/commit/?id=b8caed823b39b5a86b694f9ec60a8b43323248e8'/>
<id>b8caed823b39b5a86b694f9ec60a8b43323248e8</id>
<content type='text'>
Previously the extra m needed for cgo callbacks was created on the
first callback. This works for cgo, however the cgocallback mechanism
is also borrowed by badsignal which can run before any cgo calls are
made.

Now we initialize the extra M at runtime startup before any signal
handlers are registered, so badsignal cannot be called until the
extra M is ready.

Updates #10207.

Change-Id: Iddda2c80db6dc52d8b60e2b269670fbaa704c7b3
Reviewed-on: https://go-review.googlesource.com/7978
Reviewed-by: Ian Lance Taylor &lt;iant@golang.org&gt;
Run-TryBot: David Crawshaw &lt;crawshaw@golang.org&gt;
</content>
<content type='xhtml'>
<div xmlns='http://www.w3.org/1999/xhtml'>
<pre>
Previously the extra m needed for cgo callbacks was created on the
first callback. This works for cgo, however the cgocallback mechanism
is also borrowed by badsignal which can run before any cgo calls are
made.

Now we initialize the extra M at runtime startup before any signal
handlers are registered, so badsignal cannot be called until the
extra M is ready.

Updates #10207.

Change-Id: Iddda2c80db6dc52d8b60e2b269670fbaa704c7b3
Reviewed-on: https://go-review.googlesource.com/7978
Reviewed-by: Ian Lance Taylor &lt;iant@golang.org&gt;
Run-TryBot: David Crawshaw &lt;crawshaw@golang.org&gt;
</pre>
</div>
</content>
</entry>
</feed>
