summaryrefslogtreecommitdiff
path: root/test/tsan/global_race.cc
diff options
context:
space:
mode:
authorAlexey Samsonov <vonosmas@gmail.com>2014-11-04 01:55:20 +0000
committerAlexey Samsonov <vonosmas@gmail.com>2014-11-04 01:55:20 +0000
commit01507598154346791c2f1f493f6cf71dcc503bca (patch)
treec05e9845322dca3ca4050512e07b55ec94c3185b /test/tsan/global_race.cc
parentfda21bb18043f719665a6cf2a7373c6b8a50e116 (diff)
downloadcompiler-rt-01507598154346791c2f1f493f6cf71dcc503bca.tar.gz
[TSan] Don't strip binary/library name until the moment we print it.
This commit changes the place where TSan runtime turns full path to binary or shared library into its basename (/usr/foo/mybinary -> mybinary). Instead of doing it as early as possible (when we obtained the full path from the symbolizer), we now do it as late as possible (right before printing the error report). This seems like a right thing to do - stripping to basename is a detail of report formatting implementation, and should belong there. Also, we might need the full path at some point - for example, to match the suppressions. git-svn-id: https://llvm.org/svn/llvm-project/compiler-rt/trunk@221225 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'test/tsan/global_race.cc')
-rw-r--r--test/tsan/global_race.cc4
1 files changed, 2 insertions, 2 deletions
diff --git a/test/tsan/global_race.cc b/test/tsan/global_race.cc
index d74b4d523..f4e8bc8c0 100644
--- a/test/tsan/global_race.cc
+++ b/test/tsan/global_race.cc
@@ -1,4 +1,4 @@
-// RUN: %clangxx_tsan -O1 %s -o %t && %deflake %run %t | FileCheck %s
+// RUN: %clangxx_tsan -O1 %s -o %T/global_race_bin && %deflake %run %T/global_race_bin | FileCheck %s
#include <pthread.h>
#include <stdio.h>
#include <stddef.h>
@@ -24,5 +24,5 @@ int main() {
// CHECK: addr=[[ADDR:0x[0-9,a-f]+]]
// CHECK: WARNING: ThreadSanitizer: data race
-// CHECK: Location is global 'GlobalData' of size 40 at [[ADDR]] ({{.*}}+0x{{[0-9,a-f]+}})
+// CHECK: Location is global 'GlobalData' of size 40 at [[ADDR]] (global_race_bin+0x{{[0-9,a-f]+}})