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

Side by Side Diff: src/compiler/js-generic-lowering.cc

Issue 435393004: Carry along ContextualMode in JSLoadNamed operators. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 6 years, 4 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 | Annotate | Revision Log
« no previous file with comments | « src/compiler/ast-graph-builder.cc ('k') | src/compiler/js-operator.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 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/code-stubs.h" 5 #include "src/code-stubs.h"
6 #include "src/compiler/common-operator.h" 6 #include "src/compiler/common-operator.h"
7 #include "src/compiler/graph-inl.h" 7 #include "src/compiler/graph-inl.h"
8 #include "src/compiler/js-generic-lowering.h" 8 #include "src/compiler/js-generic-lowering.h"
9 #include "src/compiler/machine-operator.h" 9 #include "src/compiler/machine-operator.h"
10 #include "src/compiler/node-aux-data-inl.h" 10 #include "src/compiler/node-aux-data-inl.h"
(...skipping 411 matching lines...) Expand 10 before | Expand all | Expand 10 after
422 422
423 423
424 Node* JSGenericLowering::LowerJSLoadProperty(Node* node) { 424 Node* JSGenericLowering::LowerJSLoadProperty(Node* node) {
425 KeyedLoadICStubShim stub(isolate()); 425 KeyedLoadICStubShim stub(isolate());
426 ReplaceWithICStubCall(node, &stub); 426 ReplaceWithICStubCall(node, &stub);
427 return node; 427 return node;
428 } 428 }
429 429
430 430
431 Node* JSGenericLowering::LowerJSLoadNamed(Node* node) { 431 Node* JSGenericLowering::LowerJSLoadNamed(Node* node) {
432 PrintableUnique<Name> key = OpParameter<PrintableUnique<Name> >(node); 432 LoadNamedParameters p = OpParameter<LoadNamedParameters>(node);
433 // TODO(mstarzinger): The ContextualMode needs to be carried along in the 433 LoadICStubShim stub(isolate(), p.contextual_mode);
434 // operator to use JSLoadNamed for global variable loads. 434 PatchInsertInput(node, 1, jsgraph()->HeapConstant(p.name));
435 LoadICStubShim stub(isolate(), NOT_CONTEXTUAL);
436 PatchInsertInput(node, 1, jsgraph()->HeapConstant(key));
437 ReplaceWithICStubCall(node, &stub); 435 ReplaceWithICStubCall(node, &stub);
438 return node; 436 return node;
439 } 437 }
440 438
441 439
442 Node* JSGenericLowering::LowerJSStoreProperty(Node* node) { 440 Node* JSGenericLowering::LowerJSStoreProperty(Node* node) {
443 // TODO(mstarzinger): The strict_mode needs to be carried along in the 441 // TODO(mstarzinger): The strict_mode needs to be carried along in the
444 // operator so that graphs are fully compositional for inlining. 442 // operator so that graphs are fully compositional for inlining.
445 StrictMode strict_mode = info()->strict_mode(); 443 StrictMode strict_mode = info()->strict_mode();
446 KeyedStoreICStubShim stub(isolate(), strict_mode); 444 KeyedStoreICStubShim stub(isolate(), strict_mode);
(...skipping 109 matching lines...) Expand 10 before | Expand all | Expand 10 after
556 554
557 Node* JSGenericLowering::LowerJSCallRuntime(Node* node) { 555 Node* JSGenericLowering::LowerJSCallRuntime(Node* node) {
558 Runtime::FunctionId function = OpParameter<Runtime::FunctionId>(node); 556 Runtime::FunctionId function = OpParameter<Runtime::FunctionId>(node);
559 int arity = NodeProperties::GetValueInputCount(node); 557 int arity = NodeProperties::GetValueInputCount(node);
560 ReplaceWithRuntimeCall(node, function, arity); 558 ReplaceWithRuntimeCall(node, function, arity);
561 return node; 559 return node;
562 } 560 }
563 } 561 }
564 } 562 }
565 } // namespace v8::internal::compiler 563 } // namespace v8::internal::compiler
OLDNEW
« no previous file with comments | « src/compiler/ast-graph-builder.cc ('k') | src/compiler/js-operator.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698