On android, while collecting traces of a particular native process, I observed that the backtrace of a particular thread of the process was not collected(libunwind is used to collect the backtrace).

//First attempt

12-29 20:47:20.902 13088 13088 W libbacktrace: virtual bool UnwindPtrace::Unwind(size_t, ucontext_t *): unw_init_remote failed -3

12-29 20:47:20.902 13088 13088 E DEBUG : Unwind failed: tid = 1544: Setup failed

// Second attempt

12-29 20:47:54.683 13135 13135 W libbacktrace: virtual bool UnwindPtrace::Unwind(size_t, ucontext_t *): unw_init_remote failed -3

12-29 20:47:54.683 13135 13135 E DEBUG : Unwind failed: tid = 1544: Setup failed

From docs, -3 seems to be UNW_EBADREG. But I am unable to figure out when exactly is this error code is returned?

Any pointers appreciated!

1 Answers 11

Got some more info regarding why backtrace unwind of that thread was failing - the thread was in "Disk Sleep" or "D" state.

Not the answer you're looking for? Browse other questions tagged or ask your own question.