1
0
mirror of https://github.com/golang/go synced 2024-09-29 01:24:34 -06:00

runtime: remove unused pipe and setNonblock on linux/loong64

CL 389354 removed the fallback to pipe on all platforms with pipe2. This
is the case for linux. Thus, pipe and setNonblock are no longer needed
on linux/loong64 too.

Change-Id: I089adf918d0fd8de5d4d61a893707a2660f89183
Reviewed-on: https://go-review.googlesource.com/c/go/+/410736
Reviewed-by: Ian Lance Taylor <iant@google.com>
Auto-Submit: Tobias Klauser <tobias.klauser@gmail.com>
Auto-Submit: Ian Lance Taylor <iant@google.com>
Run-TryBot: Ian Lance Taylor <iant@google.com>
Reviewed-by: Dmitri Shuralyov <dmitshur@google.com>
TryBot-Result: Gopher Robot <gobot@golang.org>
This commit is contained in:
Tobias Klauser 2022-06-07 07:25:10 +02:00 committed by Gopher Robot
parent decdd87bea
commit 2882786bf4
2 changed files with 0 additions and 25 deletions

View File

@ -10,7 +10,6 @@ const (
_EINTR = 0x4
_EAGAIN = 0xb
_ENOMEM = 0xc
_ENOSYS = 0x26
_PROT_NONE = 0x0
_PROT_READ = 0x1

View File

@ -107,15 +107,6 @@ TEXT runtime·read(SB),NOSPLIT|NOFRAME,$0-28
MOVW R4, ret+24(FP)
RET
// func pipe() (r, w int32, errno int32)
TEXT runtime·pipe(SB),NOSPLIT|NOFRAME,$0-12
MOVV $r+0(FP), R4
MOVV R0, R5
MOVV $SYS_pipe2, R11
SYSCALL
MOVW R4, errno+8(FP)
RET
// func pipe2(flags int32) (r, w int32, errno int32)
TEXT runtime·pipe2(SB),NOSPLIT|NOFRAME,$0-20
MOVV $r+8(FP), R4
@ -591,21 +582,6 @@ TEXT runtime·closeonexec(SB),NOSPLIT|NOFRAME,$0
SYSCALL
RET
// func runtime·setNonblock(int32 fd)
TEXT runtime·setNonblock(SB),NOSPLIT|NOFRAME,$0-4
MOVW fd+0(FP), R4 // fd
MOVV $3, R5 // F_GETFL
MOVV $0, R6
MOVV $SYS_fcntl, R11
SYSCALL
MOVW $0x800, R6 // O_NONBLOCK
OR R4, R6
MOVW fd+0(FP), R4 // fd
MOVV $4, R5 // F_SETFL
MOVV $SYS_fcntl, R11
SYSCALL
RET
// func sbrk0() uintptr
TEXT runtime·sbrk0(SB),NOSPLIT|NOFRAME,$0-8
// Implemented as brk(NULL).