summaryrefslogtreecommitdiffstats
path: root/compiler-rt/lib/fuzzer/FuzzerTracePC.h
diff options
context:
space:
mode:
Diffstat (limited to 'compiler-rt/lib/fuzzer/FuzzerTracePC.h')
-rw-r--r--compiler-rt/lib/fuzzer/FuzzerTracePC.h13
1 files changed, 7 insertions, 6 deletions
diff --git a/compiler-rt/lib/fuzzer/FuzzerTracePC.h b/compiler-rt/lib/fuzzer/FuzzerTracePC.h
index 49514b92e76..f1d523e3348 100644
--- a/compiler-rt/lib/fuzzer/FuzzerTracePC.h
+++ b/compiler-rt/lib/fuzzer/FuzzerTracePC.h
@@ -122,6 +122,12 @@ class TracePC {
void ProtectLazyCounters();
bool UnprotectLazyCounters(void *CounterPtr);
+ struct PCTableEntry {
+ uintptr_t PC, PCFlags;
+ };
+
+ uintptr_t PCTableEntryIdx(const PCTableEntry *TE);
+
private:
bool UseCounters = false;
uint32_t UseValueProfileMask = false;
@@ -159,16 +165,11 @@ private:
CB(Modules[m].Regions[r]);
}
-
- struct PCTableEntry {
- uintptr_t PC, PCFlags;
- };
-
struct { const PCTableEntry *Start, *Stop; } ModulePCTable[4096];
size_t NumPCTables;
size_t NumPCsInPCTables;
- Set<uintptr_t> ObservedPCs;
+ Set<const PCTableEntry*> ObservedPCs;
std::unordered_map<uintptr_t, uintptr_t> ObservedFuncs; // PC => Counter.
uint8_t *FocusFunctionCounterPtr = nullptr;
OpenPOWER on IntegriCloud