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

Side by Side Diff: src/compiler/escape-analysis-reducer.cc

Issue 1581183004: [turbofan] Fix bug in object state generation of escape analysis. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 4 years, 11 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2015 the V8 project authors. All rights reserved. 1 // Copyright 2015 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/compiler/escape-analysis-reducer.h" 5 #include "src/compiler/escape-analysis-reducer.h"
6 6
7 #include "src/compiler/js-graph.h" 7 #include "src/compiler/js-graph.h"
8 #include "src/counters.h" 8 #include "src/counters.h"
9 9
10 namespace v8 { 10 namespace v8 {
(...skipping 228 matching lines...) Expand 10 before | Expand all | Expand 10 after
239 // Returns the clone if it duplicated the node, and null otherwise. 239 // Returns the clone if it duplicated the node, and null otherwise.
240 Node* EscapeAnalysisReducer::ReduceStateValueInputs(Node* node, Node* effect, 240 Node* EscapeAnalysisReducer::ReduceStateValueInputs(Node* node, Node* effect,
241 bool multiple_users) { 241 bool multiple_users) {
242 if (FLAG_trace_turbo_escape) { 242 if (FLAG_trace_turbo_escape) {
243 PrintF("Reducing StateValue #%d\n", node->id()); 243 PrintF("Reducing StateValue #%d\n", node->id());
244 } 244 }
245 DCHECK(node->opcode() == IrOpcode::kStateValues); 245 DCHECK(node->opcode() == IrOpcode::kStateValues);
246 DCHECK_NOT_NULL(effect); 246 DCHECK_NOT_NULL(effect);
247 Node* clone = nullptr; 247 Node* clone = nullptr;
248 for (int i = 0; i < node->op()->ValueInputCount(); ++i) { 248 for (int i = 0; i < node->op()->ValueInputCount(); ++i) {
249 if (Node* ret = ReduceStateValueInput(node, i, effect, multiple_users)) { 249 Node* input = NodeProperties::GetValueInput(node, i);
250 Node* ret = nullptr;
251 if (input->opcode() == IrOpcode::kStateValues) {
252 ret = ReduceStateValueInputs(input, effect, multiple_users);
253 } else {
254 ret = ReduceStateValueInput(node, i, effect, multiple_users);
255 }
256 if (ret) {
250 node = ret; 257 node = ret;
251 DCHECK_NULL(clone); 258 DCHECK_NULL(clone);
252 clone = ret; 259 clone = ret;
253 multiple_users = false; 260 multiple_users = false;
254 } 261 }
255 } 262 }
256 return clone; 263 return clone;
257 } 264 }
258 265
259 266
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
297 } 304 }
298 305
299 306
300 Counters* EscapeAnalysisReducer::counters() const { 307 Counters* EscapeAnalysisReducer::counters() const {
301 return jsgraph_->isolate()->counters(); 308 return jsgraph_->isolate()->counters();
302 } 309 }
303 310
304 } // namespace compiler 311 } // namespace compiler
305 } // namespace internal 312 } // namespace internal
306 } // namespace v8 313 } // namespace v8
OLDNEW
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698