[Bug go/79037] gccgo: Binaries crash with parforsetup: pos is not aligned on m68k
ian at gcc dot gnu.org
gcc-bugzilla@gcc.gnu.org
Wed Feb 1 23:36:00 GMT 2017
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=79037
--- Comment #14 from ian at gcc dot gnu.org <ian at gcc dot gnu.org> ---
Author: ian
Date: Wed Feb 1 23:35:59 2017
New Revision: 245110
URL: https://gcc.gnu.org/viewcvs?rev=245110&root=gcc&view=rev
Log:
PR go/79037
Backport from mainline:
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.
Change-Id: Ifdf422db7b37e88f490e54c2f6d249117d359dd6
Modified:
branches/gcc-6-branch/gcc/go/gofrontend/types.cc
branches/gcc-6-branch/libgo/runtime/go-unsafe-pointer.c
branches/gcc-6-branch/libgo/runtime/parfor.c
branches/gcc-6-branch/libgo/runtime/runtime.h
More information about the Gcc-bugs
mailing list