[GHC] #11058: selected processor does not support ARM mode

GHC ghc-devs at haskell.org
Wed Nov 4 06:27:24 UTC 2015


#11058: selected processor does not support ARM mode
----------------------------------------+------------------------------
        Reporter:  nomeata              |                Owner:
            Type:  bug                  |               Status:  new
        Priority:  normal               |            Milestone:
       Component:  Compiler             |              Version:  7.10.2
      Resolution:                       |             Keywords:
Operating System:  Unknown/Multiple     |         Architecture:  arm
 Type of failure:  Building GHC failed  |            Test Case:
      Blocked By:                       |             Blocking:
 Related Tickets:                       |  Differential Rev(s):
       Wiki Page:                       |
----------------------------------------+------------------------------

Comment (by erikd):

 Tried simple hack of:

 {{{
 diff --git a/compiler/llvmGen/LlvmCodeGen/Ppr.hs
 b/compiler/llvmGen/LlvmCodeGen/Ppr.hs
 index d7ddf80..03c369c 100644
 --- a/compiler/llvmGen/LlvmCodeGen/Ppr.hs
 +++ b/compiler/llvmGen/LlvmCodeGen/Ppr.hs
 @@ -50,7 +50,10 @@ moduleLayout = sdocWithPlatform $ \platform ->
      Platform { platformArch = ArchX86_64, platformOS = OSLinux } ->
          text "target datalayout =
 \"e-p:64:64:64-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:128:128-a0:0:64-s0:64:64-f80:128:128-n8:16:32:64\""
          $+$ text "target triple = \"x86_64-linux-gnu\""
 -    Platform { platformArch = ArchARM {}, platformOS = OSLinux } ->
 +    Platform { platformArch = ArchARM { armISA = ARMv5 }, platformOS =
 OSLinux } ->
 +        text "target datalayout =
 \"e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:64:128-a0:0:64-n32\""
 +        $+$ text "target triple = \"armv4t-unknown-linux-gnueabihf\""
 +    Platform { platformArch = ArchARM {}, platformOS = OSLinux } ->
          text "target datalayout =
 \"e-p:32:32:32-i1:8:8-i8:8:8-i16:16:16-i32:32:32-i64:64:64-f32:32:32-f64:64:64-v64:64:64-v128:64:128-a0:0:64-n32\""
          $+$ text "target triple = \"armv6-unknown-linux-gnueabihf\""
      Platform { platformArch = ArchARM {}, platformOS = OSAndroid } ->
 }}}

 but then linking the RTS fails with:

 {{{
 /usr/bin/ar: creating rts/dist/build/libHSrts_thr_debug.a
 /usr/bin/ld.gold: error: rts/dist/build/StgStartup.dyn_o uses VFP register
 arguments, output does not
 /usr/bin/ld.gold: error: rts/dist/build/Updates.dyn_o uses VFP register
 arguments, output does not
 /usr/bin/ld.gold: error: rts/dist/build/StgMiscClosures.dyn_o uses VFP
 register arguments, output does not
 /usr/bin/ld.gold: error: rts/dist/build/Apply.dyn_o uses VFP register
 arguments, output does not
 /usr/bin/ld.gold: error: rts/dist/build/HeapStackCheck.dyn_o uses VFP
 register arguments, output does not
 /usr/bin/ld.gold: error: rts/dist/build/Exception.dyn_o uses VFP register
 arguments, output does not
 /usr/bin/ld.gold: error: rts/dist/build/StgStdThunks.dyn_o uses VFP
 register arguments, output does not
 /usr/bin/ld.gold: error: rts/dist/build/PrimOps.dyn_o uses VFP register
 arguments, output does not
 /usr/bin/ld.gold: error: rts/dist/build/AutoApply.dyn_o uses VFP register
 arguments, output does not
 }}}

--
Ticket URL: <http://ghc.haskell.org/trac/ghc/ticket/11058#comment:5>
GHC <http://www.haskell.org/ghc/>
The Glasgow Haskell Compiler


More information about the ghc-tickets mailing list