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/builtins/builtins.h" | 5 #include "src/builtins/builtins.h" |
6 #include "src/code-events.h" | 6 #include "src/code-events.h" |
7 #include "src/code-stub-assembler.h" | 7 #include "src/code-stub-assembler.h" |
8 #include "src/code-stubs.h" | |
Benedikt Meurer
2016/10/05 05:41:30
This seems to be unnecessary now.
| |
8 #include "src/ic/ic-state.h" | 9 #include "src/ic/ic-state.h" |
9 #include "src/interface-descriptors.h" | 10 #include "src/interface-descriptors.h" |
10 #include "src/isolate.h" | 11 #include "src/isolate.h" |
11 #include "src/macro-assembler.h" | 12 #include "src/macro-assembler.h" |
12 #include "src/objects.h" | 13 #include "src/objects.h" |
13 | 14 |
14 namespace v8 { | 15 namespace v8 { |
15 namespace internal { | 16 namespace internal { |
16 | 17 |
17 // Forward declarations for C++ builtins. | 18 // Forward declarations for C++ builtins. |
(...skipping 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
102 // and this construction just queries the details from the descriptors table. | 103 // and this construction just queries the details from the descriptors table. |
103 CallInterfaceDescriptor descriptor(isolate, interface_descriptor); | 104 CallInterfaceDescriptor descriptor(isolate, interface_descriptor); |
104 // Ensure descriptor is already initialized. | 105 // Ensure descriptor is already initialized. |
105 DCHECK_LE(0, descriptor.GetRegisterParameterCount()); | 106 DCHECK_LE(0, descriptor.GetRegisterParameterCount()); |
106 CodeStubAssembler assembler(isolate, &zone, descriptor, flags, name); | 107 CodeStubAssembler assembler(isolate, &zone, descriptor, flags, name); |
107 generator(&assembler); | 108 generator(&assembler); |
108 Handle<Code> code = assembler.GenerateCode(); | 109 Handle<Code> code = assembler.GenerateCode(); |
109 PostBuildProfileAndTracing(isolate, *code, name); | 110 PostBuildProfileAndTracing(isolate, *code, name); |
110 return *code; | 111 return *code; |
111 } | 112 } |
113 | |
Benedikt Meurer
2016/10/05 05:41:30
Same here.
| |
112 } // anonymous namespace | 114 } // anonymous namespace |
113 | 115 |
114 void Builtins::SetUp(Isolate* isolate, bool create_heap_objects) { | 116 void Builtins::SetUp(Isolate* isolate, bool create_heap_objects) { |
115 DCHECK(!initialized_); | 117 DCHECK(!initialized_); |
116 | 118 |
117 // Create a scope for the handles in the builtins. | 119 // Create a scope for the handles in the builtins. |
118 HandleScope scope(isolate); | 120 HandleScope scope(isolate); |
119 | 121 |
120 if (create_heap_objects) { | 122 if (create_heap_objects) { |
121 int index = 0; | 123 int index = 0; |
(...skipping 164 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
286 // TODO(jochen): Remove this. | 288 // TODO(jochen): Remove this. |
287 if (responsible_context.is_null()) { | 289 if (responsible_context.is_null()) { |
288 return true; | 290 return true; |
289 } | 291 } |
290 if (*responsible_context == target->context()) return true; | 292 if (*responsible_context == target->context()) return true; |
291 return isolate->MayAccess(responsible_context, target_global_proxy); | 293 return isolate->MayAccess(responsible_context, target_global_proxy); |
292 } | 294 } |
293 | 295 |
294 } // namespace internal | 296 } // namespace internal |
295 } // namespace v8 | 297 } // namespace v8 |
OLD | NEW |