OLD | NEW |
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/factory.h" | 5 #include "src/factory.h" |
6 | 6 |
7 #include "src/allocation-site-scopes.h" | 7 #include "src/allocation-site-scopes.h" |
8 #include "src/base/bits.h" | 8 #include "src/base/bits.h" |
9 #include "src/bootstrapper.h" | 9 #include "src/bootstrapper.h" |
10 #include "src/conversions.h" | 10 #include "src/conversions.h" |
(...skipping 2089 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2100 share->set_optimized_code_map(*cleared_optimized_code_map()); | 2100 share->set_optimized_code_map(*cleared_optimized_code_map()); |
2101 share->set_scope_info(ScopeInfo::Empty(isolate())); | 2101 share->set_scope_info(ScopeInfo::Empty(isolate())); |
2102 Handle<Code> construct_stub = | 2102 Handle<Code> construct_stub = |
2103 is_constructor ? isolate()->builtins()->JSConstructStubGeneric() | 2103 is_constructor ? isolate()->builtins()->JSConstructStubGeneric() |
2104 : isolate()->builtins()->ConstructedNonConstructable(); | 2104 : isolate()->builtins()->ConstructedNonConstructable(); |
2105 share->set_construct_stub(*construct_stub); | 2105 share->set_construct_stub(*construct_stub); |
2106 share->set_instance_class_name(*Object_string()); | 2106 share->set_instance_class_name(*Object_string()); |
2107 share->set_function_data(*undefined_value(), SKIP_WRITE_BARRIER); | 2107 share->set_function_data(*undefined_value(), SKIP_WRITE_BARRIER); |
2108 share->set_script(*undefined_value(), SKIP_WRITE_BARRIER); | 2108 share->set_script(*undefined_value(), SKIP_WRITE_BARRIER); |
2109 share->set_debug_info(DebugInfo::uninitialized(), SKIP_WRITE_BARRIER); | 2109 share->set_debug_info(DebugInfo::uninitialized(), SKIP_WRITE_BARRIER); |
2110 share->set_inferred_name(*empty_string(), SKIP_WRITE_BARRIER); | 2110 share->set_function_identifier(*undefined_value(), SKIP_WRITE_BARRIER); |
2111 StaticFeedbackVectorSpec empty_spec; | 2111 StaticFeedbackVectorSpec empty_spec; |
2112 Handle<TypeFeedbackMetadata> feedback_metadata = | 2112 Handle<TypeFeedbackMetadata> feedback_metadata = |
2113 TypeFeedbackMetadata::New(isolate(), &empty_spec); | 2113 TypeFeedbackMetadata::New(isolate(), &empty_spec); |
2114 Handle<TypeFeedbackVector> feedback_vector = | 2114 Handle<TypeFeedbackVector> feedback_vector = |
2115 TypeFeedbackVector::New(isolate(), feedback_metadata); | 2115 TypeFeedbackVector::New(isolate(), feedback_metadata); |
2116 share->set_feedback_vector(*feedback_vector, SKIP_WRITE_BARRIER); | 2116 share->set_feedback_vector(*feedback_vector, SKIP_WRITE_BARRIER); |
2117 #if TRACE_MAPS | 2117 #if TRACE_MAPS |
2118 share->set_unique_id(isolate()->GetNextUniqueSharedFunctionInfoId()); | 2118 share->set_unique_id(isolate()->GetNextUniqueSharedFunctionInfoId()); |
2119 #endif | 2119 #endif |
2120 share->set_profiler_ticks(0); | 2120 share->set_profiler_ticks(0); |
(...skipping 237 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2358 } | 2358 } |
2359 | 2359 |
2360 | 2360 |
2361 Handle<Object> Factory::ToBoolean(bool value) { | 2361 Handle<Object> Factory::ToBoolean(bool value) { |
2362 return value ? true_value() : false_value(); | 2362 return value ? true_value() : false_value(); |
2363 } | 2363 } |
2364 | 2364 |
2365 | 2365 |
2366 } // namespace internal | 2366 } // namespace internal |
2367 } // namespace v8 | 2367 } // namespace v8 |
OLD | NEW |