![]() |
v8
V8 is Google’s open source high-performance JavaScript and WebAssembly engine, written in C++.
|
#include <cpu-profiler.h>
Public Member Functions | |
| ~ProfilerEventsProcessor () override | |
| void | CodeEventHandler (const CodeEventsContainer &evt_rec) override |
| void | Run () override=0 |
| void | StopSynchronously () |
| bool | running () |
| void | Enqueue (const CodeEventsContainer &event) |
| void | AddCurrentStack (bool update_stats=false, const std::optional< uint64_t > trace_id=std::nullopt) |
| void | AddDeoptStack (Address from, int fp_to_sp_delta) |
| void | AddSample (TickSample sample) |
| virtual void | SetSamplingInterval (base::TimeDelta) |
Public Member Functions inherited from v8::base::Thread | |
| Thread (const Options &options) | |
| Thread (const Thread &)=delete | |
| Thread & | operator= (const Thread &)=delete |
| virtual | ~Thread () |
| V8_WARN_UNUSED_RESULT bool | Start () |
| bool | StartSynchronously () |
| void | Join () |
| const char * | name () const |
| PlatformData * | data () |
| Priority | priority () const |
| void | NotifyStartedAndRun () |
Public Member Functions inherited from v8::internal::CodeEventObserver | |
| virtual | ~CodeEventObserver ()=default |
Protected Types | |
| enum | SampleProcessingResult { OneSampleProcessed , FoundSampleForNextCodeEvent , NoSamplesInQueue } |
Protected Member Functions | |
| ProfilerEventsProcessor (Isolate *isolate, Symbolizer *symbolizer, ProfilerCodeObserver *code_observer, CpuProfilesCollection *profiles) | |
| bool | ProcessCodeEvent () |
| virtual SampleProcessingResult | ProcessOneSample ()=0 |
Protected Attributes | |
| Symbolizer * | symbolizer_ |
| ProfilerCodeObserver * | code_observer_ |
| CpuProfilesCollection * | profiles_ |
| std::atomic_bool | running_ {true} |
| base::ConditionVariable | running_cond_ |
| base::Mutex | running_mutex_ |
| LockedQueue< CodeEventsContainer > | events_buffer_ |
| LockedQueue< TickSampleEventRecord > | ticks_from_vm_buffer_ |
| std::atomic< unsigned > | last_code_event_id_ |
| unsigned | last_processed_code_event_id_ |
| Isolate * | isolate_ |
Additional Inherited Members | |
Public Types inherited from v8::base::Thread | |
| enum class | Priority { kBestEffort , kUserVisible , kUserBlocking , kDefault } |
| using | LocalStorageKey = int32_t |
Static Public Member Functions inherited from v8::base::Thread | |
| static LocalStorageKey | CreateThreadLocalKey () |
| static void | DeleteThreadLocalKey (LocalStorageKey key) |
| static void * | GetThreadLocal (LocalStorageKey key) |
| static void | SetThreadLocal (LocalStorageKey key, void *value) |
| static bool | HasThreadLocal (LocalStorageKey key) |
| static void * | GetExistingThreadLocal (LocalStorageKey key) |
Static Public Attributes inherited from v8::base::Thread | |
| static const int | kMaxThreadNameLength = 16 |
Definition at line 169 of file cpu-profiler.h.
| Enumerator | |
|---|---|
| OneSampleProcessed | |
| FoundSampleForNextCodeEvent | |
| NoSamplesInQueue | |
Definition at line 199 of file cpu-profiler.h.
|
override |
|
protected |
| void v8::internal::ProfilerEventsProcessor::AddCurrentStack | ( | bool | update_stats = false, |
| const std::optional< uint64_t > | trace_id = std::nullopt ) |
| void v8::internal::ProfilerEventsProcessor::AddDeoptStack | ( | Address | from, |
| int | fp_to_sp_delta ) |
Definition at line 152 of file cpu-profiler.cc.
| void v8::internal::ProfilerEventsProcessor::AddSample | ( | TickSample | sample | ) |
Definition at line 180 of file cpu-profiler.cc.
|
overridevirtual |
Implements v8::internal::CodeEventObserver.
Definition at line 216 of file cpu-profiler.cc.
| void v8::internal::ProfilerEventsProcessor::Enqueue | ( | const CodeEventsContainer & | event | ) |
|
protected |
Definition at line 199 of file cpu-profiler.cc.
|
protectedpure virtual |
Implemented in v8::internal::SamplingEventsProcessor.
|
overridepure virtual |
Implements v8::base::Thread.
Implemented in v8::internal::SamplingEventsProcessor.
|
inline |
Definition at line 179 of file cpu-profiler.h.
|
inlinevirtual |
Reimplemented in v8::internal::SamplingEventsProcessor.
Definition at line 189 of file cpu-profiler.h.
| void v8::internal::ProfilerEventsProcessor::StopSynchronously | ( | ) |
Definition at line 186 of file cpu-profiler.cc.
|
protected |
Definition at line 207 of file cpu-profiler.h.
|
protected |
Definition at line 212 of file cpu-profiler.h.
|
protected |
Definition at line 216 of file cpu-profiler.h.
|
protected |
Definition at line 214 of file cpu-profiler.h.
|
protected |
Definition at line 215 of file cpu-profiler.h.
|
protected |
Definition at line 208 of file cpu-profiler.h.
|
protected |
Definition at line 209 of file cpu-profiler.h.
|
protected |
Definition at line 210 of file cpu-profiler.h.
|
protected |
Definition at line 211 of file cpu-profiler.h.
|
protected |
Definition at line 206 of file cpu-profiler.h.
|
protected |
Definition at line 213 of file cpu-profiler.h.