| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, 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_OBJECT_H_ | 5 #ifndef VM_OBJECT_H_ |
| 6 #define VM_OBJECT_H_ | 6 #define VM_OBJECT_H_ |
| 7 | 7 |
| 8 #include "include/dart_api.h" | 8 #include "include/dart_api.h" |
| 9 #include "platform/assert.h" | 9 #include "platform/assert.h" |
| 10 #include "platform/utils.h" | 10 #include "platform/utils.h" |
| (...skipping 2971 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2982 // Returns this->raw() if num_args_tested == 1 and arg_nr == 1, otherwise | 2982 // Returns this->raw() if num_args_tested == 1 and arg_nr == 1, otherwise |
| 2983 // returns a new ICData object containing only unique arg_nr checks. | 2983 // returns a new ICData object containing only unique arg_nr checks. |
| 2984 RawICData* AsUnaryClassChecksForArgNr(intptr_t arg_nr) const; | 2984 RawICData* AsUnaryClassChecksForArgNr(intptr_t arg_nr) const; |
| 2985 RawICData* AsUnaryClassChecks() const { | 2985 RawICData* AsUnaryClassChecks() const { |
| 2986 return AsUnaryClassChecksForArgNr(0); | 2986 return AsUnaryClassChecksForArgNr(0); |
| 2987 } | 2987 } |
| 2988 | 2988 |
| 2989 bool AllTargetsHaveSameOwner(intptr_t owner_cid) const; | 2989 bool AllTargetsHaveSameOwner(intptr_t owner_cid) const; |
| 2990 bool AllReceiversAreNumbers() const; | 2990 bool AllReceiversAreNumbers() const; |
| 2991 bool HasOneTarget() const; | 2991 bool HasOneTarget() const; |
| 2992 bool HasReceiverClassId(intptr_t class_id) const; |
| 2992 | 2993 |
| 2993 static RawICData* New(const Function& caller_function, | 2994 static RawICData* New(const Function& caller_function, |
| 2994 const String& target_name, | 2995 const String& target_name, |
| 2995 intptr_t deopt_id, | 2996 intptr_t deopt_id, |
| 2996 intptr_t num_args_tested); | 2997 intptr_t num_args_tested); |
| 2997 | 2998 |
| 2998 static intptr_t TestEntryLengthFor(intptr_t num_args); | 2999 static intptr_t TestEntryLengthFor(intptr_t num_args); |
| 2999 | 3000 |
| 3000 static intptr_t TargetIndexFor(intptr_t num_args) { | 3001 static intptr_t TargetIndexFor(intptr_t num_args) { |
| 3001 return num_args; | 3002 return num_args; |
| (...skipping 3272 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6274 | 6275 |
| 6275 | 6276 |
| 6276 RawObject* MegamorphicCache::GetTargetFunction(const Array& array, | 6277 RawObject* MegamorphicCache::GetTargetFunction(const Array& array, |
| 6277 intptr_t index) { | 6278 intptr_t index) { |
| 6278 return array.At((index * kEntryLength) + kTargetFunctionIndex); | 6279 return array.At((index * kEntryLength) + kTargetFunctionIndex); |
| 6279 } | 6280 } |
| 6280 | 6281 |
| 6281 } // namespace dart | 6282 } // namespace dart |
| 6282 | 6283 |
| 6283 #endif // VM_OBJECT_H_ | 6284 #endif // VM_OBJECT_H_ |
| OLD | NEW |