asm_linux_s390x.s 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657
  1. // Copyright 2016 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. //go:build linux && s390x && gc
  5. // +build linux
  6. // +build s390x
  7. // +build gc
  8. #include "textflag.h"
  9. //
  10. // System calls for s390x, Linux
  11. //
  12. // Just jump to package syscall's implementation for all these functions.
  13. // The runtime may know about them.
  14. TEXT ·Syscall(SB),NOSPLIT,$0-56
  15. BR syscall·Syscall(SB)
  16. TEXT ·Syscall6(SB),NOSPLIT,$0-80
  17. BR syscall·Syscall6(SB)
  18. TEXT ·SyscallNoError(SB),NOSPLIT,$0-48
  19. BL runtime·entersyscall(SB)
  20. MOVD a1+8(FP), R2
  21. MOVD a2+16(FP), R3
  22. MOVD a3+24(FP), R4
  23. MOVD $0, R5
  24. MOVD $0, R6
  25. MOVD $0, R7
  26. MOVD trap+0(FP), R1 // syscall entry
  27. SYSCALL
  28. MOVD R2, r1+32(FP)
  29. MOVD R3, r2+40(FP)
  30. BL runtime·exitsyscall(SB)
  31. RET
  32. TEXT ·RawSyscall(SB),NOSPLIT,$0-56
  33. BR syscall·RawSyscall(SB)
  34. TEXT ·RawSyscall6(SB),NOSPLIT,$0-80
  35. BR syscall·RawSyscall6(SB)
  36. TEXT ·RawSyscallNoError(SB),NOSPLIT,$0-48
  37. MOVD a1+8(FP), R2
  38. MOVD a2+16(FP), R3
  39. MOVD a3+24(FP), R4
  40. MOVD $0, R5
  41. MOVD $0, R6
  42. MOVD $0, R7
  43. MOVD trap+0(FP), R1 // syscall entry
  44. SYSCALL
  45. MOVD R2, r1+32(FP)
  46. MOVD R3, r2+40(FP)
  47. RET