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

Side by Side Diff: src/compiler/node-properties.cc

Issue 2384113002: [turbofan] Osr value typing + dynamic type checks on entry. (Closed)
Patch Set: Fix liveness block Created 4 years, 2 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-frame-specialization.cc ('k') | src/compiler/opcodes.h » ('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 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/common-operator.h" 5 #include "src/compiler/common-operator.h"
6 #include "src/compiler/graph.h" 6 #include "src/compiler/graph.h"
7 #include "src/compiler/js-operator.h" 7 #include "src/compiler/js-operator.h"
8 #include "src/compiler/linkage.h" 8 #include "src/compiler/linkage.h"
9 #include "src/compiler/node-properties.h" 9 #include "src/compiler/node-properties.h"
10 #include "src/compiler/operator-properties.h" 10 #include "src/compiler/operator-properties.h"
(...skipping 351 matching lines...) Expand 10 before | Expand all | Expand 10 after
362 node = NodeProperties::GetContextInput(node); 362 node = NodeProperties::GetContextInput(node);
363 break; 363 break;
364 } 364 }
365 case IrOpcode::kHeapConstant: { 365 case IrOpcode::kHeapConstant: {
366 // Extract the native context from the actual {context}. 366 // Extract the native context from the actual {context}.
367 Handle<Context> context = 367 Handle<Context> context =
368 Handle<Context>::cast(OpParameter<Handle<HeapObject>>(node)); 368 Handle<Context>::cast(OpParameter<Handle<HeapObject>>(node));
369 return handle(context->native_context()); 369 return handle(context->native_context());
370 } 370 }
371 case IrOpcode::kOsrValue: { 371 case IrOpcode::kOsrValue: {
372 int const index = OpParameter<int>(node); 372 int const index = OsrValueIndexOf(node->op());
373 if (index == Linkage::kOsrContextSpillSlotIndex) { 373 if (index == Linkage::kOsrContextSpillSlotIndex) {
374 return native_context; 374 return native_context;
375 } 375 }
376 return MaybeHandle<Context>(); 376 return MaybeHandle<Context>();
377 } 377 }
378 case IrOpcode::kParameter: { 378 case IrOpcode::kParameter: {
379 Node* const start = NodeProperties::GetValueInput(node, 0); 379 Node* const start = NodeProperties::GetValueInput(node, 0);
380 DCHECK_EQ(IrOpcode::kStart, start->opcode()); 380 DCHECK_EQ(IrOpcode::kStart, start->opcode());
381 int const index = ParameterIndexOf(node->op()); 381 int const index = ParameterIndexOf(node->op());
382 // The context is always the last parameter to a JavaScript function, 382 // The context is always the last parameter to a JavaScript function,
(...skipping 41 matching lines...) Expand 10 before | Expand all | Expand 10 after
424 // static 424 // static
425 bool NodeProperties::IsInputRange(Edge edge, int first, int num) { 425 bool NodeProperties::IsInputRange(Edge edge, int first, int num) {
426 if (num == 0) return false; 426 if (num == 0) return false;
427 int const index = edge.index(); 427 int const index = edge.index();
428 return first <= index && index < first + num; 428 return first <= index && index < first + num;
429 } 429 }
430 430
431 } // namespace compiler 431 } // namespace compiler
432 } // namespace internal 432 } // namespace internal
433 } // namespace v8 433 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler/js-frame-specialization.cc ('k') | src/compiler/opcodes.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698