[PATCH] D31555: [PPC64, Sanitizers] Proper stack frame for the thread spawned in internal_clone
Eric Christopher via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Mon Apr 3 15:24:57 PDT 2017
echristo added a comment.
Couple of inline comments. I think this looks right but I've added Kit and Nemanja on here so one of them can give an ACK if Bill doesn't.
-eric
================
Comment at: lib/sanitizer_common/sanitizer_linux.cc:1117
+// Stack frame structure.
+#if SANITIZER_PPC64V1
+// Back chain == 0 (SP + 112)
----------------
Do you mean elfv1 vs elfv2 here? The standard one would be just to check for _CALL_ELF == 1 and _CALL_ELF == 2.
================
Comment at: lib/sanitizer_common/sanitizer_linux.cc:1137
+// Back chain (SP + 0)
+# define FRAME_SIZE (12 * sizeof(unsigned long long))
+# define FRAME_TOC_SAVE_OFFSET 24
----------------
If we're just talking about power64 we can probably just hard code it to N rather than N * sizeof(some type).
https://reviews.llvm.org/D31555
More information about the llvm-commits
mailing list