[GHC] #776: GHCi 6.4.2 reports an internal error: unknown/strange object

GHC trac at galois.com
Tue May 23 15:20:53 EDT 2006


#776: GHCi 6.4.2 reports an internal error: unknown/strange object
--------------------------------------------+-------------------------------
  Reporter:  john.detreville at microsoft.com  |          Owner:       
      Type:  bug                            |         Status:  new  
  Priority:  normal                         |      Milestone:  6.4.2
 Component:  GHCi                           |        Version:  6.4.2
  Severity:  normal                         |       Keywords:       
Difficulty:  Unknown                        |   Architecture:  x86  
        Os:  Windows                        |  
--------------------------------------------+-------------------------------
I have a medium-sized interpreted program that seems to corrupt the heap
 when running under GHCi. Here's a couple of examples. (Ignore the first
 run, of course.)


 {{{
 C:\Documents and Settings\johndetr\My Documents\Haskell\Eval>ghci
    ___         ___ _
   / _ \ /\  /\/ __(_)
  / /_\// /_/ / /  | |      GHC Interactive, version 6.4.2, for Haskell 98.
 / /_\\/ __  / /___| |      http://www.haskell.org/ghc/
 \____/\/ /_/\____/|_|      Type :? for help.

 Loading package base-1.0 ... linking ... done.
 Prelude> :load Main
 Compiling Types            ( ./Types.hs, interpreted )
 Compiling Layout           ( ./Layout.hs, interpreted )
 Compiling Eval             ( ./Eval.hs, interpreted )
 Compiling Main             ( Main.hs, interpreted )
 Ok, modules loaded: Main, Eval, Layout, Types.
 *Main> main
 Loading package haskell98-1.0 ... linking ... done.
 Loading package haskell-src-1.0 ... linking ... done.
 HsVar (UnQual (HsIdent "result"))
 338350
 [Node (Color 0.0 0.5 0.0) 12005 "338350"]
 GHC's heap exhausted: current limit is 268435456 bytes;
 Use the `-M<size>' option to increase the total heap size.

 C:\Documents and Settings\johndetr\My Documents\Haskell\Eval>ghci +RTS
 -M500m
    ___         ___ _
   / _ \ /\  /\/ __(_)
  / /_\// /_/ / /  | |      GHC Interactive, version 6.4.2, for Haskell 98.
 / /_\\/ __  / /___| |      http://www.haskell.org/ghc/
 \____/\/ /_/\____/|_|      Type :? for help.

 Loading package base-1.0 ... linking ... done.
 Prelude> :load Main
 Compiling Types            ( ./Types.hs, interpreted )
 Compiling Layout           ( ./Layout.hs, interpreted )
 Compiling Eval             ( ./Eval.hs, interpreted )
 Compiling Main             ( Main.hs, interpreted )
 Ok, modules loaded: Main, Eval, Layout, Types.
 *Main> main
 Loading package haskell98-1.0 ... linking ... done.
 Loading package haskell-src-1.0 ... linking ... done.
 HsVar (UnQual (HsIdent "result"))
 338350
 [Node (Color 0.0 0.5 0.0) 12005 "338350"]
 <interactive>: internal error: update_fwd: unknown/strange object  38769
     Please report this as a compiler bug.  See:
     http://www.haskell.org/ghc/reportabug

 C:\Documents and Settings\johndetr\My Documents\Haskell\Eval>ghci +RTS
 -M800m
    ___         ___ _
   / _ \ /\  /\/ __(_)
  / /_\// /_/ / /  | |      GHC Interactive, version 6.4.2, for Haskell 98.
 / /_\\/ __  / /___| |      http://www.haskell.org/ghc/
 \____/\/ /_/\____/|_|      Type :? for help.

 Loading package base-1.0 ... linking ... done.
 Prelude> :load Main
 Compiling Types            ( ./Types.hs, interpreted )
 Compiling Layout           ( ./Layout.hs, interpreted )
 Compiling Eval             ( ./Eval.hs, interpreted )
 Compiling Main             ( Main.hs, interpreted )
 Ok, modules loaded: Main, Eval, Layout, Types.
 *Main> main

 <interactive>:1:0: Not in scope: `gain'
 *Main> main
 Loading package haskell98-1.0 ... linking ... done.
 Loading package haskell-src-1.0 ... linking ... done.
 HsVar (UnQual (HsIdent "result"))
 338350
 [Node (Color 0.0 0.5 0.0) 12005 "338350"]
 <interactive>: internal error: update_fwd: unknown/strange object  38769
     Please report this as a compiler bug.  See:
     http://www.haskell.org/ghc/reportabug
 }}}

 So, would you like the source files? Or how else can I help?

 Also, I run into the "gain" bug above quite often when I type ahead to
 GHCi under Windows. I assume this is known behavior.

 Finally, when I got the initial message above to use the -M flag, it took
 me forever to remember to add the +RTS flag. Perhaps the message could be
 reworded to help people like me?

 Cheers,
 John

-- 
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/776>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler


More information about the Glasgow-haskell-bugs mailing list