OLD | NEW |
1 // Copyright (c) 2016, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2016, 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 #include "vm/isolate_reload.h" | 5 #include "vm/isolate_reload.h" |
6 | 6 |
7 #include "vm/become.h" | 7 #include "vm/become.h" |
8 #include "vm/bit_vector.h" | 8 #include "vm/bit_vector.h" |
9 #include "vm/compiler.h" | 9 #include "vm/compiler.h" |
10 #include "vm/dart_api_impl.h" | 10 #include "vm/dart_api_impl.h" |
(...skipping 1572 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1583 func.set_optimized_instruction_count(0); | 1583 func.set_optimized_instruction_count(0); |
1584 func.set_optimized_call_site_count(0); | 1584 func.set_optimized_call_site_count(0); |
1585 } | 1585 } |
1586 } | 1586 } |
1587 | 1587 |
1588 private: | 1588 private: |
1589 void ClearAllCode(const Function& func) { | 1589 void ClearAllCode(const Function& func) { |
1590 // Null out the ICData array and code. | 1590 // Null out the ICData array and code. |
1591 func.ClearICDataArray(); | 1591 func.ClearICDataArray(); |
1592 func.ClearCode(); | 1592 func.ClearCode(); |
1593 func.set_was_compiled(false); | 1593 func.SetWasCompiled(false); |
1594 } | 1594 } |
1595 | 1595 |
1596 void PreserveUnoptimizedCode() { | 1596 void PreserveUnoptimizedCode() { |
1597 ASSERT(!code_.IsNull()); | 1597 ASSERT(!code_.IsNull()); |
1598 // We are preserving the unoptimized code, fill all ICData arrays with | 1598 // We are preserving the unoptimized code, fill all ICData arrays with |
1599 // the sentinel values so that we have no stale type feedback. | 1599 // the sentinel values so that we have no stale type feedback. |
1600 code_.ResetICDatas(zone_); | 1600 code_.ResetICDatas(zone_); |
1601 } | 1601 } |
1602 | 1602 |
1603 bool IsFromDirtyLibrary(const Function& func) { | 1603 bool IsFromDirtyLibrary(const Function& func) { |
(...skipping 221 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1825 ASSERT(!super_cls.IsNull()); | 1825 ASSERT(!super_cls.IsNull()); |
1826 super_cls.AddDirectSubclass(cls); | 1826 super_cls.AddDirectSubclass(cls); |
1827 } | 1827 } |
1828 } | 1828 } |
1829 } | 1829 } |
1830 } | 1830 } |
1831 | 1831 |
1832 #endif // !PRODUCT | 1832 #endif // !PRODUCT |
1833 | 1833 |
1834 } // namespace dart | 1834 } // namespace dart |
OLD | NEW |