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

Side by Side Diff: src/snapshot/code-serializer.h

Issue 2051043003: [snapshot] pass arguments as pointers, not references. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@snapshotcreator
Patch Set: rebase 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/api.cc ('k') | src/snapshot/code-serializer.cc » ('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 #ifndef V8_SNAPSHOT_CODE_SERIALIZER_H_ 5 #ifndef V8_SNAPSHOT_CODE_SERIALIZER_H_
6 #define V8_SNAPSHOT_CODE_SERIALIZER_H_ 6 #define V8_SNAPSHOT_CODE_SERIALIZER_H_
7 7
8 #include "src/parsing/preparse-data.h" 8 #include "src/parsing/preparse-data.h"
9 #include "src/snapshot/serializer.h" 9 #include "src/snapshot/serializer.h"
10 10
(...skipping 42 matching lines...) Expand 10 before | Expand all | Expand 10 after
53 53
54 // Wrapper around ScriptData to provide code-serializer-specific functionality. 54 // Wrapper around ScriptData to provide code-serializer-specific functionality.
55 class SerializedCodeData : public SerializedData { 55 class SerializedCodeData : public SerializedData {
56 public: 56 public:
57 // Used when consuming. 57 // Used when consuming.
58 static SerializedCodeData* FromCachedData(Isolate* isolate, 58 static SerializedCodeData* FromCachedData(Isolate* isolate,
59 ScriptData* cached_data, 59 ScriptData* cached_data,
60 String* source); 60 String* source);
61 61
62 // Used when producing. 62 // Used when producing.
63 SerializedCodeData(const List<byte>& payload, const CodeSerializer& cs); 63 SerializedCodeData(const List<byte>* payload, const CodeSerializer* cs);
64 64
65 // Return ScriptData object and relinquish ownership over it to the caller. 65 // Return ScriptData object and relinquish ownership over it to the caller.
66 ScriptData* GetScriptData(); 66 ScriptData* GetScriptData();
67 67
68 Vector<const Reservation> Reservations() const; 68 Vector<const Reservation> Reservations() const;
69 Vector<const byte> Payload() const; 69 Vector<const byte> Payload() const;
70 70
71 Vector<const uint32_t> CodeStubKeys() const; 71 Vector<const uint32_t> CodeStubKeys() const;
72 72
73 private: 73 private:
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
110 static const int kPayloadLengthOffset = kNumCodeStubKeysOffset + kInt32Size; 110 static const int kPayloadLengthOffset = kNumCodeStubKeysOffset + kInt32Size;
111 static const int kChecksum1Offset = kPayloadLengthOffset + kInt32Size; 111 static const int kChecksum1Offset = kPayloadLengthOffset + kInt32Size;
112 static const int kChecksum2Offset = kChecksum1Offset + kInt32Size; 112 static const int kChecksum2Offset = kChecksum1Offset + kInt32Size;
113 static const int kHeaderSize = kChecksum2Offset + kInt32Size; 113 static const int kHeaderSize = kChecksum2Offset + kInt32Size;
114 }; 114 };
115 115
116 } // namespace internal 116 } // namespace internal
117 } // namespace v8 117 } // namespace v8
118 118
119 #endif // V8_SNAPSHOT_CODE_SERIALIZER_H_ 119 #endif // V8_SNAPSHOT_CODE_SERIALIZER_H_
OLDNEW
« no previous file with comments | « src/api.cc ('k') | src/snapshot/code-serializer.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698