Opened 9 years ago

Last modified 8 months ago

#2648 new feature request

Report out of date interface files robustly

Reported by: simonpj Owned by:
Priority: lowest Milestone:
Component: GHCi Version: 7.6.3
Keywords: TypeErrorMessages Cc: pho@…, hackage.haskell.org@…, hvr, asr
Operating System: Unknown/Multiple Architecture: Unknown/Multiple
Type of failure: GHCi crash Test Case:
Blocked By: Blocking:
Related Tickets: Differential Rev(s):
Wiki Page:

Description

Suppose X.hi refers to Y.f77, but Y.hi is out of date and has no f77. Then you get a bad crash:

(GHC version 6.8.3 for i386-unknown-mingw32):
    tcIfaceGlobal (local): not found:
Please report this as a GHC bug

The solution lies within our grasp:

  • X.hi already contains a fingerprint for Y.hi
  • So, we should simply check Y.hi's fingerprint when we suck it in

(Currently we do this fingerprint checking only for the module we are currently compiling, to see if the bits it depends on have changed.)

Simon

Change History (22)

comment:1 Changed 9 years ago by PHO

Cc: pho@… added

comment:2 Changed 8 years ago by igloo

Milestone: 6.12 branch6.12.3

comment:3 Changed 8 years ago by igloo

Milestone: 6.12.36.14.1
Priority: normallow

comment:4 Changed 7 years ago by igloo

Milestone: 7.0.17.0.2

comment:5 Changed 7 years ago by igloo

Milestone: 7.0.27.2.1

comment:6 Changed 6 years ago by igloo

Milestone: 7.2.17.4.1

comment:7 Changed 6 years ago by igloo

Milestone: 7.4.17.6.1
Priority: lowlowest

comment:8 Changed 5 years ago by igloo

Milestone: 7.6.17.6.2

comment:9 Changed 5 years ago by liyang

Cc: hackage.haskell.org@… added
Type of failure: None/Unknown
Version: 6.8.37.6.3

This is biting me on a regular basis when I :reload a fairly large project in GHCi. It didn't seem to crop up so often (at all?) back when I was still using 7.4.2…

comment:10 Changed 5 years ago by liyang

Component: CompilerGHCi
Type of failure: None/UnknownGHCi crash

For what it's worth, I don't think I have ever seen this when compiling the project.

comment:11 Changed 5 years ago by liyang

I'm not entirely sure if what I'm seeing is due to out-of-date interface files, but see the details below:

ghc: panic! (the 'impossible' happened)
  (GHC version 7.6.3 for x86_64-unknown-linux):
        tcIfaceGlobal (local): not found:
<<details unavailable>>

comment:12 Changed 5 years ago by igloo

Can anyone give me a testcase for this please?

comment:13 Changed 5 years ago by simonpj

As Ian says, I think we are stalled on fixing this until we have a test case. The scenario I wrote up at the start is a bit contrived, and I'm far from certain that it's what people are tripping over.

Simon

comment:14 Changed 4 years ago by simonmar

Cc: hvr added

@liyang: this should never happen during the normal course of developing and reloading a multi-module program in GHCi. You're probably encountering a different bug with the same symptom. We'd be really grateful if you could find a way to reproduce it; if so just open another ticket and dump your instructions in there.

comment:15 Changed 3 years ago by thoughtpolice

Milestone: 7.6.27.10.1

Moving to 7.10.1.

comment:16 Changed 3 years ago by thoughtpolice

Milestone: 7.10.17.12.1

Moving to 7.12.1 milestone; if you feel this is an error and should be addressed sooner, please move it back to the 7.10.1 milestone.

comment:17 Changed 3 years ago by thoughtpolice

Moving to 7.12.1 milestone; if you feel this is an error and should be addressed sooner, please move it back to the 7.10.1 milestone.

comment:18 Changed 3 years ago by asr

Cc: asr added

comment:19 Changed 2 years ago by thoughtpolice

Milestone: 7.12.18.0.1

Milestone renamed

comment:20 Changed 23 months ago by thomie

Milestone: 8.0.1

comment:21 Changed 8 months ago by simonpj

comment:22 Changed 8 months ago by simonpj

Keywords: TypeErrorMessages added
Note: See TracTickets for help on using tickets.