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

Side by Side Diff: src/factory.cc

Issue 1384673002: The metadata part of TypeFeedbackVector is extracted to TypeFeedbackMetadata array. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: Cleanup Created 5 years, 2 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
« no previous file with comments | « src/compiler.cc ('k') | src/heap/heap.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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/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 2120 matching lines...) Expand 10 before | Expand all | Expand 10 after
2131 share->set_scope_info(ScopeInfo::Empty(isolate())); 2131 share->set_scope_info(ScopeInfo::Empty(isolate()));
2132 Code* construct_stub = 2132 Code* construct_stub =
2133 isolate()->builtins()->builtin(Builtins::kJSConstructStubGeneric); 2133 isolate()->builtins()->builtin(Builtins::kJSConstructStubGeneric);
2134 share->set_construct_stub(construct_stub); 2134 share->set_construct_stub(construct_stub);
2135 share->set_instance_class_name(*Object_string()); 2135 share->set_instance_class_name(*Object_string());
2136 share->set_function_data(*undefined_value(), SKIP_WRITE_BARRIER); 2136 share->set_function_data(*undefined_value(), SKIP_WRITE_BARRIER);
2137 share->set_script(*undefined_value(), SKIP_WRITE_BARRIER); 2137 share->set_script(*undefined_value(), SKIP_WRITE_BARRIER);
2138 share->set_debug_info(*undefined_value(), SKIP_WRITE_BARRIER); 2138 share->set_debug_info(*undefined_value(), SKIP_WRITE_BARRIER);
2139 share->set_inferred_name(*empty_string(), SKIP_WRITE_BARRIER); 2139 share->set_inferred_name(*empty_string(), SKIP_WRITE_BARRIER);
2140 StaticFeedbackVectorSpec empty_spec; 2140 StaticFeedbackVectorSpec empty_spec;
2141 Handle<TypeFeedbackMetadata> feedback_metadata =
2142 TypeFeedbackMetadata::New(isolate(), &empty_spec);
2141 Handle<TypeFeedbackVector> feedback_vector = 2143 Handle<TypeFeedbackVector> feedback_vector =
2142 TypeFeedbackVector::New(isolate(), &empty_spec); 2144 TypeFeedbackVector::New(isolate(), feedback_metadata);
2143 share->set_feedback_vector(*feedback_vector, SKIP_WRITE_BARRIER); 2145 share->set_feedback_vector(*feedback_vector, SKIP_WRITE_BARRIER);
2144 #if TRACE_MAPS 2146 #if TRACE_MAPS
2145 share->set_unique_id(isolate()->GetNextUniqueSharedFunctionInfoId()); 2147 share->set_unique_id(isolate()->GetNextUniqueSharedFunctionInfoId());
2146 #endif 2148 #endif
2147 share->set_profiler_ticks(0); 2149 share->set_profiler_ticks(0);
2148 share->set_ast_node_count(0); 2150 share->set_ast_node_count(0);
2149 share->set_counters(0); 2151 share->set_counters(0);
2150 2152
2151 // Set integer fields (smi or int, depending on the architecture). 2153 // Set integer fields (smi or int, depending on the architecture).
2152 share->set_length(0); 2154 share->set_length(0);
(...skipping 230 matching lines...) Expand 10 before | Expand all | Expand 10 after
2383 } 2385 }
2384 2386
2385 2387
2386 Handle<Object> Factory::ToBoolean(bool value) { 2388 Handle<Object> Factory::ToBoolean(bool value) {
2387 return value ? true_value() : false_value(); 2389 return value ? true_value() : false_value();
2388 } 2390 }
2389 2391
2390 2392
2391 } // namespace internal 2393 } // namespace internal
2392 } // namespace v8 2394 } // namespace v8
OLDNEW
« no previous file with comments | « src/compiler.cc ('k') | src/heap/heap.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698