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

Side by Side Diff: src/heap/heap-inl.h

Issue 2066993004: [snapshot] serialize embedder-provided external references. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: address comment Created 4 years, 6 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/heap/heap.cc ('k') | src/isolate.h » ('j') | 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 #ifndef V8_HEAP_HEAP_INL_H_ 5 #ifndef V8_HEAP_HEAP_INL_H_
6 #define V8_HEAP_HEAP_INL_H_ 6 #define V8_HEAP_HEAP_INL_H_
7 7
8 #include <cmath> 8 #include <cmath>
9 9
10 #include "src/base/platform/platform.h" 10 #include "src/base/platform/platform.h"
(...skipping 708 matching lines...) Expand 10 before | Expand all | Expand 10 after
719 void Heap::SetSetterStubDeoptPCOffset(int pc_offset) { 719 void Heap::SetSetterStubDeoptPCOffset(int pc_offset) {
720 DCHECK(setter_stub_deopt_pc_offset() == Smi::FromInt(0)); 720 DCHECK(setter_stub_deopt_pc_offset() == Smi::FromInt(0));
721 set_setter_stub_deopt_pc_offset(Smi::FromInt(pc_offset)); 721 set_setter_stub_deopt_pc_offset(Smi::FromInt(pc_offset));
722 } 722 }
723 723
724 void Heap::SetInterpreterEntryReturnPCOffset(int pc_offset) { 724 void Heap::SetInterpreterEntryReturnPCOffset(int pc_offset) {
725 DCHECK(interpreter_entry_return_pc_offset() == Smi::FromInt(0)); 725 DCHECK(interpreter_entry_return_pc_offset() == Smi::FromInt(0));
726 set_interpreter_entry_return_pc_offset(Smi::FromInt(pc_offset)); 726 set_interpreter_entry_return_pc_offset(Smi::FromInt(pc_offset));
727 } 727 }
728 728
729 int Heap::GetNextTemplateSerialNumber() {
730 int next_serial_number = next_template_serial_number()->value() + 1;
731 set_next_template_serial_number(Smi::FromInt(next_serial_number));
732 return next_serial_number;
733 }
734
729 AlwaysAllocateScope::AlwaysAllocateScope(Isolate* isolate) 735 AlwaysAllocateScope::AlwaysAllocateScope(Isolate* isolate)
730 : heap_(isolate->heap()) { 736 : heap_(isolate->heap()) {
731 heap_->always_allocate_scope_count_.Increment(1); 737 heap_->always_allocate_scope_count_.Increment(1);
732 } 738 }
733 739
734 740
735 AlwaysAllocateScope::~AlwaysAllocateScope() { 741 AlwaysAllocateScope::~AlwaysAllocateScope() {
736 heap_->always_allocate_scope_count_.Increment(-1); 742 heap_->always_allocate_scope_count_.Increment(-1);
737 } 743 }
738 744
(...skipping 11 matching lines...) Expand all
750 756
751 void VerifySmisVisitor::VisitPointers(Object** start, Object** end) { 757 void VerifySmisVisitor::VisitPointers(Object** start, Object** end) {
752 for (Object** current = start; current < end; current++) { 758 for (Object** current = start; current < end; current++) {
753 CHECK((*current)->IsSmi()); 759 CHECK((*current)->IsSmi());
754 } 760 }
755 } 761 }
756 } // namespace internal 762 } // namespace internal
757 } // namespace v8 763 } // namespace v8
758 764
759 #endif // V8_HEAP_HEAP_INL_H_ 765 #endif // V8_HEAP_HEAP_INL_H_
OLDNEW
« no previous file with comments | « src/heap/heap.cc ('k') | src/isolate.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698