| OLD | NEW |
| (Empty) |
| 1 // Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file | |
| 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. | |
| 4 | |
| 5 #ifndef RUNTIME_VM_OPTIMIZER_H_ | |
| 6 #define RUNTIME_VM_OPTIMIZER_H_ | |
| 7 | |
| 8 #include "vm/globals.h" | |
| 9 | |
| 10 #include "vm/growable_array.h" | |
| 11 | |
| 12 namespace dart { | |
| 13 | |
| 14 class Optimizer { | |
| 15 public: | |
| 16 // Tries to add cid tests to 'results' so that no deoptimization is | |
| 17 // necessary for common number-related type tests. Unconditionally adds an | |
| 18 // entry for the Smi type to the start of the array. | |
| 19 // TODO(srdjan): Do also for other than numeric types. | |
| 20 static bool SpecializeTestCidsForNumericTypes( | |
| 21 ZoneGrowableArray<intptr_t>* results, | |
| 22 const AbstractType& type); | |
| 23 }; | |
| 24 | |
| 25 } // namespace dart | |
| 26 | |
| 27 #endif // RUNTIME_VM_OPTIMIZER_H_ | |
| OLD | NEW |