failure implementing :next command in ghci
Peter Hercek
phercek at gmail.com
Fri Apr 17 07:33:27 EDT 2009
Hi,
Maybe the code adding one Int argument to rts_breakpoint_io_action is
correct in general since when Pepe Iborra applied the patch to his ghc
trunk the test did not crash on his machine. Regardless on my machine
the test does not work even with the stock ghc 6.10.2 sources (so even
when I do not have the patch applied). Here is how I did the test on my
32 bit archlinux:
* downloaded ghc-6.10.2-src.tar.bz2 from
http://haskell.org/ghc/download_ghc_6_10_2.html#sources
(I did not download the extralibs tarball)
* unpacked ghc-6.10.2-src.tar.bz2 and did this in the ghc-6.10.2 directory:
./boot
./configure
make
* then I did this test:
status:0 peter at metod [892] ~/haskell/ghc-6.10.2
% cat a.hs
f :: Int -> Int
f x = x + 1
a = f 1
status:0 peter at metod [893] ~/haskell/ghc-6.10.2
% ghc/stage2-inplace/ghc --interactive a.hs
GHCi, version 6.10.2: http://www.haskell.org/ghc/ :? for help
Loading package ghc-prim ... linking ... done.
Loading package integer ... linking ... done.
Loading package base ... linking ... done.
[1 of 1] Compiling Main ( a.hs, interpreted )
Ok, modules loaded: Main.
*Main> :break f
Breakpoint 0 activated at a.hs:2:0-10
*Main> :force a
zsh: segmentation fault ghc/stage2-inplace/ghc --interactive a.hs
status:139 peter at metod [894] ~/haskell/ghc-6.10.2
%
The test works ok when I do it with the ghc-custom I have installed
(6.10.1 with few of my patches).
The same behavior is on my laptop which has only stock uptodate
archlinux, and stock ghc 6.10.1 installed (so I think it cannot be
because of my few patches in ghc 6.10.1). I did the clean build and the
test there too. Well to be precise, it works worse on my laptop since
when I try to run ghci 6.10.1 (as distributed by archlinux) I'll get a
crash too:
status:0 peter at dwarf [852] ~/haskell/ghc-6.10.2
% ghci a.hs
GHCi, version 6.10.1: http://www.haskell.org/ghc/ :? for help
Loading package ghc-prim ... linking ... done.
Loading package integer ... linking ... done.
Loading package base ... linking ... done.
[1 of 1] Compiling Main ( a.hs, interpreted )
Ok, modules loaded: Main.
*Main> :break f
Breakpoint 0 activated at a.hs:2:0-10
*Main> :force
a%
status:139 peter at dwarf [853] ~/haskell/ghc-6.10.2
%
The question is: Is the test supposed to work with ghc 6.10.2 without
installing it?
I hope I'm doing some stupid mistake and that archlinux is not borked.
What is the platform (distribution and it's version) ghc HQ uses for ghc
development (on which the test I presented works)?
Thanks,
Peter.
More information about the Glasgow-haskell-users
mailing list