id,summary,reporter,owner,description,type,status,priority,milestone,component,version,resolution,keywords,cc,os,architecture,failure,testcase,blockedby,blocking,related,differential,wikipage
2264,"Validate using ghc-6.4.1: 3 failures, 1 workaround, 1 fix",thorkilnaur,,"Using
{{{
$ uname -a
Linux linux 2.6.13-15-default #1 Tue Sep 13 14:56:15 UTC 2005 i686 i686 i386 GNU/Linux
$ ghc --version
The Glorious Glasgow Haskell Compilation System, version 6.4.1
}}}
to validate a recent HEAD, I get the following error:
{{{
/home/tn/tn/install/ghc-6.4.1/bin/ghc -Werror -H64m -Onot -fasm -istage1/utils -istage1/basicTypes -istage1/types -istage1/hsSyn -istage1/prelude -istage1/rename -istage1/typecheck -istage1/deSugar -istage1/coreSyn -istage1/vectorise -istage1/specialise -istage1/simplCore -istage1/stranal -istage1/stgSyn -istage1/simplStg -istage1/codeGen -istage1/main -istage1/profiling -istage1/parser -istage1/cprAnalysis -istage1/iface -istage1/cmm -istage1/nativeGen -Wall -fno-warn-name-shadowing -fno-warn-orphans -Istage1 -cpp -fglasgow-exts -fno-generics -Rghc-timing -I. -Iparser -package unix -ignore-package lang -recomp -Rghc-timing -O -fasm -H16M '-#include ""cutils.h""' -DUSING_COMPAT -i../compat -ignore-package Cabal -c utils/Util.lhs -o stage1/utils/Util.o -ohi stage1/utils/Util.hi
utils/Util.lhs:204:0:
Warning: Pattern match(es) are non-exhaustive
In the definition of `zipLazy': Patterns not matched: (_ : _) []
<>
make[1]: *** [stage1/utils/Util.o] Error 1
make[1]: *** Waiting for unfinished jobs....
<>
make: *** [stage1] Error 1
}}}
Offhand, I was not able to find a correction to this problem that was also found acceptanble by the stage2 (GHC-6.9-ish) compiler, so I simply ended up working around by disabling warnings, as indicated in first of the attached patches. Which should not, I stress, be taken as my suggested solution, simply as a way of getting ahead with the validate. (I am sure that a suitable solution can be found by the appropriate experts, as needed.)
In any case, with this workaround in place, I get:
{{{
/home/tn/tn/install/ghc-6.4.1/bin/ghc -Werror -H64m -Onot -fasm -istage1/utils -istage1/basicTypes -istage1/types -istage1/hsSyn -istage1/prelude -istage1/rename -istage1/typecheck -istage1/deSugar -istage1/coreSyn -istage1/vectorise -istage1/specialise -istage1/simplCore -istage1/stranal -istage1/stgSyn -istage1/simplStg -istage1/codeGen -istage1/main -istage1/profiling -istage1/parser -istage1/cprAnalysis -istage1/iface -istage1/cmm -istage1/nativeGen -Wall -fno-warn-name-shadowing -fno-warn-orphans -Istage1 -cpp -fglasgow-exts -fno-generics -Rghc-timing -I. -Iparser -package unix -ignore-package lang -recomp -Rghc-timing -O -fasm -H16M '-#include ""cutils.h""' -DUSING_COMPAT -i../compat -ignore-package Cabal -c basicTypes/OccName.lhs -o stage1/basicTypes/OccName.o -ohi stage1/basicTypes/OccName.hi
basicTypes/OccName.lhs:86:0:
Warning: Definition but no type signature for `isSymbol'
<>
make[1]: *** [stage1/basicTypes/OccName.o] Error 1
make[1]: *** Waiting for unfinished jobs....
<>
make: *** [stage1] Error 1
}}}
And this time, the attached patch that eliminates this warning could be found to be the actual solution to the problem.
Unfortunately, even with the second patch in place, I get:
{{{
/home/tn/tn/install/ghc-6.4.1/bin/ghc -Werror -H64m -Onot -fasm -istage1/utils -istage1/basicTypes -istage1/types -istage1/hsSyn -istage1/prelude -istage1/rename -istage1/typecheck -istage1/deSugar -istage1/coreSyn -istage1/vectorise -istage1/specialise -istage1/simplCore -istage1/stranal -istage1/stgSyn -istage1/simplStg -istage1/codeGen -istage1/main -istage1/profiling -istage1/parser -istage1/cprAnalysis -istage1/iface -istage1/cmm -istage1/nativeGen -Wall -fno-warn-name-shadowing -fno-warn-orphans -Istage1 -cpp -fglasgow-exts -fno-generics -Rghc-timing -I. -Iparser -package unix -ignore-package lang -recomp -Rghc-timing -O -fasm -H16M '-#include ""cutils.h""' -DUSING_COMPAT -i../compat -ignore-package Cabal -c cmm/ZipDataflow.hs -o stage1/cmm/ZipDataflow.o -ohi stage1/cmm/ZipDataflow.hi
cmm/ZipDataflow.hs:285:0:
Contexts differ in length
When matching the contexts of the signatures for
fwd_pure_anal :: forall m l a.
(DebugNodes m l, Outputable a) =>
PassName
-> BlockEnv a
-> ForwardTransfers m l a
-> a
-> Graph m l
-> DFM a (ForwardFixedPoint m l a ())
forward_sol :: forall m l (g :: * -> * -> *) a.
(DebugNodes m l, LastNode l, Outputable a) =>
(forall a. Fuel -> Maybe a -> Maybe a)
-> (g m l -> DFM a (Graph m l))
-> RewritingDepth
-> PassName
-> BlockEnv a
-> ForwardTransfers m l a
-> ForwardRewrites m l a g
-> a
-> Graph m l
-> Fuel
-> DFM a (ForwardFixedPoint m l a (), Fuel)
The signature contexts in a mutually recursive group should all be identical
cmm/ZipDataflow.hs:309:19:
GHC internal error: `a' is not in scope
In the type signature:
forw :: RewritingDepth
-> PassName
-> BlockEnv a
-> ForwardTransfers m l a
-> ForwardRewrites m l a g
-> a -> Graph m l -> Fuel -> DFM a (ForwardFixedPoint m l a (), Fuel)
In the definition of `forward_sol':
forward_sol check_maybe return_graph
= forw
where
forw ::
RewritingDepth
-> PassName
-> BlockEnv a
-> ForwardTransfers m l a
-> ForwardRewrites m l a g
-> a -> Graph m l -> Fuel -> DFM a (ForwardFixedPoint m l a (), Fuel)
forw rewrite name start_facts transfers rewrites
= let
either_last rewrites in' (LastExit) = ...
either_last rewrites in' (LastOther l) = ...
anal_f :: DFM a b -> a -> Graph m l -> DFM a b
anal_f finish in' g = ...
solve :: DFM a b -> a -> Graph m l -> Fuel -> DFM a (b, Fuel)
solve_tail in' (ZTail m t) fuel = ...
solve_tail in' (ZLast l) fuel = ...
solve finish in_fact (Graph entry blockenv) fuel = ...
fixed_point in_fact g fuel = ...
in fixed_point
cmm/ZipDataflow.hs:317:21:
GHC internal error: `a' is not in scope
In the type signature: anal_f :: DFM a b -> a -> Graph m l -> DFM a b
In the definition of `forw':
forw rewrite name start_facts transfers rewrites
= let
either_last rewrites in' (LastExit) = fr_exit rewrites in'
either_last rewrites in' (LastOther l) = fr_last rewrites in' l
anal_f :: DFM a b -> a -> Graph m l -> DFM a b
anal_f finish in' g
= do
...
...
solve :: DFM a b -> a -> Graph m l -> Fuel -> DFM a (b, Fuel)
solve_tail in' (ZTail m t) fuel
= case ... of
Nothing -> ...
Just g -> ...
solve_tail in' (ZLast l) fuel
= case ... of
Nothing -> ...
Just g -> ...
solve finish in_fact (Graph entry blockenv) fuel = let ... in ...
fixed_point in_fact g fuel
= do
...
(a, fuel) <- ...
facts <- ...
last_outs <- ...
let ...
let ...
...
in fixed_point
In the definition of `forward_sol':
forward_sol check_maybe return_graph
= forw
where
forw ::
RewritingDepth
-> PassName
-> BlockEnv a
-> ForwardTransfers m l a
-> ForwardRewrites m l a g
-> a -> Graph m l -> Fuel -> DFM a (ForwardFixedPoint m l a (), Fuel)
forw rewrite name start_facts transfers rewrites
= let
either_last rewrites in' (LastExit) = ...
either_last rewrites in' (LastOther l) = ...
anal_f :: DFM a b -> a -> Graph m l -> DFM a b
anal_f finish in' g = ...
solve :: DFM a b -> a -> Graph m l -> Fuel -> DFM a (b, Fuel)
solve_tail in' (ZTail m t) fuel = ...
solve_tail in' (ZLast l) fuel = ...
solve finish in_fact (Graph entry blockenv) fuel = ...
fixed_point in_fact g fuel = ...
in fixed_point
cmm/ZipDataflow.hs:321:20:
GHC internal error: `a' is not in scope
In the type signature:
solve :: DFM a b -> a -> Graph m l -> Fuel -> DFM a (b, Fuel)
In the definition of `forw':
forw rewrite name start_facts transfers rewrites
= let
either_last rewrites in' (LastExit) = fr_exit rewrites in'
either_last rewrites in' (LastOther l) = fr_last rewrites in' l
anal_f :: DFM a b -> a -> Graph m l -> DFM a b
anal_f finish in' g
= do
...
...
solve :: DFM a b -> a -> Graph m l -> Fuel -> DFM a (b, Fuel)
solve_tail in' (ZTail m t) fuel
= case ... of
Nothing -> ...
Just g -> ...
solve_tail in' (ZLast l) fuel
= case ... of
Nothing -> ...
Just g -> ...
solve finish in_fact (Graph entry blockenv) fuel = let ... in ...
fixed_point in_fact g fuel
= do
...
(a, fuel) <- ...
facts <- ...
last_outs <- ...
let ...
let ...
...
in fixed_point
In the definition of `forward_sol':
forward_sol check_maybe return_graph
= forw
where
forw ::
RewritingDepth
-> PassName
-> BlockEnv a
-> ForwardTransfers m l a
-> ForwardRewrites m l a g
-> a -> Graph m l -> Fuel -> DFM a (ForwardFixedPoint m l a (), Fuel)
forw rewrite name start_facts transfers rewrites
= let
either_last rewrites in' (LastExit) = ...
either_last rewrites in' (LastOther l) = ...
anal_f :: DFM a b -> a -> Graph m l -> DFM a b
anal_f finish in' g = ...
solve :: DFM a b -> a -> Graph m l -> Fuel -> DFM a (b, Fuel)
solve_tail in' (ZTail m t) fuel = ...
solve_tail in' (ZLast l) fuel = ...
solve finish in_fact (Graph entry blockenv) fuel = ...
fixed_point in_fact g fuel = ...
in fixed_point
cmm/ZipDataflow.hs:371:43:
Occurs check: cannot construct the infinite type: f = LastOutFacts f
Expected type: DFM f f
Inferred type: DFM f (LastOutFacts f)
In the first argument of `solve', namely `lastOutFacts'
In a case alternative:
RewriteDeep -> solve lastOutFacts in' g (oneLessFuel fuel)
cmm/ZipDataflow.hs:497:64:
Couldn't match the rigid variable `a' against `()'
`a' is bound by the type signature for `forward_rew'
Expected type: a
Inferred type: ()
In the first argument of `return', namely `()'
In the first argument of `inner_rew', namely `(return ())'
cmm/ZipDataflow.hs:584:19:
GHC internal error: `a' is not in scope
In the type signature:
back :: RewritingDepth
-> PassName
-> BlockEnv a
-> BackwardTransfers m l a
-> BackwardRewrites m l a g
-> Graph m l -> a -> Fuel -> DFM a (BackwardFixedPoint m l a (), Fuel)
In the definition of `backward_sol':
backward_sol check_maybe return_graph
= back
where
back ::
RewritingDepth
-> PassName
-> BlockEnv a
-> BackwardTransfers m l a
-> BackwardRewrites m l a g
-> Graph m l -> a -> Fuel -> DFM a (BackwardFixedPoint m l a (), Fuel)
back rewrite name start_facts transfers rewrites
= let
anal_b :: Graph m l -> a -> DFM a a
anal_b g out = ...
subsolve :: g m l -> a -> Fuel -> DFM a (a, Fuel)
solve :: Graph m l -> a -> Fuel -> DFM a (a, Fuel)
subsolve = ...
solve (Graph entry blockenv) exit_fact fuel = ...
set_head_fact (ZFirst id) a fuel = ...
set_head_fact (ZHead h m) a fuel = ...
fixed_point g exit_fact fuel = ...
in fixed_point
cmm/ZipDataflow.hs:592:23:
GHC internal error: `m' is not in scope
In the type signature: anal_b :: Graph m l -> a -> DFM a a
In the definition of `back':
back rewrite name start_facts transfers rewrites
= let
anal_b :: Graph m l -> a -> DFM a a
anal_b g out
= do
fp <- ...
...
subsolve :: g m l -> a -> Fuel -> DFM a (a, Fuel)
solve :: Graph m l -> a -> Fuel -> DFM a (a, Fuel)
subsolve = case ... of
RewriteDeep -> ...
RewriteShallow -> ...
solve (Graph entry blockenv) exit_fact fuel = let ... in ...
set_head_fact (ZFirst id) a fuel
= case ... of
Nothing -> ...
Just g -> ...
set_head_fact (ZHead h m) a fuel
= case ... of
Nothing -> ...
Just g -> ...
fixed_point g exit_fact fuel
= do
...
(a, fuel) <- ...
facts <- ...
let ...
...
in fixed_point
In the definition of `backward_sol':
backward_sol check_maybe return_graph
= back
where
back ::
RewritingDepth
-> PassName
-> BlockEnv a
-> BackwardTransfers m l a
-> BackwardRewrites m l a g
-> Graph m l -> a -> Fuel -> DFM a (BackwardFixedPoint m l a (), Fuel)
back rewrite name start_facts transfers rewrites
= let
anal_b :: Graph m l -> a -> DFM a a
anal_b g out = ...
subsolve :: g m l -> a -> Fuel -> DFM a (a, Fuel)
solve :: Graph m l -> a -> Fuel -> DFM a (a, Fuel)
subsolve = ...
solve (Graph entry blockenv) exit_fact fuel = ...
set_head_fact (ZFirst id) a fuel = ...
set_head_fact (ZHead h m) a fuel = ...
fixed_point g exit_fact fuel = ...
in fixed_point
cmm/ZipDataflow.hs:597:19:
GHC internal error: `g' is not in scope
In the type signature: subsolve :: g m l -> a -> Fuel -> DFM a (a, Fuel)
In the definition of `back':
back rewrite name start_facts transfers rewrites
= let
anal_b :: Graph m l -> a -> DFM a a
anal_b g out
= do
fp <- ...
...
subsolve :: g m l -> a -> Fuel -> DFM a (a, Fuel)
solve :: Graph m l -> a -> Fuel -> DFM a (a, Fuel)
subsolve = case ... of
RewriteDeep -> ...
RewriteShallow -> ...
solve (Graph entry blockenv) exit_fact fuel = let ... in ...
set_head_fact (ZFirst id) a fuel
= case ... of
Nothing -> ...
Just g -> ...
set_head_fact (ZHead h m) a fuel
= case ... of
Nothing -> ...
Just g -> ...
fixed_point g exit_fact fuel
= do
...
(a, fuel) <- ...
facts <- ...
let ...
...
in fixed_point
In the definition of `backward_sol':
backward_sol check_maybe return_graph
= back
where
back ::
RewritingDepth
-> PassName
-> BlockEnv a
-> BackwardTransfers m l a
-> BackwardRewrites m l a g
-> Graph m l -> a -> Fuel -> DFM a (BackwardFixedPoint m l a (), Fuel)
back rewrite name start_facts transfers rewrites
= let
anal_b :: Graph m l -> a -> DFM a a
anal_b g out = ...
subsolve :: g m l -> a -> Fuel -> DFM a (a, Fuel)
solve :: Graph m l -> a -> Fuel -> DFM a (a, Fuel)
subsolve = ...
solve (Graph entry blockenv) exit_fact fuel = ...
set_head_fact (ZFirst id) a fuel = ...
set_head_fact (ZHead h m) a fuel = ...
fixed_point g exit_fact fuel = ...
in fixed_point
cmm/ZipDataflow.hs:653:0:
Contexts differ in length
When matching the contexts of the signatures for
backward_sol :: forall m l (g :: * -> * -> *) a.
(DebugNodes m l, LastNode l, Outputable a) =>
(forall a. Fuel -> Maybe a -> Maybe a)
-> (g m l -> DFM a (Graph m l))
-> RewritingDepth
-> PassName
-> BlockEnv a
-> BackwardTransfers m l a
-> BackwardRewrites m l a g
-> Graph m l
-> a
-> Fuel
-> DFM a (CommonFixedPoint m l a (), Fuel)
bwd_pure_anal :: forall m l a.
(DebugNodes m l, Outputable a) =>
PassName
-> BlockEnv a
-> BackwardTransfers m l a
-> Graph m l
-> a
-> DFM a (CommonFixedPoint m l a ())
The signature contexts in a mutually recursive group should all be identical
<>
make[1]: *** [stage1/cmm/ZipDataflow.o] Error 1
make[1]: *** Waiting for unfinished jobs....
<>
make: *** [stage1] Error 1
}}}
And that is the state of affairs as I report this.
Best regards
Thorkil",bug,closed,high,6.10 branch,Compiler,6.9,fixed,,,Unknown/Multiple,Unknown/Multiple,None/Unknown,,,,,,