commit | a2a45943ae67364d56c5d7d62dee78cff16c8dc8 | [log] [tgz] |
---|---|---|
author | Jason A. Donenfeld <Jason@zx2c4.com> | Thu Apr 19 23:46:52 2018 +0200 |
committer | Brad Fitzpatrick <bradfitz@golang.org> | Thu Apr 19 22:20:23 2018 +0000 |
tree | 54f5934ee1229094e1161a2e846839bb182618b8 | |
parent | 3ccc7e5779793fd54564baf60c51bf017955e0ba [diff] |
unix: avoid extra syscall on send/recvmsg on Linux By simply rearranging the logic, we avoid the overhead of a superfluous call to getsockopt. For, if p is already non empty, there's no point in having to check if we need to attach dummy payload. This has performance benefits when using send/recvmsg for high speed communications. Change-Id: If47ab5322464aad8e6d2603a369e95327223211f Reviewed-on: https://go-review.googlesource.com/108337 Reviewed-by: Brad Fitzpatrick <bradfitz@golang.org> Run-TryBot: Brad Fitzpatrick <bradfitz@golang.org> TryBot-Result: Gobot Gobot <gobot@golang.org>
This repository holds supplemental Go packages for low-level interactions with the operating system.
The easiest way to install is to run go get -u golang.org/x/sys
. You can also manually git clone the repository to $GOPATH/src/golang.org/x/sys
.
This repository uses Gerrit for code changes. To learn how to submit changes to this repository, see https://golang.org/doc/contribute.html.
The main issue tracker for the sys repository is located at https://github.com/golang/go/issues. Prefix your issue with “x/sys:” in the subject line, so it is easy to find.