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

Side by Side Diff: include/dart_api.h

Issue 8970004: Changes to create an application snapshot which can be layered on top (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/runtime/
Patch Set: '' Created 9 years 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 | Annotate | Revision Log
« no previous file with comments | « bin/main.cc ('k') | tests/vm/vm.status » ('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 (c) 2011, the Dart project authors. Please see the AUTHORS file 1 // Copyright (c) 2011, the Dart project authors. Please see the AUTHORS file
2 // for details. All rights reserved. Use of this source code is governed by a 2 // for details. All rights reserved. Use of this source code is governed by a
3 // BSD-style license that can be found in the LICENSE file. 3 // BSD-style license that can be found in the LICENSE file.
4 4
5 #ifndef INCLUDE_DART_API_H_ 5 #ifndef INCLUDE_DART_API_H_
6 #define INCLUDE_DART_API_H_ 6 #define INCLUDE_DART_API_H_
7 7
8 /** \mainpage Dart Embedding API Reference 8 /** \mainpage Dart Embedding API Reference
9 * 9 *
10 * Dart is a class-based programming language for creating structured 10 * Dart is a class-based programming language for creating structured
(...skipping 365 matching lines...) Expand 10 before | Expand all | Expand 10 after
376 * snapshot. This buffer is scope allocated and is only valid 376 * snapshot. This buffer is scope allocated and is only valid
377 * until the next call to Dart_ExitScope. 377 * until the next call to Dart_ExitScope.
378 * \param size Returns the size of the buffer. 378 * \param size Returns the size of the buffer.
379 * 379 *
380 * \return A valid handle if no error occurs during the operation. 380 * \return A valid handle if no error occurs during the operation.
381 */ 381 */
382 DART_EXPORT Dart_Handle Dart_CreateSnapshot(uint8_t** buffer, 382 DART_EXPORT Dart_Handle Dart_CreateSnapshot(uint8_t** buffer,
383 intptr_t* size); 383 intptr_t* size);
384 384
385 /** 385 /**
386 * Creates a snapshot of the specified application script. 386 * Creates a snapshot of the application script loaded in the isolate.
387 * 387 *
388 * A script snapshot can be used for implementing fast startup of applications 388 * A script snapshot can be used for implementing fast startup of applications
389 * (skips the script tokenizing and parsing process). A Snapshot of the script 389 * (skips the script tokenizing and parsing process). A Snapshot of the script
390 * can only be created before any dart code has executed. 390 * can only be created before any dart code has executed.
391 * 391 *
392 * Requires there to be a current isolate. 392 * Requires there to be a current isolate which already has loaded script.
393 * 393 *
394 * \param library An application script for which a snapshot is to be
395 * created.
396 * \param buffer Returns a pointer to a buffer containing 394 * \param buffer Returns a pointer to a buffer containing
397 * the snapshot. This buffer is scope allocated and is only valid 395 * the snapshot. This buffer is scope allocated and is only valid
398 * until the next call to Dart_ExitScope. 396 * until the next call to Dart_ExitScope.
399 * \param size Returns the size of the buffer. 397 * \param size Returns the size of the buffer.
400 * 398 *
401 * \return A valid handle if no error occurs during the operation. 399 * \return A valid handle if no error occurs during the operation.
402 */ 400 */
403 DART_EXPORT Dart_Handle Dart_CreateScriptSnapshot(Dart_Handle library, 401 DART_EXPORT Dart_Handle Dart_CreateScriptSnapshot(uint8_t** buffer,
404 uint8_t** buffer,
405 intptr_t* size); 402 intptr_t* size);
406 403
407 404
408 /** 405 /**
409 * Schedules an interrupt for the specified isolate. 406 * Schedules an interrupt for the specified isolate.
410 * 407 *
411 * Note that the interrupt does not occur immediately. In fact, if 408 * Note that the interrupt does not occur immediately. In fact, if
412 * 'isolate' does not execute any further Dart code, then the 409 * 'isolate' does not execute any further Dart code, then the
413 * interrupt will not occur at all. If and when the isolate is 410 * interrupt will not occur at all. If and when the isolate is
414 * interrupted, the isolate interrupt callback will be invoked with 411 * interrupted, the isolate interrupt callback will be invoked with
(...skipping 970 matching lines...) Expand 10 before | Expand all | Expand 10 after
1385 1382
1386 // --- Profiling support ---- 1383 // --- Profiling support ----
1387 1384
1388 // External pprof support for gathering and dumping symbolic 1385 // External pprof support for gathering and dumping symbolic
1389 // information that can be used for better profile reports for 1386 // information that can be used for better profile reports for
1390 // dynamically generated code. 1387 // dynamically generated code.
1391 DART_EXPORT void Dart_InitPprofSupport(); 1388 DART_EXPORT void Dart_InitPprofSupport();
1392 DART_EXPORT void Dart_GetPprofSymbolInfo(void** buffer, int* buffer_size); 1389 DART_EXPORT void Dart_GetPprofSymbolInfo(void** buffer, int* buffer_size);
1393 1390
1394 #endif // INCLUDE_DART_API_H_ 1391 #endif // INCLUDE_DART_API_H_
OLDNEW
« no previous file with comments | « bin/main.cc ('k') | tests/vm/vm.status » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698