[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Libunwind-devel] How to get a backtrace from saved frame pointer

From: Roman Tsisyk
Subject: [Libunwind-devel] How to get a backtrace from saved frame pointer
Date: Sun, 05 Feb 2017 09:52:39 +0300


My application uses lightweight user-space threads (fibers a.k.a coroutines). 
Each fiber has its own stack and a saved frame pointer to the last executed 
function, retrieved from `__builtin_frame_address(0)`. I want to create 
backtraces for all fibers using saved frame pointers. 

Currently this feature is implemented using libbfd[1], which is non-portable 
and just terrible. I want to switch to libunwind, but I don't understand how to 
wrap unw_create_addr_space()/unw_init_remote() for my case. Could you please 
provide some examples?


   Roman Tsisyk <address@hidden> - an efficient in-memory data store and a Lua 
application server

reply via email to

[Prev in Thread] Current Thread [Next in Thread]