[GHC] #2124: My program compiles with -O1 but compiler panics
with -O2 and up
GHC
trac at galois.com
Wed Feb 27 05:51:57 EST 2008
#2124: My program compiles with -O1 but compiler panics with -O2 and up
--------------------------+-------------------------------------------------
Reporter: brassel | Owner:
Type: bug | Status: new
Priority: normal | Milestone:
Component: Compiler | Version: 6.8.2
Severity: minor | Resolution:
Keywords: optimization | Difficulty: Unknown
Testcase: | Architecture: x86
Os: Linux |
--------------------------+-------------------------------------------------
Comment (by brassel):
Ha, I succeeded in isolating the bug quite a bit:
{{{
module CompileBug where
import qualified Data.Map as FM
data J = J (String,String)
myFromList = FM.fromList
myLookup = FM.lookup
myMember = FM.member
elimConsts = myMember True
makeTypeMap ps s = maybe undefined id (myLookup s fm)
where
fm = myFromList (concatMap typeMapTypeDecl ps)
typeMapTypeDecl consDecls = zip (map (\ (J name) -> name) consDecls)
undefined
}}}
Hope this helps!
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/2124#comment:3>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the Glasgow-haskell-bugs
mailing list