- 14 Nov, 2014 9 commits
-
-
Russ Cox authored
Fixes build. Tested that all these systems can make.bash. TBR=austin CC=golang-codereviews https://golang.org/cl/177770043
-
Russ Cox authored
While we are here, add the linux/power64 version. LGTM=austin R=austin CC=aram, dvyukov, golang-codereviews https://golang.org/cl/177750043
-
Russ Cox authored
TBR=austin CC=golang-codereviews https://golang.org/cl/176760044
-
Joel Sing authored
LGTM=rsc R=golang-codereviews, rsc CC=golang-codereviews https://golang.org/cl/176750043
-
Russ Cox authored
This is to reduce the delta between dev.cc and dev.garbage to just garbage collector changes. These are the files that had merge conflicts and have been edited by hand: malloc.go mem_linux.go mgc.go os1_linux.go proc1.go panic1.go runtime1.go LGTM=austin R=austin CC=golang-codereviews https://golang.org/cl/174180043
-
Joel Sing authored
LGTM=rsc R=golang-codereviews, bradfitz, rsc CC=golang-codereviews https://golang.org/cl/173200044
-
Aram Hăvărneanu authored
This change fixes the Solaris port. LGTM=dave, rsc R=rsc, dave CC=brad, golang-codereviews https://golang.org/cl/168600045
-
Alex Brainman authored
LGTM=rsc R=rsc CC=dvyukov, golang-codereviews https://golang.org/cl/172530043
-
Joel Sing authored
LGTM=rsc R=rsc, bradfitz CC=golang-codereviews https://golang.org/cl/171660043
-
- 13 Nov, 2014 7 commits
-
-
Austin Clements authored
This adds registerization support to 9g equivalent to what the other compilers have. LGTM=rsc R=rsc, dave CC=golang-codereviews https://golang.org/cl/174980043
-
Austin Clements authored
None of the other compilers have a tag for this enum. Cleaning all of this up to use proper types will happen after the conversion. LGTM=minux, rsc R=rsc, minux CC=golang-codereviews https://golang.org/cl/166690043
-
Austin Clements authored
Previously, the 6g and 8g registerizers scanned for used registers beyond the end of a region being considered for registerization. This ancient artifact was copied from the C compilers, where it was probably necessary to track implicitly used registers. In the Go compilers it's harmless (because it can only over-restrict the set of available registers), but no longer necessary because the Go compilers correctly track register use/set information. The consequences of this extra scan were (at least) that 1) we would not consider allocating the AX register if there was a deferproc call in the future because deferproc uses AX as a return register, so we see the use of AX, but don't track that AX is set by the CALL, and 2) we could not consider allocating the DX register if there was a MUL in the future because MUL implicitly sets DX and (thanks to an abuse of copyu in this code) we would also consider DX used. This commit fixes these problems by nuking this code. LGTM=rsc R=rsc CC=golang-codereviews https://golang.org/cl/174110043
-
Joel Sing authored
This was originally done to the C port in rev 17d3b45534b5 and seemingly got lost during the conversion. LGTM=bradfitz R=rsc, bradfitz CC=golang-codereviews https://golang.org/cl/167700043
-
Aram Hăvărneanu authored
Memory management was consolitated with the BSD ports, since it was almost identical. Assembly thunks are gone, being replaced by the new //go:linkname feature. This change supersedes CL 138390043 (runtime: convert solaris netpoll to Go), which was previously reviewed and tested. This change is only the first step, the port now builds, but doesn't run. Binaries fail to exec: ld.so.1: 6.out: fatal: 6.out: TLS requirement failure : TLS support is unavailable Killed This seems to happen because binaries don't link with libc.so anymore. We will have to solve that in a different CL. Also this change is just a rough translation of the original C code, cleanup will come in a different CL. [This CL is part of the removal of C code from package runtime. See golang.org/s/dev.cc for an overview.] LGTM=rsc R=rsc, dave CC=golang-codereviews, iant, khr, minux, r, rlh https://golang.org/cl/174960043
-
Alex Brainman authored
LGTM=rsc R=rsc CC=golang-codereviews https://golang.org/cl/175000043
-
Alex Brainman authored
LGTM=rsc R=rsc CC=golang-codereviews https://golang.org/cl/169490043
-
- 12 Nov, 2014 11 commits
-
-
Austin Clements authored
LGTM=dave, rsc R=rsc, dave CC=golang-codereviews https://golang.org/cl/169460043
-
Joel Sing authored
LGTM=rsc R=rsc CC=golang-codereviews https://golang.org/cl/174050043
-
Austin Clements authored
For D_OREG addresses, store the used registers in regindex instead of reguse because they're really part of addressing. Add implicit register use/set for DUFFZERO/DUFFCOPY. LGTM=rsc R=rsc CC=golang-codereviews https://golang.org/cl/174050044
-
Russ Cox authored
Scalararg and ptrarg are not "signal safe". Go code filling them out can be interrupted by a signal, and then the signal handler runs, and if it also ends up in Go code that uses scalararg or ptrarg, now the old values have been smashed. For the pieces of code that do need to run in a signal handler, we introduced onM_signalok, which is really just onM except that the _signalok is meant to convey that the caller asserts that scalarg and ptrarg will be restored to their old values after the call (instead of the usual behavior, zeroing them). Scalararg and ptrarg are also untyped and therefore error-prone. Go code can always pass a closure instead of using scalararg and ptrarg; they were only really necessary for C code. And there's no more C code. For all these reasons, delete scalararg and ptrarg, converting the few remaining references to use closures. Once those are gone, there is no need for a distinction between onM and onM_signalok, so replace both with a single function equivalent to the current onM_signalok (that is, it can be called on any of the curg, g0, and gsignal stacks). The name onM and the phrase 'm stack' are misnomers, because on most system an M has two system stacks: the main thread stack and the signal handling stack. Correct the misnomer by naming the replacement function systemstack. Fix a few references to "M stack" in code. The main motivation for this change is to eliminate scalararg/ptrarg. Rick and I have already seen them cause problems because the calling sequence m.ptrarg[0] = p is a heap pointer assignment, so it gets a write barrier. The write barrier also uses onM, so it has all the same problems as if it were being invoked by a signal handler. We worked around this by saving and restoring the old values and by calling onM_signalok, but there's no point in keeping this nice home for bugs around any longer. This CL also changes funcline to return the file name as a result instead of filling in a passed-in *string. (The *string signature is left over from when the code was written in and called from C.) That's arguably an unrelated change, except that once I had done the ptrarg/scalararg/onM cleanup I started getting false positives about the *string argument escaping (not allowed in package runtime). The compiler is wrong, but the easiest fix is to write the code like Go code instead of like C code. I am a bit worried that the compiler is wrong because of some use of uninitialized memory in the escape analysis. If that's the reason, it will go away when we convert the compiler to Go. (And if not, we'll debug it the next time.) LGTM=khr R=r, khr CC=austin, golang-codereviews, iant, rlh https://golang.org/cl/174950043
-
Russ Cox authored
LGTM=bradfitz, r R=r, bradfitz CC=golang-codereviews https://golang.org/cl/167650043
-
Austin Clements authored
LGTM=rsc R=rsc CC=golang-codereviews https://golang.org/cl/174970043
-
Russ Cox authored
Last try and then someone with a FreeBSD has to do it. TBR=r CC=golang-codereviews https://golang.org/cl/171590043
-
Russ Cox authored
TBR=r CC=golang-codereviews https://golang.org/cl/168600043
-
Russ Cox authored
Will prod freebsd build along. Not claiming it will fix it. TBR=r CC=golang-codereviews https://golang.org/cl/171580044
-
Russ Cox authored
It builds. Don't know if it works, but it's a lot closer than having everything in C. LGTM=r R=r CC=golang-codereviews https://golang.org/cl/168590043
-
Russ Cox authored
Also include onM_signalok fix from issue 8995. Fixes linux/arm build. Fixes #8995. LGTM=r R=r, dave CC=golang-codereviews https://golang.org/cl/168580043
-
- 11 Nov, 2014 13 commits
-
-
Russ Cox authored
This was recorded as an hg mv instead of an hg cp. For now a C version is needed for the Go compiler. TBR=r CC=golang-codereviews https://golang.org/cl/174020043
-
Russ Cox authored
The conversion was done with an automated tool and then modified only as necessary to make it compile and run. vlrt.c was only called from C. Pure delete. [This CL is part of the removal of C code from package runtime. See golang.org/s/dev.cc for an overview.] LGTM=r R=r, austin CC=dvyukov, golang-codereviews, iant, khr https://golang.org/cl/174860043
-
Russ Cox authored
The conversion was done with an automated tool and then modified only as necessary to make it compile and run. [This CL is part of the removal of C code from package runtime. See golang.org/s/dev.cc for an overview.] LGTM=r R=r CC=austin, dvyukov, golang-codereviews, iant, khr https://golang.org/cl/174830044
-
Russ Cox authored
The conversion was done with an automated tool and then modified only as necessary to make it compile and run. [This CL is part of the removal of C code from package runtime. See golang.org/s/dev.cc for an overview.] LGTM=r R=r, daniel.morsing CC=austin, dvyukov, golang-codereviews, iant, khr https://golang.org/cl/172260043
-
Russ Cox authored
The conversion was done with an automated tool and then modified only as necessary to make it compile and run. [This CL is part of the removal of C code from package runtime. See golang.org/s/dev.cc for an overview.] LGTM=r R=r CC=austin, dvyukov, golang-codereviews, iant, khr https://golang.org/cl/172250044
-
Russ Cox authored
The conversion was done with an automated tool and then modified only as necessary to make it compile and run. [This CL is part of the removal of C code from package runtime. See golang.org/s/dev.cc for an overview.] LGTM=r R=r, austin CC=dvyukov, golang-codereviews, iant, khr https://golang.org/cl/172250043
-
Russ Cox authored
The conversion was done with an automated tool and then modified only as necessary to make it compile and run. In a few cases, defs_$GOOS_$GOARCH.go already existed, so the target here is defs1_$GOOS_$GOARCH.go. [This CL is part of the removal of C code from package runtime. See golang.org/s/dev.cc for an overview.] LGTM=r R=r CC=austin, dvyukov, golang-codereviews, iant, khr https://golang.org/cl/171490043
-
Russ Cox authored
float.c held bit patterns for special float64 values, hiding from the real uses. Rewrite Go code not to refer to those values directly. Convert library routines in runtime.c and string.c. LGTM=r R=r, dave CC=austin, dvyukov, golang-codereviews, iant, khr https://golang.org/cl/170330043
-
Russ Cox authored
Otherwise no system will get an 'ok' until they all do. LGTM=r, dave R=r, dave CC=austin, dvyukov, golang-codereviews, iant, khr https://golang.org/cl/170320044
-
Russ Cox authored
The main change is that #include "zasm_GOOS_GOARCH.h" is now #include "go_asm.h" and/or #include "go_tls.h". Also, because C StackGuard is now Go _StackGuard, the assembly name changes from const_StackGuard to const__StackGuard. In asm_$GOARCH.s, add new function getg, formerly implemented in C. The renamed atomics now have Go wrappers, to get escape analysis annotations right. Those wrappers are in CL 174860043. LGTM=r, aram R=r, aram CC=austin, dvyukov, golang-codereviews, iant, khr https://golang.org/cl/168510043
-
Russ Cox authored
This code overused macros and could not be converted automatically. Instead a new sigctxt type had to be defined for each os/arch combination, with a common (implicit) interface used by the arch-specific signal handler code. [This CL is part of the removal of C code from package runtime. See golang.org/s/dev.cc for an overview.] LGTM=r R=r CC=austin, dvyukov, golang-codereviews, iant, khr https://golang.org/cl/168500044
-
Russ Cox authored
The conversion was done with an automated tool and then modified only as necessary to make it compile and run. [This CL is part of the removal of C code from package runtime. See golang.org/s/dev.cc for an overview.] LGTM=r R=r CC=austin, dvyukov, golang-codereviews, iant, khr https://golang.org/cl/168500043
-
Russ Cox authored
The conversion was done with an automated tool and then modified only as necessary to make it compile and run. [This CL is part of the removal of C code from package runtime. See golang.org/s/dev.cc for an overview.] LGTM=r R=r, austin CC=dvyukov, golang-codereviews, iant, khr https://golang.org/cl/167550043
-