Sorry, I have lots of CLs. This is already deprecated (and, yes, it is a ...
11 years, 1 month ago
(2013-03-12 16:44:08 UTC)
#2
Sorry, I have lots of CLs. This is already deprecated (and, yes, it is a mess).
The part that removes duplication in fd_unix and fd_linux is already upstreamed.
The alive CLs are:
7448048: runtime: add network polling support into scheduler (already LGTMed)
7569043: runtime: integrated network poller for darwin (in review)
7579044: runtime: integrated network poller for linux (not yet mailed but ready
for review, missing linux/arm syscalls)
On 2013/03/12 16:09:57, rsc wrote:
> I don't know if you were ready for me to look at this - it was linked from the
> other CL. In order to get this merged into the main tree the duplication in
> fd_linux_amd64.go needs to be removed. We need to refactor things so that
> there's only one copy of the code from fd_unix.go (maybe still in fd_unix.go).
>
> https://codereview.appspot.com/7326051/diff/10002/src/pkg/net/fd_linux.go
> File src/pkg/net/fd_linux.go (right):
>
>
https://codereview.appspot.com/7326051/diff/10002/src/pkg/net/fd_linux.go#new...
> src/pkg/net/fd_linux.go:5: // +build 386
> Is arm going to happen too? Or is this just 386-specific?
> If the latter, make the file fd_linux_arm.go.
>
>
https://codereview.appspot.com/7326051/diff/10002/src/pkg/net/fd_linux_amd64.go
> File src/pkg/net/fd_linux_amd64.go (right):
>
>
https://codereview.appspot.com/7326051/diff/10002/src/pkg/net/fd_linux_amd64....
> src/pkg/net/fd_linux_amd64.go:5: // +build linux,amd64
> This is redundant with the file name.
>
>
https://codereview.appspot.com/7326051/diff/10002/src/pkg/net/fd_linux_amd64....
> src/pkg/net/fd_linux_amd64.go:323: func (fd *netFD) Write(p []byte) (int,
error)
> {
> There's a lot of logic in this file that I'd like to not duplicate once for
> every architecture and operating system combination. Can most of it be
factored
> out into common code?