Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1)

Side by Side Diff: src/frames.cc

Issue 1319423003: Make frames.h usable without handles-inl.h header. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 3 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
« no previous file with comments | « src/frames.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2012 the V8 project authors. All rights reserved. 1 // Copyright 2012 the V8 project authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #include "src/frames.h" 5 #include "src/frames.h"
6 6
7 #include <sstream> 7 #include <sstream>
8 8
9 #include "src/ast.h" 9 #include "src/ast.h"
10 #include "src/base/bits.h" 10 #include "src/base/bits.h"
(...skipping 861 matching lines...) Expand 10 before | Expand all | Expand 10 after
872 void JavaScriptFrame::RestoreOperandStack(FixedArray* store) { 872 void JavaScriptFrame::RestoreOperandStack(FixedArray* store) {
873 int operands_count = store->length(); 873 int operands_count = store->length();
874 DCHECK_LE(operands_count, ComputeOperandsCount()); 874 DCHECK_LE(operands_count, ComputeOperandsCount());
875 for (int i = 0; i < operands_count; i++) { 875 for (int i = 0; i < operands_count; i++) {
876 DCHECK_EQ(GetOperand(i), isolate()->heap()->the_hole_value()); 876 DCHECK_EQ(GetOperand(i), isolate()->heap()->the_hole_value());
877 Memory::Object_at(GetOperandSlot(i)) = store->get(i); 877 Memory::Object_at(GetOperandSlot(i)) = store->get(i);
878 } 878 }
879 } 879 }
880 880
881 881
882 FrameSummary::FrameSummary(Object* receiver, JSFunction* function, Code* code,
883 int offset, bool is_constructor)
884 : receiver_(receiver, function->GetIsolate()),
885 function_(function),
886 code_(code),
887 offset_(offset),
888 is_constructor_(is_constructor) {}
889
890
882 void FrameSummary::Print() { 891 void FrameSummary::Print() {
883 PrintF("receiver: "); 892 PrintF("receiver: ");
884 receiver_->ShortPrint(); 893 receiver_->ShortPrint();
885 PrintF("\nfunction: "); 894 PrintF("\nfunction: ");
886 function_->shared()->DebugName()->ShortPrint(); 895 function_->shared()->DebugName()->ShortPrint();
887 PrintF("\ncode: "); 896 PrintF("\ncode: ");
888 code_->ShortPrint(); 897 code_->ShortPrint();
889 if (code_->kind() == Code::FUNCTION) PrintF(" NON-OPT"); 898 if (code_->kind() == Code::FUNCTION) PrintF(" NON-OPT");
890 if (code_->kind() == Code::OPTIMIZED_FUNCTION) PrintF(" OPT"); 899 if (code_->kind() == Code::OPTIMIZED_FUNCTION) PrintF(" OPT");
891 PrintF("\npc: %d\n", offset_); 900 PrintF("\npc: %d\n", offset_);
(...skipping 655 matching lines...) Expand 10 before | Expand all | Expand 10 after
1547 for (StackFrameIterator it(isolate); !it.done(); it.Advance()) { 1556 for (StackFrameIterator it(isolate); !it.done(); it.Advance()) {
1548 StackFrame* frame = AllocateFrameCopy(it.frame(), zone); 1557 StackFrame* frame = AllocateFrameCopy(it.frame(), zone);
1549 list.Add(frame, zone); 1558 list.Add(frame, zone);
1550 } 1559 }
1551 return list.ToVector(); 1560 return list.ToVector();
1552 } 1561 }
1553 1562
1554 1563
1555 } // namespace internal 1564 } // namespace internal
1556 } // namespace v8 1565 } // namespace v8
OLDNEW
« no previous file with comments | « src/frames.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698