| OLD | NEW |
| 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 VM_DART_ENTRY_H_ | 5 #ifndef VM_DART_ENTRY_H_ |
| 6 #define VM_DART_ENTRY_H_ | 6 #define VM_DART_ENTRY_H_ |
| 7 | 7 |
| 8 #include "vm/allocation.h" | 8 #include "vm/allocation.h" |
| 9 #include "vm/growable_array.h" | 9 #include "vm/growable_array.h" |
| 10 | 10 |
| (...skipping 73 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 84 return kFirstNamedEntryIndex + (kNamedEntrySize * count) + 1; | 84 return kFirstNamedEntryIndex + (kNamedEntrySize * count) + 1; |
| 85 } | 85 } |
| 86 | 86 |
| 87 static RawArray* NewNonCached(intptr_t count, bool canonicalize = true); | 87 static RawArray* NewNonCached(intptr_t count, bool canonicalize = true); |
| 88 | 88 |
| 89 const Array& array_; | 89 const Array& array_; |
| 90 | 90 |
| 91 // A cache of VM heap allocated arguments descriptors. | 91 // A cache of VM heap allocated arguments descriptors. |
| 92 static RawArray* cached_args_descriptors_[kCachedDescriptorCount]; | 92 static RawArray* cached_args_descriptors_[kCachedDescriptorCount]; |
| 93 | 93 |
| 94 friend class FullSnapshotWriter; |
| 95 friend class VmIsolateSnapshotReader; |
| 94 DISALLOW_COPY_AND_ASSIGN(ArgumentsDescriptor); | 96 DISALLOW_COPY_AND_ASSIGN(ArgumentsDescriptor); |
| 95 }; | 97 }; |
| 96 | 98 |
| 97 | 99 |
| 98 // DartEntry abstracts functionality needed to resolve dart functions | 100 // DartEntry abstracts functionality needed to resolve dart functions |
| 99 // and invoke them from C++. | 101 // and invoke them from C++. |
| 100 class DartEntry : public AllStatic { | 102 class DartEntry : public AllStatic { |
| 101 public: | 103 public: |
| 102 // On success, returns a RawInstance. On failure, a RawError. | 104 // On success, returns a RawInstance. On failure, a RawError. |
| 103 typedef RawObject* (*invokestub)(uword entry_point, | 105 typedef RawObject* (*invokestub)(uword entry_point, |
| (...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 170 // | 172 // |
| 171 // Returns null on success, a RawError on failure. | 173 // Returns null on success, a RawError on failure. |
| 172 static RawObject* MapSetAt(const Instance& map, | 174 static RawObject* MapSetAt(const Instance& map, |
| 173 const Instance& key, | 175 const Instance& key, |
| 174 const Instance& value); | 176 const Instance& value); |
| 175 }; | 177 }; |
| 176 | 178 |
| 177 } // namespace dart | 179 } // namespace dart |
| 178 | 180 |
| 179 #endif // VM_DART_ENTRY_H_ | 181 #endif // VM_DART_ENTRY_H_ |
| OLD | NEW |