| OLD | NEW |
| 1 // Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2013, 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_ARM. | 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_ARM. |
| 6 #if defined(TARGET_ARCH_ARM) | 6 #if defined(TARGET_ARCH_ARM) |
| 7 | 7 |
| 8 #include "vm/intermediate_language.h" | 8 #include "vm/intermediate_language.h" |
| 9 | 9 |
| 10 #include "vm/dart_entry.h" | 10 #include "vm/dart_entry.h" |
| (...skipping 3990 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4001 comparison()->EmitBranchCode(compiler, this); | 4001 comparison()->EmitBranchCode(compiler, this); |
| 4002 } | 4002 } |
| 4003 | 4003 |
| 4004 | 4004 |
| 4005 LocationSummary* CheckClassInstr::MakeLocationSummary() const { | 4005 LocationSummary* CheckClassInstr::MakeLocationSummary() const { |
| 4006 const intptr_t kNumInputs = 1; | 4006 const intptr_t kNumInputs = 1; |
| 4007 const intptr_t kNumTemps = 0; | 4007 const intptr_t kNumTemps = 0; |
| 4008 LocationSummary* summary = | 4008 LocationSummary* summary = |
| 4009 new LocationSummary(kNumInputs, kNumTemps, LocationSummary::kNoCall); | 4009 new LocationSummary(kNumInputs, kNumTemps, LocationSummary::kNoCall); |
| 4010 summary->set_in(0, Location::RequiresRegister()); | 4010 summary->set_in(0, Location::RequiresRegister()); |
| 4011 if (!null_check()) { | 4011 if (!IsNullCheck()) { |
| 4012 summary->AddTemp(Location::RequiresRegister()); | 4012 summary->AddTemp(Location::RequiresRegister()); |
| 4013 } | 4013 } |
| 4014 return summary; | 4014 return summary; |
| 4015 } | 4015 } |
| 4016 | 4016 |
| 4017 | 4017 |
| 4018 void CheckClassInstr::EmitNativeCode(FlowGraphCompiler* compiler) { | 4018 void CheckClassInstr::EmitNativeCode(FlowGraphCompiler* compiler) { |
| 4019 if (null_check()) { | 4019 if (IsNullCheck()) { |
| 4020 Label* deopt = compiler->AddDeoptStub(deopt_id(), | 4020 Label* deopt = compiler->AddDeoptStub(deopt_id(), |
| 4021 kDeoptCheckClass); | 4021 kDeoptCheckClass); |
| 4022 __ CompareImmediate(locs()->in(0).reg(), | 4022 __ CompareImmediate(locs()->in(0).reg(), |
| 4023 reinterpret_cast<intptr_t>(Object::null())); | 4023 reinterpret_cast<intptr_t>(Object::null())); |
| 4024 __ b(deopt, EQ); | 4024 __ b(deopt, EQ); |
| 4025 return; | 4025 return; |
| 4026 } | 4026 } |
| 4027 | 4027 |
| 4028 ASSERT((unary_checks().GetReceiverClassIdAt(0) != kSmiCid) || | 4028 ASSERT((unary_checks().GetReceiverClassIdAt(0) != kSmiCid) || |
| 4029 (unary_checks().NumberOfChecks() > 1)); | 4029 (unary_checks().NumberOfChecks() > 1)); |
| (...skipping 397 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 4427 compiler->GenerateCall(token_pos(), | 4427 compiler->GenerateCall(token_pos(), |
| 4428 &label, | 4428 &label, |
| 4429 PcDescriptors::kOther, | 4429 PcDescriptors::kOther, |
| 4430 locs()); | 4430 locs()); |
| 4431 __ Drop(2); // Discard type arguments and receiver. | 4431 __ Drop(2); // Discard type arguments and receiver. |
| 4432 } | 4432 } |
| 4433 | 4433 |
| 4434 } // namespace dart | 4434 } // namespace dart |
| 4435 | 4435 |
| 4436 #endif // defined TARGET_ARCH_ARM | 4436 #endif // defined TARGET_ARCH_ARM |
| OLD | NEW |