Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(509)

Side by Side Diff: runtime/vm/intermediate_language_ia32.cc

Issue 10447133: FlowGraphCompiler is not a visitor any longer. Start consolidating shared code between the x64 and … (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 8 years, 6 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch | Annotate | Revision Log
OLDNEW
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/intermediate_language.h" 8 #include "vm/intermediate_language.h"
9 9
10 #include "vm/flow_graph_compiler.h" 10 #include "vm/flow_graph_compiler.h"
(...skipping 36 matching lines...) Expand 10 before | Expand all | Expand 10 after
47 return result; 47 return result;
48 } 48 }
49 49
50 50
51 void BindInstr::EmitNativeCode(FlowGraphCompiler* compiler) { 51 void BindInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
52 computation()->EmitNativeCode(compiler); 52 computation()->EmitNativeCode(compiler);
53 __ pushl(locs()->out().reg()); 53 __ pushl(locs()->out().reg());
54 } 54 }
55 55
56 56
57 void GraphEntryInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
58 // Nothing to do.
59 }
60
61
62 void JoinEntryInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
63 __ Bind(compiler->GetBlockLabel(this));
64 }
65
66
67 void TargetEntryInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
68 __ Bind(compiler->GetBlockLabel(this));
69 if (HasTryIndex()) {
70 compiler->AddExceptionHandler(try_index(),
71 compiler->assembler()->CodeSize());
72 }
73 }
74
75
57 LocationSummary* ReturnInstr::MakeLocationSummary() const { 76 LocationSummary* ReturnInstr::MakeLocationSummary() const {
58 const intptr_t kNumInputs = 1; 77 const intptr_t kNumInputs = 1;
59 const intptr_t kNumTemps = 1; 78 const intptr_t kNumTemps = 1;
60 LocationSummary* locs = new LocationSummary(kNumInputs, kNumTemps); 79 LocationSummary* locs = new LocationSummary(kNumInputs, kNumTemps);
61 locs->set_in(0, Location::RegisterLocation(EAX)); 80 locs->set_in(0, Location::RegisterLocation(EAX));
62 locs->set_temp(0, Location::RequiresRegister()); 81 locs->set_temp(0, Location::RequiresRegister());
63 return locs; 82 return locs;
64 } 83 }
65 84
66 85
(...skipping 539 matching lines...) Expand 10 before | Expand all | Expand 10 after
606 void NumberNegateComp::EmitNativeCode(FlowGraphCompiler* compile) { 625 void NumberNegateComp::EmitNativeCode(FlowGraphCompiler* compile) {
607 UNIMPLEMENTED(); 626 UNIMPLEMENTED();
608 } 627 }
609 628
610 629
611 } // namespace dart 630 } // namespace dart
612 631
613 #undef __ 632 #undef __
614 633
615 #endif // defined TARGET_ARCH_X64 634 #endif // defined TARGET_ARCH_X64
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698