[PATCH] D12395: [compiler-rt] [TSan] Enable TSan for AArch64/42-bit VMA

Adhemerval Zanella via llvm-commits llvm-commits at lists.llvm.org
Thu Aug 27 07:04:21 PDT 2015


zatrazz added inline comments.

================
Comment at: test/tsan/test.h:46
@@ +45,3 @@
+#elif defined(__aarch64__)
+  // AArch64 currently has 3 different VMA (39, 42, and 48 bits) and it require
+  // different pointer size to match the diagnostic message.
----------------
dvyukov wrote:
> s/require/requires/
I will fix it.

================
Comment at: test/tsan/test.h:48
@@ +47,3 @@
+  // different pointer size to match the diagnostic message.
+  const char *format = NULL;
+  unsigned long vma = (unsigned long)__builtin_frame_address(0);
----------------
dvyukov wrote:
> s/NULL/0/ for consistency with the rest of tsan code
I will change it.

================
Comment at: test/tsan/test.h:53
@@ +52,3 @@
+    format = "0x%010lx";
+  else if (vma == 42)
+    format = "0x%011lx";
----------------
dvyukov wrote:
> in the comment you say 39, 42 and 48, but here you handle only 39 and 42
> do
>   else {
>     fprintf(stderr, "unsupported vma: %ul\n", vma);
>     exit(1);
>   }
> 
> better than crash with format==0
I only handle 39 and 42 because 48 I not really yet supported. I will add this crash check. Thanks for the review.


http://reviews.llvm.org/D12395





More information about the llvm-commits mailing list