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

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

Issue 10892037: Stop attaching try_index to individual instructions put it at block entry instead. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: address Srdjan's comment, make meaning of CatchTryIndex clear Created 8 years, 3 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/flow_graph_compiler_x64.cc ('k') | runtime/vm/intermediate_language.h » ('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/il_printer.h" 5 #include "vm/il_printer.h"
6 6
7 #include "vm/intermediate_language.h" 7 #include "vm/intermediate_language.h"
8 #include "vm/os.h" 8 #include "vm/os.h"
9 #include "vm/parser.h" 9 #include "vm/parser.h"
10 10
(...skipping 480 matching lines...) Expand 10 before | Expand all | Expand 10 after
491 void ParameterInstr::PrintTo(BufferFormatter* f) const { 491 void ParameterInstr::PrintTo(BufferFormatter* f) const {
492 f->Print(" v%d <- parameter(%d)", 492 f->Print(" v%d <- parameter(%d)",
493 HasSSATemp() ? ssa_temp_index() : temp_index(), 493 HasSSATemp() ? ssa_temp_index() : temp_index(),
494 index()); 494 index());
495 PrintPropagatedType(f, *this); 495 PrintPropagatedType(f, *this);
496 } 496 }
497 497
498 498
499 void TargetEntryInstr::PrintTo(BufferFormatter* f) const { 499 void TargetEntryInstr::PrintTo(BufferFormatter* f) const {
500 f->Print("%2d: [target", block_id()); 500 f->Print("%2d: [target", block_id());
501 if (HasTryIndex()) { 501 if (IsCatchEntry()) {
502 f->Print(" catch %d]", try_index()); 502 f->Print(" catch %d]", catch_try_index());
503 } else { 503 } else {
504 f->Print("]"); 504 f->Print("]");
505 } 505 }
506 if (HasParallelMove()) { 506 if (HasParallelMove()) {
507 f->Print("\n"); 507 f->Print("\n");
508 parallel_move()->PrintTo(f); 508 parallel_move()->PrintTo(f);
509 } 509 }
510 } 510 }
511 511
512 512
(...skipping 243 matching lines...) Expand 10 before | Expand all | Expand 10 after
756 756
757 void ParameterInstr::PrintToVisualizer(BufferFormatter* f) const { 757 void ParameterInstr::PrintToVisualizer(BufferFormatter* f) const {
758 ASSERT(HasSSATemp()); 758 ASSERT(HasSSATemp());
759 ASSERT(temp_index() == -1); 759 ASSERT(temp_index() == -1);
760 f->Print("v%d Parameter(%d)", ssa_temp_index(), index()); 760 f->Print("v%d Parameter(%d)", ssa_temp_index(), index());
761 } 761 }
762 762
763 763
764 void TargetEntryInstr::PrintToVisualizer(BufferFormatter* f) const { 764 void TargetEntryInstr::PrintToVisualizer(BufferFormatter* f) const {
765 f->Print("_ [target"); 765 f->Print("_ [target");
766 if (HasTryIndex()) { 766 if (IsCatchEntry()) {
767 f->Print(" catch %d]", try_index()); 767 f->Print(" catch %d]", catch_try_index());
768 } else { 768 } else {
769 f->Print("]"); 769 f->Print("]");
770 } 770 }
771 } 771 }
772 772
773 773
774 void BindInstr::PrintToVisualizer(BufferFormatter* f) const { 774 void BindInstr::PrintToVisualizer(BufferFormatter* f) const {
775 if (!is_used()) { 775 if (!is_used()) {
776 f->Print("_ "); 776 f->Print("_ ");
777 } else if (HasSSATemp()) { 777 } else if (HasSSATemp()) {
(...skipping 55 matching lines...) Expand 10 before | Expand all | Expand 10 after
833 if ((locations_ != NULL) && !locations_[i].IsInvalid()) { 833 if ((locations_ != NULL) && !locations_[i].IsInvalid()) {
834 f->Print(" ["); 834 f->Print(" [");
835 locations_[i].PrintTo(f); 835 locations_[i].PrintTo(f);
836 f->Print("]"); 836 f->Print("]");
837 } 837 }
838 } 838 }
839 f->Print(" }"); 839 f->Print(" }");
840 } 840 }
841 841
842 } // namespace dart 842 } // namespace dart
OLDNEW
« no previous file with comments | « runtime/vm/flow_graph_compiler_x64.cc ('k') | runtime/vm/intermediate_language.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698