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

Unified Diff: runtime/vm/intermediate_language.cc

Issue 15529003: A few simple cleanups. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 7 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « runtime/vm/intermediate_language.h ('k') | runtime/vm/intermediate_language_arm.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: runtime/vm/intermediate_language.cc
diff --git a/runtime/vm/intermediate_language.cc b/runtime/vm/intermediate_language.cc
index 91eca3945c8e2cce83355b80f6e3ddbc2061a57f..052b3c73ca60b1d2c9839fa99845d881194b09f4 100644
--- a/runtime/vm/intermediate_language.cc
+++ b/runtime/vm/intermediate_language.cc
@@ -1396,56 +1396,13 @@ Instruction* CheckEitherNonSmiInstr::Canonicalize(FlowGraph* flow_graph) {
}
-// Shared code generation methods (EmitNativeCode, MakeLocationSummary, and
-// PrepareEntry). Only assembly code that can be shared across all architectures
-// can be used. Machine specific register allocation and code generation
-// is located in intermediate_language_<arch>.cc
+// Shared code generation methods (EmitNativeCode and
+// MakeLocationSummary). Only assembly code that can be shared across all
+// architectures can be used. Machine specific register allocation and code
+// generation is located in intermediate_language_<arch>.cc
#define __ compiler->assembler()->
-void GraphEntryInstr::PrepareEntry(FlowGraphCompiler* compiler) {
- // Nothing to do.
-}
-
-
-void JoinEntryInstr::PrepareEntry(FlowGraphCompiler* compiler) {
- if (!compiler->is_optimizing()) {
- compiler->AddCurrentDescriptor(PcDescriptors::kDeopt,
- deopt_id_,
- Scanner::kDummyTokenIndex);
- }
- __ Bind(compiler->GetJumpLabel(this));
- if (HasParallelMove()) {
- compiler->parallel_move_resolver()->EmitNativeCode(parallel_move());
- }
-}
-
-
-void TargetEntryInstr::PrepareEntry(FlowGraphCompiler* compiler) {
- if (!compiler->is_optimizing()) {
- compiler->AddCurrentDescriptor(PcDescriptors::kDeopt,
- deopt_id_,
- Scanner::kDummyTokenIndex);
- }
- __ Bind(compiler->GetJumpLabel(this));
- if (HasParallelMove()) {
- compiler->parallel_move_resolver()->EmitNativeCode(parallel_move());
- }
-}
-
-
-void CatchBlockEntryInstr::PrepareEntry(FlowGraphCompiler* compiler) {
- __ Bind(compiler->GetJumpLabel(this));
- compiler->AddExceptionHandler(catch_try_index(),
- try_index(),
- compiler->assembler()->CodeSize(),
- catch_handler_types_);
- if (HasParallelMove()) {
- compiler->parallel_move_resolver()->EmitNativeCode(parallel_move());
- }
-}
-
-
LocationSummary* GraphEntryInstr::MakeLocationSummary() const {
UNREACHABLE();
return NULL;
@@ -1453,7 +1410,7 @@ LocationSummary* GraphEntryInstr::MakeLocationSummary() const {
void GraphEntryInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
- UNREACHABLE();
+ // Nothing to do.
}
@@ -1464,7 +1421,15 @@ LocationSummary* JoinEntryInstr::MakeLocationSummary() const {
void JoinEntryInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
- UNREACHABLE();
+ if (!compiler->is_optimizing()) {
+ compiler->AddCurrentDescriptor(PcDescriptors::kDeopt,
+ deopt_id_,
+ Scanner::kDummyTokenIndex);
+ }
+ __ Bind(compiler->GetJumpLabel(this));
+ if (HasParallelMove()) {
+ compiler->parallel_move_resolver()->EmitNativeCode(parallel_move());
+ }
}
@@ -1475,7 +1440,15 @@ LocationSummary* TargetEntryInstr::MakeLocationSummary() const {
void TargetEntryInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
- UNREACHABLE();
+ if (!compiler->is_optimizing()) {
+ compiler->AddCurrentDescriptor(PcDescriptors::kDeopt,
+ deopt_id_,
+ Scanner::kDummyTokenIndex);
+ }
+ __ Bind(compiler->GetJumpLabel(this));
+ if (HasParallelMove()) {
+ compiler->parallel_move_resolver()->EmitNativeCode(parallel_move());
+ }
}
@@ -1486,7 +1459,14 @@ LocationSummary* CatchBlockEntryInstr::MakeLocationSummary() const {
void CatchBlockEntryInstr::EmitNativeCode(FlowGraphCompiler* compiler) {
- UNREACHABLE();
+ __ Bind(compiler->GetJumpLabel(this));
+ compiler->AddExceptionHandler(catch_try_index(),
+ try_index(),
+ compiler->assembler()->CodeSize(),
+ catch_handler_types_);
+ if (HasParallelMove()) {
+ compiler->parallel_move_resolver()->EmitNativeCode(parallel_move());
+ }
}
« no previous file with comments | « runtime/vm/intermediate_language.h ('k') | runtime/vm/intermediate_language_arm.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698