| Index: src/debug/debug-interface.h
|
| diff --git a/src/debug/debug-interface.h b/src/debug/debug-interface.h
|
| index 905a71e8628977c14f4eed6dd16143119be58f40..e13550f7ce40fb744f4aad4151cd88bd66885d9f 100644
|
| --- a/src/debug/debug-interface.h
|
| +++ b/src/debug/debug-interface.h
|
| @@ -221,16 +221,19 @@ class V8_EXPORT_PRIVATE Coverage {
|
| // Disable optimization and prevent feedback vectors from being garbage
|
| // collected in order to get precise invocation counts.
|
| kPreciseCount,
|
| + // We are only interested in a yes/no result for the function. Optimization
|
| + // and garbage collection can be allowed once a function has been invoked.
|
| + kPreciseBinary
|
| };
|
|
|
| class ScriptData; // Forward declaration.
|
|
|
| class V8_EXPORT_PRIVATE FunctionData {
|
| public:
|
| - int StartOffset();
|
| - int EndOffset();
|
| - uint32_t Count();
|
| - MaybeLocal<String> Name();
|
| + int StartOffset() const;
|
| + int EndOffset() const;
|
| + uint32_t Count() const;
|
| + MaybeLocal<String> Name() const;
|
|
|
| private:
|
| explicit FunctionData(i::CoverageFunction* function)
|
| @@ -242,9 +245,9 @@ class V8_EXPORT_PRIVATE Coverage {
|
|
|
| class V8_EXPORT_PRIVATE ScriptData {
|
| public:
|
| - Local<debug::Script> GetScript();
|
| - size_t FunctionCount();
|
| - FunctionData GetFunctionData(size_t i);
|
| + Local<debug::Script> GetScript() const;
|
| + size_t FunctionCount() const;
|
| + FunctionData GetFunctionData(size_t i) const;
|
|
|
| private:
|
| explicit ScriptData(i::CoverageScript* script) : script_(script) {}
|
| @@ -253,13 +256,14 @@ class V8_EXPORT_PRIVATE Coverage {
|
| friend class v8::debug::Coverage;
|
| };
|
|
|
| - static Coverage Collect(Isolate* isolate, bool reset_count);
|
| + static Coverage CollectPrecise(Isolate* isolate);
|
| + static Coverage CollectBestEffort(Isolate* isolate);
|
|
|
| static void SelectMode(Isolate* isolate, Mode mode);
|
|
|
| - size_t ScriptCount();
|
| - ScriptData GetScriptData(size_t i);
|
| - bool IsEmpty() { return coverage_ == nullptr; }
|
| + size_t ScriptCount() const;
|
| + ScriptData GetScriptData(size_t i) const;
|
| + bool IsEmpty() const { return coverage_ == nullptr; }
|
|
|
| ~Coverage();
|
|
|
|
|