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

Side by Side Diff: runtime/vm/intermediate_language_x64.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
« no previous file with comments | « runtime/vm/intermediate_language_ia32.cc ('k') | runtime/vm/vm_sources.gypi » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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_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/intermediate_language.h" 8 #include "vm/intermediate_language.h"
9 9
10 #include "lib/error.h" 10 #include "lib/error.h"
(...skipping 39 matching lines...) Expand 10 before | Expand all | Expand 10 after
50 v2->AsUse()->definition()->temp_index(); 50 v2->AsUse()->definition()->temp_index();
51 } 51 }
52 52
53 53
54 void BindInstr::EmitNativeCode(FlowGraphCompiler* compiler) { 54 void BindInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
55 computation()->EmitNativeCode(compiler); 55 computation()->EmitNativeCode(compiler);
56 __ pushq(locs()->out().reg()); 56 __ pushq(locs()->out().reg());
57 } 57 }
58 58
59 59
60 void GraphEntryInstr::PrepareEntry(FlowGraphCompiler* compiler) {
61 // Nothing to do.
62 }
63
64
65 void JoinEntryInstr::PrepareEntry(FlowGraphCompiler* compiler) {
66 __ Bind(compiler->GetBlockLabel(this));
67 }
68
69
70 void TargetEntryInstr::PrepareEntry(FlowGraphCompiler* compiler) {
71 __ Bind(compiler->GetBlockLabel(this));
72 if (HasTryIndex()) {
73 compiler->AddExceptionHandler(try_index(),
74 compiler->assembler()->CodeSize());
75 }
76 }
77
78
60 LocationSummary* ThrowInstr::MakeLocationSummary() const { 79 LocationSummary* ThrowInstr::MakeLocationSummary() const {
61 const int kNumInputs = 0; 80 const int kNumInputs = 0;
62 const int kNumTemps = 0; 81 const int kNumTemps = 0;
63 return new LocationSummary(kNumInputs, kNumTemps); 82 return new LocationSummary(kNumInputs, kNumTemps);
64 } 83 }
65 84
66 85
67 void ThrowInstr::EmitNativeCode(FlowGraphCompiler* compiler) { 86 void ThrowInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
68 ASSERT(exception()->IsUse()); 87 ASSERT(exception()->IsUse());
69 compiler->GenerateCallRuntime(cid(), 88 compiler->GenerateCallRuntime(cid(),
(...skipping 1338 matching lines...) Expand 10 before | Expand all | Expand 10 after
1408 } else { 1427 } else {
1409 UNREACHABLE(); 1428 UNREACHABLE();
1410 } 1429 }
1411 } 1430 }
1412 1431
1413 } // namespace dart 1432 } // namespace dart
1414 1433
1415 #undef __ 1434 #undef __
1416 1435
1417 #endif // defined TARGET_ARCH_X64 1436 #endif // defined TARGET_ARCH_X64
OLDNEW
« no previous file with comments | « runtime/vm/intermediate_language_ia32.cc ('k') | runtime/vm/vm_sources.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698