Commit 48a4d245 authored by Alexei Filippov's avatar Alexei Filippov Committed by Commit Bot

Make MSAN happy about stack frame unwinder.

Followup to fix test failure after r589730.

BUG=878604
TBR=erikchen@chromium.org,thestig@chromium.org

Change-Id: I55ae973e2d3b2204549ce67be24dfdd929b6f374
Reviewed-on: https://chromium-review.googlesource.com/1215054Reviewed-by: default avatarAlexei Filippov <alph@chromium.org>
Commit-Queue: Alexei Filippov <alph@chromium.org>
Cr-Commit-Position: refs/heads/master@{#589794}
parent 0efe9132
......@@ -47,11 +47,15 @@ constexpr size_t kStackFrameAdjustment = 0;
#endif
uintptr_t GetNextStackFrame(uintptr_t fp) {
return reinterpret_cast<const uintptr_t*>(fp)[0] - kStackFrameAdjustment;
const uintptr_t* fp_addr = reinterpret_cast<const uintptr_t*>(fp);
MSAN_UNPOISON(fp_addr, sizeof(uintptr_t));
return fp_addr[0] - kStackFrameAdjustment;
}
uintptr_t GetStackFramePC(uintptr_t fp) {
return reinterpret_cast<const uintptr_t*>(fp)[1];
const uintptr_t* fp_addr = reinterpret_cast<const uintptr_t*>(fp);
MSAN_UNPOISON(&fp_addr[1], sizeof(uintptr_t));
return fp_addr[1];
}
bool IsStackFrameValid(uintptr_t fp, uintptr_t prev_fp, uintptr_t stack_end) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment