OLD | NEW |
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/flow_graph_range_analysis.h" | 7 #include "vm/flow_graph_range_analysis.h" |
8 #include "vm/intermediate_language.h" | 8 #include "vm/intermediate_language.h" |
9 #include "vm/os.h" | 9 #include "vm/os.h" |
10 #include "vm/parser.h" | 10 #include "vm/parser.h" |
(...skipping 547 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
558 right()->PrintTo(f); | 558 right()->PrintTo(f); |
559 if (needs_number_check()) { | 559 if (needs_number_check()) { |
560 f->Print(", with number check"); | 560 f->Print(", with number check"); |
561 } | 561 } |
562 } | 562 } |
563 | 563 |
564 | 564 |
565 void TestCidsInstr::PrintOperandsTo(BufferFormatter* f) const { | 565 void TestCidsInstr::PrintOperandsTo(BufferFormatter* f) const { |
566 left()->PrintTo(f); | 566 left()->PrintTo(f); |
567 f->Print(" %s [", Token::Str(kind())); | 567 f->Print(" %s [", Token::Str(kind())); |
568 for (intptr_t i = 0; i < cid_results().length(); i += 2) { | 568 intptr_t length = cid_results().length(); |
| 569 for (intptr_t i = 0; i < length; i += 2) { |
569 f->Print("0x%" Px ":%s ", cid_results()[i], | 570 f->Print("0x%" Px ":%s ", cid_results()[i], |
570 cid_results()[i + 1] == 0 ? "false" : "true"); | 571 cid_results()[i + 1] == 0 ? "false" : "true"); |
571 } | 572 } |
572 f->Print("] "); | 573 f->Print("] "); |
| 574 if (CanDeoptimize()) { |
| 575 ASSERT(deopt_id() != Thread::kNoDeoptId); |
| 576 f->Print("else deoptimize "); |
| 577 } else { |
| 578 ASSERT(deopt_id() == Thread::kNoDeoptId); |
| 579 f->Print("else %s ", cid_results()[length - 1] != 0 ? "false" : "true"); |
| 580 } |
573 } | 581 } |
574 | 582 |
575 | 583 |
576 void EqualityCompareInstr::PrintOperandsTo(BufferFormatter* f) const { | 584 void EqualityCompareInstr::PrintOperandsTo(BufferFormatter* f) const { |
577 left()->PrintTo(f); | 585 left()->PrintTo(f); |
578 f->Print(" %s ", Token::Str(kind())); | 586 f->Print(" %s ", Token::Str(kind())); |
579 right()->PrintTo(f); | 587 right()->PrintTo(f); |
580 } | 588 } |
581 | 589 |
582 | 590 |
(...skipping 807 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1390 } | 1398 } |
1391 | 1399 |
1392 | 1400 |
1393 bool FlowGraphPrinter::ShouldPrint(const Function& function) { | 1401 bool FlowGraphPrinter::ShouldPrint(const Function& function) { |
1394 return false; | 1402 return false; |
1395 } | 1403 } |
1396 | 1404 |
1397 #endif // !PRODUCT | 1405 #endif // !PRODUCT |
1398 | 1406 |
1399 } // namespace dart | 1407 } // namespace dart |
OLD | NEW |