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

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

Issue 1193313002: Vector ICs: Additional Turbofan support (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Created 5 years, 6 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
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-factory.h" 5 #include "src/code-factory.h"
6 #include "src/code-stubs.h" 6 #include "src/code-stubs.h"
7 #include "src/compiler/common-operator.h" 7 #include "src/compiler/common-operator.h"
8 #include "src/compiler/js-generic-lowering.h" 8 #include "src/compiler/js-generic-lowering.h"
9 #include "src/compiler/js-graph.h" 9 #include "src/compiler/js-graph.h"
10 #include "src/compiler/machine-operator.h" 10 #include "src/compiler/machine-operator.h"
(...skipping 316 matching lines...) Expand 10 before | Expand all | Expand 10 after
327 Callable callable = CodeFactory::LoadICInOptimizedCode( 327 Callable callable = CodeFactory::LoadICInOptimizedCode(
328 isolate(), p.contextual_mode(), UNINITIALIZED); 328 isolate(), p.contextual_mode(), UNINITIALIZED);
329 node->InsertInput(zone(), 1, jsgraph()->HeapConstant(p.name())); 329 node->InsertInput(zone(), 1, jsgraph()->HeapConstant(p.name()));
330 node->InsertInput(zone(), 2, jsgraph()->SmiConstant(p.feedback().index())); 330 node->InsertInput(zone(), 2, jsgraph()->SmiConstant(p.feedback().index()));
331 ReplaceWithStubCall(node, callable, flags); 331 ReplaceWithStubCall(node, callable, flags);
332 } 332 }
333 333
334 334
335 void JSGenericLowering::LowerJSStoreProperty(Node* node) { 335 void JSGenericLowering::LowerJSStoreProperty(Node* node) {
336 CallDescriptor::Flags flags = AdjustFrameStatesForCall(node); 336 CallDescriptor::Flags flags = AdjustFrameStatesForCall(node);
337 const StorePropertyParameters& p = StorePropertyParametersOf(node->op());
337 LanguageMode language_mode = OpParameter<LanguageMode>(node); 338 LanguageMode language_mode = OpParameter<LanguageMode>(node);
338 Callable callable = CodeFactory::KeyedStoreICInOptimizedCode( 339 Callable callable = CodeFactory::KeyedStoreICInOptimizedCode(
339 isolate(), language_mode, UNINITIALIZED); 340 isolate(), language_mode, UNINITIALIZED);
341 if (FLAG_vector_stores) {
342 DCHECK(p.feedback().index() != -1);
343 node->InsertInput(zone(), 3, jsgraph()->SmiConstant(p.feedback().index()));
344 }
340 ReplaceWithStubCall(node, callable, 345 ReplaceWithStubCall(node, callable,
341 CallDescriptor::kPatchableCallSite | flags); 346 CallDescriptor::kPatchableCallSite | flags);
342 } 347 }
343 348
344 349
345 void JSGenericLowering::LowerJSStoreNamed(Node* node) { 350 void JSGenericLowering::LowerJSStoreNamed(Node* node) {
346 CallDescriptor::Flags flags = AdjustFrameStatesForCall(node); 351 CallDescriptor::Flags flags = AdjustFrameStatesForCall(node);
347 const StoreNamedParameters& p = StoreNamedParametersOf(node->op()); 352 const StoreNamedParameters& p = StoreNamedParametersOf(node->op());
348 Callable callable = CodeFactory::StoreIC(isolate(), p.language_mode()); 353 Callable callable = CodeFactory::StoreIC(isolate(), p.language_mode());
349 node->InsertInput(zone(), 1, jsgraph()->HeapConstant(p.name())); 354 node->InsertInput(zone(), 1, jsgraph()->HeapConstant(p.name()));
355 if (FLAG_vector_stores) {
356 DCHECK(p.feedback().index() != -1);
357 node->InsertInput(zone(), 3, jsgraph()->SmiConstant(p.feedback().index()));
358 }
350 ReplaceWithStubCall(node, callable, 359 ReplaceWithStubCall(node, callable,
351 CallDescriptor::kPatchableCallSite | flags); 360 CallDescriptor::kPatchableCallSite | flags);
352 } 361 }
353 362
354 363
355 void JSGenericLowering::LowerJSDeleteProperty(Node* node) { 364 void JSGenericLowering::LowerJSDeleteProperty(Node* node) {
356 LanguageMode language_mode = OpParameter<LanguageMode>(node); 365 LanguageMode language_mode = OpParameter<LanguageMode>(node);
357 ReplaceWithBuiltinCall(node, Builtins::DELETE, 3); 366 ReplaceWithBuiltinCall(node, Builtins::DELETE, 3);
358 node->InsertInput(zone(), 4, jsgraph()->SmiConstant(language_mode)); 367 node->InsertInput(zone(), 4, jsgraph()->SmiConstant(language_mode));
359 } 368 }
(...skipping 410 matching lines...) Expand 10 before | Expand all | Expand 10 after
770 } 779 }
771 780
772 781
773 MachineOperatorBuilder* JSGenericLowering::machine() const { 782 MachineOperatorBuilder* JSGenericLowering::machine() const {
774 return jsgraph()->machine(); 783 return jsgraph()->machine();
775 } 784 }
776 785
777 } // namespace compiler 786 } // namespace compiler
778 } // namespace internal 787 } // namespace internal
779 } // namespace v8 788 } // namespace v8
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698