Ticket #4045 (closed bug: worksforme)

Opened 3 years ago

Last modified 2 years ago

Ghc panics 'ASSERT failed! file compiler/typecheck/TcTyFuns.lhs line 318' when compiling my ghc tree.

Reported by: milan Owned by:
Priority: normal Milestone: 7.0.1
Component: Compiler Version: 6.13
Keywords: Cc: simonpj@…
Operating System: Linux Architecture: x86_64 (amd64)
Type of failure: Compile-time crash Difficulty:
Test Case: Blocked By:
Blocking: Related Tickets:

Description (last modified by simonpj) (diff)

In the middle of the work on GHC backend I triggered a bug in GHC. After discussing with simonpj, I have snapshotted the source tree, as I could not reduce the test case.

When compiled the stage 1 compiler with -DDEBUG, ghc-stage1 compiler panics when compiling stage 2. It is enough to invoke 'make' in the tree to get following compilation error:

ghc-stage1: panic! (the 'impossible' happened)
  (GHC version 6.13 for x86_64-unknown-linux):
        ASSERT failed! file compiler/typecheck/TcTyFuns.lhs line 318
[Wanted t_a1KB{tv} [tau] :: hoopl-3.8.0.0:Compiler.Hoopl.Dataflow.Fact{tc raN}
                              x{tv a1Ks} [sk] ghc-6.13:CmmSpillReload.DualLive{tc r11W}
                              ~
                            hoopl-3.8.0.0:Compiler.Hoopl.Dataflow.Fact{tc raN}
                              x{tv a1Ks} [sk] f{tv a1Kt} [tau]]

The file causing the bug is compiler/cmm/CmmSpillReload.hs. On line 271, there is a description of a change that makes the source compile.

This is different to #4044:

  • #4044 is a bug in 6.12.2
  • #4045 is a bug in the HEAD, when compiling code that 6.12.2 managed to compile.

Milan managed to find a way to change the source code to avoid both bugs.

Change History

Changed 3 years ago by milan

The tree is at /64playpen/t-mistra/ghc-bug-4045. Anyone in GHC group can modify everything.

Changed 3 years ago by simonpj

  • description modified (diff)

Changed 3 years ago by igloo

  • milestone set to 6.14.1

Changed 2 years ago by simonpj

This bug was never reproducible and seems to have gone away, so I'm closing it.

Changed 2 years ago by simonpj

  • status changed from new to closed
  • resolution set to worksforme
Note: See TracTickets for help on using tickets.