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_MIPS. | 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_MIPS. |
6 #if defined(TARGET_ARCH_MIPS) | 6 #if defined(TARGET_ARCH_MIPS) |
7 | 7 |
8 #include "vm/flow_graph_compiler.h" | 8 #include "vm/flow_graph_compiler.h" |
9 | 9 |
10 #include "vm/ast_printer.h" | 10 #include "vm/ast_printer.h" |
(...skipping 1356 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1367 void FlowGraphCompiler::EmitSwitchableInstanceCall( | 1367 void FlowGraphCompiler::EmitSwitchableInstanceCall( |
1368 const ICData& ic_data, | 1368 const ICData& ic_data, |
1369 intptr_t argument_count, | 1369 intptr_t argument_count, |
1370 intptr_t deopt_id, | 1370 intptr_t deopt_id, |
1371 TokenPosition token_pos, | 1371 TokenPosition token_pos, |
1372 LocationSummary* locs) { | 1372 LocationSummary* locs) { |
1373 __ Comment("SwitchableCall"); | 1373 __ Comment("SwitchableCall"); |
1374 __ lw(T0, Address(SP, (argument_count - 1) * kWordSize)); | 1374 __ lw(T0, Address(SP, (argument_count - 1) * kWordSize)); |
1375 if (ic_data.NumArgsTested() == 1) { | 1375 if (ic_data.NumArgsTested() == 1) { |
1376 __ LoadUniqueObject(S5, ic_data); | 1376 __ LoadUniqueObject(S5, ic_data); |
1377 __ BranchLinkPatchable(*StubCode::ICLookup_entry()); | 1377 __ BranchLinkPatchable(*StubCode::ICLookupThroughFunction_entry()); |
1378 } else { | 1378 } else { |
1379 const String& name = String::Handle(zone(), ic_data.target_name()); | 1379 const String& name = String::Handle(zone(), ic_data.target_name()); |
1380 const Array& arguments_descriptor = | 1380 const Array& arguments_descriptor = |
1381 Array::ZoneHandle(zone(), ic_data.arguments_descriptor()); | 1381 Array::ZoneHandle(zone(), ic_data.arguments_descriptor()); |
1382 ASSERT(!arguments_descriptor.IsNull() && | 1382 ASSERT(!arguments_descriptor.IsNull() && |
1383 (arguments_descriptor.Length() > 0)); | 1383 (arguments_descriptor.Length() > 0)); |
1384 const MegamorphicCache& cache = MegamorphicCache::ZoneHandle(zone(), | 1384 const MegamorphicCache& cache = MegamorphicCache::ZoneHandle(zone(), |
1385 MegamorphicCacheTable::Lookup(isolate(), name, arguments_descriptor)); | 1385 MegamorphicCacheTable::Lookup(isolate(), name, arguments_descriptor)); |
1386 | 1386 |
1387 __ LoadUniqueObject(S5, cache); | 1387 __ LoadUniqueObject(S5, cache); |
(...skipping 554 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1942 __ AddImmediate(SP, kDoubleSize); | 1942 __ AddImmediate(SP, kDoubleSize); |
1943 } | 1943 } |
1944 | 1944 |
1945 | 1945 |
1946 #undef __ | 1946 #undef __ |
1947 | 1947 |
1948 | 1948 |
1949 } // namespace dart | 1949 } // namespace dart |
1950 | 1950 |
1951 #endif // defined TARGET_ARCH_MIPS | 1951 #endif // defined TARGET_ARCH_MIPS |
OLD | NEW |