summaryrefslogtreecommitdiff
path: root/src/pkg/runtime/proc.c
AgeCommit message (Collapse)AuthorFilesLines
2011-09-13Imported Upstream version 60upstream/60Ondřej Surý1-0/+1568
2011-09-13Imported Upstream version 60Ondřej Surý1-1368/+0
2011-08-03Imported Upstream version 59upstream/59Ondřej Surý1-1/+1
2011-06-30Imported Upstream version 58upstream/58Ondřej Surý1-6/+29
2011-04-28Imported Upstream version 2011.04.27upstream/2011.04.27Ondřej Surý1-6/+38
2011-04-26Imported Upstream version 2011.04.13upstream/2011.04.13Ondřej Surý1-157/+210
2011-04-20Imported Upstream version 2011.03.07.1upstream/2011.03.07.1Ondřej Surý1-27/+87
2011-02-18Imported Upstream version 2011.02.15upstream/2011.02.15Ondřej Surý1-3/+3
2011-02-14Imported Upstream version 2011-02-01.1upstream/2011-02-01.1Ondřej Surý1-125/+86
2011-01-17Imported Upstream version 2011.01.12upstream/2011.01.12Ondřej Surý1-242/+303
2010-06-29runtime: fix scheduling bug - world wasn't stoppingRuss Cox1-1/+1
Fixes issue 886. R=r CC=golang-dev http://codereview.appspot.com/1667051
2010-05-06Save the scheduling state even predawn.Ian Lance Taylor1-4/+4
This permits cgo callbacks to work when run in init code. Otherwise cgocallback switches to the wrong stack address. R=rsc CC=golang-dev http://codereview.appspot.com/1123043
2010-05-06runtime.GOMAXPROCS: hack it to have it return the old value.Rob Pike1-5/+8
R=rsc CC=golang-dev http://codereview.appspot.com/1140041
2010-04-21runtime: switch state back to Grunning after recoveryRuss Cox1-1/+2
Fixes issue 733. R=r CC=golang-dev http://codereview.appspot.com/958041
2010-04-09Library support for cgo export.Ian Lance Taylor1-2/+24
These functions are used to call from a C function back to a Go function. This only includes 386 support. R=rsc CC=golang-dev http://codereview.appspot.com/834045
2010-04-08runtime: fix bad status throwRuss Cox1-3/+6
when garbage collector sees recovering goroutine Fixes issue 711. R=r CC=golang-dev http://codereview.appspot.com/869045
2010-04-06runtime: two proc bug fixesRuss Cox1-6/+13
1. Fix bug in GOMAXPROCS when trying to cut number of procs Race could happen on any system but was manifesting only on Xen hosted Linux. 2. Fix recover on ARM, where FP != caller SP. R=r CC=golang-dev http://codereview.appspot.com/880043
2010-04-05runtime: various arm fixesRuss Cox1-4/+5
* correct symbol table size * do not reorder functions in output * traceback * signal handling * use same code for go + defer * handle leaf functions in symbol table R=kaib, dpx CC=golang-dev http://codereview.appspot.com/884041
2010-03-31runtime: make type assertion a runtime.Error, the first of manyRuss Cox1-1/+1
R=r CC=golang-dev http://codereview.appspot.com/805043
2010-03-31gc: implement panic and recoverRuss Cox1-1/+165
R=ken2, r, ken3 CC=golang-dev http://codereview.appspot.com/831042
2010-03-29runtime: run deferred calls at GoexitRuss Cox1-34/+90
baby step toward panic+recover. Fixes issue 349. R=r CC=golang-dev http://codereview.appspot.com/825043
2010-03-26runtime: run all finalizers in a single goroutine.Russ Cox1-1/+2
eliminate second pass of mark+sweep by scanning finalizer table specially. R=r CC=golang-dev http://codereview.appspot.com/782041
2010-03-24runtime: malloc sampling, pprof interfaceRuss Cox1-0/+3
R=r CC=golang-dev http://codereview.appspot.com/719041
2010-03-04cc: disallow ... argument unless NOSPLIT is set.Russ Cox1-4/+6
check that NOSPLIT functions don't use too much stack. correct some missing NOSPLITs in the runtime library. Fixes bug reported in https://groups.google.com/group/golang-nuts/t/efff68b73941eccf R=ken2 CC=golang-dev http://codereview.appspot.com/236041
2010-02-10runtime: garbage collection + malloc performanceRuss Cox1-20/+16
* add bit tracking finalizer status, avoiding getfinalizer lookup * add ability to allocate uncleared memory R=iant CC=golang-dev http://codereview.appspot.com/207044
2010-02-08runtime: allow arbitrary return type in SetFinalizer.Russ Cox1-3/+10
finalize chan, to free OS X semaphore inside Lock. os: finalize File, to close fd. Fixes issue 503. R=ken2 CC=golang-dev http://codereview.appspot.com/204065
2010-01-25in C and asm, replace pkg·name with ·nameRuss Cox1-14/+14
(eliminate assumption of package global name space, make code easier to move between packages). R=r CC=golang-dev http://codereview.appspot.com/194072
2010-01-12runtime: fix bug in preemption checks; was causing "lock count" panicsRuss Cox1-0/+2
R=r CC=golang-dev http://codereview.appspot.com/186078
2010-01-09runtime: check for preemption due to garbage collectionRuss Cox1-0/+4
in various already expensive routines. helps keep cpu utilization up when GOMAXPROCS > 1, but not a full solution. http://groups.google.com/group/golang-nuts/t/7a9535c4136d3e2 R=r CC=golang-dev http://codereview.appspot.com/184043
2010-01-06runtime: close TODO now that 8c bug is fixedRuss Cox1-12/+2
R=r CC=golang-dev http://codereview.appspot.com/183138
2010-01-06Ported runtime to Windows.Hector Chu1-2/+14
R=rsc CC=golang-dev http://codereview.appspot.com/176066 Committer: Russ Cox <rsc@golang.org>
2009-12-15os/signal: new packageDavid Symonds1-4/+1
Fixes issue 71. R=rsc, r http://codereview.appspot.com/162056 Committer: Russ Cox <rsc@golang.org>
2009-12-14runtime: in exitsyscall, avoid confusing garbage collectorRuss Cox1-1/+6
R=r CC=golang-dev http://codereview.appspot.com/178046
2009-12-07runtime: don't touch pages of memory unnecessarily.Russ Cox1-1/+2
cuts working size for hello world from 6 MB to 1.2 MB. still some work to be done, but diminishing returns. R=r http://codereview.appspot.com/165080
2009-11-18More FreeBSD-touchups. Thundercats are GOOOOO!Devon H. O'Dell1-0/+2
R=rsc CC=golang-dev http://codereview.appspot.com/157074 Committer: Russ Cox <rsc@golang.org>
2009-11-17runtime: two trivial but important bug fixesRuss Cox1-1/+1
R=r http://codereview.appspot.com/156059
2009-11-17runtime: do not create new threads during malloc.Russ Cox1-2/+5
the signal handling stack is a different size than the normal stack, so it cannot be allocated using the backup stack allocator. Fixes issue 250. R=agl1 CC=golang-dev http://codereview.appspot.com/157044
2009-11-10update old comment: things are much better nowRuss Cox1-5/+6
R=r http://codereview.appspot.com/152057
2009-10-15rename sys functions to runtime,Russ Cox1-7/+7
because they are in package runtime. another step to enforcing package boundaries. R=r DELTA=732 (114 added, 93 deleted, 525 changed) OCL=35811 CL=35824
2009-10-12stack overflow debugging and fix.Russ Cox1-10/+1
* in 6l, -K already meant check for stack underflow. add -KK to mean double-check stack overflows even in nosplit functions. * comment out print locks; they deadlock too easily but are still useful to put back for special occasions. * let runcgo assembly switch to scheduler stack without involving scheduler directly. because runcgo gets called from matchmg, it is too hard to keep it from being called on other stacks. R=r DELTA=94 (65 added, 18 deleted, 11 changed) OCL=35591 CL=35604
2009-10-09keep a list of all the M's,Russ Cox1-1/+6
so that the garbage collector doesn't free them. R=ken OCL=35538 CL=35538
2009-10-038c, 8l dynamic loading support.Russ Cox1-4/+41
better mach binaries. cgo working on darwin+linux amd64+386. eliminated context switches - pi is 30x faster. add libcgo to build. on snow leopard: - non-cgo binaries work; all tests pass. - cgo binaries work on amd64 but not 386. R=r DELTA=2031 (1316 added, 626 deleted, 89 changed) OCL=35264 CL=35304
2009-09-18Rudimentary command shell for Ogle. Hack to prevent linkerAustin Clements1-0/+6
from inlining newprocreadylocked. Fix type bridge's handling of basic types. Include interpreter's Thread in bridged native function calls. ; load . "6.out" Started 6.out ; BpSet("main·merge") ; ContWait() breakpoint at 0x400800 => 400800 main·merge /home/austin/src-go1/usr/austin/ptrace/test/sort.go:19 ; bt => 400800 main·merge /home/austin/src-go1/usr/austin/ptrace/test/sort.go:19 400b6a main·mergeSort+0x1be /home/austin/src-go1/usr/austin/ptrace/test/sort.go:34 448313 goexit /home/austin/src-go1/src/pkg/runtime/proc.c:133 ; main.merge.a {1} ; load . "pid:25753" Attached to 25753 ; bt => 479ddf syscall·Syscall+0x24 /home/austin/src-go1/src/pkg/syscall/asm_linux_amd64.s:24 47c011 syscall·Read+0x5d /home/austin/src-go1/src/pkg/syscall/zsyscall_linux_amd64.go:368 4119e5 os·*File·Read+0x5f /home/austin/src-go1/src/pkg/os/file.go:122 427bf3 bufio·*Reader·fill+0x116 /home/austin/src-go1/src/pkg/bufio/bufio.go:105 428361 bufio·*Reader·ReadSlice+0x195 /home/austin/src-go1/src/pkg/bufio/bufio.go:244 40204a ogle·Main+0x94 /home/austin/src-go1/usr/austin/ogle/cmd.go:226 40080f main·main+0xf /home/austin/src-go1/usr/austin/ogle/main.go:6 41c4b8 mainstart+0xf /home/austin/src-go1/src/pkg/runtime/amd64/asm.s:55 41531f goexit /home/austin/src-go1/src/pkg/runtime/proc.c:133 R=rsc APPROVED=rsc DELTA=433 (420 added, 2 deleted, 11 changed) OCL=34410 CL=34782
2009-08-31add newprocreadylocked for debuggerRuss Cox1-1/+10
R=austin DELTA=10 (9 added, 0 deleted, 1 changed) OCL=34163 CL=34166
2009-08-26recycle G structsRuss Cox1-0/+1
R=r DELTA=1 (1 added, 0 deleted, 0 changed) OCL=33887 CL=33904
2009-08-06add runtime.GOMAXPROCS, allowing a program to, in effect, set $GOMAXPROCSRob Pike1-1/+23
R=rsc DELTA=29 (28 added, 1 deleted, 0 changed) OCL=32829 CL=32837
2009-07-21runtime: fix init scheduling bug.Russ Cox1-0/+8
if there is a goroutine waiting to run and the init goroutine enters a system call, entersyscall was trying to kick off a new scheduler for the other goroutine, causing a panic (new goroutines can't run until main.main). R=r DELTA=32 (32 added, 0 deleted, 0 changed) OCL=31982 CL=31982
2009-07-13add LockOSThread and UnlockOSThread toRuss Cox1-80/+90
runtime package for use by debugger, which needs to make sure that all ptrace calls about a given pid come from the same thread. R=r DELTA=175 (90 added, 63 deleted, 22 changed) OCL=31546 CL=31558
2009-07-08reflection for functionsRuss Cox1-4/+5
add channel send type check (thanks austin). fix type mismatch message. R=r DELTA=241 (225 added, 5 deleted, 11 changed) OCL=31370 CL=31375
2009-06-17runtime: stack growth adjustments, cleanupRuss Cox1-104/+50
* keep coherent SP/PC in gobuf (i.e., SP that would be in use at that PC) * gogocall replaces setspgoto, should work better in presence of link registers * delete unused system calls only amd64; 386 is now broken R=r DELTA=548 (183 added, 183 deleted, 182 changed) OCL=30381 CL=30442