Skip to content
Closed
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions RegsArm64.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,15 @@ static uint64_t strip_pac(uint64_t pc, uint64_t mask) {
pc = __bionic_clear_pac_bits(pc);
#endif
#endif // SENTRY_REMOVED
#ifndef SENTRY_ADDED
#if defined(__aarch64__)
// __bionic_clear_pac_bits() is not in the NDK. Use xpaclri like it does,
// spelled as hint #7 for assemblers without Armv8.3-A support.
register uint64_t x30 __asm("x30") = pc;
asm("hint #7" : "+r"(x30));
pc = x30;
#endif
#endif // SENTRY_ADDED
}
return pc;
}
Expand Down
Loading