forked from OSchip/llvm-project
tsan: remove unused ReportMutex::destroyed
Depends on D113980. Reviewed By: melver Differential Revision: https://reviews.llvm.org/D113981
This commit is contained in:
parent
69807fe161
commit
52a4a4a53c
|
@ -157,7 +157,7 @@ int __tsan_get_report_mutex(void *report, uptr idx, uptr *mutex_id, void **addr,
|
|||
ReportMutex *mutex = rep->mutexes[idx];
|
||||
*mutex_id = mutex->id;
|
||||
*addr = (void *)mutex->addr;
|
||||
*destroyed = mutex->destroyed;
|
||||
*destroyed = false;
|
||||
if (mutex->stack) CopyTrace(mutex->stack->frames, trace, trace_size);
|
||||
return 1;
|
||||
}
|
||||
|
|
|
@ -223,17 +223,11 @@ static void PrintMutexShortWithAddress(const ReportMutex *rm,
|
|||
|
||||
static void PrintMutex(const ReportMutex *rm) {
|
||||
Decorator d;
|
||||
if (rm->destroyed) {
|
||||
Printf("%s", d.Mutex());
|
||||
Printf(" Mutex M%u is already destroyed.\n\n", rm->id);
|
||||
Printf("%s", d.Default());
|
||||
} else {
|
||||
Printf("%s", d.Mutex());
|
||||
Printf(" Mutex M%u (%p) created at:\n", rm->id,
|
||||
reinterpret_cast<void *>(rm->addr));
|
||||
Printf("%s", d.Default());
|
||||
PrintStack(rm->stack);
|
||||
}
|
||||
Printf("%s", d.Mutex());
|
||||
Printf(" Mutex M%u (%p) created at:\n", rm->id,
|
||||
reinterpret_cast<void *>(rm->addr));
|
||||
Printf("%s", d.Default());
|
||||
PrintStack(rm->stack);
|
||||
}
|
||||
|
||||
static void PrintThread(const ReportThread *rt) {
|
||||
|
|
|
@ -93,7 +93,6 @@ struct ReportThread {
|
|||
struct ReportMutex {
|
||||
int id;
|
||||
uptr addr;
|
||||
bool destroyed;
|
||||
ReportStack *stack;
|
||||
};
|
||||
|
||||
|
|
|
@ -270,7 +270,6 @@ int ScopedReportBase::AddMutex(uptr addr, StackID creation_stack_id) {
|
|||
rep_->mutexes.PushBack(rm);
|
||||
rm->id = rep_->mutexes.Size() - 1;
|
||||
rm->addr = addr;
|
||||
rm->destroyed = false;
|
||||
rm->stack = SymbolizeStackId(creation_stack_id);
|
||||
return rm->id;
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue