diff options
author | Peter Collingbourne <peter@pcc.me.uk> | 2015-04-05 23:30:42 +0000 |
---|---|---|
committer | Peter Collingbourne <peter@pcc.me.uk> | 2015-04-05 23:30:42 +0000 |
commit | 93c73ebcbd73f5436d13ffc41f49a86fc062deb8 (patch) | |
tree | 10bf9fb3a1314fc8a1c3b963b4550960718384ad /llgo/third_party/gofrontend/libgo/go/runtime/rdebug.go | |
parent | 7d39641c805bf3263ffb55a23ecf4bbfd37402c0 (diff) | |
download | bcm5719-llvm-93c73ebcbd73f5436d13ffc41f49a86fc062deb8.tar.gz bcm5719-llvm-93c73ebcbd73f5436d13ffc41f49a86fc062deb8.zip |
Roll gofrontend to a6e10414311a
This takes us to Go 1.4. Also includes a couple of changes to the test
suite, both in the runtime package:
- Disable TestSetPanicOnFault. We cannot support this scenario at all,
due to LLVM's lack of non-call exceptions.
- Tweak TestFinalizerType. This test only passes with two GC runs.
Differential Revision: http://reviews.llvm.org/D8828
llvm-svn: 234134
Diffstat (limited to 'llgo/third_party/gofrontend/libgo/go/runtime/rdebug.go')
-rw-r--r-- | llgo/third_party/gofrontend/libgo/go/runtime/rdebug.go | 37 |
1 files changed, 37 insertions, 0 deletions
diff --git a/llgo/third_party/gofrontend/libgo/go/runtime/rdebug.go b/llgo/third_party/gofrontend/libgo/go/runtime/rdebug.go new file mode 100644 index 00000000000..e5e691122c6 --- /dev/null +++ b/llgo/third_party/gofrontend/libgo/go/runtime/rdebug.go @@ -0,0 +1,37 @@ +// Copyright 2014 The Go Authors. All rights reserved. +// Use of this source code is governed by a BSD-style +// license that can be found in the LICENSE file. + +package runtime + +func setMaxStack(in int) (out int) { + out = int(maxstacksize) + maxstacksize = uintptr(in) + return out +} + +func setGCPercent(in int32) (out int32) { + mp := acquirem() + mp.scalararg[0] = uintptr(int(in)) + onM(setgcpercent_m) + out = int32(int(mp.scalararg[0])) + releasem(mp) + return out +} + +func setPanicOnFault(new bool) (old bool) { + mp := acquirem() + old = mp.curg.paniconfault + mp.curg.paniconfault = new + releasem(mp) + return old +} + +func setMaxThreads(in int) (out int) { + mp := acquirem() + mp.scalararg[0] = uintptr(in) + onM(setmaxthreads_m) + out = int(mp.scalararg[0]) + releasem(mp) + return out +} |