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/globals.h" // Needed here to get TARGET_ARCH_DBC. | 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_DBC. |
6 #if defined(TARGET_ARCH_DBC) | 6 #if defined(TARGET_ARCH_DBC) |
7 | 7 |
8 #include "vm/intermediate_language.h" | 8 #include "vm/intermediate_language.h" |
9 | 9 |
10 #include "vm/cpu.h" | 10 #include "vm/cpu.h" |
(...skipping 680 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
691 2, Location::RequiresRegister(), | 691 2, Location::RequiresRegister(), |
692 LocationSummary::kCall) { | 692 LocationSummary::kCall) { |
693 if (compiler->is_optimizing()) { | 693 if (compiler->is_optimizing()) { |
694 const Register length = locs()->in(kLengthPos).reg(); | 694 const Register length = locs()->in(kLengthPos).reg(); |
695 const Register type_arguments = locs()->in(kElementTypePos).reg(); | 695 const Register type_arguments = locs()->in(kElementTypePos).reg(); |
696 const Register out = locs()->out(0).reg(); | 696 const Register out = locs()->out(0).reg(); |
697 __ CreateArrayOpt(out, length, type_arguments); | 697 __ CreateArrayOpt(out, length, type_arguments); |
698 __ Push(type_arguments); | 698 __ Push(type_arguments); |
699 __ Push(length); | 699 __ Push(length); |
700 __ CreateArrayTOS(); | 700 __ CreateArrayTOS(); |
701 compiler->RecordSafepoint(locs()); | 701 compiler->RecordAfterCall(this); |
702 __ PopLocal(out); | 702 __ PopLocal(out); |
703 } else { | 703 } else { |
704 __ CreateArrayTOS(); | 704 __ CreateArrayTOS(); |
705 compiler->RecordSafepoint(locs()); | 705 compiler->RecordAfterCall(this); |
706 } | 706 } |
707 } | 707 } |
708 | 708 |
709 | 709 |
710 EMIT_NATIVE_CODE(StoreIndexed, 3, Location::NoLocation(), | 710 EMIT_NATIVE_CODE(StoreIndexed, 3, Location::NoLocation(), |
711 LocationSummary::kNoCall, 1) { | 711 LocationSummary::kNoCall, 1) { |
712 if (!compiler->is_optimizing()) { | 712 if (!compiler->is_optimizing()) { |
713 ASSERT(class_id() == kArrayCid); | 713 ASSERT(class_id() == kArrayCid); |
714 __ StoreIndexedTOS(); | 714 __ StoreIndexedTOS(); |
715 return; | 715 return; |
(...skipping 1254 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1970 __ IfULe(length, index); | 1970 __ IfULe(length, index); |
1971 compiler->EmitDeopt(deopt_id(), | 1971 compiler->EmitDeopt(deopt_id(), |
1972 ICData::kDeoptCheckArrayBound, | 1972 ICData::kDeoptCheckArrayBound, |
1973 (generalized_ ? ICData::kGeneralized : 0) | | 1973 (generalized_ ? ICData::kGeneralized : 0) | |
1974 (licm_hoisted_ ? ICData::kHoisted : 0)); | 1974 (licm_hoisted_ ? ICData::kHoisted : 0)); |
1975 } | 1975 } |
1976 | 1976 |
1977 } // namespace dart | 1977 } // namespace dart |
1978 | 1978 |
1979 #endif // defined TARGET_ARCH_DBC | 1979 #endif // defined TARGET_ARCH_DBC |
OLD | NEW |