| 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_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/intermediate_language.h" | 8 #include "vm/intermediate_language.h" |
| 9 | 9 |
| 10 #include "vm/dart_entry.h" | 10 #include "vm/dart_entry.h" |
| 11 #include "vm/flow_graph.h" |
| 11 #include "vm/flow_graph_compiler.h" | 12 #include "vm/flow_graph_compiler.h" |
| 12 #include "vm/locations.h" | 13 #include "vm/locations.h" |
| 13 #include "vm/object_store.h" | 14 #include "vm/object_store.h" |
| 14 #include "vm/parser.h" | 15 #include "vm/parser.h" |
| 15 #include "vm/stack_frame.h" | 16 #include "vm/stack_frame.h" |
| 16 #include "vm/stub_code.h" | 17 #include "vm/stub_code.h" |
| 17 #include "vm/symbols.h" | 18 #include "vm/symbols.h" |
| 18 | 19 |
| 19 #define __ compiler->assembler()-> | 20 #define __ compiler->assembler()-> |
| 20 | 21 |
| (...skipping 5970 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 5991 void GraphEntryInstr::EmitNativeCode(FlowGraphCompiler* compiler) { | 5992 void GraphEntryInstr::EmitNativeCode(FlowGraphCompiler* compiler) { |
| 5992 if (!compiler->CanFallThroughTo(normal_entry())) { | 5993 if (!compiler->CanFallThroughTo(normal_entry())) { |
| 5993 __ jmp(compiler->GetJumpLabel(normal_entry())); | 5994 __ jmp(compiler->GetJumpLabel(normal_entry())); |
| 5994 } | 5995 } |
| 5995 } | 5996 } |
| 5996 | 5997 |
| 5997 | 5998 |
| 5998 void TargetEntryInstr::EmitNativeCode(FlowGraphCompiler* compiler) { | 5999 void TargetEntryInstr::EmitNativeCode(FlowGraphCompiler* compiler) { |
| 5999 __ Bind(compiler->GetJumpLabel(this)); | 6000 __ Bind(compiler->GetJumpLabel(this)); |
| 6000 if (!compiler->is_optimizing()) { | 6001 if (!compiler->is_optimizing()) { |
| 6001 if (FLAG_emit_edge_counters) { | 6002 if (compiler->NeedsEdgeCounter(this)) { |
| 6002 compiler->EmitEdgeCounter(); | 6003 compiler->EmitEdgeCounter(); |
| 6003 } | 6004 } |
| 6004 // The deoptimization descriptor points after the edge counter code for | 6005 // The deoptimization descriptor points after the edge counter code for |
| 6005 // uniformity with ARM and MIPS, where we can reuse pattern matching | 6006 // uniformity with ARM and MIPS, where we can reuse pattern matching |
| 6006 // code that matches backwards from the end of the pattern. | 6007 // code that matches backwards from the end of the pattern. |
| 6007 compiler->AddCurrentDescriptor(PcDescriptors::kDeopt, | 6008 compiler->AddCurrentDescriptor(PcDescriptors::kDeopt, |
| 6008 deopt_id_, | 6009 deopt_id_, |
| 6009 Scanner::kNoSourcePos); | 6010 Scanner::kNoSourcePos); |
| 6010 } | 6011 } |
| 6011 if (HasParallelMove()) { | 6012 if (HasParallelMove()) { |
| (...skipping 279 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 6291 PcDescriptors::kOther, | 6292 PcDescriptors::kOther, |
| 6292 locs()); | 6293 locs()); |
| 6293 __ Drop(ArgumentCount()); // Discard arguments. | 6294 __ Drop(ArgumentCount()); // Discard arguments. |
| 6294 } | 6295 } |
| 6295 | 6296 |
| 6296 } // namespace dart | 6297 } // namespace dart |
| 6297 | 6298 |
| 6298 #undef __ | 6299 #undef __ |
| 6299 | 6300 |
| 6300 #endif // defined TARGET_ARCH_IA32 | 6301 #endif // defined TARGET_ARCH_IA32 |
| OLD | NEW |