Opened 3 years ago

Closed 5 weeks ago

#7316 closed bug (fixed)

GHC segfaults on ARM

Reported by: laney Owned by: bgamari
Priority: normal Milestone: 8.0.1
Component: Compiler Version: 7.4.2
Keywords: Cc: bgamari, cjwatson@…, erikd
Operating System: Unknown/Multiple Architecture: arm
Type of failure: None/Unknown Test Case:
Blocked By: #3658 Blocking: #7623
Related Tickets: Differential Rev(s):
Wiki Page:


Sorry for the lack of detail. I thought I'd file this upstream. We've been seeing this in Ubuntu with 7.4.2. Some cabal packages, like chell, fail to build with a segfault in ghc.

[3 of 4] Compiling Test.Chell.Main  ( lib/Test/Chell/Main.hs, dist-ghc/build/Test/Chell/Main.o )
Loading package ghc-prim ... linking ... done.
Loading package integer-gmp ... linking ... done.
Loading package base ... linking ... done.
Loading package array- ... linking ... done.
Loading package deepseq- ... linking ... done.
Loading package old-locale- ... linking ... done.
Loading package time-1.4 ... linking ... done.
Loading package random- ... linking ... done.
Loading package containers- ... linking ... done.
Loading package patience-0.1.1 ... linking ... done.
Loading package bytestring- ... linking ... done.
Loading package transformers- ... linking ... done.
Loading package monads-tf- ... linking ... done.
Loading package text- ... linking ... done.
Loading package system-filepath-0.4.6 ... linking ... done.
Loading package pretty- ... linking ... done.
Loading package template-haskell ... linking ... done.
Loading package options-0.1.1 ... linking ... done.
make: *** [build-ghc-stamp] Error 11

Full build log attached. I'll try to reduce the example and/or reproduce with 7.6 soon. (I can also provide you with SSH access to hardware if you need it).

Attachments (1)

buildlog_ubuntu-quantal-armhf.haskell-chell_0.3-1build1_FAILEDTOBUILD.txt.gz (7.9 KB) - added by laney 3 years ago.
Log of chell building on Ubuntu Quantal (GHC 7.4.2)

Download all attachments as: .zip

Change History (14)

comment:1 Changed 3 years ago by laney

  • Summary changed from GHC segfaults on hardfloat ARM to GHC segfaults on ARM

Changed 3 years ago by laney

Log of chell building on Ubuntu Quantal (GHC 7.4.2)

comment:2 follow-up: Changed 3 years ago by simonmar

  • Cc bgamari added
  • difficulty set to Unknown
  • Milestone set to 7.6.2
  • Priority changed from normal to high

@bgamari smells like a problem with the ARM linker, any chance you could investigate?

comment:3 in reply to: ↑ 2 Changed 3 years ago by bgamari

Replying to simonmar:

@bgamari smells like a problem with the ARM linker, any chance you could investigate?

Of course. I've recently been having a hard time getting GHC to build on my test machine apparently due to inconsistent compiler options being used by by LLVM and GCC. Nevertheless, I'll take a look at this as soon as the compiler issue is sorted out.

comment:4 Changed 3 years ago by dterei

  • Blocking 7623 added

comment:5 Changed 3 years ago by cjwatson

  • Cc cjwatson@… added

I'm far from certain, but it's possible that my patch in will help with this.

comment:6 Changed 3 years ago by igloo

  • Blocked By 3658 added

This should be fixed by using dynamic libraries to implement GHCi.

comment:7 Changed 2 years ago by bgamari

  • Owner set to bgamari

comment:8 Changed 21 months ago by bgamari

  • Priority changed from high to normal

At this point it seems like dynamic linking works pretty well with the LLVM backend on ARM. We can keep this bug open as the bug likely still lurks in GHC's linker, but it's not nearly as critical now.

comment:9 Changed 17 months ago by thoughtpolice

  • Milestone changed from 7.6.2 to 7.10.1

Moving to 7.10.1.

comment:10 Changed 11 months ago by thoughtpolice

  • Milestone changed from 7.10.1 to 7.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:11 Changed 3 months ago by thoughtpolice

  • Milestone changed from 7.12.1 to 8.0.1

Milestone renamed

comment:12 Changed 6 weeks ago by erikd

  • Cc erikd added

comment:13 Changed 5 weeks ago by bgamari

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

laney, as of 7.10.3 ARM support should be reasonable stable (with the exception of distributions using Thumb binaries) as #10375 is resolved.

Given that we don't really know what happened in this particular bug I'm going to close this. Feel free to open another ticket if you are still having trouble with 7.10.3 or later.

Note: See TracTickets for help on using tickets.