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

Unified Diff: src/snapshot.h

Issue 6901090: Add support for startup data (snapshot) compression. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 9 years, 8 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 side-by-side diff with in-line comments
Download patch
Index: src/snapshot.h
diff --git a/src/snapshot.h b/src/snapshot.h
index bedd186e507118f568b7a534669fc81cd0046203..0a07046a504f2237b4368e51cf448940a528d2f0 100644
--- a/src/snapshot.h
+++ b/src/snapshot.h
@@ -50,9 +50,25 @@ STATIC_CLASS Snapshot {
// successfully.
static bool WriteToFile(const char* snapshot_file);
+ static const byte* data() { return data_; }
+ static int size() { return size_; }
+ static int decompressed_size() { return decompressed_size_; }
+ static void set_decompressed_data(const byte* decompressed_data) {
+ decompressed_data_ = decompressed_data;
+ }
+ static const byte* context_data() { return context_data_; }
+ static int context_size() { return context_size_; }
+ static int context_decompressed_size() { return context_decompressed_size_; }
+ static void set_context_decompressed_data(
+ const byte* context_decompressed_data) {
+ context_decompressed_data_ = context_decompressed_data;
+ }
+
private:
static const byte data_[];
+ static const byte* decompressed_data_;
static const byte context_data_[];
+ static const byte* context_decompressed_data_;
static const int new_space_used_;
static const int pointer_space_used_;
static const int data_space_used_;
@@ -61,7 +77,9 @@ STATIC_CLASS Snapshot {
static const int cell_space_used_;
static const int large_space_used_;
static const int size_;
+ static const int decompressed_size_;
static const int context_size_;
+ static const int context_decompressed_size_;
static bool Deserialize(const byte* content, int len);

Powered by Google App Engine
This is Rietveld 408576698