
Simon Peyton Jones
Thanks Kavon.
What news of CpsCall in LLVM? That seems crucial.
I didn’t know of an effort to use a different SP register. I seriously doubt that, with GHC’s use of zillions of small, heap-allocated stacks that move around during GHC, we’ll be able to leverage profiling or debugging tools in a serious way. But perhaps I need education.
I don't see there being a problem here: * DWARF debugging information is expressive enough to capture GHC's underflow frame concept, so unwinding across stack chunks shouldn't be problematic. * The fact that the stacks move shouldn't be a problem since either: * You are using gdb, which must pause the process to look at the stack anyways * You are using statistical sampling profiling (e.g. perf on Linux) which pauses the thread being sampled while capturing the stack state. If you sample during a GC then you won't capture any Haskell stack chunks so the fact that stacks might move isn't problematic; if you sample during mutator execution then the stack is guaranteed to be stationary. Cheers, - Ben