Yao Zhang | 980b00f | 2015-09-23 14:05:16 -0400 | [diff] [blame] | 1 | // Copyright 2015 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 mips64 mips64le |
| 6 | |
| 7 | package runtime |
| 8 | |
| 9 | import "unsafe" |
| 10 | |
| 11 | // adjust Gobuf as if it executed a call to fn with context ctxt |
| 12 | // and then did an immediate Gosave. |
| 13 | func gostartcall(buf *gobuf, fn, ctxt unsafe.Pointer) { |
| 14 | if buf.lr != 0 { |
| 15 | throw("invalid use of gostartcall") |
| 16 | } |
| 17 | buf.lr = buf.pc |
| 18 | buf.pc = uintptr(fn) |
| 19 | buf.ctxt = ctxt |
| 20 | } |