mirror of
https://github.com/golang/go.git
synced 2025-12-08 06:10:04 +00:00
net: remove the alloc from ReadMsgUDPAddrPort
name old time/op new time/op delta ReadWriteMsgUDPAddrPort-8 4.95µs ± 5% 4.55µs ± 1% -7.96% (p=0.016 n=5+4) name old alloc/op new alloc/op delta ReadWriteMsgUDPAddrPort-8 32.0B ± 0% 0.0B -100.00% (p=0.008 n=5+5) name old allocs/op new allocs/op delta ReadWriteMsgUDPAddrPort-8 1.00 ± 0% 0.00 -100.00% (p=0.008 n=5+5) Change-Id: Ib968c6f2968926ec9a364dd52063cd0d7c29b10c Reviewed-on: https://go-review.googlesource.com/c/go/+/360862 Trust: Josh Bleecher Snyder <josharian@gmail.com> Run-TryBot: Josh Bleecher Snyder <josharian@gmail.com> TryBot-Result: Go Bot <gobot@golang.org> Reviewed-by: Ian Lance Taylor <iant@golang.org>
This commit is contained in:
parent
bfd74fd422
commit
37634eeff9
8 changed files with 195 additions and 13 deletions
|
|
@ -34,3 +34,11 @@ func SendmsgNInet4(fd int, p, oob []byte, to syscall.SockaddrInet4, flags int) (
|
|||
//go:linkname SendmsgNInet6 syscall.sendmsgNInet6
|
||||
//go:noescape
|
||||
func SendmsgNInet6(fd int, p, oob []byte, to syscall.SockaddrInet6, flags int) (n int, err error)
|
||||
|
||||
//go:linkname RecvmsgInet4 syscall.recvmsgInet4
|
||||
//go:noescape
|
||||
func RecvmsgInet4(fd int, p, oob []byte, flags int, from *syscall.SockaddrInet4) (n, oobn int, recvflags int, err error)
|
||||
|
||||
//go:linkname RecvmsgInet6 syscall.recvmsgInet6
|
||||
//go:noescape
|
||||
func RecvmsgInet6(fd int, p, oob []byte, flags int, from *syscall.SockaddrInet6) (n, oobn int, recvflags int, err error)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue