| 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 #include "vm/object.h" | 5 #include "vm/object.h" |
| 6 | 6 |
| 7 #include "include/dart_api.h" | 7 #include "include/dart_api.h" |
| 8 #include "platform/assert.h" | 8 #include "platform/assert.h" |
| 9 #include "vm/assembler.h" | 9 #include "vm/assembler.h" |
| 10 #include "vm/cpu.h" | 10 #include "vm/cpu.h" |
| (...skipping 6704 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6715 } | 6715 } |
| 6716 set_ic_data_array(a); | 6716 set_ic_data_array(a); |
| 6717 } | 6717 } |
| 6718 } | 6718 } |
| 6719 | 6719 |
| 6720 | 6720 |
| 6721 void Function::RestoreICDataMap( | 6721 void Function::RestoreICDataMap( |
| 6722 ZoneGrowableArray<const ICData*>* deopt_id_to_ic_data) const { | 6722 ZoneGrowableArray<const ICData*>* deopt_id_to_ic_data) const { |
| 6723 Zone* zone = Thread::Current()->zone(); | 6723 Zone* zone = Thread::Current()->zone(); |
| 6724 const Array& saved_icd = Array::Handle(zone, ic_data_array()); | 6724 const Array& saved_icd = Array::Handle(zone, ic_data_array()); |
| 6725 if (saved_icd.Length() == 0) { | 6725 if (saved_icd.IsNull() || (saved_icd.Length() == 0)) { |
| 6726 deopt_id_to_ic_data->Clear(); | 6726 deopt_id_to_ic_data->Clear(); |
| 6727 return; | 6727 return; |
| 6728 } | 6728 } |
| 6729 ICData& icd = ICData::Handle(); | 6729 ICData& icd = ICData::Handle(); |
| 6730 icd ^= saved_icd.At(saved_icd.Length() - 1); | 6730 icd ^= saved_icd.At(saved_icd.Length() - 1); |
| 6731 const intptr_t len = icd.deopt_id() + 1; | 6731 const intptr_t len = icd.deopt_id() + 1; |
| 6732 deopt_id_to_ic_data->SetLength(len); | 6732 deopt_id_to_ic_data->SetLength(len); |
| 6733 for (intptr_t i = 0; i < len; i++) { | 6733 for (intptr_t i = 0; i < len; i++) { |
| 6734 (*deopt_id_to_ic_data)[i] = NULL; | 6734 (*deopt_id_to_ic_data)[i] = NULL; |
| 6735 } | 6735 } |
| (...skipping 14003 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 20739 return tag_label.ToCString(); | 20739 return tag_label.ToCString(); |
| 20740 } | 20740 } |
| 20741 | 20741 |
| 20742 | 20742 |
| 20743 void UserTag::PrintJSONImpl(JSONStream* stream, bool ref) const { | 20743 void UserTag::PrintJSONImpl(JSONStream* stream, bool ref) const { |
| 20744 Instance::PrintJSONImpl(stream, ref); | 20744 Instance::PrintJSONImpl(stream, ref); |
| 20745 } | 20745 } |
| 20746 | 20746 |
| 20747 | 20747 |
| 20748 } // namespace dart | 20748 } // namespace dart |
| OLD | NEW |