blob: 649e58714d9cb3314a948ee58c21da903f25b218 [file] [log] [blame]
Matthias Andreas Benkard832a54e2019-01-29 09:27:38 +01001// Copyright 2014 The Go Authors. All rights reserved.
2// Use of this source code is governed by a BSD-style
3// license that can be found in the LICENSE file.
4
5// +build linux
6// +build ppc64 ppc64le
7// +build !gccgo
8
9#include "textflag.h"
10
11//
12// System calls for ppc64, Linux
13//
14
15// Just jump to package syscall's implementation for all these functions.
16// The runtime may know about them.
17
18TEXT ·Syscall(SB),NOSPLIT,$0-56
19 BR syscall·Syscall(SB)
20
21TEXT ·Syscall6(SB),NOSPLIT,$0-80
22 BR syscall·Syscall6(SB)
23
24TEXT ·SyscallNoError(SB),NOSPLIT,$0-48
25 BL runtime·entersyscall(SB)
26 MOVD a1+8(FP), R3
27 MOVD a2+16(FP), R4
28 MOVD a3+24(FP), R5
29 MOVD R0, R6
30 MOVD R0, R7
31 MOVD R0, R8
32 MOVD trap+0(FP), R9 // syscall entry
33 SYSCALL R9
34 MOVD R3, r1+32(FP)
35 MOVD R4, r2+40(FP)
36 BL runtime·exitsyscall(SB)
37 RET
38
39TEXT ·RawSyscall(SB),NOSPLIT,$0-56
40 BR syscall·RawSyscall(SB)
41
42TEXT ·RawSyscall6(SB),NOSPLIT,$0-80
43 BR syscall·RawSyscall6(SB)
44
45TEXT ·RawSyscallNoError(SB),NOSPLIT,$0-48
46 MOVD a1+8(FP), R3
47 MOVD a2+16(FP), R4
48 MOVD a3+24(FP), R5
49 MOVD R0, R6
50 MOVD R0, R7
51 MOVD R0, R8
52 MOVD trap+0(FP), R9 // syscall entry
53 SYSCALL R9
54 MOVD R3, r1+32(FP)
55 MOVD R4, r2+40(FP)
56 RET