5 #ifndef V8_PROFILE_GENERATOR_H_
6 #define V8_PROFILE_GENERATOR_H_
24 const char*
GetCopy(
const char* src);
38 HashMap::Entry*
GetEntry(
const char* str,
int len);
123 void Print(
int indent);
127 return reinterpret_cast<CodeEntry*
>(entry1)->IsSameAs(
162 template <
typename Callback>
234 return a < b ? -1 : (a > b ? 1 : 0);
static const int kNoColumnNumberInfo
static const int kNoLineNumberInfo
void SetBuiltinId(Builtins::Name id)
const char * name_prefix_
Logger::LogEventsAndTags tag_
bool is_js_function() const
const char * bailout_reason_
void set_script_id(int script_id)
int column_number() const
List< OffsetRange > * no_frame_ranges_
void set_shared_id(int shared_id)
void set_bailout_reason(const char *bailout_reason)
Builtins::Name builtin_id_
static const char *const kEmptyResourceName
bool has_name_prefix() const
static bool is_js_function_tag(Logger::LogEventsAndTags tag)
const char * resource_name_
const char * bailout_reason() const
const char * name_prefix() const
const char * resource_name() const
static const char *const kEmptyBailoutReason
static const char *const kEmptyNamePrefix
List< OffsetRange > * no_frame_ranges() const
Builtins::Name builtin_id() const
CodeEntry(Logger::LogEventsAndTags tag, const char *name, const char *name_prefix=CodeEntry::kEmptyNamePrefix, const char *resource_name=CodeEntry::kEmptyResourceName, int line_number=v8::CpuProfileNode::kNoLineNumberInfo, int column_number=v8::CpuProfileNode::kNoColumnNumberInfo)
DISALLOW_COPY_AND_ASSIGN(CodeEntry)
uint32_t GetCallUid() const
bool IsSameAs(CodeEntry *entry) const
void set_no_frame_ranges(List< OffsetRange > *ranges)
const char * name() const
void Call(const Address &key, const CodeEntryInfo &value)
void DeleteAllCoveredCode(Address start, Address end)
DISALLOW_COPY_AND_ASSIGN(CodeMap)
void AddCode(Address addr, CodeEntry *entry, unsigned size)
static CodeEntry *const kSharedFunctionCodeEntry
int GetSharedId(Address addr)
SplayTree< CodeTreeConfig > CodeTree
void MoveCode(Address from, Address to)
CodeEntry * FindEntry(Address addr, Address *start=NULL)
const ProfileTree * top_down() const
base::TimeTicks end_time_
base::TimeTicks sample_timestamp(int index) const
base::TimeTicks start_time() const
base::TimeTicks start_time_
const char * title() const
CpuProfile(const char *title, bool record_samples)
void CalculateTotalTicksAndSamplingRate()
DISALLOW_COPY_AND_ASSIGN(CpuProfile)
int samples_count() const
base::TimeTicks end_time() const
void AddPath(base::TimeTicks timestamp, const Vector< CodeEntry * > &path)
ProfileNode * sample(int index) const
List< ProfileNode * > samples_
List< base::TimeTicks > timestamps_
List< CpuProfile * > current_profiles_
StringsStorage function_and_resource_names_
const char * GetName(int args_count)
CodeEntry * NewCodeEntry(Logger::LogEventsAndTags tag, const char *name, const char *name_prefix=CodeEntry::kEmptyNamePrefix, const char *resource_name=CodeEntry::kEmptyResourceName, int line_number=v8::CpuProfileNode::kNoLineNumberInfo, int column_number=v8::CpuProfileNode::kNoColumnNumberInfo)
const char * GetName(Name *name)
bool StartProfiling(const char *title, bool record_samples)
static const int kMaxSimultaneousProfiles
void AddPathToCurrentProfiles(base::TimeTicks timestamp, const Vector< CodeEntry * > &path)
const char * GetFunctionName(Name *name)
void RemoveProfile(CpuProfile *profile)
CpuProfilesCollection(Heap *heap)
List< CpuProfile * > finished_profiles_
List< CpuProfile * > * profiles()
DISALLOW_COPY_AND_ASSIGN(CpuProfilesCollection)
bool IsLastProfile(const char *title)
List< CodeEntry * > code_entries_
base::Semaphore current_profiles_semaphore_
CpuProfile * StopProfiling(const char *title)
const char * GetFunctionName(const char *name)
CodeEntry * EntryForVMState(StateTag tag)
void RecordTickSample(const TickSample &sample)
CpuProfilesCollection * profiles_
ProfileGenerator(CpuProfilesCollection *profiles)
static const char *const kProgramEntryName
static const char *const kUnresolvedFunctionName
DISALLOW_COPY_AND_ASSIGN(ProfileGenerator)
CodeEntry * unresolved_entry_
static const char *const kIdleEntryName
static const char *const kGarbageCollectorEntryName
CodeEntry * program_entry_
CodeEntry * entry() const
static bool CodeEntriesMatch(void *entry1, void *entry2)
unsigned self_ticks() const
void IncrementSelfTicks()
DISALLOW_COPY_AND_ASSIGN(ProfileNode)
ProfileNode * FindChild(CodeEntry *entry)
const List< ProfileNode * > * children() const
ProfileNode * FindOrAddChild(CodeEntry *entry)
static uint32_t CodeEntryHash(CodeEntry *entry)
void IncreaseSelfTicks(unsigned amount)
List< ProfileNode * > children_list_
ProfileNode(ProfileTree *tree, CodeEntry *entry)
ProfileNode * root() const
ProfileNode * AddPathFromEnd(const Vector< CodeEntry * > &path)
void TraverseDepthFirst(Callback *callback)
DISALLOW_COPY_AND_ASSIGN(ProfileTree)
void AddPathFromStart(const Vector< CodeEntry * > &path)
StringsStorage(Heap *heap)
const char * GetFunctionName(Name *name)
const char * GetName(Name *name)
const char * AddOrDisposeString(char *str, int len)
const char * GetFormatted(const char *format,...)
const char * GetCopy(const char *src)
const char * GetVFormatted(const char *format, va_list args)
HashMap::Entry * GetEntry(const char *str, int len)
static const int kMaxNameSize
static bool StringsMatch(void *key1, void *key2)
size_t GetUsedMemorySize() const
DISALLOW_COPY_AND_ASSIGN(StringsStorage)
enable harmony numeric enable harmony object literal extensions Optimize object Array DOM strings and string trace pretenuring decisions of HAllocate instructions Enables optimizations which favor memory size over execution speed maximum source size in bytes considered for a single inlining maximum cumulative number of AST nodes considered for inlining trace the tracking of allocation sites deoptimize every n garbage collections perform array bounds checks elimination analyze liveness of environment slots and zap dead values flushes the cache of optimized code for closures on every GC allow uint32 values on optimize frames if they are used only in safe operations track concurrent recompilation artificial compilation delay in ms do not emit check maps for constant values that have a leaf deoptimize the optimized code if the layout of the maps changes enable context specialization in TurboFan execution budget before interrupt is triggered max percentage of megamorphic generic ICs to allow optimization enable use of SAHF instruction if enable use of VFP3 instructions if available enable use of NEON instructions if enable use of SDIV and UDIV instructions if enable use of MLS instructions if enable loading bit constant by means of movw movt instruction enable unaligned accesses for enable use of d16 d31 registers on ARM this requires VFP3 force all emitted branches to be in long enable alignment of csp to bytes on platforms which prefer the register to always be expose gc extension under the specified name show built in functions in stack traces use random jit cookie to mask large constants minimum length for automatic enable preparsing CPU profiler sampling interval in microseconds trace out of bounds accesses to external arrays default size of stack region v8 is allowed to maximum length of function source code printed in a stack trace min size of a semi the new space consists of two semi spaces print one trace line following each garbage collection do not print trace line after scavenger collection print cumulative GC statistics in only print modified registers Trace simulator debug messages Implied by trace sim abort randomize hashes to avoid predictable hash Fixed seed to use to hash property Print the time it takes to deserialize the snapshot A filename with extra code to be included in the A file to write the raw snapshot bytes to(mksnapshot only)") DEFINE_STRING(raw_context_file
enable harmony numeric enable harmony object literal extensions Optimize object size
enable harmony numeric enable harmony object literal extensions Optimize object Array DOM strings and string trace pretenuring decisions of HAllocate instructions Enables optimizations which favor memory size over execution speed maximum source size in bytes considered for a single inlining maximum cumulative number of AST nodes considered for inlining trace the tracking of allocation sites deoptimize every n garbage collections perform array bounds checks elimination analyze liveness of environment slots and zap dead values flushes the cache of optimized code for closures on every GC allow uint32 values on optimize frames if they are used only in safe operations track concurrent recompilation artificial compilation delay in ms do not emit check maps for constant values that have a leaf deoptimize the optimized code if the layout of the maps changes enable context specialization in TurboFan execution budget before interrupt is triggered max percentage of megamorphic generic ICs to allow optimization enable use of SAHF instruction if enable use of VFP3 instructions if available enable use of NEON instructions if enable use of SDIV and UDIV instructions if enable use of MLS instructions if enable loading bit constant by means of movw movt instruction enable unaligned accesses for enable use of d16 d31 registers on ARM this requires VFP3 force all emitted branches to be in long enable alignment of csp to bytes on platforms which prefer the register to always be expose gc extension under the specified name show built in functions in stack traces use random jit cookie to mask large constants minimum length for automatic enable preparsing CPU profiler sampling interval in microseconds trace out of bounds accesses to external arrays default size of stack region v8 is allowed to maximum length of function source code printed in a stack trace min size of a semi the new space consists of two semi spaces print one trace line following each garbage collection do not print trace line after scavenger collection print cumulative GC statistics in name
enable harmony numeric enable harmony object literal extensions Optimize object Array DOM strings and string trace pretenuring decisions of HAllocate instructions Enables optimizations which favor memory size over execution speed maximum source size in bytes considered for a single inlining maximum cumulative number of AST nodes considered for inlining trace the tracking of allocation sites deoptimize every n garbage collections perform array bounds checks elimination analyze liveness of environment slots and zap dead values flushes the cache of optimized code for closures on every GC allow uint32 values on optimize frames if they are used only in safe operations track concurrent recompilation artificial compilation delay in ms do not emit check maps for constant values that have a leaf deoptimize the optimized code if the layout of the maps changes enable context specialization in TurboFan execution budget before interrupt is triggered max percentage of megamorphic generic ICs to allow optimization enable use of SAHF instruction if enable use of VFP3 instructions if available enable use of NEON instructions if enable use of SDIV and UDIV instructions if enable use of MLS instructions if enable loading bit constant by means of movw movt instruction enable unaligned accesses for enable use of d16 d31 registers on ARM this requires VFP3 force all emitted branches to be in long enable alignment of csp to bytes on platforms which prefer the register to always be NULL
Debugger support for the V8 JavaScript engine.
CodeEntryInfo(CodeEntry *an_entry, unsigned a_size)
static int Compare(const Key &a, const Key &b)
static const Value NoValue()