[GHC] #14626: No need to enter a scrutinised value
GHC
ghc-devs at haskell.org
Fri Jan 5 15:31:19 UTC 2018
#14626: No need to enter a scrutinised value
-------------------------------------+-------------------------------------
Reporter: heisenbug | Owner: heisenbug
Type: bug | Status: new
Priority: normal | Milestone:
Component: Compiler | Version: 8.2.2
Resolution: | Keywords: performance
Operating System: Unknown/Multiple | Architecture:
| Unknown/Multiple
Type of failure: None/Unknown | Test Case:
Blocked By: | Blocking:
Related Tickets: #13861 | Differential Rev(s):
Wiki Page: |
-------------------------------------+-------------------------------------
Comment (by heisenbug):
Replying to [comment:10 simonpj]:
> The names of the variables should not make any difference! That's
bizarre.
Of course it is not the names, ''per se''! Rather, one of the names
starting with `ds` is misbehaving in a specific way, that trips over
`stage2`.
I built a `quick` compiler with the given revision, that is `stage2`
compiled with `-O0`, and it behaves well. Testsuite passes without any
strangeness.
Then I bisected the sources in `compiler/*` and isolated these two
(mutually dependent) sources, which when built with `-O1` (and all others
with `-O0`) break stage 2. Here is what I did (for the record):
{{{#!sh
nice make V=1 GhcStage2HcOpts="-O0 -g" -j8
rm compiler/stage2/build/StgCmmBind.*
nice make V=1 GhcStage2HcOpts="-O1 -g" -j8
./compiler/stage2/build/StgCmmBind.hi
nice make V=1 GhcStage2HcOpts="-O0 -g" -j8
}}}
I'll have a look which differences occur here between `-O0` and `-O1`.
Both interesting sources are >500 LOC, so it won't be trivial :-)
>
> Guessing is usually fruitless; you need data.
>
> Did you add that assertionn I suggested?
>
> As I say, a stage2 compiler is a huge program. I urge you to first
build the libraries and compiler without the change; then switch the
change on and run the testsuite. Any bugs must be in those little
programs. Then nofib.
>
--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/14626#comment:11>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler
More information about the ghc-tickets
mailing list