OLD | NEW |
1 // Copyright 2014 the V8 project authors. All rights reserved. | 1 // Copyright 2014 the V8 project authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include "src/v8.h" | 5 #include "src/v8.h" |
6 #include "test/cctest/cctest.h" | 6 #include "test/cctest/cctest.h" |
7 | 7 |
8 #include "src/compiler/instruction.h" | 8 #include "src/compiler/instruction.h" |
9 #include "src/compiler/instruction-codes.h" | 9 #include "src/compiler/instruction-codes.h" |
10 #include "src/compiler/jump-threading.h" | 10 #include "src/compiler/jump-threading.h" |
(...skipping 67 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
78 current_ = NULL; | 78 current_ = NULL; |
79 rpo_number_ = RpoNumber::FromInt(rpo_number_.ToInt() + 1); | 79 rpo_number_ = RpoNumber::FromInt(rpo_number_.ToInt() + 1); |
80 } | 80 } |
81 InstructionOperand UseRpo(int num) { | 81 InstructionOperand UseRpo(int num) { |
82 return sequence_.AddImmediate(Constant(RpoNumber::FromInt(num))); | 82 return sequence_.AddImmediate(Constant(RpoNumber::FromInt(num))); |
83 } | 83 } |
84 void Start(bool deferred = false) { | 84 void Start(bool deferred = false) { |
85 if (current_ == NULL) { | 85 if (current_ == NULL) { |
86 current_ = new (main_zone()) | 86 current_ = new (main_zone()) |
87 InstructionBlock(main_zone(), rpo_number_, RpoNumber::Invalid(), | 87 InstructionBlock(main_zone(), rpo_number_, RpoNumber::Invalid(), |
88 RpoNumber::Invalid(), deferred); | 88 RpoNumber::Invalid(), deferred, false); |
89 blocks_.push_back(current_); | 89 blocks_.push_back(current_); |
90 sequence_.StartBlock(rpo_number_); | 90 sequence_.StartBlock(rpo_number_); |
91 } | 91 } |
92 } | 92 } |
93 void Defer() { | 93 void Defer() { |
94 CHECK(current_ == NULL); | 94 CHECK(current_ == NULL); |
95 Start(true); | 95 Start(true); |
96 } | 96 } |
97 void AddGapMove(int index, const InstructionOperand& from, | 97 void AddGapMove(int index, const InstructionOperand& from, |
98 const InstructionOperand& to) { | 98 const InstructionOperand& to) { |
(...skipping 658 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
757 for (int k = 4; k < 5; k++) assembly[k]--; | 757 for (int k = 4; k < 5; k++) assembly[k]--; |
758 } | 758 } |
759 CheckAssemblyOrder(code, 5, assembly); | 759 CheckAssemblyOrder(code, 5, assembly); |
760 } | 760 } |
761 } | 761 } |
762 } | 762 } |
763 | 763 |
764 } // namespace compiler | 764 } // namespace compiler |
765 } // namespace internal | 765 } // namespace internal |
766 } // namespace v8 | 766 } // namespace v8 |
OLD | NEW |