Hi.

This occurs with both the package 4.02 source and the current source
(well the only differ in a file or two). I am using the binary ghc for
compilation. Details:

$ tar xzf ghc-current-src.tar.gz 
$ mv ghc-4.02 fptools
$ mkdir fptools-build; cd fptools-build; lndir ../fptools
[snip]
$ rm configure; autoconf
[snip]
$ ./configure --prefix=/usr/local/somewhere
[snip]
$ echo "GhcHcOpts=-optCrts-M100m" > mk/build.mk
[otherwise ParseIface fails to compile]
$ make boot
[snip]
$ make all
[after some time has passed]
==fptools== make all --no-print-directory -r;
 in /home/myxie/devel/ghc/fptools-build/ghc/lib/std
------------------------------------------------------------------------
rm -f PrelBase.o ; if [ ! -d PrelBase ]; then mkdir PrelBase; else find PrelBase -name 
'*.o' -print | xargs rm -f __rm_food ; fi ;    
../../../ghc/driver/ghc -recomp -cpp -fglasgow-exts -fvia-C -Rghc-timing -O 
-split-objs -odir PrelBase  -H10m  -c PrelBase.lhs -o PrelBase.o -osuf o
make[3]: *** [PrelBase.o] Error 1
make[2]: *** [all] Error 1
make[1]: *** [all] Error 1
make: *** [all] Error 1

The lack of a diagnostic is rather annoying! Is this a known
problem?

Compiling with -dshow-passes indicates failure during or after the Code
Output phase. I don't think I'm running into any ulimit problems.

After hacking HC := strace ... $(HC) into build.mk an examination of
the straces reveals:

execve("/bin/sh", ["sh", "-c", "/home/myxie/devel/ghc/fptools-bu"...], [/* 26 vars 
*/]) = 0
...
getrusage(RUSAGE_SELF, {ru_utime={35, 750000}, ru_stime={0, 720000}, ...}) = 0
write(5, "   254152    270336  12581296  0"..., 79) = 79
write(6, ");\nEF_(PrelBase_ZCDShow_con_ent"..., 5597) = 5597
close(6)                                = 0
times({tms_utime=3575, tms_stime=72, tms_cutime=0, tms_cstime=0}) = 13579633
times({tms_utime=3575, tms_stime=72, tms_cutime=0, tms_cstime=0}) = 13579633
write(5, "   175104                      0"..., 567) = 567
close(5)                                = 0
munmap(0x40015000, 4096)                = 0
--- SIGSEGV (Segmentation fault) ---

fd 6 was "/tmp/ghc402.hc", fd 5 was "/tmp/ghc402.stat". The mmap was
produced with:

mmap(0, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x40015000
which is immeditiately followed by:
mmap(0x50000000, 1048576, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 
0x50000000
(4K and 1M respectively)

This is the compiler in action! Earlier in the strace there is:
write(2, "R", 1)                        = 1
write(2, "e", 1)                        = 1
This is part of the byte-by-byte output of "** Reader:\n" I thought IO
output had been improved? Or has buffering been turned off altogeter?

Is there much point in trying for a coredump?

Other details:

/dev/hda9              1988924   1141915    744195  61% /home
/dev/hda6               248847       634    235363   0% /tmp
64M of RAM, 128M of swap
Linux henry 2.2.6 #5 Thu May 6 15:15:49 BST 1999 i686 unknown
GNU Make version 3.77, by Richard Stallman and Roland McGrath.
ldd (GNU libc) 2.1.1
egcs-2.91.66 (1.1.2 source)
GNU ld 2.9.1 (binutils version)
The Glorious Glasgow Haskell Compilation System, version 4.02, patchlevel 0
Happy Version 1.5 Copyright (c) Andy Gill, Simon Marlow 1993-1997

I suppose I should try the from-hc build.

Giuliano.

Reply via email to