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

Side by Side Diff: src/factory.cc

Issue 1410223007: Add non-script SharedFunctionInfos to the Iterator. (Closed) Base URL: https://chromium.googlesource.com/v8/v8.git@master
Patch Set: REBASE. Created 5 years, 1 month 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 | « no previous file | src/heap/heap.h » ('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 2143 matching lines...) Expand 10 before | Expand all | Expand 10 after
2154 share->set_internal_formal_parameter_count(0); 2154 share->set_internal_formal_parameter_count(0);
2155 share->set_expected_nof_properties(0); 2155 share->set_expected_nof_properties(0);
2156 share->set_num_literals(0); 2156 share->set_num_literals(0);
2157 share->set_start_position_and_type(0); 2157 share->set_start_position_and_type(0);
2158 share->set_end_position(0); 2158 share->set_end_position(0);
2159 share->set_function_token_position(0); 2159 share->set_function_token_position(0);
2160 // All compiler hints default to false or 0. 2160 // All compiler hints default to false or 0.
2161 share->set_compiler_hints(0); 2161 share->set_compiler_hints(0);
2162 share->set_opt_count_and_bailout_reason(0); 2162 share->set_opt_count_and_bailout_reason(0);
2163 2163
2164 // Link into the list.
2165 Handle<Object> new_noscript_list =
2166 WeakFixedArray::Add(noscript_shared_function_infos(), share);
2167 isolate()->heap()->set_noscript_shared_function_infos(*new_noscript_list);
2168
2164 return share; 2169 return share;
2165 } 2170 }
2166 2171
2167 2172
2168 static inline int NumberCacheHash(Handle<FixedArray> cache, 2173 static inline int NumberCacheHash(Handle<FixedArray> cache,
2169 Handle<Object> number) { 2174 Handle<Object> number) {
2170 int mask = (cache->length() >> 1) - 1; 2175 int mask = (cache->length() >> 1) - 1;
2171 if (number->IsSmi()) { 2176 if (number->IsSmi()) {
2172 return Handle<Smi>::cast(number)->value() & mask; 2177 return Handle<Smi>::cast(number)->value() & mask;
2173 } else { 2178 } else {
(...skipping 210 matching lines...) Expand 10 before | Expand all | Expand 10 after
2384 } 2389 }
2385 2390
2386 2391
2387 Handle<Object> Factory::ToBoolean(bool value) { 2392 Handle<Object> Factory::ToBoolean(bool value) {
2388 return value ? true_value() : false_value(); 2393 return value ? true_value() : false_value();
2389 } 2394 }
2390 2395
2391 2396
2392 } // namespace internal 2397 } // namespace internal
2393 } // namespace v8 2398 } // namespace v8
OLDNEW
« no previous file with comments | « no previous file | src/heap/heap.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698