v8
V8 is Google’s open source high-performance JavaScript and WebAssembly engine, written in C++.
Loading...
Searching...
No Matches
v8::internal::ProfilerListener Class Reference

#include <profiler-listener.h>

Inheritance diagram for v8::internal::ProfilerListener:
Collaboration diagram for v8::internal::ProfilerListener:

Public Member Functions

 ProfilerListener (Isolate *, CodeEventObserver *, CodeEntryStorage &code_entry_storage, WeakCodeRegistry &weak_code_registry, CpuProfilingNamingMode mode=kDebugNaming)
 
 ~ProfilerListener () override
 
 ProfilerListener (const ProfilerListener &)=delete
 
ProfilerListeneroperator= (const ProfilerListener &)=delete
 
void CodeCreateEvent (CodeTag tag, DirectHandle< AbstractCode > code, const char *name) override
 
void CodeCreateEvent (CodeTag tag, DirectHandle< AbstractCode > code, DirectHandle< Name > name) override
 
void CodeCreateEvent (CodeTag tag, DirectHandle< AbstractCode > code, DirectHandle< SharedFunctionInfo > shared, DirectHandle< Name > script_name) override
 
void CodeCreateEvent (CodeTag tag, DirectHandle< AbstractCode > code, DirectHandle< SharedFunctionInfo > shared, DirectHandle< Name > script_name, int line, int column) override
 
void CallbackEvent (DirectHandle< Name > name, Address entry_point) override
 
void GetterCallbackEvent (DirectHandle< Name > name, Address entry_point) override
 
void SetterCallbackEvent (DirectHandle< Name > name, Address entry_point) override
 
void RegExpCodeCreateEvent (DirectHandle< AbstractCode > code, DirectHandle< String > source, RegExpFlags flags) override
 
void CodeMoveEvent (Tagged< InstructionStream > from, Tagged< InstructionStream > to) override
 
void BytecodeMoveEvent (Tagged< BytecodeArray > from, Tagged< BytecodeArray > to) override
 
void SharedFunctionInfoMoveEvent (Address from, Address to) override
 
void NativeContextMoveEvent (Address from, Address to) override
 
void CodeMovingGCEvent () override
 
void CodeDisableOptEvent (DirectHandle< AbstractCode > code, DirectHandle< SharedFunctionInfo > shared) override
 
void CodeDeoptEvent (DirectHandle< Code > code, DeoptimizeKind kind, Address pc, int fp_to_sp_delta) override
 
void CodeDependencyChangeEvent (DirectHandle< Code > code, DirectHandle< SharedFunctionInfo > sfi, const char *reason) override
 
void WeakCodeClearEvent () override
 
void OnHeapObjectDeletion (CodeEntry *) override
 
void CodeSweepEvent ()
 
const char * GetName (Tagged< Name > name)
 
const char * GetName (int args_count)
 
const char * GetName (const char *name)
 
const char * GetName (base::Vector< const char > name)
 
const char * GetConsName (const char *prefix, Tagged< Name > name)
 
void set_observer (CodeEventObserver *observer)
 
- Public Member Functions inherited from v8::internal::LogEventListener
virtual ~LogEventListener ()=default
 
virtual bool is_listening_to_code_events ()
 
virtual bool allows_code_compaction ()
 
- Public Member Functions inherited from v8::internal::WeakCodeRegistry::Listener

Private Member Functions

const char * GetFunctionName (Tagged< SharedFunctionInfo >)
 
void AttachDeoptInlinedFrames (DirectHandle< Code > code, CodeDeoptEventRecord *rec)
 
Tagged< NameInferScriptName (Tagged< Name > name, Tagged< SharedFunctionInfo > info)
 
V8_INLINE void DispatchCodeEvent (const CodeEventsContainer &evt_rec)
 

Private Attributes

Isolateisolate_
 
CodeEventObserverobserver_
 
CodeEntryStoragecode_entries_
 
WeakCodeRegistryweak_code_registry_
 
const CpuProfilingNamingMode naming_mode_
 

Additional Inherited Members

- Public Types inherited from v8::internal::LogEventListener
enum class  Event : uint8_t { LOG_EVENT_LIST =(DECLARE_ENUM) kLength }
 
enum class  CodeTag : uint8_t { CODE_TYPE_LIST =(DECLARE_ENUM) kLength }
 

Detailed Description

Definition at line 27 of file profiler-listener.h.

Constructor & Destructor Documentation

◆ ProfilerListener() [1/2]

v8::internal::ProfilerListener::ProfilerListener ( Isolate * isolate,
CodeEventObserver * observer,
CodeEntryStorage & code_entry_storage,
WeakCodeRegistry & weak_code_registry,
CpuProfilingNamingMode mode = kDebugNaming )

