runtime: scan register backing store on ia64
[official-gcc.git] / libgo / go / runtime / rdebug.go
blob76535a905acc1ca8a32c9ffc4c6edb7c578ae78c
1 // 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.
5 package runtime
7 import _ "unsafe" // for go:linkname
9 // Define maxstacksize here for gccgo. For gc it is defined in
10 // stack.go, but gccgo doesn't use that file. Or, for that matter,
11 // maxstacksize.
12 var maxstacksize uintptr = 1 << 20 // enough until runtime.main sets it for real
14 //go:linkname setMaxStack runtime_debug.setMaxStack
15 func setMaxStack(in int) (out int) {
16 out = int(maxstacksize)
17 maxstacksize = uintptr(in)
18 return out
21 //go:linkname setPanicOnFault runtime_debug.setPanicOnFault
22 func setPanicOnFault(new bool) (old bool) {
23 _g_ := getg()
24 old = _g_.paniconfault
25 _g_.paniconfault = new
26 return old