| OLD | NEW |
| 1 // Copyright (c) 2012, the Dart project authors. Please see the AUTHORS file | 1 // Copyright (c) 2012, 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_IA32. | 5 #include "vm/globals.h" // Needed here to get TARGET_ARCH_IA32. |
| 6 #if defined(TARGET_ARCH_IA32) | 6 #if defined(TARGET_ARCH_IA32) |
| 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 77 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 88 if (compiler->IsLeaf()) { | 88 if (compiler->IsLeaf()) { |
| 89 Label L; | 89 Label L; |
| 90 __ call(&L); | 90 __ call(&L); |
| 91 const intptr_t offset = assem->CodeSize(); | 91 const intptr_t offset = assem->CodeSize(); |
| 92 __ Bind(&L); | 92 __ Bind(&L); |
| 93 __ popl(EAX); | 93 __ popl(EAX); |
| 94 __ subl(EAX, | 94 __ subl(EAX, |
| 95 Immediate(offset - AssemblerMacros::kOffsetOfSavedPCfromEntrypoint)); | 95 Immediate(offset - AssemblerMacros::kOffsetOfSavedPCfromEntrypoint)); |
| 96 __ movl(Address(EBP, -kWordSize), EAX); | 96 __ movl(Address(EBP, -kWordSize), EAX); |
| 97 } | 97 } |
| 98 __ movl(EAX, Immediate(Smi::RawValue(reason_))); | |
| 99 __ call(&StubCode::DeoptimizeLabel()); | 98 __ call(&StubCode::DeoptimizeLabel()); |
| 100 const intptr_t deopt_info_index = stub_ix; | 99 const intptr_t deopt_info_index = stub_ix; |
| 101 compiler->pc_descriptors_list()-> AddDeoptInfo( | 100 compiler->pc_descriptors_list()-> AddDeoptInfo( |
| 102 compiler->assembler()->CodeSize(), | 101 compiler->assembler()->CodeSize(), |
| 103 deopt_id_, | 102 deopt_id_, |
| 104 deopt_token_pos_, | 103 reason_, |
| 105 deopt_info_index); | 104 deopt_info_index); |
| 106 #undef __ | 105 #undef __ |
| 107 } | 106 } |
| 108 | 107 |
| 109 | 108 |
| 110 #define __ assembler()-> | 109 #define __ assembler()-> |
| 111 | 110 |
| 112 | 111 |
| 113 // Fall through if bool_register contains null. | 112 // Fall through if bool_register contains null. |
| 114 void FlowGraphCompiler::GenerateBoolToJump(Register bool_register, | 113 void FlowGraphCompiler::GenerateBoolToJump(Register bool_register, |
| (...skipping 1138 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 1253 __ popl(ECX); | 1252 __ popl(ECX); |
| 1254 __ popl(EAX); | 1253 __ popl(EAX); |
| 1255 } | 1254 } |
| 1256 | 1255 |
| 1257 | 1256 |
| 1258 #undef __ | 1257 #undef __ |
| 1259 | 1258 |
| 1260 } // namespace dart | 1259 } // namespace dart |
| 1261 | 1260 |
| 1262 #endif // defined TARGET_ARCH_IA32 | 1261 #endif // defined TARGET_ARCH_IA32 |
| OLD | NEW |