[PATCH] [LSan] [MIPS] adding support of LSan for mips64/mips64el arch

Kostya Serebryany kcc at google.com
Fri Jan 16 10:29:19 PST 2015


REPOSITORY
  rL LLVM

================
Comment at: lib/sanitizer_common/sanitizer_linux_libcdep.cc:166
@@ +165,3 @@
+#if defined(__mips__)
+uptr TlsPreTcbSize() {
+  const uptr kTcbHead = 16;
----------------
Please add a comment and/or a more descriptive name. 


================
Comment at: lib/sanitizer_common/sanitizer_linux_libcdep.cc:186
@@ -176,1 +185,3 @@
   get_tls(&tls_size, &tls_align);
+#if defined(__mips__)
+  uptr kDlTlsStaticAlign = 16;
----------------
Can we avoid an ifdef here? 

================
Comment at: lib/sanitizer_common/sanitizer_linux_libcdep.cc:188
@@ +187,3 @@
+  uptr kDlTlsStaticAlign = 16;
+  g_tls_size = ((tls_size + TlsPreTcbSize() + kDlTlsStaticAlign -1)
+                 & ~(kDlTlsStaticAlign - 1));
----------------
can you pull this logic inside TlsPreTcbSize?

http://reviews.llvm.org/D7013

EMAIL PREFERENCES
  http://reviews.llvm.org/settings/panel/emailpreferences/






More information about the llvm-commits mailing list