Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/external/gpl3/gcc/dist/libsanitizer/asan Disable glibc worka...
details: https://anonhg.NetBSD.org/src/rev/891ea9313e60
branches: trunk
changeset: 345807:891ea9313e60
user: christos <christos%NetBSD.org@localhost>
date: Thu Jun 09 14:30:57 2016 +0000
description:
Disable glibc workaround for non linux. Rin Okuyama
diffstat:
external/gpl3/gcc/dist/libsanitizer/asan/asan_malloc_linux.cc | 5 +++++
1 files changed, 5 insertions(+), 0 deletions(-)
diffs (18 lines):
diff -r d4dd88162c6d -r 891ea9313e60 external/gpl3/gcc/dist/libsanitizer/asan/asan_malloc_linux.cc
--- a/external/gpl3/gcc/dist/libsanitizer/asan/asan_malloc_linux.cc Thu Jun 09 09:01:21 2016 +0000
+++ b/external/gpl3/gcc/dist/libsanitizer/asan/asan_malloc_linux.cc Thu Jun 09 14:30:57 2016 +0000
@@ -56,9 +56,14 @@
}
INTERCEPTOR(void*, malloc, uptr size) {
+#if SANITIZER_LINUX
+ // This is a workaround for glibc, by which asan_malloc() fails into infinite
+ // recursion of AsanInitInternal(): http://reviews.llvm.org/rL254395
+ // It is irrelevant to us, rather causes abort due to shortage of buffer.
if (UNLIKELY(!asan_inited))
// Hack: dlsym calls malloc before REAL(malloc) is retrieved from dlsym.
return AllocateFromLocalPool(size);
+#endif
GET_STACK_TRACE_MALLOC;
return asan_malloc(size, &stack);
}
Home |
Main Index |
Thread Index |
Old Index