Index: gin/public/isolate_holder.h |
diff --git a/gin/public/isolate_holder.h b/gin/public/isolate_holder.h |
index 7968b1df0ba3edd8a9978105b927a494ec4cb5ef..cce92b2b29623e935f51a481348d15d4d871adeb 100644 |
--- a/gin/public/isolate_holder.h |
+++ b/gin/public/isolate_holder.h |
@@ -6,6 +6,7 @@ |
#define GIN_PUBLIC_ISOLATE_HOLDER_H_ |
#include "base/basictypes.h" |
+#include "base/files/file.h" |
#include "base/memory/scoped_ptr.h" |
#include "gin/gin_export.h" |
#include "v8/include/v8.h" |
@@ -56,13 +57,26 @@ class GIN_EXPORT IsolateHolder { |
static const char kNativesFileName[]; |
static const char kSnapshotFileName[]; |
+ // Load the V8 snapshot data from the given file descriptors. If offset and |
+ // size are zero it will load the whole file, otherwise it will map and load |
+ // the region of the file specified by offset and size. Returns true on |
+ // success. |
James Cook
2015/03/19 15:48:37
Thanks for documenting the other methods!
|
static bool LoadV8SnapshotFd(int natives_fd, |
int64 natives_offset, |
int64 natives_size, |
int snapshot_fd, |
int64 snapshot_offset, |
int64 snapshot_size); |
+ |
+ // Load the V8 snapshot data from the snapshot files. Returns true on success. |
static bool LoadV8Snapshot(); |
+ |
+ // Opens the V8 snapshot data files and returns open file descriptors to these |
+ // files in |natives_fd_out| and |snapshot_fd_out|, which can be passed to |
+ // child processes. |
+ static bool OpenV8FilesForChildProcesses(base::PlatformFile* natives_fd_out, |
+ base::PlatformFile* snapshot_fd_out); |
+ |
#endif // V8_USE_EXTERNAL_STARTUP_DATA |
static void GetV8ExternalSnapshotData(const char** natives_data_out, |
int* natives_size_out, |