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 4347 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4358 MaybeObject* maybe_map = object_function->initial_map()->Copy(); | 4358 MaybeObject* maybe_map = object_function->initial_map()->Copy(); |
4359 if (!maybe_map->To(&new_map)) return maybe_map; | 4359 if (!maybe_map->To(&new_map)) return maybe_map; |
4360 } | 4360 } |
4361 | 4361 |
4362 Object* prototype; | 4362 Object* prototype; |
4363 MaybeObject* maybe_prototype = AllocateJSObjectFromMap(new_map); | 4363 MaybeObject* maybe_prototype = AllocateJSObjectFromMap(new_map); |
4364 if (!maybe_prototype->ToObject(&prototype)) return maybe_prototype; | 4364 if (!maybe_prototype->ToObject(&prototype)) return maybe_prototype; |
4365 | 4365 |
4366 if (!function->shared()->is_generator()) { | 4366 if (!function->shared()->is_generator()) { |
4367 MaybeObject* maybe_failure = | 4367 MaybeObject* maybe_failure = |
4368 JSObject::cast(prototype)->SetLocalPropertyIgnoreAttributes( | 4368 JSObject::cast(prototype)->SetLocalPropertyIgnoreAttributesTrampoline( |
4369 constructor_string(), function, DONT_ENUM); | 4369 constructor_string(), function, DONT_ENUM); |
4370 if (maybe_failure->IsFailure()) return maybe_failure; | 4370 if (maybe_failure->IsFailure()) return maybe_failure; |
4371 } | 4371 } |
4372 | 4372 |
4373 return prototype; | 4373 return prototype; |
4374 } | 4374 } |
4375 | 4375 |
4376 | 4376 |
4377 MaybeObject* Heap::AllocateFunction(Map* function_map, | 4377 MaybeObject* Heap::AllocateFunction(Map* function_map, |
4378 SharedFunctionInfo* shared, | 4378 SharedFunctionInfo* shared, |
(...skipping 3716 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
8095 if (FLAG_concurrent_recompilation) { | 8095 if (FLAG_concurrent_recompilation) { |
8096 heap_->relocation_mutex_->Lock(); | 8096 heap_->relocation_mutex_->Lock(); |
8097 #ifdef DEBUG | 8097 #ifdef DEBUG |
8098 heap_->relocation_mutex_locked_by_optimizer_thread_ = | 8098 heap_->relocation_mutex_locked_by_optimizer_thread_ = |
8099 heap_->isolate()->optimizing_compiler_thread()->IsOptimizerThread(); | 8099 heap_->isolate()->optimizing_compiler_thread()->IsOptimizerThread(); |
8100 #endif // DEBUG | 8100 #endif // DEBUG |
8101 } | 8101 } |
8102 } | 8102 } |
8103 | 8103 |
8104 } } // namespace v8::internal | 8104 } } // namespace v8::internal |
OLD | NEW |