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

Side by Side Diff: runtime/include/dart_api.h

Issue 1041523002: Refactor Thread lifecycle interface, add Thread::Enter/ExitIsolate. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 5 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 unified diff | Download patch | Annotate | Revision Log
« no previous file with comments | « no previous file | runtime/lib/isolate.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 /* 1 /*
2 * Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file 2 * Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file
3 * for details. All rights reserved. Use of this source code is governed by a 3 * for details. All rights reserved. Use of this source code is governed by a
4 * BSD-style license that can be found in the LICENSE file. 4 * BSD-style license that can be found in the LICENSE file.
5 */ 5 */
6 6
7 #ifndef INCLUDE_DART_API_H_ 7 #ifndef INCLUDE_DART_API_H_
8 #define INCLUDE_DART_API_H_ 8 #define INCLUDE_DART_API_H_
9 9
10 /** \mainpage Dart Embedding API Reference 10 /** \mainpage Dart Embedding API Reference
(...skipping 931 matching lines...) Expand 10 before | Expand all | Expand 10 after
942 * 942 *
943 * This name is unique to each isolate and should only be used to make 943 * This name is unique to each isolate and should only be used to make
944 * debugging messages more comprehensible. 944 * debugging messages more comprehensible.
945 */ 945 */
946 DART_EXPORT Dart_Handle Dart_DebugName(); 946 DART_EXPORT Dart_Handle Dart_DebugName();
947 947
948 /** 948 /**
949 * Enters an isolate. After calling this function, 949 * Enters an isolate. After calling this function,
950 * the current isolate will be set to the provided isolate. 950 * the current isolate will be set to the provided isolate.
951 * 951 *
952 * Requires there to be no current isolate. 952 * Requires there to be no current isolate. Multiple threads may not be in
953 * the same isolate at once.
953 */ 954 */
954 DART_EXPORT void Dart_EnterIsolate(Dart_Isolate isolate); 955 DART_EXPORT void Dart_EnterIsolate(Dart_Isolate isolate);
955 /* TODO(turnidge): Describe what happens if two threads attempt to
956 * enter the same isolate simultaneously. Check for this in the code.
957 * Describe whether isolates are allowed to migrate. */
958 956
959 /** 957 /**
960 * Notifies the VM that the current isolate is about to make a blocking call. 958 * Notifies the VM that the current isolate is about to make a blocking call.
961 */ 959 */
962 DART_EXPORT void Dart_IsolateBlocked(); 960 DART_EXPORT void Dart_IsolateBlocked();
963 961
964 /** 962 /**
965 * Notifies the VM that the current isolate is no longer blocked. 963 * Notifies the VM that the current isolate is no longer blocked.
966 */ 964 */
967 DART_EXPORT void Dart_IsolateUnblocked(); 965 DART_EXPORT void Dart_IsolateUnblocked();
(...skipping 1856 matching lines...) Expand 10 before | Expand all | Expand 10 after
2824 * NOTE: If multiple callbacks with the same name are registered, only the 2822 * NOTE: If multiple callbacks with the same name are registered, only the
2825 * last callback registered will be remembered. 2823 * last callback registered will be remembered.
2826 */ 2824 */
2827 DART_EXPORT void Dart_RegisterRootServiceRequestCallback( 2825 DART_EXPORT void Dart_RegisterRootServiceRequestCallback(
2828 const char* name, 2826 const char* name,
2829 Dart_ServiceRequestCallback callback, 2827 Dart_ServiceRequestCallback callback,
2830 void* user_data); 2828 void* user_data);
2831 2829
2832 2830
2833 #endif /* INCLUDE_DART_API_H_ */ /* NOLINT */ 2831 #endif /* INCLUDE_DART_API_H_ */ /* NOLINT */
OLDNEW
« no previous file with comments | « no previous file | runtime/lib/isolate.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698