| 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/conversions.h" | 9 #include "src/conversions.h" |
| 10 #include "src/isolate-inl.h" | 10 #include "src/isolate-inl.h" |
| (...skipping 784 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 795 isolate()->heap()->AllocateStruct(type), | 795 isolate()->heap()->AllocateStruct(type), |
| 796 Struct); | 796 Struct); |
| 797 } | 797 } |
| 798 | 798 |
| 799 | 799 |
| 800 Handle<CodeCache> Factory::NewCodeCache() { | 800 Handle<CodeCache> Factory::NewCodeCache() { |
| 801 Handle<CodeCache> code_cache = | 801 Handle<CodeCache> code_cache = |
| 802 Handle<CodeCache>::cast(NewStruct(CODE_CACHE_TYPE)); | 802 Handle<CodeCache>::cast(NewStruct(CODE_CACHE_TYPE)); |
| 803 code_cache->set_default_cache(*empty_fixed_array(), SKIP_WRITE_BARRIER); | 803 code_cache->set_default_cache(*empty_fixed_array(), SKIP_WRITE_BARRIER); |
| 804 code_cache->set_normal_type_cache(*undefined_value(), SKIP_WRITE_BARRIER); | 804 code_cache->set_normal_type_cache(*undefined_value(), SKIP_WRITE_BARRIER); |
| 805 code_cache->set_weak_cell_cache(*undefined_value(), SKIP_WRITE_BARRIER); |
| 805 return code_cache; | 806 return code_cache; |
| 806 } | 807 } |
| 807 | 808 |
| 808 | 809 |
| 809 Handle<AliasedArgumentsEntry> Factory::NewAliasedArgumentsEntry( | 810 Handle<AliasedArgumentsEntry> Factory::NewAliasedArgumentsEntry( |
| 810 int aliased_context_slot) { | 811 int aliased_context_slot) { |
| 811 Handle<AliasedArgumentsEntry> entry = Handle<AliasedArgumentsEntry>::cast( | 812 Handle<AliasedArgumentsEntry> entry = Handle<AliasedArgumentsEntry>::cast( |
| 812 NewStruct(ALIASED_ARGUMENTS_ENTRY_TYPE)); | 813 NewStruct(ALIASED_ARGUMENTS_ENTRY_TYPE)); |
| 813 entry->set_aliased_context_slot(aliased_context_slot); | 814 entry->set_aliased_context_slot(aliased_context_slot); |
| 814 return entry; | 815 return entry; |
| (...skipping 1705 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 2520 return Handle<Object>::null(); | 2521 return Handle<Object>::null(); |
| 2521 } | 2522 } |
| 2522 | 2523 |
| 2523 | 2524 |
| 2524 Handle<Object> Factory::ToBoolean(bool value) { | 2525 Handle<Object> Factory::ToBoolean(bool value) { |
| 2525 return value ? true_value() : false_value(); | 2526 return value ? true_value() : false_value(); |
| 2526 } | 2527 } |
| 2527 | 2528 |
| 2528 | 2529 |
| 2529 } } // namespace v8::internal | 2530 } } // namespace v8::internal |
| OLD | NEW |