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

Side by Side Diff: src/external-reference-table.cc

Issue 2736923002: SnapshotCreator: start from existing snapshot if we have one (Closed)
Patch Set: addressed comments Created 3 years, 9 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/external-reference-table.h ('k') | src/snapshot/code-serializer.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 2016 the V8 project authors. All rights reserved. 1 // Copyright 2016 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/external-reference-table.h" 5 #include "src/external-reference-table.h"
6 6
7 #include "src/accessors.h" 7 #include "src/accessors.h"
8 #include "src/assembler.h" 8 #include "src/assembler.h"
9 #include "src/builtins/builtins.h" 9 #include "src/builtins/builtins.h"
10 #include "src/counters.h" 10 #include "src/counters.h"
(...skipping 28 matching lines...) Expand all
39 ExternalReferenceTable::ExternalReferenceTable(Isolate* isolate) { 39 ExternalReferenceTable::ExternalReferenceTable(Isolate* isolate) {
40 // nullptr is preserved through serialization/deserialization. 40 // nullptr is preserved through serialization/deserialization.
41 Add(nullptr, "nullptr"); 41 Add(nullptr, "nullptr");
42 AddReferences(isolate); 42 AddReferences(isolate);
43 AddBuiltins(isolate); 43 AddBuiltins(isolate);
44 AddRuntimeFunctions(isolate); 44 AddRuntimeFunctions(isolate);
45 AddIsolateAddresses(isolate); 45 AddIsolateAddresses(isolate);
46 AddAccessors(isolate); 46 AddAccessors(isolate);
47 AddStubCache(isolate); 47 AddStubCache(isolate);
48 AddDeoptEntries(isolate); 48 AddDeoptEntries(isolate);
49 // API references must be added last.
49 AddApiReferences(isolate); 50 AddApiReferences(isolate);
50 } 51 }
51 52
52 #ifdef DEBUG 53 #ifdef DEBUG
53 void ExternalReferenceTable::ResetCount() { 54 void ExternalReferenceTable::ResetCount() {
54 for (ExternalReferenceEntry& entry : refs_) entry.count = 0; 55 for (ExternalReferenceEntry& entry : refs_) entry.count = 0;
55 } 56 }
56 57
57 void ExternalReferenceTable::PrintCount() { 58 void ExternalReferenceTable::PrintCount() {
58 for (int i = 0; i < refs_.length(); i++) { 59 for (int i = 0; i < refs_.length(); i++) {
(...skipping 393 matching lines...) Expand 10 before | Expand all | Expand 10 after
452 while (*api_external_references != 0) { 453 while (*api_external_references != 0) {
453 Address address = reinterpret_cast<Address>(*api_external_references); 454 Address address = reinterpret_cast<Address>(*api_external_references);
454 Add(address, ResolveSymbol(address)); 455 Add(address, ResolveSymbol(address));
455 api_external_references++; 456 api_external_references++;
456 } 457 }
457 } 458 }
458 } 459 }
459 460
460 } // namespace internal 461 } // namespace internal
461 } // namespace v8 462 } // namespace v8
OLDNEW
« no previous file with comments | « src/external-reference-table.h ('k') | src/snapshot/code-serializer.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698