gcc/libgo/go/runtime
Ian Lance Taylor 58f7dab40d runtime: copy mstats code from Go 1.7 runtime
This replaces mem.go and the C runtime_ReadMemStats function with the Go
    1.7 mstats.go.
    
    The GCStats code is commented out for now.  The corresponding gccgo code
    is in runtime/mgc0.c.
    
    The variables memstats and worldsema are shared between the Go code and
    the C code, but are not exported.  To make this work, add temporary
    accessor functions acquireWorldsema, releaseWorldsema, getMstats (the
    latter known as mstats in the C code).
    
    Check the preemptoff field of m when allocating and when considering
    whether to start a GC.  This works with the new stopTheWorld and
    startTheWorld functions in Go, which are essentially the Go 1.7
    versions.
    
    Change the compiler to stack allocate closures when compiling the
    runtime package.  Within the runtime packages closures do not escape.
    This is similar to what the gc compiler does, except that the gc
    compiler, when compiling the runtime package, gives an error if escape
    analysis shows that a closure does escape.  I added this here because
    the Go version of ReadMemStats calls systemstack with a closure, and
    having that allocate memory was causing some tests that measure memory
    allocations to fail.
    
    Reviewed-on: https://go-review.googlesource.com/30972

From-SVN: r241124
2016-10-13 15:24:50 +00:00
..
debug libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
internal runtime/internal/sys: new package, API copied from Go 1.7 2016-09-11 13:23:27 +00:00
msan libgo: Update to go1.6rc1. 2016-02-03 21:58:02 +00:00
pprof libgo: update to Go 1.7.1 release 2016-09-10 13:14:00 +00:00
race libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
testdata libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
append_test.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
callers_test.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
cgo_mmap.go libgo: change build procedure to use build tags 2016-08-06 00:36:33 +00:00
cgocheck.go libgo: change build procedure to use build tags 2016-08-06 00:36:33 +00:00
chan.go runtime: copy channel code from Go 1.7 runtime 2016-10-10 16:52:09 +00:00
chan_test.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
chanbarrier_test.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
closure_test.go
compiler.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
complex_test.go
cputicks.go runtime: copy runtime.go and runtime1.go from Go 1.7 2016-09-29 00:56:44 +00:00
crash_cgo_test.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
crash_nonunix_test.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
crash_test.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
crash_unix_test.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
debug.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
env_posix.go runtime: copy runtime.go and runtime1.go from Go 1.7 2016-09-29 00:56:44 +00:00
env_test.go runtime: Remove now unnecessary pad field from ParFor. 2015-10-31 00:59:47 +00:00
error.go compiler, runtime: copy string code from Go 1.7 2016-10-12 18:17:52 +00:00
export_arm_test.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
export_linux_test.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
export_mmap_test.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
export_test.go runtime: copy internal locking code from Go 1.7 runtime 2016-09-30 13:45:08 +00:00
export_windows_test.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
extern.go runtime/internal/sys: new package, API copied from Go 1.7 2016-09-11 13:23:27 +00:00
fastlog2.go libgo: change build procedure to use build tags 2016-08-06 00:36:33 +00:00
fastlog2_test.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
fastlog2table.go libgo: change build procedure to use build tags 2016-08-06 00:36:33 +00:00
gc_test.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
gcinfo_test.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
hashmap.go compiler, runtime: replace hashmap code with Go 1.7 hashmap 2016-09-21 20:58:51 +00:00
hashmap_fast.go compiler, runtime: replace hashmap code with Go 1.7 hashmap 2016-09-21 20:58:51 +00:00
iface_test.go runtime: Remove now unnecessary pad field from ParFor. 2015-10-31 00:59:47 +00:00
lfstack_64bit.go libgo: change build procedure to use build tags 2016-08-06 00:36:33 +00:00
lfstack_test.go runtime: Remove now unnecessary pad field from ParFor. 2015-10-31 00:59:47 +00:00
lock_futex.go runtime: copy internal locking code from Go 1.7 runtime 2016-09-30 13:45:08 +00:00
lock_sema.go runtime: copy internal locking code from Go 1.7 runtime 2016-09-30 13:45:08 +00:00
malloc_test.go libgo: Update to go1.6rc1. 2016-02-03 21:58:02 +00:00
map_test.go compiler, runtime: replace hashmap code with Go 1.7 hashmap 2016-09-21 20:58:51 +00:00
mapspeed_test.go runtime: Remove now unnecessary pad field from ParFor. 2015-10-31 00:59:47 +00:00
mcache.go runtime: use -fgo-c-header to build C header file 2016-08-30 21:07:47 +00:00
mfinal_test.go runtime: Remove now unnecessary pad field from ParFor. 2015-10-31 00:59:47 +00:00
mkfastlog2table.go libgo: Update to go1.6rc1. 2016-02-03 21:58:02 +00:00
mmap.go libgo: change build procedure to use build tags 2016-08-06 00:36:33 +00:00
msan0.go compiler, runtime: replace hashmap code with Go 1.7 hashmap 2016-09-21 20:58:51 +00:00
mstats.go runtime: copy mstats code from Go 1.7 runtime 2016-10-13 15:24:50 +00:00
mstkbar.go libgo: change build procedure to use build tags 2016-08-06 00:36:33 +00:00
norace_test.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
os_darwin.go runtime: copy internal locking code from Go 1.7 runtime 2016-09-30 13:45:08 +00:00
os_dragonfly.go runtime: copy internal locking code from Go 1.7 runtime 2016-09-30 13:45:08 +00:00
os_freebsd.go runtime: copy internal locking code from Go 1.7 runtime 2016-09-30 13:45:08 +00:00
os_linux.go runtime: copy internal locking code from Go 1.7 runtime 2016-09-30 13:45:08 +00:00
os_netbsd.go runtime: copy internal locking code from Go 1.7 runtime 2016-09-30 13:45:08 +00:00
os_openbsd.go runtime: copy internal locking code from Go 1.7 runtime 2016-09-30 13:45:08 +00:00
os_solaris.go runtime: copy internal locking code from Go 1.7 runtime 2016-09-30 13:45:08 +00:00
print.go runtime: copy print/println support from Go 1.7 2016-10-10 23:13:39 +00:00
proc_runtime_test.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
proc_test.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
race0.go compiler, runtime: replace hashmap code with Go 1.7 hashmap 2016-09-21 20:58:51 +00:00
rune.go compiler, runtime: copy string code from Go 1.7 2016-10-12 18:17:52 +00:00
runtime-lldb_test.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
runtime.go runtime: copy runtime.go and runtime1.go from Go 1.7 2016-09-29 00:56:44 +00:00
runtime1.go runtime: copy runtime.go and runtime1.go from Go 1.7 2016-09-29 00:56:44 +00:00
runtime2.go runtime: copy print/println support from Go 1.7 2016-10-10 23:13:39 +00:00
runtime_mmap_test.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
runtime_test.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
runtime_unix_test.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
select.go runtime: copy channel code from Go 1.7 runtime 2016-10-10 16:52:09 +00:00
sema.go runtime: copy Go 1.7 runtime semaphore code 2016-10-12 15:38:56 +00:00
signal2_unix.go libgo: change build procedure to use build tags 2016-08-06 00:36:33 +00:00
signal_sigtramp.go libgo: change build procedure to use build tags 2016-08-06 00:36:33 +00:00
stack.go libgo: change build procedure to use build tags 2016-08-06 00:36:33 +00:00
string.go compiler, runtime: copy string code from Go 1.7 2016-10-12 18:17:52 +00:00
string_test.go compiler, runtime: copy string code from Go 1.7 2016-10-12 18:17:52 +00:00
stubs.go runtime: copy mstats code from Go 1.7 runtime 2016-10-13 15:24:50 +00:00
stubs2.go runtime: copy runtime.go and runtime1.go from Go 1.7 2016-09-29 00:56:44 +00:00
symtab.go libgo: update to go1.7rc3 2016-07-22 18:15:38 +00:00
symtab_test.go runtime: Remove now unnecessary pad field from ParFor. 2015-10-31 00:59:47 +00:00
trace.go runtime: copy channel code from Go 1.7 runtime 2016-10-10 16:52:09 +00:00
type.go compiler, runtime: replace hashmap code with Go 1.7 hashmap 2016-09-21 20:58:51 +00:00
typekind.go compiler, runtime: replace hashmap code with Go 1.7 hashmap 2016-09-21 20:58:51 +00:00
vdso_none.go runtime: copy runtime.go and runtime1.go from Go 1.7 2016-09-29 00:56:44 +00:00
write_err.go Accidentally failed to commit these earlier, as part of: 2016-10-11 00:08:35 +00:00
write_err_android.go Accidentally failed to commit these earlier, as part of: 2016-10-11 00:08:35 +00:00