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 3273 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
3284 | 3284 |
3285 MaybeObject* Heap::AllocateSharedFunctionInfo(Object* name) { | 3285 MaybeObject* Heap::AllocateSharedFunctionInfo(Object* name) { |
3286 SharedFunctionInfo* share; | 3286 SharedFunctionInfo* share; |
3287 MaybeObject* maybe = Allocate(shared_function_info_map(), OLD_POINTER_SPACE); | 3287 MaybeObject* maybe = Allocate(shared_function_info_map(), OLD_POINTER_SPACE); |
3288 if (!maybe->To<SharedFunctionInfo>(&share)) return maybe; | 3288 if (!maybe->To<SharedFunctionInfo>(&share)) return maybe; |
3289 | 3289 |
3290 // Set pointer fields. | 3290 // Set pointer fields. |
3291 share->set_name(name); | 3291 share->set_name(name); |
3292 Code* illegal = isolate_->builtins()->builtin(Builtins::kIllegal); | 3292 Code* illegal = isolate_->builtins()->builtin(Builtins::kIllegal); |
3293 share->set_code(illegal); | 3293 share->set_code(illegal); |
3294 share->ClearOptimizedCodeMap(); | 3294 share->set_optimized_code_map(Smi::FromInt(0)); |
3295 share->set_scope_info(ScopeInfo::Empty(isolate_)); | 3295 share->set_scope_info(ScopeInfo::Empty(isolate_)); |
3296 Code* construct_stub = | 3296 Code* construct_stub = |
3297 isolate_->builtins()->builtin(Builtins::kJSConstructStubGeneric); | 3297 isolate_->builtins()->builtin(Builtins::kJSConstructStubGeneric); |
3298 share->set_construct_stub(construct_stub); | 3298 share->set_construct_stub(construct_stub); |
3299 share->set_instance_class_name(Object_string()); | 3299 share->set_instance_class_name(Object_string()); |
3300 share->set_function_data(undefined_value(), SKIP_WRITE_BARRIER); | 3300 share->set_function_data(undefined_value(), SKIP_WRITE_BARRIER); |
3301 share->set_script(undefined_value(), SKIP_WRITE_BARRIER); | 3301 share->set_script(undefined_value(), SKIP_WRITE_BARRIER); |
3302 share->set_debug_info(undefined_value(), SKIP_WRITE_BARRIER); | 3302 share->set_debug_info(undefined_value(), SKIP_WRITE_BARRIER); |
3303 share->set_inferred_name(empty_string(), SKIP_WRITE_BARRIER); | 3303 share->set_inferred_name(empty_string(), SKIP_WRITE_BARRIER); |
3304 share->set_initial_map(undefined_value(), SKIP_WRITE_BARRIER); | 3304 share->set_initial_map(undefined_value(), SKIP_WRITE_BARRIER); |
(...skipping 4578 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
7883 if (FLAG_parallel_recompilation) { | 7883 if (FLAG_parallel_recompilation) { |
7884 heap_->relocation_mutex_->Lock(); | 7884 heap_->relocation_mutex_->Lock(); |
7885 #ifdef DEBUG | 7885 #ifdef DEBUG |
7886 heap_->relocation_mutex_locked_by_optimizer_thread_ = | 7886 heap_->relocation_mutex_locked_by_optimizer_thread_ = |
7887 heap_->isolate()->optimizing_compiler_thread()->IsOptimizerThread(); | 7887 heap_->isolate()->optimizing_compiler_thread()->IsOptimizerThread(); |
7888 #endif // DEBUG | 7888 #endif // DEBUG |
7889 } | 7889 } |
7890 } | 7890 } |
7891 | 7891 |
7892 } } // namespace v8::internal | 7892 } } // namespace v8::internal |
OLD | NEW |