[llvm-commits] [compiler-rt] r161575 - in /compiler-rt/trunk/lib/asan: asan_report.cc asan_report.h

Alexey Samsonov samsonov at google.com
Thu Aug 9 04:29:13 PDT 2012


Author: samsonov
Date: Thu Aug  9 06:29:13 2012
New Revision: 161575

URL: http://llvm.org/viewvc/llvm-project?rev=161575&view=rev
Log:
[ASan] Small fix to please tests on Windows, where stack unwinding using provided pc/bp works too bad

Modified:
    compiler-rt/trunk/lib/asan/asan_report.cc
    compiler-rt/trunk/lib/asan/asan_report.h

Modified: compiler-rt/trunk/lib/asan/asan_report.cc
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/asan/asan_report.cc?rev=161575&r1=161574&r2=161575&view=diff
==============================================================================
--- compiler-rt/trunk/lib/asan/asan_report.cc (original)
+++ compiler-rt/trunk/lib/asan/asan_report.cc Thu Aug  9 06:29:13 2012
@@ -221,8 +221,13 @@
   AsanPrintf("\n");
 }
 
-void ReportInvalidMemoryAccess(uptr pc, uptr bp, uptr sp, uptr addr,
-                               bool is_write, uptr access_size) {
+}  // namespace __asan
+
+// --------------------------- Interface --------------------- {{{1
+using namespace __asan;  // NOLINT
+
+void __asan_report_error(uptr pc, uptr bp, uptr sp,
+                         uptr addr, bool is_write, uptr access_size) {
   static atomic_uint32_t num_calls;
   if (atomic_fetch_add(&num_calls, 1, memory_order_relaxed) != 0) {
     // Do not print more than one report, otherwise they will mix up.
@@ -323,16 +328,6 @@
   Die();
 }
 
-}  // namespace __asan
-
-// --------------------------- Interface --------------------- {{{1
-using namespace __asan;  // NOLINT
-
-void __asan_report_error(uptr pc, uptr bp, uptr sp,
-                         uptr addr, bool is_write, uptr access_size) {
-  ReportInvalidMemoryAccess(pc, bp, sp, addr, is_write, access_size);
-}
-
 void NOINLINE __asan_set_error_report_callback(void (*callback)(const char*)) {
   error_report_callback = callback;
   if (callback) {

Modified: compiler-rt/trunk/lib/asan/asan_report.h
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/asan/asan_report.h?rev=161575&r1=161574&r2=161575&view=diff
==============================================================================
--- compiler-rt/trunk/lib/asan/asan_report.h (original)
+++ compiler-rt/trunk/lib/asan/asan_report.h Thu Aug  9 06:29:13 2012
@@ -39,8 +39,5 @@
 void NORETURN ReportStringFunctionMemoryRangesOverlap(
     const char *function, const char *offset1, uptr length1,
     const char *offset2, uptr length2, AsanStackTrace *stack);
-// Generic error report.
-void NORETURN ReportInvalidMemoryAccess(uptr pc, uptr bp, uptr sp, uptr addr,
-                                        bool is_write, uptr access_size);
 
 }  // namespace __asan





More information about the llvm-commits mailing list