Opened 2 years ago

Closed 2 years ago

#7628 closed feature request (fixed)

Improve error message when mixing 32bit and 64bit images

Reported by: morabbin Owned by: igloo
Priority: normal Milestone:
Component: Compiler Version: 7.6.1
Keywords: Cc:
Operating System: MacOS X Architecture: Unknown/Multiple
Type of failure: None/Unknown Test Case:
Blocked By: Blocking:
Related Tickets: Differential Revisions:

Description

Since we know when the user has mixed 32 and 64 bit images, let's say so in the error message. Before:

Loading object (static) dist/build/HOC_cbits.o ... ghc: dist/build/HOC_cbits.o: Bad magic. Expected: feedfacf, got: feedface.

ghc: panic! (the 'impossible' happened)
  (GHC version 7.6.1 for x86_64-apple-darwin):
        loadObj "dist/build/HOC_cbits.o": failed

Please report this as a GHC bug:  http://www.haskell.org/ghc/reportabug

After:

Loading object (static) dist/build/HOC_cbits.o ... ghc-stage2: Could not load image dist/build/HOC_cbits.o: bad magic!
  Expected feedfacf (64bit), got feedface (32bit).

ghc-stage2: panic! (the 'impossible' happened)
  (GHC version 7.7.20130124 for x86_64-apple-darwin):
        loadObj "dist/build/HOC_cbits.o": failed

Patch to come.

Attachments (1)

0001-Patch-for-7628-improve-error-message-when-mixing-32-.patch (1.4 KB) - added by morabbin 2 years ago.
Patch for #7628

Download all attachments as: .zip

Change History (5)

comment:1 Changed 2 years ago by morabbin

  • Status changed from new to patch

comment:2 Changed 2 years ago by simonpj

  • difficulty set to Unknown
  • Owner set to igloo

Assigning to Ian for patch review

comment:3 Changed 2 years ago by andy.adamsmoran@…

commit 12e3d3f4690d76b57ca70cdfdbad049fabd79bde

Author: Andy Adams-Moran <[email protected]>
Date:   Fri Jan 25 11:11:01 2013 -0800

    Patch for #7628: improve error message when mixing 32 and 64 bit images (on Mac OS X)

 rts/Linker.c |   12 ++++++++----
 1 files changed, 8 insertions(+), 4 deletions(-)

comment:4 Changed 2 years ago by igloo

  • Resolution set to fixed
  • Status changed from patch to closed

Applied, thanks

Note: See TracTickets for help on using tickets.