Definition at line 30 of file profiler-listener.cc.

◆ ~ProfilerListener()

v8::internal::ProfilerListener::~ProfilerListener ( )
overridedefault

◆ ProfilerListener() [2/2]

v8::internal::ProfilerListener::ProfilerListener ( const ProfilerListener & )
delete

Member Function Documentation

◆ AttachDeoptInlinedFrames()

void v8::internal::ProfilerListener::AttachDeoptInlinedFrames ( DirectHandle< Code > code,
CodeDeoptEventRecord * rec )
private

Definition at line 401 of file profiler-listener.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ BytecodeMoveEvent()

void v8::internal::ProfilerListener::BytecodeMoveEvent ( Tagged< BytecodeArray > from,
Tagged< BytecodeArray > to )
overridevirtual

Implements v8::internal::LogEventListener.

Definition at line 312 of file profiler-listener.cc.

Here is the call graph for this function:

◆ CallbackEvent()

void v8::internal::ProfilerListener::CallbackEvent ( DirectHandle< Name > name,
Address entry_point )
overridevirtual

Implements v8::internal::LogEventListener.

Definition at line 253 of file profiler-listener.cc.

Here is the call graph for this function:

◆ CodeCreateEvent() [1/4]

void v8::internal::ProfilerListener::CodeCreateEvent ( CodeTag tag,
DirectHandle< AbstractCode > code,
const char * name )
overridevirtual

Implements v8::internal::LogEventListener.

Definition at line 43 of file profiler-listener.cc.

Here is the call graph for this function:

◆ CodeCreateEvent() [2/4]

void v8::internal::ProfilerListener::CodeCreateEvent ( CodeTag tag,
DirectHandle< AbstractCode > code,
DirectHandle< Name > name )
overridevirtual

Implements v8::internal::LogEventListener.

Definition at line 59 of file profiler-listener.cc.

Here is the call graph for this function:

◆ CodeCreateEvent() [3/4]

void v8::internal::ProfilerListener::CodeCreateEvent ( CodeTag tag,
DirectHandle< AbstractCode > code,
DirectHandle< SharedFunctionInfo > shared,
DirectHandle< Name > script_name )
overridevirtual

Implements v8::internal::LogEventListener.

Definition at line 75 of file profiler-listener.cc.

Here is the call graph for this function:

◆ CodeCreateEvent() [4/4]

void v8::internal::ProfilerListener::CodeCreateEvent ( CodeTag tag,
DirectHandle< AbstractCode > code,
DirectHandle< SharedFunctionInfo > shared,
DirectHandle< Name > script_name,
int line,
int column )
overridevirtual

Implements v8::internal::LogEventListener.

Definition at line 111 of file profiler-listener.cc.

Here is the call graph for this function:

◆ CodeDeoptEvent()

void v8::internal::ProfilerListener::CodeDeoptEvent ( DirectHandle< Code > code,
DeoptimizeKind kind,
Address pc,
int fp_to_sp_delta )
overridevirtual

Implements v8::internal::LogEventListener.

Definition at line 340 of file profiler-listener.cc.

Here is the call graph for this function:

◆ CodeDependencyChangeEvent()

void v8::internal::ProfilerListener::CodeDependencyChangeEvent ( DirectHandle< Code > code,
DirectHandle< SharedFunctionInfo > sfi,
const char * reason )
inlineoverridevirtual

Implements v8::internal::LogEventListener.

Definition at line 74 of file profiler-listener.h.

◆ CodeDisableOptEvent()

void v8::internal::ProfilerListener::CodeDisableOptEvent ( DirectHandle< AbstractCode > code,
DirectHandle< SharedFunctionInfo > shared )
overridevirtual

Implements v8::internal::LogEventListener.

Definition at line 329 of file profiler-listener.cc.

Here is the call graph for this function:

◆ CodeMoveEvent()

void v8::internal::ProfilerListener::CodeMoveEvent ( Tagged< InstructionStream > from,
Tagged< InstructionStream > to )
overridevirtual

Implements v8::internal::LogEventListener.

Definition at line 302 of file profiler-listener.cc.

Here is the call graph for this function:

◆ CodeMovingGCEvent()

void v8::internal::ProfilerListener::CodeMovingGCEvent ( )
inlineoverridevirtual

Implements v8::internal::LogEventListener.

Definition at line 69 of file profiler-listener.h.

◆ CodeSweepEvent()

void v8::internal::ProfilerListener::CodeSweepEvent ( )

Definition at line 366 of file profiler-listener.cc.

Here is the call graph for this function:

◆ DispatchCodeEvent()

V8_INLINE void v8::internal::ProfilerListener::DispatchCodeEvent ( const CodeEventsContainer & evt_rec)
inlineprivate

