ghc 6.10.1 on freebsd 7 amd64 - ghci problems

Simon Marlow marlowsd at gmail.com
Fri Nov 28 04:42:02 EST 2008


Markus Barenhoff wrote:
> On Thu 27.11 09:49, Simon Marlow wrote:
>> Brandon S. Allbery KF8NH wrote:
>>> On 2008 Nov 26, at 9:30, Markus Barenhoff wrote:
>>>> Because the ports seem not to get updated, I tried to compile ghc 6.10.1
>>>> under freebsd 7 on amd64 myself. For compiling I first used the ports ghc
>>> The tree's not being updated because 64-bit on freebsd doesn't work yet, 
>>> as you found.  I believe a fix for the mmap() problem has been committed 
>>> for the upcoming 6.10.2.
>> Yes.
>>
>> http://hackage.haskell.org/trac/ghc/ticket/2063
>>
>> The patches haven't been merged into stable yet, but you can grab a HEAD 
>> snapshot and try that instead - we'd appreciate the testing.
> 
> I checked out and translated the head version of ghc today from darcs.
> It compiled fine. When I now try to start the ghci I get the following:
> 
> ---- snip ----
> GHCi, version 6.11.20081126: http://www.haskell.org/ghc/  :? for help
> ghc: internal error: loadObj: failed to mmap() memory below 2Gb; asked for 626688 bytes at 0x40000000, got 0x801635000.  Try specifying an address with +RTS -xm<addr> -RTS
>     (GHC version 6.11.20081126 for x86_64_unknown_freebsd)
> 	    Please report this as a GHC bug:  http://www.haskell.org/ghc/reportabug
> 		Abort (core dumped)	
> ---- snip ----
> 
> If it helps somehow, you can find the core dump here:
> http://www.alios.org/~alios/ghc.core.bz2

That's odd, because 6.8.3 is using 0x40000000 on FreeBSD and is working 
fine (or is it?).

Ideally I need to find out what the memory map is for GHCi.  I posted some 
instructions for doing this on Linux/Xen, maybe you can adapt these to work 
on FreeBSD:

http://www.haskell.org/pipermail/glasgow-haskell-users/2008-November/016091.html

The bit that needs to change is 'cat /proc/<pid>/maps' - does FreeBSD have 
something similar?

Also you could try doing as the error message suggests, and specify a 
different address.  e.g.

   ghci +RTS -xm30000000
   ghci +RTS -xm50000000

for 0.75 and 1.25GB respectively.

Cheers,
	Simon



More information about the Glasgow-haskell-users mailing list