Skip to content

GitLab

  • Projects
  • Groups
  • Snippets
  • Help
    • Loading...
  • Help
    • Help
    • Support
    • Community forum
    • Submit feedback
  • Sign in / Register
GHC
GHC
  • Project overview
    • Project overview
    • Details
    • Activity
    • Releases
  • Repository
    • Repository
    • Files
    • Commits
    • Branches
    • Tags
    • Contributors
    • Graph
    • Compare
    • Locked Files
  • Issues 4,324
    • Issues 4,324
    • List
    • Boards
    • Labels
    • Service Desk
    • Milestones
    • Iterations
  • Merge Requests 385
    • Merge Requests 385
  • Requirements
    • Requirements
    • List
  • CI / CD
    • CI / CD
    • Pipelines
    • Jobs
    • Schedules
  • Security & Compliance
    • Security & Compliance
    • Dependency List
    • License Compliance
  • Operations
    • Operations
    • Incidents
    • Environments
  • Analytics
    • Analytics
    • CI / CD
    • Code Review
    • Insights
    • Issue
    • Repository
    • Value Stream
  • Wiki
    • Wiki
  • Snippets
    • Snippets
  • Members
    • Members
  • Collapse sidebar
  • Activity
  • Graph
  • Create a new issue
  • Jobs
  • Commits
  • Issue Boards
  • Glasgow Haskell Compiler
  • GHCGHC
  • Issues
  • #15747

Closed
Open
Opened Oct 14, 2018 by Sergei Trofimovich@trofiReporter

GHC panics when builds for arm as: ghc-stage1: panic! (the 'impossible' happened): padLiveArgs -- i > regNum ??

ghc-HEAD fails build as:

$ LANG=C make
===--- building phase 0
make --no-print-directory -f ghc.mk phase=0 phase_0_builds
make[1]: Nothing to be done for 'phase_0_builds'.
===--- building phase 1
make --no-print-directory -f ghc.mk phase=1 phase_1_builds
make[1]: Nothing to be done for 'phase_1_builds'.
===--- building final phase
make --no-print-directory -f ghc.mk phase=final all
"inplace/bin/ghc-stage1" -static  -H32m -O -O0   -Wall   -Iincludes -Iincludes/dist -Iincludes/dist-derivedconstants/header -Iincludes/dist-ghcconstants/header -Irts -Irts/dist/build -DCOMPILING_RTS -DFS_NAMESPACE=rts -this-unit-id rts -dcmm-lint      -i -irts -irts/dist/build -Irts/dist/build -irts/dist/build/./autogen -Irts/dist/build/./autogen            -O2 -Wcpp-undef    -Wnoncanonical-monad-instances  -c rts/HeapStackCheck.cmm -o rts/dist/build/HeapStackCheck.o
You are using an unsupported version of LLVM!
Currently only 6.0 is supported.
We will try though...
ghc-stage1: panic! (the 'impossible' happened)
  (GHC version 8.7.20181014 for arm-unknown-linux):
        padLiveArgs -- i > regNum ??(2,1)
CallStack (from HasCallStack):
  error, called at compiler/llvmGen/LlvmCodeGen/Base.hs:194:27 in ghc:LlvmCodeGen.Base

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

make[1]: *** [rts/ghc.mk:318: rts/dist/build/HeapStackCheck.o] Error 1
make: *** [Makefile:127: all] Error 2

The suspect is: https://phabricator.haskell.org/D5190

GHC is built for armv7a-unknown-linux-gnueabihf target.

inplace/bin/ghc-stage1 --info
 [("Project name","The Glorious Glasgow Haskell Compilation System")
 ,("GCC extra via C opts"," -fwrapv -fno-builtin")
 ,("C compiler command","armv7a-unknown-linux-gnueabihf-gcc")
 ,("C compiler flags"," -marm -fno-stack-protector")
 ,("C compiler link flags","  -Wl,-z,noexecstack")
 ,("C compiler supports -no-pie","YES")
 ,("Haskell CPP command","armv7a-unknown-linux-gnueabihf-gcc")
 ,("Haskell CPP flags","-E -undef -traditional")
 ,("ld command","armv7a-unknown-linux-gnueabihf-ld.gold")
 ,("ld flags"," -z noexecstack")
 ,("ld supports compact unwind","YES")
 ,("ld supports build-id","YES")
 ,("ld supports filelist","NO")
 ,("ld is GNU ld","YES")
 ,("ar command","armv7a-unknown-linux-gnueabihf-ar")
 ,("ar flags","q")
 ,("ar supports at file","YES")
 ,("ranlib command","armv7a-unknown-linux-gnueabihf-ranlib")
 ,("touch command","touch")
 ,("dllwrap command","armv7a-unknown-linux-gnueabihf-dllwrap")
 ,("windres command","armv7a-unknown-linux-gnueabihf-windres")
 ,("libtool command","libtool")
 ,("perl command","/usr/bin/perl")
 ,("cross compiling","YES")
 ,("target os","OSLinux")
 ,("target arch","ArchARM {armISA = ARMv7, armISAExt = [VFPv3,NEON], armABI = HARD}")
 ,("target word size","4")
 ,("target has GNU nonexec stack","True")
 ,("target has .ident directive","True")
 ,("target has subsections via symbols","False")
 ,("target has RTS linker","YES")
 ,("Unregisterised","NO")
 ,("LLVM llc command","llc")
 ,("LLVM opt command","opt")
 ,("LLVM clang command","clang")
 ,("Project version","8.7.20181014")
 ,("Project Git commit id","4a79ae580698ec635a6edd2b56958af2682511dd")
 ,("Booter version","8.4.2")
 ,("Stage","1")
 ,("Build platform","x86_64-unknown-linux")
 ,("Host platform","x86_64-unknown-linux")
 ,("Target platform","arm-unknown-linux")
 ,("Have interpreter","YES")
 ,("Object splitting supported","NO")
 ,("Have native code generator","NO")
 ,("Support SMP","YES")
 ,("Tables next to code","YES")
 ,("RTS ways","l debug thr thr_debug thr_l  dyn debug_dyn thr_dyn thr_debug_dyn l_dyn thr_l_dyn ")
 ,("RTS expects libdw","NO")
 ,("Support dynamic-too","YES")
 ,("Support parallel --make","YES")
 ,("Support reexported-modules","YES")
 ,("Support thinning and renaming package flags","YES")
 ,("Support Backpack","YES")
 ,("Requires unified installed package IDs","YES")
 ,("Uses package keys","YES")
 ,("Uses unit IDs","YES")
 ,("Dynamic by default","NO")
 ,("GHC Dynamic","NO")
 ,("GHC Profiled","NO")
 ,("Leading underscore","NO")
 ,("Debug on","False")
 ,("LibDir","/tmp/portage/cross-armv7a-unknown-linux-gnueabihf/ghc-9999/work/ghc-9999/inplace/lib")
 ,("Global Package DB","/tmp/portage/cross-armv7a-unknown-linux-gnueabihf/ghc-9999/work/ghc-9999/inplace/lib/package.conf.d")
 ]
Trac metadata
Trac field Value
Version
Type Bug
TypeOfFailure OtherFailure
Priority normal
Resolution Unresolved
Component Compiler
Test case
Differential revisions
BlockedBy
Related
Blocking
CC bgamari, kavon
Operating system
Architecture
Assignee
Assign to
None
Milestone
None
Assign milestone
Time tracking
None
Due date
None
Reference: ghc/ghc#15747