staticvoid verify_unwind_data(const UnwindData& unwind_data) { // In order to avoid a false positive, the caller must have at least 2 frames // outside of the signal handler. This avoids a case where the only frame // right after the signal handler winds up being garbage.
EXPECT_GT(unwind_data.handler_frame_count, unwind_data.expected_frame_count + 1);
_Unwind_Backtrace(FrameCounter, &g_unwind_data.expected_frame_count);
ASSERT_LE(2, g_unwind_data.expected_frame_count)
<< "The current call must contain at least 2 frames for the test to be valid.";
ASSERT_EQ(0, kill(getpid(), SIGUSR1)); while (!g_unwind_data.signal_handler_complete) {}
// On LP32, the SA_SIGINFO flag gets you __restore_rt instead of __restore.
TEST(stack_unwinding, unwind_through_signal_frame_SA_SIGINFO) {
ScopedSignalHandler ssh(SIGUSR1, UnwindSignalHandler, SA_SIGINFO);
SignalUnwindTest();
}
Messung V0.5 in Prozent
¤ Dauer der Verarbeitung: 0.9 Sekunden
(vorverarbeitet am 2026-06-28)
¤
Die Informationen auf dieser Webseite wurden
nach bestem Wissen sorgfältig zusammengestellt. Es wird jedoch weder Vollständigkeit, noch Richtigkeit,
noch Qualität der bereit gestellten Informationen zugesichert.
Bemerkung:
Die farbliche Syntaxdarstellung und die Messung sind noch experimentell.