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

Unified Diff: runtime/vm/dart_api_message.h

Issue 14065006: Add support for typed data views on native threads (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Addressed review commetns Created 7 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
« no previous file with comments | « no previous file | runtime/vm/dart_api_message.cc » ('j') | runtime/vm/dart_api_message.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/dart_api_message.h
diff --git a/runtime/vm/dart_api_message.h b/runtime/vm/dart_api_message.h
index 84d44a8cf35b10df13be9350e1156eec2f9a11b7..d215ab01f2a1884d65399249baded3e3e9f52693 100644
--- a/runtime/vm/dart_api_message.h
+++ b/runtime/vm/dart_api_message.h
@@ -14,13 +14,26 @@ namespace dart {
// data. These are objects that we need to process in order to
// generate the Dart_CObject graph but that we don't want to expose in
// that graph.
-// TODO(sjesse): Remove this when message serialization format is
-// updated.
struct Dart_CObject_Internal : public Dart_CObject {
enum Type {
kTypeArguments = Dart_CObject::kNumberOfTypes,
kDynamicType,
+ kClass,
+ kView,
+ kUninitialized,
};
+ struct Dart_CObject_Internal* cls;
+ union {
+ struct {
+ struct _Dart_CObject* library_url;
+ struct _Dart_CObject* class_name;
+ } as_class;
+ struct {
+ struct _Dart_CObject* buffer;
+ int offset_in_bytes;
+ int length;
+ } as_view;
+ } internal;
};
@@ -79,6 +92,11 @@ class ApiMessageReader : public BaseReader {
Dart_CObject* AllocateDartCObjectUint8Array(intptr_t length);
// Allocates a C array of Dart_CObject objects.
Dart_CObject* AllocateDartCObjectArray(intptr_t length);
+ // Allocates a Dart_CObject_Internal object with the specified type.
+ Dart_CObject_Internal* AllocateDartCObjectInternal(
+ Dart_CObject_Internal::Type type);
+ // Allocates a Dart_CObject_Internal object for a class object.
+ Dart_CObject_Internal* AllocateDartCObjectClass();
// Allocates a backwards reference node.
BackRefNode* AllocateBackRefNode(Dart_CObject* ref, DeserializeState state);
« no previous file with comments | « no previous file | runtime/vm/dart_api_message.cc » ('j') | runtime/vm/dart_api_message.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698