Skip to content

Implement unwind rules for non-Intel architectures

To support DWARF-based stack unwinding, a platform needs a few things,

  • Valid unwind records in stg_stop_thread (defined in rts/StgStartup.cmm)
  • Support in the native code generator (by implementing the generateUnwindTable field of NcgImpl)
  • A mapping of register numbers to DWARF register numbers (see dwarfRegNo in nativeGhc/Dwarf/Constants.hs)
  • For unwinding support in the runtime system:
  • Unwinding support in libdw
  • a set_initial_registers implementation (see rts/Libdw.c)

Currently the only platforms that has all of these implemented is x86_64 and i386. Someone should pick up the other platforms.

Trac metadata
Trac field Value
Version 8.0.1
Type Task
TypeOfFailure OtherFailure
Priority normal
Resolution Unresolved
Component Compiler
Test case
Differential revisions
BlockedBy
Related
Blocking
CC
Operating system
Architecture
To upload designs, you'll need to enable LFS and have an admin enable hashed storage. More information