OLD | NEW |
1 // Copyright 2016 the V8 project authors. All rights reserved. | 1 // Copyright 2016 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/builtins/builtins-utils.h" | 5 #include "src/builtins/builtins-utils.h" |
6 #include "src/builtins/builtins.h" | 6 #include "src/builtins/builtins.h" |
7 #include "src/code-factory.h" | 7 #include "src/code-factory.h" |
8 #include "src/code-stub-assembler.h" | 8 #include "src/code-stub-assembler.h" |
9 #include "src/property-descriptor.h" | 9 #include "src/property-descriptor.h" |
10 | 10 |
(...skipping 1060 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1071 typedef CompareDescriptor Descriptor; | 1071 typedef CompareDescriptor Descriptor; |
1072 CodeStubAssembler assembler(state); | 1072 CodeStubAssembler assembler(state); |
1073 | 1073 |
1074 Node* constructor = assembler.Parameter(Descriptor::kLeft); | 1074 Node* constructor = assembler.Parameter(Descriptor::kLeft); |
1075 Node* object = assembler.Parameter(Descriptor::kRight); | 1075 Node* object = assembler.Parameter(Descriptor::kRight); |
1076 Node* context = assembler.Parameter(Descriptor::kContext); | 1076 Node* context = assembler.Parameter(Descriptor::kContext); |
1077 | 1077 |
1078 assembler.Return(assembler.OrdinaryHasInstance(context, constructor, object)); | 1078 assembler.Return(assembler.OrdinaryHasInstance(context, constructor, object)); |
1079 } | 1079 } |
1080 | 1080 |
| 1081 void Builtins::Generate_GetSuperConstructor( |
| 1082 compiler::CodeAssemblerState* state) { |
| 1083 typedef compiler::Node Node; |
| 1084 typedef TypeofDescriptor Descriptor; |
| 1085 CodeStubAssembler assembler(state); |
| 1086 |
| 1087 Node* object = assembler.Parameter(Descriptor::kObject); |
| 1088 Node* context = assembler.Parameter(Descriptor::kContext); |
| 1089 |
| 1090 assembler.Return(assembler.GetSuperConstructor(object, context)); |
| 1091 } |
| 1092 |
1081 } // namespace internal | 1093 } // namespace internal |
1082 } // namespace v8 | 1094 } // namespace v8 |
OLD | NEW |