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

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

Issue 197283004: Generate smaller unoptimized code for certain expressions. (Closed) Base URL: http://dart.googlecode.com/svn/branches/bleeding_edge/dart/
Patch Set: Created 6 years, 9 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/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 294 matching lines...) Expand 10 before | Expand all | Expand 10 after
305 305
306 const char* RangeBoundary::ToCString() const { 306 const char* RangeBoundary::ToCString() const {
307 char buffer[256]; 307 char buffer[256];
308 BufferFormatter f(buffer, sizeof(buffer)); 308 BufferFormatter f(buffer, sizeof(buffer));
309 PrintTo(&f); 309 PrintTo(&f);
310 return Isolate::Current()->current_zone()->MakeCopyOfString(buffer); 310 return Isolate::Current()->current_zone()->MakeCopyOfString(buffer);
311 } 311 }
312 312
313 313
314 void DropTempsInstr::PrintOperandsTo(BufferFormatter* f) const { 314 void DropTempsInstr::PrintOperandsTo(BufferFormatter* f) const {
315 f->Print("%" Pd ", ", num_temps()); 315 f->Print("%" Pd "", num_temps());
316 value()->PrintTo(f); 316 if (value() != NULL) {
317 f->Print(", ");
318 value()->PrintTo(f);
319 }
317 } 320 }
318 321
319 322
320 void AssertAssignableInstr::PrintOperandsTo(BufferFormatter* f) const { 323 void AssertAssignableInstr::PrintOperandsTo(BufferFormatter* f) const {
321 value()->PrintTo(f); 324 value()->PrintTo(f);
322 f->Print(", %s, '%s'", 325 f->Print(", %s, '%s'",
323 dst_type().ToCString(), 326 dst_type().ToCString(),
324 dst_name().ToCString()); 327 dst_name().ToCString());
325 f->Print(" instantiator("); 328 f->Print(" instantiator(");
326 instantiator()->PrintTo(f); 329 instantiator()->PrintTo(f);
(...skipping 700 matching lines...) Expand 10 before | Expand all | Expand 10 after
1027 f->Print(" ["); 1030 f->Print(" [");
1028 locations_[i].PrintTo(f); 1031 locations_[i].PrintTo(f);
1029 f->Print("]"); 1032 f->Print("]");
1030 } 1033 }
1031 } 1034 }
1032 f->Print(" }"); 1035 f->Print(" }");
1033 if (outer_ != NULL) outer_->PrintTo(f); 1036 if (outer_ != NULL) outer_->PrintTo(f);
1034 } 1037 }
1035 1038
1036 } // namespace dart 1039 } // namespace dart
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698