50 static inline Address* ResolveReturnAddressLocation(
Address* pc_address) {
51 if (return_address_location_resolver ==
NULL) {
54 return reinterpret_cast<Address*
>(
55 return_address_location_resolver(
56 reinterpret_cast<uintptr_t>(pc_address)));
66 : limit_(frame->
fp()), handler_(handler) {
68 ASSERT(frame->sp() <= handler->address());
71 StackHandler*
handler()
const {
return handler_; }
74 return handler_ ==
NULL || handler_->
address() > limit_;
78 handler_ = handler_->next();
83 StackHandler* handler_;
90 #define INITIALIZE_SINGLETON(type, field) field##_(this),
91 StackFrameIterator::StackFrameIterator()
92 : isolate_(Isolate::Current()),
95 thread_(isolate_->thread_local_top()),
96 fp_(
NULL), sp_(
NULL), advance_(&StackFrameIterator::AdvanceWithHandler) {
99 StackFrameIterator::StackFrameIterator(Isolate* isolate)
103 thread_(isolate_->thread_local_top()),
104 fp_(
NULL), sp_(
NULL), advance_(&StackFrameIterator::AdvanceWithHandler) {
107 StackFrameIterator::StackFrameIterator(Isolate* isolate, ThreadLocalTop* t)
110 frame_(
NULL), handler_(
NULL), thread_(t),
111 fp_(
NULL), sp_(
NULL), advance_(&StackFrameIterator::AdvanceWithHandler) {
114 StackFrameIterator::StackFrameIterator(Isolate* isolate,
119 thread_(use_top ? isolate_->thread_local_top() :
NULL),
120 fp_(use_top ?
NULL : fp), sp_(sp),
121 advance_(use_top ? &StackFrameIterator::AdvanceWithHandler :
122 &StackFrameIterator::AdvanceWithoutHandler) {
123 if (use_top || fp !=
NULL) {
128 #undef INITIALIZE_SINGLETON
131 void StackFrameIterator::AdvanceWithHandler() {
137 StackFrame::State state;
138 StackFrame::Type
type = frame_->GetCallerState(&state);
141 StackHandlerIterator it(frame_, handler_);
142 while (!it.done()) it.Advance();
143 handler_ = it.handler();
146 frame_ = SingletonFor(type, &state);
154 void StackFrameIterator::AdvanceWithoutHandler() {
157 StackFrame::State state;
158 StackFrame::Type type = frame_->GetCallerState(&state);
159 frame_ = SingletonFor(type, &state);
164 StackFrame::State state;
165 StackFrame::Type
type;
166 if (thread_ !=
NULL) {
167 type = ExitFrame::GetStateForFramePointer(
168 Isolate::c_entry_fp(thread_), &state);
169 handler_ = StackHandler::FromAddress(
170 Isolate::handler(thread_));
175 state.pc_address = ResolveReturnAddressLocation(
176 reinterpret_cast<Address*>(StandardFrame::ComputePCAddress(fp_)));
177 type = StackFrame::ComputeType(isolate(), &state);
179 if (SingletonFor(type) ==
NULL)
return;
180 frame_ = SingletonFor(type, &state);
184 StackFrame* StackFrameIterator::SingletonFor(StackFrame::Type type,
185 StackFrame::State* state) {
189 result->state_ = *state;
194 StackFrame* StackFrameIterator::SingletonFor(StackFrame::Type type) {
195 #define FRAME_TYPE_CASE(type, field) \
196 case StackFrame::type: result = &field##_; break;
206 #undef FRAME_TYPE_CASE
213 StackTraceFrameIterator::StackTraceFrameIterator() {
214 if (!done() && !IsValidFrame()) Advance();
218 StackTraceFrameIterator::StackTraceFrameIterator(
Isolate* isolate)
220 if (!done() && !IsValidFrame())
Advance();
226 JavaScriptFrameIterator::Advance();
228 if (IsValidFrame())
return;
232 bool StackTraceFrameIterator::IsValidFrame() {
233 if (!frame()->
function()->IsJSFunction())
return false;
236 return (script->IsScript() &&
244 bool SafeStackFrameIterator::ExitFrameValidator::IsValidFP(
Address fp) {
245 if (!validator_.IsValid(fp))
return false;
247 if (!validator_.IsValid(sp))
return false;
248 StackFrame::State state;
250 if (!validator_.IsValid(reinterpret_cast<Address>(state.pc_address))) {
253 return *state.pc_address !=
NULL;
257 SafeStackFrameIterator::ActiveCountMaintainer::ActiveCountMaintainer(
259 : isolate_(isolate) {
260 isolate_->set_safe_stack_iterator_counter(
261 isolate_->safe_stack_iterator_counter() + 1);
265 SafeStackFrameIterator::ActiveCountMaintainer::~ActiveCountMaintainer() {
266 isolate_->set_safe_stack_iterator_counter(
267 isolate_->safe_stack_iterator_counter() - 1);
271 SafeStackFrameIterator::SafeStackFrameIterator(
274 maintainer_(isolate),
275 stack_validator_(low_bound, high_bound),
276 is_valid_top_(IsValidTop(isolate, low_bound, high_bound)),
277 is_valid_fp_(IsWithinBounds(low_bound, high_bound, fp)),
278 is_working_iterator_(is_valid_top_ || is_valid_fp_),
279 iteration_done_(!is_working_iterator_),
280 iterator_(isolate, is_valid_top_, is_valid_fp_ ? fp :
NULL, sp) {
283 bool SafeStackFrameIterator::is_active(Isolate* isolate) {
284 return isolate->safe_stack_iterator_counter() > 0;
288 bool SafeStackFrameIterator::IsValidTop(Isolate* isolate,
290 ThreadLocalTop* top = isolate->thread_local_top();
292 ExitFrameValidator validator(low_bound, high_bound);
293 if (!validator.IsValidFP(fp))
return false;
298 void SafeStackFrameIterator::Advance() {
299 ASSERT(is_working_iterator_);
302 Address last_sp = last_frame->sp(), last_fp = last_frame->fp();
304 iteration_done_ = !IsValidFrame(last_frame) ||
305 !CanIterateHandles(last_frame, iterator_.handler()) ||
306 !IsValidCaller(last_frame);
307 if (iteration_done_)
return;
310 if (iterator_.done())
return;
313 iteration_done_ = prev_frame->sp() < last_sp || prev_frame->fp() < last_fp;
317 bool SafeStackFrameIterator::CanIterateHandles(
StackFrame* frame,
318 StackHandler* handler) {
322 return !is_valid_top_ || (frame->sp() <= handler->address());
326 bool SafeStackFrameIterator::IsValidFrame(
StackFrame* frame)
const {
327 return IsValidStackAddress(frame->sp()) && IsValidStackAddress(frame->fp());
331 bool SafeStackFrameIterator::IsValidCaller(
StackFrame* frame) {
332 StackFrame::State state;
333 if (frame->is_entry() || frame->is_entry_construct()) {
339 ExitFrameValidator validator(stack_validator_);
340 if (!validator.IsValidFP(caller_fp))
return false;
341 }
else if (frame->is_arguments_adaptor()) {
345 Object* number_of_args =
reinterpret_cast<ArgumentsAdaptorFrame*
>(frame)->
347 if (!number_of_args->IsSmi()) {
351 frame->ComputeCallerState(&state);
352 return IsValidStackAddress(state.sp) && IsValidStackAddress(state.fp) &&
353 iterator_.SingletonFor(frame->GetCallerState(&state)) !=
NULL;
358 if (is_working_iterator_) {
360 iteration_done_ =
false;
372 if (!done() && !frame()->is_java_script())
Advance();
378 SafeJavaScriptFrameIterator::Advance();
380 if (frame()->is_java_script())
return;
385 Code* StackFrame::GetSafepointData(
Isolate* isolate,
387 SafepointEntry* safepoint_entry,
388 unsigned* stack_slots) {
400 Code* code = entry->
code;
402 *stack_slots = code->stack_slots();
407 bool StackFrame::HasHandler()
const {
408 StackHandlerIterator it(
this, top_handler());
414 static bool GcSafeCodeContains(HeapObject*
object,
Address addr);
418 void StackFrame::IteratePc(ObjectVisitor* v,
422 ASSERT(GcSafeCodeContains(holder, pc));
423 unsigned pc_offset =
static_cast<unsigned>(pc - holder->instruction_start());
425 v->VisitPointer(&code);
426 if (code != holder) {
427 holder =
reinterpret_cast<Code*
>(code);
428 pc = holder->instruction_start() + pc_offset;
434 void StackFrame::SetReturnAddressLocationResolver(
436 ASSERT(return_address_location_resolver ==
NULL);
437 return_address_location_resolver = resolver;
441 StackFrame::Type StackFrame::ComputeType(Isolate* isolate, State* state) {
451 if (!marker->IsSmi()) {
456 if (SafeStackFrameIterator::is_active(isolate))
return JAVA_SCRIPT;
457 Code::Kind kind = GetContainingCode(isolate, *(state->pc_address))->kind();
466 StackFrame::Type StackFrame::GetCallerState(State* state)
const {
467 ComputeCallerState(state);
468 return ComputeType(isolate(), state);
472 Address StackFrame::UnpaddedFP()
const {
473 #if defined(V8_TARGET_ARCH_IA32)
474 if (!is_optimized())
return fp();
487 return HEAP->raw_unchecked_js_entry_code();
491 void EntryFrame::ComputeCallerState(State* state)
const {
492 GetCallerState(state);
502 StackFrame::Type EntryFrame::GetCallerState(State* state)
const {
510 return HEAP->raw_unchecked_js_construct_entry_code();
525 void ExitFrame::ComputeCallerState(State* state)
const {
527 state->sp = caller_sp();
529 state->pc_address = ResolveReturnAddressLocation(
542 IteratePc(v, pc_address(), LookupCode());
553 if (fp == 0)
return NONE;
564 state->pc_address = ResolveReturnAddressLocation(
593 return static_cast<int>((base - limit) / kPointerSize);
598 state->sp = caller_sp();
600 state->pc_address = ResolveReturnAddressLocation(
613 for (StackHandlerIterator it(
this, top_handler()); !it.done(); it.Advance()) {
614 if (it.handler()->includes(address))
return true;
623 StackHandlerIterator it(
this, top_handler());
629 ASSERT(!SafeStackFrameIterator::is_active(isolate()));
632 unsigned stack_slots = 0;
633 SafepointEntry safepoint_entry;
634 Code* code = StackFrame::GetSafepointData(
635 isolate(),
pc(), &safepoint_entry, &stack_slots);
644 if (safepoint_entry.argument_count() > 0) {
645 v->VisitPointers(parameters_base,
646 parameters_base + safepoint_entry.argument_count());
647 parameters_base += safepoint_entry.argument_count();
651 if (safepoint_entry.has_doubles()) {
657 if (safepoint_entry.HasRegisters()) {
659 if (safepoint_entry.HasRegisterAt(i)) {
660 int reg_stack_index = MacroAssembler::SafepointRegisterStackIndex(i);
661 v->VisitPointer(parameters_base + reg_stack_index);
669 uint8_t* safepoint_bits = safepoint_entry.bits();
673 v->VisitPointers(parameters_base, parameters_limit);
676 for (
unsigned index = 0; index < stack_slots; index++) {
679 if ((safepoint_bits[byte_index] & (1
U << bit_index)) != 0) {
680 v->VisitPointer(parameters_limit + index);
688 v->VisitPointers(fixed_base, fixed_limit);
691 IteratePc(v, pc_address(), code);
717 return function->unchecked_code();
722 ASSERT(!SafeStackFrameIterator::is_active(isolate()) &&
726 return function->shared()->formal_parameter_count();
736 ASSERT(functions->length() == 0);
742 ASSERT(functions->length() == 0);
743 Code* code_pointer = LookupCode();
744 int offset =
static_cast<int>(
pc() - code_pointer->address());
750 functions->
Add(summary);
756 bool print_line_number) {
762 if (it.frame()->is_java_script()) {
767 if (maybe_fun->IsJSFunction()) {
774 PrintF(
"+%d", code_offset);
776 if (print_line_number) {
778 v8::internal::Isolate::Current()->heap()->FindCodeObject(pc));
780 Object* maybe_script = shared->script();
781 if (maybe_script->IsScript()) {
784 Object* script_name_raw = script->name();
785 if (script_name_raw->IsString()) {
790 PrintF(file,
" at %s:%d", *c_script_name, line);
792 PrintF(file,
"at <unknown>:%d", line);
795 PrintF(file,
" at <unknown>:<unknown>");
809 for (
int i = 0; i < length; i++) {
824 receiver_->ShortPrint();
826 function_->shared()->DebugName()->ShortPrint();
831 PrintF(
"\npc: %d\n", offset_);
836 ASSERT(frames->length() == 0);
839 int deopt_index = Safepoint::kNoDeoptimizationIndex;
847 if (deopt_index == Safepoint::kNoDeoptimizationIndex) {
852 TranslationIterator it(data->TranslationByteArray(),
853 data->TranslationIndex(deopt_index)->value());
855 ASSERT(opcode == Translation::BEGIN);
857 int jsframe_count = it.Next();
862 int i = jsframe_count;
865 if (opcode == Translation::JS_FRAME) {
867 int ast_id = it.Next();
868 int function_id = it.Next();
877 ASSERT(opcode == Translation::STACK_SLOT ||
878 opcode == Translation::LITERAL);
879 int index = it.Next();
883 if (opcode == Translation::LITERAL) {
884 receiver = data->LiteralArray()->
get(index);
896 int parameter_index = index + parameter_count;
897 receiver = (parameter_index == -1)
903 Code* code =
function->shared()->code();
913 FrameSummary summary(receiver,
function, code, pc_offset, is_constructor);
914 frames->
Add(summary);
915 is_constructor =
false;
916 }
else if (opcode == Translation::CONSTRUCT_STUB_FRAME) {
918 it.Skip(Translation::NumberOfOperandsFor(opcode));
920 is_constructor =
true;
923 it.Skip(Translation::NumberOfOperandsFor(opcode));
941 code = isolate()->inner_pointer_to_code_cache()->
942 GcSafeFindCodeForInnerPointer(
pc());
948 *deopt_index = safepoint_entry.deoptimization_index();
949 ASSERT(*deopt_index != Safepoint::kNoDeoptimizationIndex);
958 int deopt_index = Safepoint::kNoDeoptimizationIndex;
961 TranslationIterator it(data->TranslationByteArray(),
962 data->TranslationIndex(deopt_index)->value());
964 ASSERT(opcode == Translation::BEGIN);
967 int jsframe_count = it.Next();
968 return jsframe_count;
973 ASSERT(functions->length() == 0);
976 int deopt_index = Safepoint::kNoDeoptimizationIndex;
979 TranslationIterator it(data->TranslationByteArray(),
980 data->TranslationIndex(deopt_index)->value());
982 ASSERT(opcode == Translation::BEGIN);
984 int jsframe_count = it.Next();
988 while (jsframe_count > 0) {
990 if (opcode == Translation::JS_FRAME) {
993 int function_id = it.Next();
997 functions->
Add(
function);
1000 it.Skip(Translation::NumberOfOperandsFor(opcode));
1024 return isolate()->builtins()->builtin(
1025 Builtins::kArgumentsAdaptorTrampoline);
1033 return reinterpret_cast<Code*
>(code);
1040 accumulator->
Add((mode == OVERVIEW) ?
"%5d: " :
"[%d]: ", index);
1049 Object*
function = this->
function();
1052 PrintIndex(accumulator, mode, index);
1066 Object* script_obj = shared->script();
1067 if (script_obj->IsScript()) {
1069 accumulator->
Add(
" [");
1077 accumulator->
Add(
":%d", line);
1079 int function_start_pos = shared->start_position();
1081 accumulator->
Add(
":~%d", line);
1084 accumulator->
Add(
"] ");
1088 accumulator->
Add(
"(this=%o", receiver);
1092 for (
int i = 0; i < parameters_count; i++) {
1093 accumulator->
Add(
",");
1097 if (i < scope_info->ParameterCount()) {
1098 accumulator->
PrintName(scope_info->ParameterName(i));
1099 accumulator->
Add(
"=");
1104 accumulator->
Add(
")");
1105 if (mode == OVERVIEW) {
1106 accumulator->
Add(
"\n");
1109 if (is_optimized()) {
1110 accumulator->
Add(
" {\n// optimized frame\n}\n");
1113 accumulator->
Add(
" {\n");
1116 int stack_locals_count = scope_info->StackLocalCount();
1117 int heap_locals_count = scope_info->ContextLocalCount();
1121 if (stack_locals_count > 0) {
1122 accumulator->
Add(
" // stack-allocated locals\n");
1124 for (
int i = 0; i < stack_locals_count; i++) {
1125 accumulator->
Add(
" var ");
1126 accumulator->
PrintName(scope_info->StackLocalName(i));
1127 accumulator->
Add(
" = ");
1128 if (i < expressions_count) {
1131 accumulator->
Add(
"// no expression found - inconsistent frame?");
1133 accumulator->
Add(
"\n");
1143 if (heap_locals_count > 0) {
1144 accumulator->
Add(
" // heap-allocated locals\n");
1146 for (
int i = 0; i < heap_locals_count; i++) {
1147 accumulator->
Add(
" var ");
1148 accumulator->
PrintName(scope_info->ContextLocalName(i));
1149 accumulator->
Add(
" = ");
1150 if (context !=
NULL) {
1151 if (i < context->length()) {
1155 "// warning: missing context slot - inconsistent frame?");
1158 accumulator->
Add(
"// warning: no context found - inconsistent frame?");
1160 accumulator->
Add(
"\n");
1164 int expressions_start = stack_locals_count;
1165 if (expressions_start < expressions_count) {
1166 accumulator->
Add(
" // expression stack (top to bottom)\n");
1168 for (
int i = expressions_count - 1; i >= expressions_start; i--) {
1174 if (FLAG_max_stack_trace_source_length != 0 && code !=
NULL) {
1176 accumulator->
Add(
"--------- s o u r c e c o d e ---------\n");
1177 shared->
SourceCodePrint(accumulator, FLAG_max_stack_trace_source_length);
1178 accumulator->
Add(
"\n-----------------------------------------\n");
1181 accumulator->
Add(
"}\n\n");
1190 Object*
function = this->
function();
1195 PrintIndex(accumulator, mode, index);
1196 accumulator->
Add(
"arguments adaptor frame: %d->%d", actual, expected);
1197 if (mode == OVERVIEW) {
1198 accumulator->
Add(
"\n");
1201 accumulator->
Add(
" {\n");
1204 if (actual > 0) accumulator->
Add(
" // actual arguments\n");
1205 for (
int i = 0; i < actual; i++) {
1207 if (expected != -1 && i >= expected) {
1208 accumulator->
Add(
" // not passed to callee");
1210 accumulator->
Add(
"\n");
1213 accumulator->
Add(
"}\n\n");
1218 StackHandlerIterator it(
this, top_handler());
1220 StackHandler* handler = it.handler();
1221 ASSERT(handler->is_js_entry());
1222 handler->Iterate(v, LookupCode());
1229 IteratePc(v, pc_address(), LookupCode());
1237 for (StackHandlerIterator it(
this, top_handler()); !it.done(); it.Advance()) {
1238 StackHandler* handler = it.handler();
1242 const Address address = handler->address();
1243 v->VisitPointers(base, reinterpret_cast<Object**>(address));
1246 handler->Iterate(v, LookupCode());
1248 v->VisitPointers(base, limit);
1254 IteratePc(v, pc_address(), LookupCode());
1262 IteratePc(v, pc_address(), LookupCode());
1271 for (
int i = 0; i <= n; i++) {
1272 while (!iterator_.frame()->is_java_script()) iterator_.Advance();
1274 iterator_.Advance();
1284 static Map* GcSafeMapOfCodeSpaceObject(HeapObject*
object) {
1285 MapWord map_word =
object->
map_word();
1286 return map_word.IsForwardingAddress() ?
1287 map_word.ToForwardingAddress()->map() : map_word.ToMap();
1291 static int GcSafeSizeOfCodeSpaceObject(HeapObject*
object) {
1292 return object->SizeFromMap(GcSafeMapOfCodeSpaceObject(
object));
1297 static bool GcSafeCodeContains(HeapObject* code,
Address addr) {
1298 Map* map = GcSafeMapOfCodeSpaceObject(code);
1299 ASSERT(map == code->GetHeap()->code_map());
1300 Address start = code->address();
1301 Address end = code->address() + code->SizeFromMap(map);
1302 return start <= addr && addr < end;
1309 Code* code =
reinterpret_cast<Code*
>(object);
1310 ASSERT(code !=
NULL && GcSafeCodeContains(code, inner_pointer));
1320 if (large_page !=
NULL) {
1334 if (addr == top && addr != limit) {
1340 int obj_size = GcSafeSizeOfCodeSpaceObject(obj);
1341 Address next_addr = addr + obj_size;
1342 if (next_addr > inner_pointer)
return GcSafeCastToCode(obj, inner_pointer);
1350 isolate_->
counters()->pc_to_code()->Increment();
1353 static_cast<uint32_t>(reinterpret_cast<uintptr_t>(inner_pointer)),
1354 v8::internal::kZeroHashSeed);
1355 uint32_t index = hash & (kInnerPointerToCodeCacheSize - 1);
1357 if (entry->inner_pointer == inner_pointer) {
1358 isolate_->
counters()->pc_to_code_cached()->Increment();
1366 entry->safepoint_entry.Reset();
1367 entry->inner_pointer = inner_pointer;
1376 return CompilerIntrinsics::CountSetBits(reglist);
1390 caller_saved_code_data.
reg_code[i++] = r;
1397 return caller_saved_code_data.
reg_code[n];
1401 #define DEFINE_WRAPPER(type, field) \
1402 class field##_Wrapper : public ZoneObject { \
1404 field##_Wrapper(const field& original) : frame_(original) { \
1409 #undef DEFINE_WRAPPER
1412 #define FRAME_TYPE_CASE(type, field) \
1413 case StackFrame::type: { \
1414 field##_Wrapper* wrapper = \
1415 new(zone) field##_Wrapper(*(reinterpret_cast<field*>(frame))); \
1416 return &wrapper->frame_; \
1419 switch (frame->type()) {
1423 #undef FRAME_TYPE_CASE
1429 for (StackFrameIterator it; !it.done(); it.Advance()) {
1430 StackFrame* frame = AllocateFrameCopy(it.frame(), zone);
1431 list.
Add(frame, zone);
virtual int GetNumberOfIncomingArguments() const
static const int kCallerFPOffset
static DeoptimizationOutputData * cast(Object *obj)
Object * function() const
static Object *& Object_at(Address addr)
static void FillState(Address fp, Address sp, State *state)
virtual Address GetCallerStackPointer() const
int GetArgumentsLength() const
void PrintF(const char *format,...)
Code * GcSafeCastToCode(HeapObject *object, Address inner_pointer)
static String * cast(Object *obj)
#define FRAME_TYPE_CASE(type, field)
void SourceCodePrint(StringStream *accumulator, int max_length)
static Type GetStateForFramePointer(Address fp, State *state)
virtual int GetInlineCount()
virtual Code * unchecked_code() const
int NumRegs(RegList reglist)
static MemoryChunk * FromAddress(Address a)
static bool IsArgumentsAdaptorFrame(Address fp)
Address GetExpressionAddress(int n) const
void PrintSecurityTokenIfChanged(Object *function)
Address caller_fp() const
static const int kNumAllocatableRegisters
virtual void Summarize(List< FrameSummary > *frames)
Object * GetExpression(int index) const
virtual void SetCallerFp(Address caller_fp)
const int kBitsPerByteLog2
static Address handler(ThreadLocalTop *thread)
Object *& code_slot() const
int reg_code[kNumJSCallerSaved]
static const int kCallerSPOffset
#define ASSERT(condition)
v8::Handle< v8::Value > Print(const v8::Arguments &args)
const RegList kJSCallerSaved
int ComputeExpressionsCount() const
static Script * cast(Object *obj)
int SourcePosition(Address pc)
virtual Code * unchecked_code() const
void IterateExpressions(ObjectVisitor *v) const
static Context * cast(Object *context)
Vector< StackFrame * > CreateStackMap(Zone *zone)
virtual void ComputeCallerState(State *state) const
int ComputeParametersCount() const
static Code * cast(Object *obj)
const int kAlignmentPaddingPushed
virtual void GetFunctions(List< JSFunction * > *functions)
static Smi * cast(Object *object)
#define STACK_FRAME_TYPE_LIST(V)
void Add(Vector< const char > format, Vector< FmtElm > elms)
int JSCallerSavedCode(int n)
SmartArrayPointer< char > ToCString(AllowNullsFlag allow_nulls, RobustnessFlag robustness_flag, int offset, int length, int *length_output=0)
virtual void Iterate(ObjectVisitor *v) const
Object * receiver() const
virtual Code * unchecked_code() const
HANDLE HANDLE LPSTACKFRAME64 StackFrame
static const int kCallerPCOffset
virtual Address GetCallerStackPointer() const
static void PrintTop(FILE *file, bool print_args, bool print_line_number)
DeoptimizationInputData * GetDeoptimizationData(int *deopt_index)
bool IsConstructor() const
LargePage * FindPage(Address a)
static Address c_entry_fp(ThreadLocalTop *thread)
virtual void Iterate(ObjectVisitor *v) const
StackHandler * handler() const
static Address ComputePCAddress(Address fp)
static const int kCallerFPOffset
Vector< T > ToVector() const
byte * instruction_start()
activate correct semantics for inheriting readonliness enable harmony semantics for typeof enable harmony enable harmony proxies enable all harmony harmony_scoping harmony_proxies harmony_scoping tracks arrays with only smi values automatically unbox arrays of doubles use crankshaft use hydrogen range analysis use hydrogen global value numbering use function inlining maximum number of AST nodes considered for a single inlining loop invariant code motion print statistics for hydrogen trace generated IR for specified phases trace register allocator trace range analysis trace representation types environment for every instruction put a break point before deoptimizing polymorphic inlining perform array bounds checks elimination trace on stack replacement optimize closures functions with arguments object optimize functions containing for in loops profiler considers IC stability primitive functions trigger their own optimization re try self optimization if it failed insert an interrupt check at function exit execution budget before interrupt is triggered call count before self optimization self_optimization count_based_interrupts weighted_back_edges trace_opt emit comments in code disassembly enable use of SSE3 instructions if available enable use of CMOV instruction if available enable use of SAHF instruction if enable use of VFP3 instructions if available this implies enabling ARMv7 enable use of ARMv7 instructions if enable use of MIPS FPU instructions if NULL
static Address & Address_at(Address addr)
uintptr_t(* ReturnAddressLocationResolver)(uintptr_t return_addr_location)
static int32_t & int32_at(Address addr)
static const int kExpressionsOffset
static unsigned decode(uint32_t value)
static const int kDynamicAlignmentStateOffset
virtual void Print(StringStream *accumulator, PrintMode mode, int index) const
const int kNumJSCallerSaved
SafepointEntry GetSafepointEntry(Address pc)
int GetScriptLineNumberSafe(Handle< Script > script, int code_pos)
virtual void Summarize(List< FrameSummary > *frames)
static int GetOutputInfo(DeoptimizationOutputData *data, unsigned node_id, SharedFunctionInfo *shared)
JavaScriptFrameIteratorTemp< SafeStackFrameIterator > SafeJavaScriptFrameIterator
virtual Code * unchecked_code() const
static JavaScriptFrame * cast(StackFrame *frame)
LargeObjectSpace * lo_space()
virtual void Iterate(ObjectVisitor *v) const
static ScopeInfo * Empty()
virtual void Iterate(ObjectVisitor *v) const
SafeStackTraceFrameIterator(Isolate *isolate, Address fp, Address sp, Address low_bound, Address high_bound)
virtual void SetCallerFp(Address caller_fp)
static const int kCallerSPDisplacement
virtual Code * unchecked_code() const
virtual int GetNumberOfIncomingArguments() const
InnerPointerToCodeCache * inner_pointer_to_code_cache()
static Address ComputeStackPointer(Address fp)
void SetUpJSCallerSavedCodeData()
uint32_t ComputeIntegerHash(uint32_t key, uint32_t seed)
JavaScriptFrameIteratorTemp< StackFrameIterator > JavaScriptFrameIterator
static const int kCallerFPOffset
InnerPointerToCodeCacheEntry * GetCacheEntry(Address inner_pointer)
virtual void GetFunctions(List< JSFunction * > *functions)
const int kNumSafepointRegisters
void PrintName(Object *o)
static const int kContextOffset
static const int kFunctionOffset
virtual void Iterate(ObjectVisitor *v) const
static const int kHeaderSize
virtual Address GetCallerStackPointer() const
activate correct semantics for inheriting readonliness enable harmony semantics for typeof enable harmony enable harmony proxies enable all harmony harmony_scoping harmony_proxies harmony_scoping tracks arrays with only smi values automatically unbox arrays of doubles use crankshaft use hydrogen range analysis use hydrogen global value numbering use function inlining maximum number of AST nodes considered for a single inlining loop invariant code motion print statistics for hydrogen trace generated IR for specified phases trace register allocator trace range analysis trace representation types environment for every instruction put a break point before deoptimizing polymorphic inlining perform array bounds checks elimination trace on stack replacement optimize closures functions with arguments object optimize functions containing for in loops profiler considers IC stability primitive functions trigger their own optimization re try self optimization if it failed insert an interrupt check at function exit execution budget before interrupt is triggered call count before self optimization self_optimization count_based_interrupts weighted_back_edges trace_opt emit comments in code disassembly enable use of SSE3 instructions if available enable use of CMOV instruction if available enable use of SAHF instruction if enable use of VFP3 instructions if available this implies enabling ARMv7 enable use of ARMv7 instructions if enable use of MIPS FPU instructions if NULL
void PrintFunction(Object *function, Object *receiver, Code **code)
bool IsExpressionInsideHandler(int n) const
static HeapObject * FromAddress(Address address)
virtual void Print(StringStream *accumulator, PrintMode mode, int index) const
static bool IsConstructFrame(Address fp)
JSCallerSavedCodeData caller_saved_code_data
void Add(const T &element, AllocationPolicy allocator=AllocationPolicy())
SafepointEntry safepoint_entry
StackHandlerIterator(const StackFrame *frame, StackHandler *handler)
static const int kCodeOffset
#define DEFINE_WRAPPER(type, field)
#define INITIALIZE_SINGLETON(type, field)
static const int kMarkerOffset
Code * GcSafeFindCodeForInnerPointer(Address inner_pointer)
virtual void SetCallerFp(Address caller_fp)
Object * GetParameter(int index) const
bool has_adapted_arguments() const
Address StartFor(Address addr)
static const int kCodeOffset
virtual Address GetCallerStackPointer() const
virtual Code * unchecked_code() const
static JSFunction * cast(Object *obj)