Ticket #1015 (closed bug: fixed)

Opened 6 years ago

Last modified 3 years ago

regex001(ghci,threaded1) seg-faults under Solaris

Reported by: maeder@… Owned by: benl
Priority: normal Milestone: _|_
Component: Compiler Version: 6.6
Keywords: Cc:
Operating System: Solaris Architecture: Unknown/Multiple
Type of failure: Difficulty: Unknown
Test Case: Blocked By:
Blocking: Related Tickets:

Description

copied from  http://hackage.haskell.org/trac/ghc/ticket/993

Starting program: 
/home/maeder/haskell/pc-solaris/ghc-6.6/testsuite/tests/ghc-regress/lib/Regex/regex001
warning: Lowest section in /lib/libpthread.so.1 is .dynamic at 00000074
[New LWP 1]
[New LWP 2]
[New LWP 3]
[New LWP 4]

Program received signal SIGSEGV, Segmentation fault.
[Switching to LWP 3]
0xbfd4386a in _free_unlocked () from /lib/libc.so.1

Under Sparc-solaris only the ghci-version seg-faulted

Change History

Changed 5 years ago by igloo

  • milestone changed from 6.6.1 to _|_

Set milestone to _|_ as this is a registerised bug in a non-actively-maintained port.

Changed 4 years ago by simonmar

Christian - is this bug still relevant?

Changed 4 years ago by maeder

Yes, I've just tested under sparc solaris:

=====> regex001(ghci)
cd ./lib/Regex && '/local/home/maeder/ghc-6.8.2/compiler/stage2/ghc-inplace' -no-recomp -dcore-lint -dcmm-lint -Dsparc_sun_solaris2  regex001.hs --interactive -v0 -package regex-posix  <regex001.genscript 1>regex001.interp.stdout 2>regex001.interp.stderr
Bus Error
Wrong exit code (expected 0 , actual 138 )
Stdout:
*** framework failure for regex001(ghci) :
Traceback (most recent call last):
  File "/home/ian/ghc/6.6-branch/ghc/testsuite/driver/testlib.py", line 363, in do_test
    result = apply(func, [name,way] + args)
  File "/home/ian/ghc/6.6-branch/ghc/testsuite/driver/testlib.py", line 509, in compile_and_run
    return compile_and_run_helper( name, way, extra_hc_opts, 0 )
  File "/home/ian/ghc/6.6-branch/ghc/testsuite/driver/testlib.py", line 519, in compile_and_run_helper
    return interpreter_run( name, way, extra_hc_opts, 0, '' )
  File "/home/ian/ghc/6.6-branch/ghc/testsuite/driver/testlib.py", line 736, in interpreter_run
    dump_stdout(name)
  File "/home/ian/ghc/6.6-branch/ghc/testsuite/driver/testlib.py", line 880, in dump_stdout
    print read_no_crs(qualify(name, 'run.stdout'))
  File "/home/ian/ghc/6.6-branch/ghc/testsuite/driver/testlib.py", line 899, in read_no_crs
    h = open(file)
IOError: [Errno 2] No such file or directory: './lib/Regex/regex001.run.stdout'
=====> regex001(threaded1)
cd ./lib/Regex && '/local/home/maeder/ghc-6.8.2/compiler/stage2/ghc-inplace' -no-recomp -dcore-lint -dcmm-lint -Dsparc_sun_solaris2  -o regex001 regex001.hs -threaded -debug -package regex-posix  >regex001.comp.stderr 2>&1
cd ./lib/Regex && ./regex001    </dev/null >regex001.run.stdout 2>regex001.run.stderr
Segmentation Fault
Wrong exit code (expected 0 , actual 139 )
Stdout:

Stderr:

*** unexpected failure for regex001(threaded1)

Changed 4 years ago by maeder

under x86 Solaris as well:

-bash-3.1$ ghc -no-recomp -lbfd -lintl -liberty -dcore-lint -dcmm-lint -Dsparc_sun_solaris2  -o regex001 regex001.hs -threaded -debug -package regex-posix
-bash-3.1$ ./regex001
Segmentation Fault

Changed 4 years ago by simonmar

  • architecture changed from Multiple to Unknown/Multiple

Changed 3 years ago by benl

  • owner set to benl
  • status changed from new to assigned

Changed 3 years ago by benl

  • status changed from assigned to closed
  • resolution set to fixed

Mon Apr 6 15:35:13 EST 2009 Ben.Lippmeier@…

  • Fix #1015: Don't free the buffers of regexes who's compile fails. The SunOS 5.10 man page says that if regcomp fails then the regex buffer becomes "undefined". Trying to free it causes a segv under x86 and SPARC.
Note: See TracTickets for help on using tickets.