Ticket #6163 (closed bug: fixed)

Opened 11 months ago

Last modified 10 months ago

GHC stops producing runnable code in OSX Mountain Lion DP4

Reported by: smidget Owned by:
Priority: highest Milestone: 7.6.1
Component: Compiler Version: 7.4.2
Keywords: OSX, Mountain Lion, strange closure, abort Cc: chak@…, gdr@…, benl@…, pho@…, anton.nik@…, jhenahan@…, ireney.knapp@…
Operating System: MacOS X Architecture: Unknown/Multiple
Type of failure: Incorrect result at runtime Difficulty: Unknown
Test Case: Blocked By:
Blocking: Related Tickets:

Description

Yesterday I upgraded my OSX 10.8 Mountain Lion Developer Preview 3 install to Developer Preview 4, and this appears to have broken GHC. I've tried the GHC included in the OSX Haskell-Package 2012.2.0.0 as well as the GHC from Homebrew in both 32 and 64 bit versions. Everything worked flawlessly in Developer Previews 2 and 3.

I can compile software just fine, and when I run it it appears to run, but then aborts with a strange closure error. For example, I can run Xmonad for several seconds before it crashes.

I've been able to replicate this in both a fresh install of Mountain Lion DP4 on a clean partition and on my upgrade from DP3.

To replicate, install Mountain Lion DP4 on a fresh partition, install GHC either from Homebrew or Haskell-Package, and try to compile a hello world program. It will compile without error, but when running it, I get:

jesse@Mulder:~/temp/hello
> ls
hello.hs   typescript

jesse@Mulder:~/temp/hello
> cat hello.hs 
main = putStrLn "Hello, World!"

jesse@Mulder:~/temp/hello
> ghc --make hello.hs 
[1 of 1] Compiling Main             ( hello.hs, hello.o )
Linking hello ...

jesse@Mulder:~/temp/hello
> ./hello
Hello, World!
hello: internal error: evacuate(static): strange closure type 32
    (GHC version 7.4.2 for x86_64_apple_darwin)
    Please report this as a GHC bug:  http://www.haskell.org/ghc/reportabug
[1]    61943 abort      ./hello

Xmonad exits with a similar message, as does trying to compile GHC myself. Notice how it prints Hello, World! before it crashes.

Any ideas on how I can provide for information to help debug this would be most appreciated. Life is difficult in OSX without Xmonad.

I have attached the OSX crash log of Xmonad as it may provide some detail into what is going on, but this appears to happen regardless of the program being run.

Kernel:

Darwin Mulder.local 12.0.0 Darwin Kernel Version 12.0.0: Thu Jun  7 18:47:37 PDT 2012; root:xnu-2050.6.71~1/RELEASE_X86_64 x86_64

GCC:

jesse@Mulder:~/temp/hello
> gcc -v
Using built-in specs.
Target: i686-apple-darwin11
Configured with: /private/var/tmp/llvmgcc42/llvmgcc42-2336.10~42/src/configure --disable-checking --enable-werror --prefix=/Applications/Xcode.app/Contents/Developer/usr/llvm-gcc-4.2 --mandir=/share/man --enable-languages=c,objc,c++,obj-c++ --program-prefix=llvm- --program-transform-name=/^[cg][^.-]*$/s/$/-4.2/ --with-slibdir=/usr/lib --build=i686-apple-darwin11 --enable-llvm=/private/var/tmp/llvmgcc42/llvmgcc42-2336.10~42/dst-llvmCore/Developer/usr/local --program-prefix=i686-apple-darwin11- --host=x86_64-apple-darwin11 --target=i686-apple-darwin11 --with-gxx-include-dir=/usr/include/c++/4.2.1
Thread model: posix
gcc version 4.2.1 (Based on Apple Inc. build 5658) (LLVM build 2336.10.00)

Normally I wouldn't ask for support for software still in beta, but apparently this release is at least someone close to the final product.

Thank you very much for any assistance!

Attachments

xmonad-x86_64-darwin_2012-06-14-172935_Mulder.crash Download (8.5 KB) - added by smidget 11 months ago.
XMonad crash log

Change History

Changed 11 months ago by smidget

XMonad crash log

Changed 11 months ago by simonmar

  • priority changed from normal to highest
  • difficulty set to Unknown
  • milestone set to 7.6.1

We had problems with DP1 and DP2, but they went away with DP3 and XCode 4.4 DP5 (see #5899). I really hope the problem has not reappeared.

Can you confirm that you're on the latest XCode too?

Changed 11 months ago by chak

  • cc chak@…, gdr@…, benl@…, pho@…, anton.nik@…, jhenahan@…, ireney.knapp@… added

I cannot reproduce this problem. I just tested GHC 7.4.2 x86_64 (using the OS X installer package from GHC HQ) on OS X 10.8 DP4 with Xcode 4.5 DP (using the command line tools installed by that version of Xcode). I can compile and validate GHC HEAD without any problems.

Can you please try installing Xcode 4.5 DP and make sure to reinstall the command line tools, just to be sure, and give this another try? Thanks.

Changed 11 months ago by simonpj

  • status changed from new to infoneeded

Changed 10 months ago by igloo

  • status changed from infoneeded to closed
  • resolution set to fixed

No response from submitter, so assuming this is working.

Note: See TracTickets for help on using tickets.