OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 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 | 6 |
7 #include <sstream> | 7 #include <sstream> |
8 | 8 |
9 #include "src/bootstrapper.h" | 9 #include "src/bootstrapper.h" |
10 #include "src/code-factory.h" | 10 #include "src/code-factory.h" |
(...skipping 428 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
439 Node* slot = assembler->Parameter(2); | 439 Node* slot = assembler->Parameter(2); |
440 Node* vector = assembler->Parameter(3); | 440 Node* vector = assembler->Parameter(3); |
441 Node* context = assembler->Parameter(4); | 441 Node* context = assembler->Parameter(4); |
442 | 442 |
443 CodeStubAssembler::LoadICParameters p(context, receiver, name, slot, vector); | 443 CodeStubAssembler::LoadICParameters p(context, receiver, name, slot, vector); |
444 assembler->LoadIC(&p); | 444 assembler->LoadIC(&p); |
445 } | 445 } |
446 | 446 |
447 void LoadGlobalICTrampolineStub::GenerateAssembly( | 447 void LoadGlobalICTrampolineStub::GenerateAssembly( |
448 CodeStubAssembler* assembler) const { | 448 CodeStubAssembler* assembler) const { |
449 if (!FLAG_new_load_global_ic) { | |
450 return LoadICTrampolineTFStub::GenerateAssembly(assembler); | |
451 } | |
452 typedef compiler::Node Node; | 449 typedef compiler::Node Node; |
453 | 450 |
454 Node* name = assembler->Parameter(0); | 451 Node* name = assembler->Parameter(0); |
455 Node* slot = assembler->Parameter(1); | 452 Node* slot = assembler->Parameter(1); |
456 Node* context = assembler->Parameter(2); | 453 Node* context = assembler->Parameter(2); |
457 Node* vector = assembler->LoadTypeFeedbackVectorForStub(); | 454 Node* vector = assembler->LoadTypeFeedbackVectorForStub(); |
458 | 455 |
459 CodeStubAssembler::LoadICParameters p(context, nullptr, name, slot, vector); | 456 CodeStubAssembler::LoadICParameters p(context, nullptr, name, slot, vector); |
460 assembler->LoadGlobalIC(&p); | 457 assembler->LoadGlobalIC(&p); |
461 } | 458 } |
462 | 459 |
463 void LoadGlobalICStub::GenerateAssembly(CodeStubAssembler* assembler) const { | 460 void LoadGlobalICStub::GenerateAssembly(CodeStubAssembler* assembler) const { |
464 if (!FLAG_new_load_global_ic) { | |
465 return LoadICTFStub::GenerateAssembly(assembler); | |
466 } | |
467 typedef compiler::Node Node; | 461 typedef compiler::Node Node; |
468 | 462 |
469 Node* name = assembler->Parameter(0); | 463 Node* name = assembler->Parameter(0); |
470 Node* slot = assembler->Parameter(1); | 464 Node* slot = assembler->Parameter(1); |
471 Node* vector = assembler->Parameter(2); | 465 Node* vector = assembler->Parameter(2); |
472 Node* context = assembler->Parameter(3); | 466 Node* context = assembler->Parameter(3); |
473 | 467 |
474 CodeStubAssembler::LoadICParameters p(context, nullptr, name, slot, vector); | 468 CodeStubAssembler::LoadICParameters p(context, nullptr, name, slot, vector); |
475 assembler->LoadGlobalIC(&p); | 469 assembler->LoadGlobalIC(&p); |
476 } | 470 } |
(...skipping 4259 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4736 if (type->Is(Type::UntaggedPointer())) { | 4730 if (type->Is(Type::UntaggedPointer())) { |
4737 return Representation::External(); | 4731 return Representation::External(); |
4738 } | 4732 } |
4739 | 4733 |
4740 DCHECK(!type->Is(Type::Untagged())); | 4734 DCHECK(!type->Is(Type::Untagged())); |
4741 return Representation::Tagged(); | 4735 return Representation::Tagged(); |
4742 } | 4736 } |
4743 | 4737 |
4744 } // namespace internal | 4738 } // namespace internal |
4745 } // namespace v8 | 4739 } // namespace v8 |
OLD | NEW |