Definition at line 107 of file profiler-listener.h.

Here is the caller graph for this function:

◆ GetConsName()

const char * v8::internal::ProfilerListener::GetConsName ( const char * prefix,
Tagged< Name > name )
inline

Definition at line 94 of file profiler-listener.h.

Here is the caller graph for this function:

◆ GetFunctionName()

const char * v8::internal::ProfilerListener::GetFunctionName ( Tagged< SharedFunctionInfo > shared)
private

Definition at line 389 of file profiler-listener.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ GetName() [1/4]

const char * v8::internal::ProfilerListener::GetName ( base::Vector< const char > name)

Definition at line 368 of file profiler-listener.cc.

Here is the call graph for this function:

◆ GetName() [2/4]

const char * v8::internal::ProfilerListener::GetName ( const char * name)
inline

Definition at line 90 of file profiler-listener.h.

◆ GetName() [3/4]

const char * v8::internal::ProfilerListener::GetName ( int args_count)
inline

Definition at line 87 of file profiler-listener.h.

◆ GetName() [4/4]

const char * v8::internal::ProfilerListener::GetName ( Tagged< Name > name)
inline

Definition at line 84 of file profiler-listener.h.

Here is the caller graph for this function:

◆ GetterCallbackEvent()

void v8::internal::ProfilerListener::GetterCallbackEvent ( DirectHandle< Name > name,
Address entry_point )
overridevirtual

Implements v8::internal::LogEventListener.

Definition at line 264 of file profiler-listener.cc.

Here is the call graph for this function:

◆ InferScriptName()

Tagged< Name > v8::internal::ProfilerListener::InferScriptName ( Tagged< Name > name,
Tagged< SharedFunctionInfo > info )
private

Definition at line 381 of file profiler-listener.cc.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ NativeContextMoveEvent()

void v8::internal::ProfilerListener::NativeContextMoveEvent ( Address from,
Address to )
overridevirtual

Implements v8::internal::LogEventListener.

Definition at line 322 of file profiler-listener.cc.

Here is the call graph for this function:

◆ OnHeapObjectDeletion()

void v8::internal::ProfilerListener::OnHeapObjectDeletion ( CodeEntry * entry)
overridevirtual

Implements v8::internal::WeakCodeRegistry::Listener.

Definition at line 360 of file profiler-listener.cc.

Here is the call graph for this function:

◆ operator=()

ProfilerListener & v8::internal::ProfilerListener::operator= ( const ProfilerListener & )
delete

◆ RegExpCodeCreateEvent()

void v8::internal::ProfilerListener::RegExpCodeCreateEvent ( DirectHandle< AbstractCode > code,
DirectHandle< String > source,
RegExpFlags flags )
overridevirtual

Implements v8::internal::LogEventListener.

Definition at line 286 of file profiler-listener.cc.

Here is the call graph for this function:

◆ set_observer()

void v8::internal::ProfilerListener::set_observer ( CodeEventObserver * observer)
inline

Definition at line 98 of file profiler-listener.h.

◆ SetterCallbackEvent()

void v8::internal::ProfilerListener::SetterCallbackEvent ( DirectHandle< Name > name,
Address entry_point )
overridevirtual

Implements v8::internal::LogEventListener.

Definition at line 275 of file profiler-listener.cc.

Here is the call graph for this function:

◆ SharedFunctionInfoMoveEvent()

void v8::internal::ProfilerListener::SharedFunctionInfoMoveEvent ( Address from,
Address to )
inlineoverridevirtual

Implements v8::internal::LogEventListener.

Definition at line 67 of file profiler-listener.h.

◆ WeakCodeClearEvent()

void v8::internal::ProfilerListener::WeakCodeClearEvent ( )
overridevirtual

Implements v8::internal::LogEventListener.

Definition at line 358 of file profiler-listener.cc.

Here is the call graph for this function:

Member Data Documentation

◆ code_entries_

CodeEntryStorage& v8::internal::ProfilerListener::code_entries_
private

Definition at line 113 of file profiler-listener.h.

◆ isolate_

Isolate* v8::internal::ProfilerListener::isolate_
private

Definition at line 111 of file profiler-listener.h.

◆ naming_mode_

const CpuProfilingNamingMode v8::internal::ProfilerListener::naming_mode_
private

Definition at line 115 of file profiler-listener.h.

◆ observer_

CodeEventObserver* v8::internal::ProfilerListener::observer_
private

Definition at line 112 of file profiler-listener.h.

◆ weak_code_registry_

WeakCodeRegistry& v8::internal::ProfilerListener::weak_code_registry_
private

Definition at line 114 of file profiler-listener.h.


The documentation for this class was generated from the following files: