| 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 6692 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6703 } | 6703 } |
| 6704 set_ic_data_array(a); | 6704 set_ic_data_array(a); |
| 6705 } | 6705 } |
| 6706 } | 6706 } |
| 6707 | 6707 |
| 6708 | 6708 |
| 6709 void Function::RestoreICDataMap( | 6709 void Function::RestoreICDataMap( |
| 6710 ZoneGrowableArray<const ICData*>* deopt_id_to_ic_data) const { | 6710 ZoneGrowableArray<const ICData*>* deopt_id_to_ic_data) const { |
| 6711 Zone* zone = Thread::Current()->zone(); | 6711 Zone* zone = Thread::Current()->zone(); |
| 6712 const Array& saved_icd = Array::Handle(zone, ic_data_array()); | 6712 const Array& saved_icd = Array::Handle(zone, ic_data_array()); |
| 6713 if (saved_icd.Length() == 0) { | 6713 if (saved_icd.IsNull() || (saved_icd.Length() == 0)) { |
| 6714 deopt_id_to_ic_data->Clear(); | 6714 deopt_id_to_ic_data->Clear(); |
| 6715 return; | 6715 return; |
| 6716 } | 6716 } |
| 6717 ICData& icd = ICData::Handle(); | 6717 ICData& icd = ICData::Handle(); |
| 6718 icd ^= saved_icd.At(saved_icd.Length() - 1); | 6718 icd ^= saved_icd.At(saved_icd.Length() - 1); |
| 6719 const intptr_t len = icd.deopt_id() + 1; | 6719 const intptr_t len = icd.deopt_id() + 1; |
| 6720 deopt_id_to_ic_data->SetLength(len); | 6720 deopt_id_to_ic_data->SetLength(len); |
| 6721 for (intptr_t i = 0; i < len; i++) { | 6721 for (intptr_t i = 0; i < len; i++) { |
| 6722 (*deopt_id_to_ic_data)[i] = NULL; | 6722 (*deopt_id_to_ic_data)[i] = NULL; |
| 6723 } | 6723 } |
| (...skipping 14006 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 20730 return tag_label.ToCString(); | 20730 return tag_label.ToCString(); |
| 20731 } | 20731 } |
| 20732 | 20732 |
| 20733 | 20733 |
| 20734 void UserTag::PrintJSONImpl(JSONStream* stream, bool ref) const { | 20734 void UserTag::PrintJSONImpl(JSONStream* stream, bool ref) const { |
| 20735 Instance::PrintJSONImpl(stream, ref); | 20735 Instance::PrintJSONImpl(stream, ref); |
| 20736 } | 20736 } |
| 20737 | 20737 |
| 20738 | 20738 |
| 20739 } // namespace dart | 20739 } // namespace dart |
| OLD | NEW |