[NFC][lsan] Use kIgnored in MarkInvalidPCCb
authorVitaly Buka <vitalybuka@google.com>
Wed, 8 Dec 2021 03:49:44 +0000 (19:49 -0800)
committerVitaly Buka <vitalybuka@google.com>
Wed, 8 Dec 2021 03:53:08 +0000 (19:53 -0800)
kIgnored didn't exist when the code was added, but it should be
equivalent to kReachable.
The goal is to refactor MarkInvalidPCCb to avoid StackDepotGet
in StopTheWorld.

compiler-rt/lib/lsan/lsan_common.cpp

index 308dbb3..1725610 100644 (file)
@@ -505,7 +505,7 @@ static void MarkInvalidPCCb(uptr chunk, void *arg) {
     // it as reachable, as we can't properly report its allocation stack anyway.
     if (caller_pc == 0 || (param->skip_linker_allocations &&
                            GetLinker()->containsAddress(caller_pc))) {
-      m.set_tag(kReachable);
+      m.set_tag(kIgnored);
       param->frontier->push_back(chunk);
     }
   }