OLD | NEW |
1 // Copyright 2012 the V8 project authors. All rights reserved. | 1 // Copyright 2012 the V8 project authors. All rights reserved. |
2 // Redistribution and use in source and binary forms, with or without | 2 // Redistribution and use in source and binary forms, with or without |
3 // modification, are permitted provided that the following conditions are | 3 // modification, are permitted provided that the following conditions are |
4 // met: | 4 // met: |
5 // | 5 // |
6 // * Redistributions of source code must retain the above copyright | 6 // * Redistributions of source code must retain the above copyright |
7 // notice, this list of conditions and the following disclaimer. | 7 // notice, this list of conditions and the following disclaimer. |
8 // * Redistributions in binary form must reproduce the above | 8 // * Redistributions in binary form must reproduce the above |
9 // copyright notice, this list of conditions and the following | 9 // copyright notice, this list of conditions and the following |
10 // disclaimer in the documentation and/or other materials provided | 10 // disclaimer in the documentation and/or other materials provided |
(...skipping 2979 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
2990 | 2990 |
2991 MaybeObject* Heap::AllocateSharedFunctionInfo(Object* name) { | 2991 MaybeObject* Heap::AllocateSharedFunctionInfo(Object* name) { |
2992 SharedFunctionInfo* share; | 2992 SharedFunctionInfo* share; |
2993 MaybeObject* maybe = Allocate(shared_function_info_map(), OLD_POINTER_SPACE); | 2993 MaybeObject* maybe = Allocate(shared_function_info_map(), OLD_POINTER_SPACE); |
2994 if (!maybe->To<SharedFunctionInfo>(&share)) return maybe; | 2994 if (!maybe->To<SharedFunctionInfo>(&share)) return maybe; |
2995 | 2995 |
2996 // Set pointer fields. | 2996 // Set pointer fields. |
2997 share->set_name(name); | 2997 share->set_name(name); |
2998 Code* illegal = isolate_->builtins()->builtin(Builtins::kIllegal); | 2998 Code* illegal = isolate_->builtins()->builtin(Builtins::kIllegal); |
2999 share->set_code(illegal); | 2999 share->set_code(illegal); |
| 3000 share->set_optimized_code_map(Smi::FromInt(0)); |
3000 share->set_scope_info(ScopeInfo::Empty()); | 3001 share->set_scope_info(ScopeInfo::Empty()); |
3001 Code* construct_stub = | 3002 Code* construct_stub = |
3002 isolate_->builtins()->builtin(Builtins::kJSConstructStubGeneric); | 3003 isolate_->builtins()->builtin(Builtins::kJSConstructStubGeneric); |
3003 share->set_construct_stub(construct_stub); | 3004 share->set_construct_stub(construct_stub); |
3004 share->set_instance_class_name(Object_symbol()); | 3005 share->set_instance_class_name(Object_symbol()); |
3005 share->set_function_data(undefined_value(), SKIP_WRITE_BARRIER); | 3006 share->set_function_data(undefined_value(), SKIP_WRITE_BARRIER); |
3006 share->set_script(undefined_value(), SKIP_WRITE_BARRIER); | 3007 share->set_script(undefined_value(), SKIP_WRITE_BARRIER); |
3007 share->set_debug_info(undefined_value(), SKIP_WRITE_BARRIER); | 3008 share->set_debug_info(undefined_value(), SKIP_WRITE_BARRIER); |
3008 share->set_inferred_name(empty_string(), SKIP_WRITE_BARRIER); | 3009 share->set_inferred_name(empty_string(), SKIP_WRITE_BARRIER); |
3009 share->set_initial_map(undefined_value(), SKIP_WRITE_BARRIER); | 3010 share->set_initial_map(undefined_value(), SKIP_WRITE_BARRIER); |
(...skipping 4113 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7123 } else { | 7124 } else { |
7124 p ^= 0x1d1ed & (Page::kPageSize - 1); // I died. | 7125 p ^= 0x1d1ed & (Page::kPageSize - 1); // I died. |
7125 } | 7126 } |
7126 remembered_unmapped_pages_[remembered_unmapped_pages_index_] = | 7127 remembered_unmapped_pages_[remembered_unmapped_pages_index_] = |
7127 reinterpret_cast<Address>(p); | 7128 reinterpret_cast<Address>(p); |
7128 remembered_unmapped_pages_index_++; | 7129 remembered_unmapped_pages_index_++; |
7129 remembered_unmapped_pages_index_ %= kRememberedUnmappedPages; | 7130 remembered_unmapped_pages_index_ %= kRememberedUnmappedPages; |
7130 } | 7131 } |
7131 | 7132 |
7132 } } // namespace v8::internal | 7133 } } // namespace v8::internal |
OLD | NEW |