[compiler-rt] r346129 - Fix build on sparc64-linux-gnu.

Martin Liska via llvm-commits llvm-commits at lists.llvm.org
Mon Nov 5 04:27:43 PST 2018


Author: marxin
Date: Mon Nov  5 04:27:43 2018
New Revision: 346129

URL: http://llvm.org/viewvc/llvm-project?rev=346129&view=rev
Log:
Fix build on sparc64-linux-gnu.

Differential Revision: https://reviews.llvm.org/D54030

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

Modified: compiler-rt/trunk/lib/sanitizer_common/sanitizer_linux.cc
URL: http://llvm.org/viewvc/llvm-project/compiler-rt/trunk/lib/sanitizer_common/sanitizer_linux.cc?rev=346129&r1=346128&r2=346129&view=diff
==============================================================================
--- compiler-rt/trunk/lib/sanitizer_common/sanitizer_linux.cc (original)
+++ compiler-rt/trunk/lib/sanitizer_common/sanitizer_linux.cc Mon Nov  5 04:27:43 2018
@@ -1946,14 +1946,14 @@ static void GetPcSpBp(void *context, upt
 #elif defined(__sparc__)
   ucontext_t *ucontext = (ucontext_t*)context;
   uptr *stk_ptr;
-# if defined (__sparcv9)
+# if defined(__sparcv9) || defined (__arch64__)
 # ifndef MC_PC
 #  define MC_PC REG_PC
 # endif
 # ifndef MC_O6
 #  define MC_O6 REG_O6
 # endif
-# ifdef SANITIZER_SOLARIS
+# if SANITIZER_SOLARIS
 #  define mc_gregs gregs
 # endif
   *pc = ucontext->uc_mcontext.mc_gregs[MC_PC];




More information about the llvm-commits mailing list