[cvs-nhc98] Status of nhc98 on 64bit platforms

Malcolm Wallace Malcolm.Wallace at cs.york.ac.uk
Thu Feb 22 05:12:29 EST 2007


Sven Panne <sven.panne at aedion.de> writes:

> Just out of curiosity, I've just tried to build and install nhc98 from the 
> darcs repo on an x86_64 Linux platform
> 
> So what is the current status on 64bit platforms?

nhc98 does not support 64-bit platforms, it is 32-bit only.  However,
judging from the fact that I am able to build nhc98 just fine on a
64-bit PowerPC G5, the story is a little more nuanced than that.

Apple's gcc is configured to use the 32-bit ABI by default (the -m32
flag).  I am guessing that your Linux box has gcc configured with -m64
as the default.  So perhaps if you can work out how to pass -m32 to all
the C compiler invocations (including those that compile the bytecode
output of the nhc98 compiler proper into C arrays)?
Unfortunately,
    ./configure --buildopts="-m32"
is not the right thing - it only applies to the bootstrapping Haskell
compiler.

> Are the problems fixable within a reasonable timeframe?

Of course, using the 32-bit ABI is only a workaround I suppose.
Ultimately it should work in native 64-bit mode as well.  nhc13 did once
support the alpha processor, but that was in the days when it generated
assembly code containing the bytecodes, rather than C arrays.  Yhc fixes
this properly by storing the bytecode in an independent format, and
loading it explicitly into memory at runtime.

Regards,
    Malcolm


More information about the Cvs-nhc98 mailing list