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

Unified Diff: runtime/include/dart_api.h

Issue 2411823003: VM support for running Kernel binaries. (Closed)
Patch Set: Address comments Created 4 years, 2 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
« no previous file with comments | « runtime/bin/loader.cc ('k') | runtime/vm/compiler.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/include/dart_api.h
diff --git a/runtime/include/dart_api.h b/runtime/include/dart_api.h
index c9c0d1a926e4168cc5ed4f11adbb7496f80109e2..f25ea7d412a5e4a1ca20b3a1f9b51599ef899cfc 100755
--- a/runtime/include/dart_api.h
+++ b/runtime/include/dart_api.h
@@ -2798,7 +2798,7 @@ DART_EXPORT Dart_Handle Dart_LoadScript(Dart_Handle url,
* Loads the root script for current isolate from a snapshot.
*
* \param buffer A buffer which contains a snapshot of the script.
- * \param length Length of the passed in buffer.
+ * \param buffer_len Length of the passed in buffer.
*
* \return If no error occurs, the Library object corresponding to the root
* script is returned. Otherwise an error handle is returned.
@@ -2807,6 +2807,18 @@ DART_EXPORT Dart_Handle Dart_LoadScriptFromSnapshot(const uint8_t* buffer,
intptr_t buffer_len);
/**
+ * Loads a dart application which was compiled to a Kernel binary.
+ *
+ * \param buffer A buffer which contains a Kernel binary.
+ * \param buffer_len Length of the passed in buffer.
+ *
+ * \return If no error occurs, the Library object corresponding to the root
+ * script is returned. Otherwise an error handle is returned.
+ */
+DART_EXPORT Dart_Handle Dart_LoadKernel(const uint8_t* buffer,
+ intptr_t buffer_len);
+
+/**
* Gets the library for the root script for the current isolate.
*
* If the root script has not yet been set for the current isolate,
« no previous file with comments | « runtime/bin/loader.cc ('k') | runtime/vm/compiler.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698