Compiling natively GHC for ARMv7l softabi

shiftag at nanotek.info shiftag at nanotek.info
Thu Oct 19 07:32:32 UTC 2017


October 19, 2017 10:34 AM, "Moritz Angermann" <moritz.angermann at gmail.com> wrote:

>> "inplace/bin/ghc-stage1" -static -H32m -O -Wall -Iincludes -Iincludes/dist
>> -Iincludes/dist-derivedconstants/header -Iincludes/dist-ghcconstants/header -Irts -Irts/dist/build
>> -DCOMPILING_RTS -this-unit-id rts -optc-DNOSMP -dcmm-lint -i -irts -irts/dist/build
>> -irts/dist/build/autogen -Irts/dist/build -Irts/dist/build/autogen -O2 -c rts/StgStartup.cmm -o
>> rts/dist/build/StgStartup.o
> 
> run this with `-v`, to check the invorcations. I'm pretty certain some flags to opt/llc are
> missing/wrong here.


Ok :)

Please see below :

$ inplace/bin/ghc-stage1 -v -static  -H32m -O -Wall  -Iincludes -Iincludes/dist -Iincludes/dist-derivedconstants/header -Iincludes/dist-ghcconstants/header -Irts -Irts/dist/build -DCOMPILING_RTS -this-unit-id rts -optc-DNOSMP -dcmm-lint      -i -irts -irts/dist/build -irts/dist/build/autogen -Irts/dist/build -Irts/dist/build/autogen           -O2     -c rts/StgStartup.cmm -o rts/dist/build/StgStartup.o
Glasgow Haskell Compiler, Version 8.0.2, stage 1 booted by GHC version 8.0.2
Using binary package database: /tmp/ghc-8.0.2/inplace/lib/package.conf.d/package.cache
loading package database /tmp/ghc-8.0.2/inplace/lib/package.conf.d
wired-in package ghc-prim mapped to ghc-prim-0.5.0.0
wired-in package integer-gmp mapped to integer-gmp-1.0.0.1
wired-in package base mapped to base-4.9.1.0
wired-in package rts mapped to rts
wired-in package template-haskell mapped to template-haskell-2.11.1.0
wired-in package ghc mapped to ghc-8.0.2
wired-in package dph-seq not found.
wired-in package dph-par not found.
Hsc static flags:
Created temporary directory: /tmp/ghc25166_0
*** C Compiler:
/usr/bin/arm-linux-gnueabi-gcc -marm -fno-stack-protector -DTABLES_NEXT_TO_CODE -DNOSMP -E -I includes -I includes/dist -I includes/dist-derivedconstants/header -I includes/dist-ghcconstants/header -I rts -I rts/dist/build -I rts/dist/build -I rts/dist/build/autogen -I /tmp/ghc-8.0.2/libraries/base/include -I /tmp/ghc-8.0.2/libraries/integer-gmp/include -I /tmp/ghc-8.0.2/rts/dist/build -I /tmp/ghc-8.0.2/includes -I /tmp/ghc-8.0.2/includes/dist-derivedconstants/header '-D__GLASGOW_HASKELL__=800' -include /tmp/ghc-8.0.2/includes/ghcversion.h '-Dlinux_BUILD_OS=1' '-Dx86_64_BUILD_ARCH=1' '-Dlinux_HOST_OS=1' '-Darm_HOST_ARCH=1' '-D__GLASGOW_HASKELL_LLVM__=307' '-D__GLASGOW_HASKELL_TH__=0' -include/tmp/ghc25166_0/ghc_2.h -x assembler-with-cpp rts/StgStartup.cmm -o /tmp/ghc25166_0/ghc_1.cmmcpp
*** ParseCmm [/tmp/ghc25166_0/ghc_1.cmmcpp]:
!!! ParseCmm [/tmp/ghc25166_0/ghc_1.cmmcpp]: finished in 4.00 milliseconds, allocated 2.082 megabytes
*** LLVM CodeGen:
*** LLVM CodeGen:
Using LLVM version: (3,7)
*** Deleting temp files:
Deleting: /tmp/ghc25166_0/ghc_5.c /tmp/ghc25166_0/ghc_4.ll /tmp/ghc25166_0/ghc_3.rsp /tmp/ghc25166_0/ghc_2.h /tmp/ghc25166_0/ghc_1.cmmcpp
Warning: deleting non-existent /tmp/ghc25166_0/ghc_5.c
*** Deleting temp dirs:
Deleting: /tmp/ghc25166_0
ghc-stage1: panic! (the 'impossible' happened)
  (GHC version 8.0.2 for arm-unknown-linux):
       hscCmmFile: no_mod

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


More information about the ghc-devs mailing list