[Bug go/83314] gccgo: Compiled binaries panic with "mmap errno 9" on m68k

2017-12-07 Thread jrtc27 at jrtc27 dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83314 --- Comment #5 from James Clarke --- (In reply to John Paul Adrian Glaubitz from comment #4) > Ok, I should have actually tested this on real hardware right away. > > Here's on my Amiga 4000: > > root@elgar:~> ./hello > 5662 > fatal error: mem

[Bug go/83314] gccgo: Compiled binaries panic with "mmap errno 9" on m68k

2017-12-07 Thread glaubitz at physik dot fu-berlin.de
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83314 --- Comment #4 from John Paul Adrian Glaubitz --- Ok, I should have actually tested this on real hardware right away. Here's on my Amiga 4000: root@elgar:~> ./hello 5662 fatal error: memstats.heap_live not aligned to 8 bytes goroutine 16 [run

[Bug go/83314] gccgo: Compiled binaries panic with "mmap errno 9" on m68k

2017-12-07 Thread ian at airs dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83314 --- Comment #3 from Ian Lance Taylor --- Ah, of course. Thanks. In that case mmap is being called with a descriptor that is the executable itself, as opened by fileline_initialize in libbacktrace/fileline.c. I wonder why mmap fails on that? C

[Bug go/83314] gccgo: Compiled binaries panic with "mmap errno 9" on m68k

2017-12-07 Thread jrtc27 at jrtc27 dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83314 --- Comment #2 from James Clarke --- My guess is libbacktrace/mmapio.c (perhaps mmap.c), which calls mmap with MAP_PRIVATE, and calls `error_callback (data, "mmap", errno)` on failure. That's a function pointer, which I would assume is error_call

[Bug go/83314] gccgo: Compiled binaries panic with "mmap errno 9" on m68k

2017-12-07 Thread ian at airs dot com
https://gcc.gnu.org/bugzilla/show_bug.cgi?id=83314 --- Comment #1 from Ian Lance Taylor --- errno 9 is EBADF, which doesn't make much sense since libgo only ever calls mmap with MAP_ANONYMOUS. And I'm not even sure where those messages are coming from. I don't see any place where the GCC 7 libg