[GHC] #10043: runtime fails in threaded way on SPARC (bus error -> unaligned access to data)

GHC ghc-devs at haskell.org
Thu Jan 29 13:03:00 UTC 2015


#10043: runtime fails in threaded way on SPARC (bus error -> unaligned access to
data)
-----------------------------------+----------------------------------
              Reporter:  kgardas   |             Owner:
                  Type:  bug       |            Status:  new
              Priority:  normal    |         Milestone:
             Component:  Compiler  |           Version:  7.10.1-rc2
              Keywords:            |  Operating System:  Solaris
          Architecture:  sparc     |   Type of failure:  Runtime crash
             Test Case:            |        Blocked By:
              Blocking:            |   Related Tickets:
Differential Revisions:            |
-----------------------------------+----------------------------------
 Hello,
 it looks like runtime has changed between 7.8 and 7.10 in a way it no
 longer works well on SPARC. Tested on SPARC/Solaris 2.11. Both compilers
 compiled as their are w/o any changes so both unregisterised. On 7.8
 testblockalloc runs well, on 7.10.1-rc2 it fails in threaded way with "Bus
 error"
 {{{
 karel at niagara:~/src/ghc-7.10.0.20150123/testsuite/tests/rts$
 ./testblockalloc +RTS -I0
 Bus Error (core dumped)
 }}}

 When run in debugger it points to assignment of 0 to tso->alloc_limit:
 {{{
 karel at niagara:~/src/ghc-7.10.0.20150123/testsuite/tests/rts$ gdb
 ./testblockalloc
 GNU gdb 6.8
 Copyright (C) 2008 Free Software Foundation, Inc.
 License GPLv3+: GNU GPL version 3 or later
 <http://gnu.org/licenses/gpl.html>
 This is free software: you are free to change and redistribute it.
 There is NO WARRANTY, to the extent permitted by law.  Type "show copying"
 and "show warranty" for details.
 This GDB was configured as "sparc-sun-solaris2.11"...
 set ar(gdb) set args +RTS -I0
 (gdb) r
 Starting program:
 /home/karel/src/ghc-7.10.0.20150123/testsuite/tests/rts/testblockalloc
 +RTS -I0
 warning: Lowest section in /lib/librt.so.1 is .dynamic at 00000074
 warning: Lowest section in /lib/libdl.so.1 is .dynamic at 00000074
 warning: Lowest section in /lib/libpthread.so.1 is .dynamic at 00000074

 Program received signal SIGSEGV, Segmentation fault.
 0x006b62d4 in createThread (cap=0x821ec0, size=256) at rts/Threads.c:113
 113         tso->alloc_limit = 0;
 (gdb)
 }}}

 usually bus error is generated by unaligned access to data. I'll have a
 look at it, but any idea is of course highly appreciated.

--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/10043>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler


More information about the ghc-tickets mailing list