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

Side by Side Diff: src/compiler/js-inlining.cc

Issue 1314473007: [turbofan] Remove usage of Unique<T> from graph. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Rebased and fixed. Created 5 years, 3 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 | « src/compiler/js-graph.cc ('k') | src/compiler/js-intrinsic-lowering.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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/compiler/js-inlining.h" 5 #include "src/compiler/js-inlining.h"
6 6
7 #include "src/ast.h" 7 #include "src/ast.h"
8 #include "src/ast-numbering.h" 8 #include "src/ast-numbering.h"
9 #include "src/compiler/all-nodes.h" 9 #include "src/compiler/all-nodes.h"
10 #include "src/compiler/ast-graph-builder.h" 10 #include "src/compiler/ast-graph-builder.h"
(...skipping 225 matching lines...) Expand 10 before | Expand all | Expand 10 after
236 } 236 }
237 237
238 238
239 Reduction JSInliner::Reduce(Node* node) { 239 Reduction JSInliner::Reduce(Node* node) {
240 if (node->opcode() != IrOpcode::kJSCallFunction) return NoChange(); 240 if (node->opcode() != IrOpcode::kJSCallFunction) return NoChange();
241 241
242 JSCallFunctionAccessor call(node); 242 JSCallFunctionAccessor call(node);
243 HeapObjectMatcher match(call.jsfunction()); 243 HeapObjectMatcher match(call.jsfunction());
244 if (!match.HasValue()) return NoChange(); 244 if (!match.HasValue()) return NoChange();
245 245
246 if (!match.Value().handle()->IsJSFunction()) return NoChange(); 246 if (!match.Value()->IsJSFunction()) return NoChange();
247 Handle<JSFunction> function = 247 Handle<JSFunction> function = Handle<JSFunction>::cast(match.Value());
248 Handle<JSFunction>::cast(match.Value().handle());
249 if (mode_ == kRestrictedInlining && !function->shared()->force_inline()) { 248 if (mode_ == kRestrictedInlining && !function->shared()->force_inline()) {
250 return NoChange(); 249 return NoChange();
251 } 250 }
252 251
253 if (function->shared()->HasDebugInfo()) { 252 if (function->shared()->HasDebugInfo()) {
254 // Function contains break points. 253 // Function contains break points.
255 TRACE("Not inlining %s into %s because callee may contain break points\n", 254 TRACE("Not inlining %s into %s because callee may contain break points\n",
256 function->shared()->DebugName()->ToCString().get(), 255 function->shared()->DebugName()->ToCString().get(),
257 info_->shared_info()->DebugName()->ToCString().get()); 256 info_->shared_info()->DebugName()->ToCString().get());
258 return NoChange(); 257 return NoChange();
(...skipping 86 matching lines...) Expand 10 before | Expand all | Expand 10 after
345 344
346 // Remember that we inlined this function. 345 // Remember that we inlined this function.
347 info_->AddInlinedFunction(info.shared_info()); 346 info_->AddInlinedFunction(info.shared_info());
348 347
349 return InlineCall(node, context, frame_state, start, end); 348 return InlineCall(node, context, frame_state, start, end);
350 } 349 }
351 350
352 } // namespace compiler 351 } // namespace compiler
353 } // namespace internal 352 } // namespace internal
354 } // namespace v8 353 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/js-graph.cc ('k') | src/compiler/js-intrinsic-lowering.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698