forked from OSchip/llvm-project
[sanitizer] reverse the order of the stack traces printed for every pair of locks in the deadlock report (first print the 'from' node, then print the 'to' node of the deadlock graph)
llvm-svn: 204043
This commit is contained in:
parent
8976539627
commit
f01c094cdd
|
@ -231,8 +231,8 @@ class DeadlockDetector {
|
|||
added_edges, ARRAY_SIZE(added_edges));
|
||||
for (uptr i = 0; i < n_added_edges; i++) {
|
||||
if (n_edges_ < ARRAY_SIZE(edges_))
|
||||
edges_[n_edges_++] = Edge((u16)added_edges[i], (u16)cur_idx, stk,
|
||||
dtls->findLockContext(added_edges[i]));
|
||||
edges_[n_edges_++] = Edge((u16)added_edges[i], (u16)cur_idx,
|
||||
dtls->findLockContext(added_edges[i]), stk);
|
||||
// Printf("Edge [%zd]: %u %zd=>%zd\n", i, stk, added_edges[i], cur_idx);
|
||||
}
|
||||
return n_added_edges;
|
||||
|
|
|
@ -417,13 +417,13 @@ class LockTest {
|
|||
fprintf(stderr, "Starting Test16: detailed output test with two locks\n");
|
||||
// CHECK: Starting Test16
|
||||
// CHECK: WARNING: ThreadSanitizer: lock-order-inversion
|
||||
// CHECK: LockTest::Acquire0
|
||||
// CHECK-NEXT: LockTest::Acquire_0_then_1
|
||||
// CHECK: LockTest::Acquire1
|
||||
// CHECK-NEXT: LockTest::Acquire_0_then_1
|
||||
// CHECK: LockTest::Acquire0
|
||||
// CHECK-NEXT: LockTest::Acquire_0_then_1
|
||||
// CHECK: LockTest::Acquire0
|
||||
// CHECK: LockTest::Acquire1
|
||||
// CHECK-NEXT: LockTest::Acquire_1_then_0
|
||||
// CHECK: LockTest::Acquire1
|
||||
// CHECK: LockTest::Acquire0
|
||||
// CHECK-NEXT: LockTest::Acquire_1_then_0
|
||||
Init(5);
|
||||
Acquire_0_then_1();
|
||||
|
|
Loading…
Reference in New Issue