#4414: scc001 fails: one SCC entered 0 times; another not mentioned when
optimisation is on
---------------------------------+------------------------------------------
Reporter: igloo | Owner:
Type: bug | Status: new
Priority: normal | Milestone: 7.0.2
Component: Profiling | Version: 6.12.3
Keywords: | Testcase:
Blockedby: | Difficulty:
Os: Unknown/Multiple | Blocking:
Architecture: Unknown/Multiple | Failure: None/Unknown
---------------------------------+------------------------------------------
Comment(by simonpj):
I looked at (a), the missing entry to `g` with `-O0`. The Core code looks
right, and STG:
{{{
let {
sat_sht :: GHC.Types.IO ()
[LclId]
sat_sht =
let {
x_sha :: GHC.Types.Int
[LclId, Unf=OtherCon []]
x_sha = GHC.Types.I# 3 } in
let {
sat_shu :: GHC.Types.Int
[LclId]
sat_shu = __scc {g main:Main} x_sha } in
let {
sat_shv :: GHC.Types.Int -> GHC.Types.IO ()
[LclId]
sat_shv = System.IO.print @ GHC.Types.Int GHC.Show.$fShowInt }
in
GHC.Base.$ @ GHC.Types.Int @ (GHC.Types.IO ()) sat_shv sat_shu }
in
}}}
Note the `_scc` for "g".
The `sat_shu` closure gets compiled into a "standard form ap closure", and
the code looks a bit suspicious. I think it'll turn out to be an
interaction between these standard-form closures and profiling, but I need
to look at it with Simon.
--
Ticket URL: <http://hackage.haskell.org/trac/ghc/ticket/4414#comment:1>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
_______________________________________________
Glasgow-haskell-bugs mailing list
[email protected]
http://www.haskell.org/mailman/listinfo/glasgow-haskell-bugs