[compiler-rt] r240379 - [Sanitizers] Pass the correct arch to the symbolizer for x86_64h

Frederic Riss friss at apple.com
Mon Jun 22 22:35:19 PDT 2015


Author: friss
Date: Tue Jun 23 00:35:19 2015
New Revision: 240379

URL: http://llvm.org/viewvc/llvm-project?rev=240379&view=rev
Log:
[Sanitizers] Pass the correct arch to the symbolizer for x86_64h

I have no idea how to directly test that as it depends on a particular
(micro-)architecure of the host processor.
Combined with llvm's r240339 this should fix issues people might have
be seeing intermitently on Darwin haswell machines (the symbolizer
would use the wrong slice of the binary, thus potentially resolving
to the wrong symbol).

Modified:
    compiler-rt/trunk/lib/sanitizer_common/sanitizer_symbolizer_posix_libcdep.cc

Modified: compiler-rt/trunk/lib/sanitizer_common/sanitizer_symbolizer_posix_libcdep.cc
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/sanitizer_common/sanitizer_symbolizer_posix_libcdep.cc?rev=240379&r1=240378&r2=240379&view=diff
==============================================================================
--- compiler-rt/trunk/lib/sanitizer_common/sanitizer_symbolizer_posix_libcdep.cc (original)
+++ compiler-rt/trunk/lib/sanitizer_common/sanitizer_symbolizer_posix_libcdep.cc Tue Jun 23 00:35:19 2015
@@ -137,7 +137,9 @@ class LLVMSymbolizerProcess : public Sym
   }
 
   void ExecuteWithDefaultArgs(const char *path_to_binary) const override {
-#if defined(__x86_64__)
+#if defined(__x86_64h__)
+    const char* const kSymbolizerArch = "--default-arch=x86_64h";
+#elif defined(__x86_64__)
     const char* const kSymbolizerArch = "--default-arch=x86_64";
 #elif defined(__i386__)
     const char* const kSymbolizerArch = "--default-arch=i386";





More information about the llvm-commits mailing list