Age | Commit message (Collapse) | Author |
|
Change-Id: I83ceab6336401e9ffe788b948ba29c3fdadea973
|
|
Change-Id: I26d1099385c6c64150e153f8f6f304d161b5dac1
|
|
Change-Id: Ia4e0d5dab9b29367e5f61b6ebd65fa0c318dda86
|
|
Change-Id: Ia2ebad962c498631850b39690c1a3d67ae887c5c
|
|
Change-Id: I67684002abf84c64d0e873a8044b211923c56499
|
|
Change-Id: If635aa7dbff0d433569bcb961bd02d8e16b894bf
|
|
Change-Id: I97fe02630ee0e0dac705ef3ef3bf76ddafd5cab8
|
|
Change-Id: Iab4acacc1408cb2f8e03dd1d07ec9241c762f83a
|
|
Change-Id: I29353b553aba293581d8240e44db829cdc51b308
|
|
Reviewed-on: https://go-review.googlesource.com/40775
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@246957 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
cmd/go: generate vendor paths for -I arg on compile
This change generates the vendor path to be used with -I
on a gccgo compile to find imports from the vendor directories.
Fixes golang/go#15628
Reviewed-on: https://go-review.googlesource.com/39590
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@246864 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
time: make the ParseInLocation test more robust
This is a backport of https://golang.org/cl/37964 from the gc toolchain.
Original description:
The tzdata 2017a update (2017-02-28) changed the abbreviation of the
Asia/Baghdad time zone (used in TestParseInLocation) from 'AST' to the
numeric '+03'.
Update the test so that it skips the checks if we're using a recent
tzdata release.
Updates golang/go#19457
Fixes GCC PR 80302.
Reviewed-on: https://go-review.googlesource.com/39470
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@246695 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
Patch by Andrwas Schwab.
Reviewed-on: https://go-review.googlesource.com/38456
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@246410 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
This file was accidentally omitted from the update to the final Go 1.8.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@245814 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
Fixes Solaris build.
Patch by Rainer Orth.
Reviewed-on: https://go-review.googlesource.com/37587
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@245794 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
The use of &[1]uintptr{fn} was causing sigfwd to allocate memory, even
though it is being compiled for the runtime package. That is a bad
idea for this function, which is invoked by a signal handler. Rewrite
it to use only constructs that do not allocate memory when compiled
for the runtime package.
The test for this is misc/cgo/testcarchive in the main repo, which we
don't yet test.
Reviewed-on: https://go-review.googlesource.com/37454
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@245777 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
The quoting was causing us to never add the system-specific signals.
The test for this is misc/cgo/testcarchive in the master repo, which
we don't yet run for gccgo.
Reviewed-on: https://go-review.googlesource.com/37453
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@245776 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
Along with the update this fixes a problem that was always present but
only showed up with the new reflect test. When a program used a
**unsafe.Pointer and stored the value in an interface type, the
generated type descriptor pointed to the GC data for *unsafe.Pointer.
It did that by name, but we were not generating a variable with the
right name.
Reviewed-on: https://go-review.googlesource.com/37144
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@245535 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
libgo: fix some s390x tests
Add `+build ignore` to ignore tests that rely on s390x assembly code
not yet implemented for gccgo.
Fixes GCC PR 79443.
Reviewed-on: https://go-review.googlesource.com/36909
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@245397 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
Reviewed-on: https://go-review.googlesource.com/35844
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@244981 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
When I updated to Go 1.8, the initsig function moved from
signal1_unix.go to signal_unix.go, and lost a gccgo-specific change in
the move. Add it back.
This would have been caught by the misc/cgo/testcarchive tests in the
gc repository, but we don't run those in the gccgo repository. We
should fix that, somehow.
Reviewed-on: https://go-review.googlesource.com/35839
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@244947 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
I typoed the argument passed to getcontext in getTraceback, and the
error was hidden by ucontext_arg. This would have been caught by some
of the runtime package tests, but we don't run most of them because
they rely on `go build`, and the go tool is not available while
running the libgo testsuite. We should fix the libgo testsuite,
somehow, so that they run.
Reviewed-on: https://go-review.googlesource.com/35837
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@244946 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
Fix a bug in the generation of the hash value in reflect.FuncOf.
The merge script missed a bunch of testdata files over the years.
Copy them over.
Reviewed-on: https://go-review.googlesource.com/35570
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@244835 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
compiler, runtime: align gc data for m68k
The current GC requires that the gc data be aligned to at least a 4
byte boundary, because it uses the lower two bits of the address for
flags (see LOOP and PRECISE in runtime/mgc0.c). As the gc data is
stored as a [...]uintptr, that is normally always true. However, on
m68k, that only guarantees 2 byte alignment. Fix it by forcing the
alignment.
The parfor code used by the current GC requires that the parfor data
be aligned to at least an 8 byte boundary. The code in parfor.c
verifies this. This is normally true, as the data uses uint64_t
values, but, again, this must be enforced explicitly on m68k.
Fixes GCC PR 79037.
Reviewed-on: https://go-review.googlesource.com/35478
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@244824 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
As usual I forgot to bump the library version when I updated the
library to 1.8rc1.
Reviewed-on: https://go-review.googlesource.com/35568
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@244823 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
Some fixes that permit misc/cgo/test in the master gc repository to
pass using the current gccgo.
Install testing/internal/testdeps.gox; it is needed by `go test`.
Export runtime.lockedOSThread to enable calling via go:linkname; it is
used by misc/cgo/test.
Loop on EAGAIN when creating a new thread; this is what the gc code
does, and misc/cgo/test tests that it works.
Reviewed-on: https://go-review.googlesource.com/35479
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@244733 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
math/big: fix build on s390x
Don't build arith_decl_s390x.go for gccgo; it is only for assembly
code that has not yet been ported to gccgo.
For GCC PR 79146.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@244731 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
crypto/elliptic: explicitly ignore p256_s390x.go
The file only works if used in conjunction with assembly code not
(yet) written for gccgo.
Fixes GCC PR 79146.
Reviewed-on: https://go-review.googlesource.com/35477
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@244679 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
Reviewed-on: https://go-review.googlesource.com/35390
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@244563 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
Since the name siginfo winds up in runtime.inc, this avoids a name
collision on systems that define "struct siginfo" in the system header
files.
Reviewed-on: https://go-review.googlesource.com/35239
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@244484 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
Patch by Rainer Orth.
Reviewed-on: https://go-review.googlesource.com/35238
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@244483 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
Compiler changes:
* Change map assignment to use mapassign and assign value directly.
* Change string iteration to use decoderune, faster for ASCII strings.
* Change makeslice to take int, and use makeslice64 for larger values.
* Add new noverflow field to hmap struct used for maps.
Unresolved problems, to be fixed later:
* Commented out test in go/types/sizes_test.go that doesn't compile.
* Commented out reflect.TestStructOf test for padding after zero-sized field.
Reviewed-on: https://go-review.googlesource.com/35231
gotools/:
Updates for Go 1.8rc1.
* Makefile.am (go_cmd_go_files): Add bug.go.
(s-zdefaultcc): Write defaultPkgConfig.
* Makefile.in: Rebuild.
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@244456 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
I looked at a diff of proc.go between Go 1.7 and gccgo, and copied
over all the easy stuff.
Reviewed-on: https://go-review.googlesource.com/35090
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@244291 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
Drop the size arguments for the hash/equal functions stored in type
descriptors. Types know what size they are. To make this work,
generate hash/equal functions for types that can use an identity
comparison but are not a standard size and alignment.
Drop the multiplications by 33 in the generated hash code and the
reflect package hash code. They are not necessary since we started
passing a seed value around, as the seed includes the hash of the
earlier values.
Copy the algorithms for standard types from the Go 1.7 runtime,
replacing the C functions.
Reviewed-on: https://go-review.googlesource.com/34983
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@244256 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
This started by moving procresize from C to Go so that we can pass the
right type to the memory allocator when allocating a p, which forced
the gomaxprocs variable to move from C to Go, and everything else
followed from that.
Reviewed-on: https://go-review.googlesource.com/34916
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@244236 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
Accidentally omitted from the commit of CL 34797 (SVN revision 244036).
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@244166 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
libgo: build with -Wa,-nH if possible on Solaris
By default the Solaris assembler records the required hardware
capability in the object file. This means that the AES hashing code
breaks on systems that do not support AES, even though the code uses a
runtime check to only actually invoke the AES instructions on systems
that support it. An earlier fix for the problem only fixed the shared
library, not the static libgo.a. Fix the problem for real by using an
assembler option to not record the hardware capability.
For GCC PR 78978.
Patch by Rainer Orth.
Reviewed-on: https://go-review.googlesource.com/34910
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@244165 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
Move allocg and handling of allgs slice from C to Go.
Reviewed-on: https://go-review.googlesource.com/34797
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@244036 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
runtime: don't build aeshash.c if the assembler doesn't support it
This is for CentOS 5, whose assembler does not know the aesinc
instruction.
Fixes GCC PR 78789.
Patch by Uros Bizjak.
Reviewed-on: https://go-review.googlesource.com/34796
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@244031 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
Remove support for _cgo_allocate. It was removed from the gc
toolchain in Go 1.5, so it is unlikely that anybody is trying to use it.
Reviewed-on: https://go-review.googlesource.com/34557
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@243805 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
Don't put m[0-4] in runtime.inc.
Pass -mclear-hwcap to the linker if supported.
From Rainer Orth.
Reviewed-on: https://go-review.googlesource.com/34331
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@243619 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
Avoids warnings during the build.
Reviewed-on: https://go-review.googlesource.com/34142
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@243459 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
Rewrite the AES hashing code from gc assembler to C code using
intrinsics. The resulting code generates the same hash code for the
same input as the gc code--that doesn't matter as such, but testing it
ensures that the C code does something useful.
Also change mips64pe32le to mips64p32le in configure script--noticed
during CL review.
Reviewed-on: https://go-review.googlesource.com/34022
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@243445 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
The gc library allocates a _panic struct on the stack. This does not
work for gccgo, because when a deferred function recovers the panic we
unwind the stack up to that point so that returning from the function
will work correctly.
Allocating on the stack fine if the panic is not recovered, and it
works fine if the panic is recovered by a function that
returns. However, it fails if the panic is recovered by a function
that itself panics, and if that second panic is then recovered by a
function higher up on the stack. When we unwind the stack to that
second panic, the g will wind up pointing at a panic farther down on
the stack. Even then everything will often work fine, except when the
deferred function catching the second panic makes a bunch of calls
that use stack space before returning. In that case the code can
overwrite the panic struct, which will then cause disaster when we
remove the struct from the linked list, as the link field will be
garbage. This case is rare enough that all the x86 tests were passing,
but there was a failure on ppc64le.
Before https://golang.org/cl/33414 we allocated the panic struct on
the heap, so go back to doing that again.
Fixes golang/go#18228.
Reviewed-on: https://go-review.googlesource.com/34027
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@243444 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
Small patch from Eric Botcazou.
Reviewed-on: https://go-review.googlesource.com/34029
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@243424 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
The library initialization code in go-libmain.c sets the C variable
runtime_isarchive but failed to set the Go variable runtime.isarchive.
We don't currently have a way to let C code access an unexported Go
variable, but fortunately the only time the Go function initsig is
called with an argument of true is exactly where we want to set
isarchive. So let initsig do it.
Reviewed-on: https://go-review.googlesource.com/33753
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@243094 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
Since gccgo can trace back through C code as easily as Go code, we
should print C functions in the traceback.
This worked before https://golang.org/cl/31230 for a dumb reason. The
default value for runtime.traceback_cache was, and is, 2 << 2, meaning
to print all functions. The old C code for runtime_parsedebugvars
would return immediately and do nothing if the environment variable
GODEBUG was not set (if GODEBUG was set it would later call
setTraceback. The new Go code for runtime.parsedebugvars does not
return immediately if GODEBUG is not set, and always calls
setTraceback. Either way, if GOTRACEBACK is not set, setTraceback
would set traceback_cache to 1 << 2, meaning to only print non-runtime
functions and having the effect of not printing plain C functions.
Keep the current handling of GODEBUG/GOTRACEBACK, which matches the gc
library, but add an extra check to print C functions by default.
Reviewed-on: https://go-review.googlesource.com/33717
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@243083 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
With -buildmode=c-archive, initsig is called before the memory
allocator has been initialized. The code was doing a memory
allocation because of the call to funcPC(sigtramp). When escape
analysis is fully implemented, that call should not allocate. For
now, finesse the issue by calling a C function to get the C function
pointer value of sigtramp.
When returning from a call from C to a Go function, a deferred
function is run to go back to syscall mode. When the call occurs on a
non-Go thread, that call sets g to nil, making it impossible to add
the _defer struct back to the pool. Just drop it and let the garbage
collector clean it up.
Reviewed-on: https://go-review.googlesource.com/33675
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@242992 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
cmd/go: don't check standard packages when using gccgo
This copies https://golang.org/cl/33295 to libgo.
This fixes GCC PR 77910.
Reviewed-on: https://go-review.googlesource.com/33471
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@242724 138bc75d-0d04-0410-961f-82ee72b054a4
|
|
The actual stack unwind code is still in C, but the rest of the code,
notably all the memory allocation, is now in Go. The names are changed
to the names used in the Go 1.7 runtime, but the code is necessarily
somewhat different.
The __go_makefunc_can_recover function is dropped, as the uses of it
were removed in https://golang.org/cl/198770044.
Reviewed-on: https://go-review.googlesource.com/33414
git-svn-id: svn+ssh://gcc.gnu.org/svn/gcc/trunk@242715 138bc75d-0d04-0410-961f-82ee72b054a4
|