__pthread_unregister_cancel, sigaction restore, ProfiledThread::release()) are unreachable dead code. The while(true) loop above only exits via pthread_testcancel() triggering cancellation, which longjmps to the setjmp handler block at line 295 — the normal-return path can never reach line 311. #592
@DataDog fix this