| 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 "lib/error.h" | 10 #include "lib/error.h" |
| (...skipping 1405 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1416 GenerateDartCall(deopt_id, | 1416 GenerateDartCall(deopt_id, |
| 1417 token_pos, | 1417 token_pos, |
| 1418 &StubCode::CallStaticFunctionLabel(), | 1418 &StubCode::CallStaticFunctionLabel(), |
| 1419 PcDescriptors::kFuncCall, | 1419 PcDescriptors::kFuncCall, |
| 1420 locs); | 1420 locs); |
| 1421 AddStaticCallTarget(function); | 1421 AddStaticCallTarget(function); |
| 1422 __ Drop(argument_count); | 1422 __ Drop(argument_count); |
| 1423 } | 1423 } |
| 1424 | 1424 |
| 1425 | 1425 |
| 1426 void FlowGraphCompiler::EmitUnoptimizedStaticCall( |
| 1427 const Function& target_function, |
| 1428 const Array& arguments_descriptor, |
| 1429 intptr_t argument_count, |
| 1430 intptr_t deopt_id, |
| 1431 intptr_t token_pos, |
| 1432 LocationSummary* locs) { |
| 1433 const ICData& ic_data = ICData::ZoneHandle( |
| 1434 ICData::New(parsed_function().function(), // Caller function. |
| 1435 String::Handle(target_function.name()), |
| 1436 arguments_descriptor, |
| 1437 deopt_id, |
| 1438 0)); // No arguments checked. |
| 1439 ic_data.AddTarget(target_function); |
| 1440 __ LoadObject(S5, ic_data); |
| 1441 GenerateDartCall(deopt_id, |
| 1442 token_pos, |
| 1443 &StubCode::UnoptimizedStaticCallLabel(), |
| 1444 PcDescriptors::kFuncCall, |
| 1445 locs); |
| 1446 __ Drop(argument_count); |
| 1447 } |
| 1448 |
| 1449 |
| 1426 void FlowGraphCompiler::EmitEqualityRegConstCompare(Register reg, | 1450 void FlowGraphCompiler::EmitEqualityRegConstCompare(Register reg, |
| 1427 const Object& obj, | 1451 const Object& obj, |
| 1428 bool needs_number_check, | 1452 bool needs_number_check, |
| 1429 intptr_t token_pos) { | 1453 intptr_t token_pos) { |
| 1430 __ TraceSimMsg("EqualityRegConstCompare"); | 1454 __ TraceSimMsg("EqualityRegConstCompare"); |
| 1431 if (needs_number_check && | 1455 if (needs_number_check && |
| 1432 (obj.IsMint() || obj.IsDouble() || obj.IsBigint())) { | 1456 (obj.IsMint() || obj.IsDouble() || obj.IsBigint())) { |
| 1433 __ addiu(SP, SP, Immediate(-2 * kWordSize)); | 1457 __ addiu(SP, SP, Immediate(-2 * kWordSize)); |
| 1434 __ sw(reg, Address(SP, 1 * kWordSize)); | 1458 __ sw(reg, Address(SP, 1 * kWordSize)); |
| 1435 __ LoadObject(TMP1, obj); | 1459 __ LoadObject(TMP1, obj); |
| (...skipping 491 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1927 __ AddImmediate(SP, kDoubleSize); | 1951 __ AddImmediate(SP, kDoubleSize); |
| 1928 } | 1952 } |
| 1929 | 1953 |
| 1930 | 1954 |
| 1931 #undef __ | 1955 #undef __ |
| 1932 | 1956 |
| 1933 | 1957 |
| 1934 } // namespace dart | 1958 } // namespace dart |
| 1935 | 1959 |
| 1936 #endif // defined TARGET_ARCH_MIPS | 1960 #endif // defined TARGET_ARCH_MIPS |
| OLD | NEW |