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 <limits> | 5 #include <limits> |
6 | 6 |
7 #include "src/compiler/change-lowering.h" | 7 #include "src/compiler/change-lowering.h" |
8 #include "src/compiler/control-builders.h" | 8 #include "src/compiler/control-builders.h" |
9 #include "src/compiler/generic-node-inl.h" | 9 #include "src/compiler/generic-node-inl.h" |
10 #include "src/compiler/js-graph.h" | 10 #include "src/compiler/js-graph.h" |
(...skipping 114 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
125 this->common()->Return(), this->Int32Constant(0), store, this->start()); | 125 this->common()->Return(), this->Int32Constant(0), store, this->start()); |
126 Node* end = this->graph()->NewNode(this->common()->End(), ret); | 126 Node* end = this->graph()->NewNode(this->common()->End(), ret); |
127 this->graph()->SetEnd(end); | 127 this->graph()->SetEnd(end); |
128 LowerChange(change); | 128 LowerChange(change); |
129 } | 129 } |
130 | 130 |
131 void BuildLoadAndLower(const Operator* op, const Operator* load_op, | 131 void BuildLoadAndLower(const Operator* op, const Operator* load_op, |
132 void* location) { | 132 void* location) { |
133 // We build a graph by hand here, because the raw machine assembler | 133 // We build a graph by hand here, because the raw machine assembler |
134 // does not add the correct control and effect nodes. | 134 // does not add the correct control and effect nodes. |
135 Node* load = | 135 Node* load = this->graph()->NewNode( |
136 this->graph()->NewNode(load_op, this->PointerConstant(location), | 136 load_op, this->PointerConstant(location), this->Int32Constant(0), |
137 this->Int32Constant(0), this->start()); | 137 this->start(), this->start()); |
138 Node* change = this->graph()->NewNode(op, load); | 138 Node* change = this->graph()->NewNode(op, load); |
139 Node* ret = this->graph()->NewNode(this->common()->Return(), change, | 139 Node* ret = this->graph()->NewNode(this->common()->Return(), change, |
140 this->start(), this->start()); | 140 this->start(), this->start()); |
141 Node* end = this->graph()->NewNode(this->common()->End(), ret); | 141 Node* end = this->graph()->NewNode(this->common()->End(), ret); |
142 this->graph()->SetEnd(end); | 142 this->graph()->SetEnd(end); |
143 LowerChange(change); | 143 LowerChange(change); |
144 } | 144 } |
145 | 145 |
146 void LowerChange(Node* change) { | 146 void LowerChange(Node* change) { |
147 // Run the graph reducer with changes lowering on a single node. | 147 // Run the graph reducer with changes lowering on a single node. |
(...skipping 256 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
404 | 404 |
405 input = *i; | 405 input = *i; |
406 Object* result = t.CallWithPotentialGC<Object>(); | 406 Object* result = t.CallWithPotentialGC<Object>(); |
407 t.CheckNumber(input, result); | 407 t.CheckNumber(input, result); |
408 } | 408 } |
409 } | 409 } |
410 } | 410 } |
411 } | 411 } |
412 | 412 |
413 #endif // V8_TURBOFAN_BACKEND | 413 #endif // V8_TURBOFAN_BACKEND |
OLD | NEW |