| 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_X64. | 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_X64. |
| 6 #if defined(TARGET_ARCH_X64) | 6 #if defined(TARGET_ARCH_X64) |
| 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 980 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 991 const Function& function = parsed_function().function(); | 991 const Function& function = parsed_function().function(); |
| 992 // Load pool pointer. | 992 // Load pool pointer. |
| 993 | 993 |
| 994 if (flow_graph().IsCompiledForOsr()) { | 994 if (flow_graph().IsCompiledForOsr()) { |
| 995 intptr_t extra_slots = StackSize() | 995 intptr_t extra_slots = StackSize() |
| 996 - flow_graph().num_stack_locals() | 996 - flow_graph().num_stack_locals() |
| 997 - flow_graph().num_copied_params(); | 997 - flow_graph().num_copied_params(); |
| 998 ASSERT(extra_slots >= 0); | 998 ASSERT(extra_slots >= 0); |
| 999 __ EnterOsrFrame(extra_slots * kWordSize); | 999 __ EnterOsrFrame(extra_slots * kWordSize); |
| 1000 } else { | 1000 } else { |
| 1001 __ Comment("Invocation Count Check"); |
| 1001 const Register new_pp = R13; | 1002 const Register new_pp = R13; |
| 1002 __ LoadPoolPointer(new_pp); | 1003 __ LoadPoolPointer(new_pp); |
| 1003 | 1004 |
| 1004 if (CanOptimizeFunction() && | 1005 if (CanOptimizeFunction() && |
| 1005 function.IsOptimizable() && | 1006 function.IsOptimizable() && |
| 1006 (!is_optimizing() || may_reoptimize())) { | 1007 (!is_optimizing() || may_reoptimize())) { |
| 1007 const Register function_reg = RDI; | 1008 const Register function_reg = RDI; |
| 1008 // Load function object using the callee's pool pointer. | 1009 // Load function object using the callee's pool pointer. |
| 1009 __ LoadFunctionFromCalleePool(function_reg, function, new_pp); | 1010 __ LoadFunctionFromCalleePool(function_reg, function, new_pp); |
| 1010 | 1011 |
| (...skipping 799 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1810 __ movups(reg, Address(RSP, 0)); | 1811 __ movups(reg, Address(RSP, 0)); |
| 1811 __ AddImmediate(RSP, Immediate(kFpuRegisterSize)); | 1812 __ AddImmediate(RSP, Immediate(kFpuRegisterSize)); |
| 1812 } | 1813 } |
| 1813 | 1814 |
| 1814 | 1815 |
| 1815 #undef __ | 1816 #undef __ |
| 1816 | 1817 |
| 1817 } // namespace dart | 1818 } // namespace dart |
| 1818 | 1819 |
| 1819 #endif // defined TARGET_ARCH_X64 | 1820 #endif // defined TARGET_ARCH_X64 |
| OLD | NEW |