[PATCH] D40679: [sanitizer] Introduce a vDSO aware time function, and use it in the allocator [redo]
Kostya Kortchinsky via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Fri Dec 1 10:09:53 PST 2017
cryptoad added inline comments.
================
Comment at: lib/sanitizer_common/sanitizer_common_interceptors.inc:2011
+int real_clock_gettime(u32 clk_id, void *tp) {
+ return REAL(clock_gettime)(clk_id, tp);
+}
----------------
krytarowski wrote:
> This symbol name needs to be mangled for NetBSD.
So I don't think I understand what you mean here.
I have never touched a BSD, I am sorry if I am bit dense on this.
Which one has to be mangled and how?
It looks like the interceptor above also calls REAL(clock_gettime), so it would have triggered some NetBSD issue as well?
================
Comment at: lib/sanitizer_common/sanitizer_linux.cc:464
+#if SANITIZER_NETBSD
+ return internal_syscall_ptr(SYSCALL(__clock_gettime50), clk_id, tp);
+#else
----------------
krytarowski wrote:
> Perhaps we could define `clock_gettime_symname` similar to `sigaction_symname`.
Will do.
https://reviews.llvm.org/D40679
More information about the llvm-commits
mailing list