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

Side by Side Diff: src/isolate.cc

Issue 11818021: Allocation Info Tracking, continued. (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Rebase Created 7 years, 10 months 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 | Annotate | Revision Log
OLDNEW
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 2037 matching lines...) Expand 10 before | Expand all | Expand 10 after
2048 } 2048 }
2049 2049
2050 if (create_heap_objects) { 2050 if (create_heap_objects) {
2051 // Terminate the cache array with the sentinel so we can iterate. 2051 // Terminate the cache array with the sentinel so we can iterate.
2052 PushToPartialSnapshotCache(heap_.undefined_value()); 2052 PushToPartialSnapshotCache(heap_.undefined_value());
2053 } 2053 }
2054 2054
2055 InitializeThreadLocal(); 2055 InitializeThreadLocal();
2056 2056
2057 bootstrapper_->Initialize(create_heap_objects); 2057 bootstrapper_->Initialize(create_heap_objects);
2058
2059 deoptimizer_data_ = new DeoptimizerData;
2060
2058 builtins_.SetUp(create_heap_objects); 2061 builtins_.SetUp(create_heap_objects);
2059 2062
2060 // Only preallocate on the first initialization. 2063 // Only preallocate on the first initialization.
2061 if (FLAG_preallocate_message_memory && preallocated_message_space_ == NULL) { 2064 if (FLAG_preallocate_message_memory && preallocated_message_space_ == NULL) {
2062 // Start the thread which will set aside some memory. 2065 // Start the thread which will set aside some memory.
2063 PreallocatedMemoryThreadStart(); 2066 PreallocatedMemoryThreadStart();
2064 preallocated_message_space_ = 2067 preallocated_message_space_ =
2065 new NoAllocationStringAllocator( 2068 new NoAllocationStringAllocator(
2066 preallocated_memory_thread_->data(), 2069 preallocated_memory_thread_->data(),
2067 preallocated_memory_thread_->length()); 2070 preallocated_memory_thread_->length());
2068 PreallocatedStorageInit(preallocated_memory_thread_->length() / 4); 2071 PreallocatedStorageInit(preallocated_memory_thread_->length() / 4);
2069 } 2072 }
2070 2073
2071 if (FLAG_preemption) { 2074 if (FLAG_preemption) {
2072 v8::Locker locker(reinterpret_cast<v8::Isolate*>(this)); 2075 v8::Locker locker(reinterpret_cast<v8::Isolate*>(this));
2073 v8::Locker::StartPreemption(100); 2076 v8::Locker::StartPreemption(100);
2074 } 2077 }
2075 2078
2076 #ifdef ENABLE_DEBUGGER_SUPPORT 2079 #ifdef ENABLE_DEBUGGER_SUPPORT
2077 debug_->SetUp(create_heap_objects); 2080 debug_->SetUp(create_heap_objects);
2078 #endif 2081 #endif
2079 2082
2080 deoptimizer_data_ = new DeoptimizerData;
Toon Verwaest 2013/02/13 15:14:51 Why did you move this?
mvstanton 2013/02/19 11:04:08 Because the array constructor is a built-in, and n
2081
2082 // If we are deserializing, read the state into the now-empty heap. 2083 // If we are deserializing, read the state into the now-empty heap.
2083 if (!create_heap_objects) { 2084 if (!create_heap_objects) {
2084 des->Deserialize(); 2085 des->Deserialize();
2085 } 2086 }
2086 stub_cache_->Initialize(); 2087 stub_cache_->Initialize();
2087 2088
2088 // Finish initialization of ThreadLocal after deserialization is done. 2089 // Finish initialization of ThreadLocal after deserialization is done.
2089 clear_pending_exception(); 2090 clear_pending_exception();
2090 clear_pending_message(); 2091 clear_pending_message();
2091 clear_scheduled_exception(); 2092 clear_scheduled_exception();
(...skipping 188 matching lines...) Expand 10 before | Expand all | Expand 10 after
2280 2281
2281 #ifdef DEBUG 2282 #ifdef DEBUG
2282 #define ISOLATE_FIELD_OFFSET(type, name, ignored) \ 2283 #define ISOLATE_FIELD_OFFSET(type, name, ignored) \
2283 const intptr_t Isolate::name##_debug_offset_ = OFFSET_OF(Isolate, name##_); 2284 const intptr_t Isolate::name##_debug_offset_ = OFFSET_OF(Isolate, name##_);
2284 ISOLATE_INIT_LIST(ISOLATE_FIELD_OFFSET) 2285 ISOLATE_INIT_LIST(ISOLATE_FIELD_OFFSET)
2285 ISOLATE_INIT_ARRAY_LIST(ISOLATE_FIELD_OFFSET) 2286 ISOLATE_INIT_ARRAY_LIST(ISOLATE_FIELD_OFFSET)
2286 #undef ISOLATE_FIELD_OFFSET 2287 #undef ISOLATE_FIELD_OFFSET
2287 #endif 2288 #endif
2288 2289
2289 } } // namespace v8::internal 2290 } } // namespace v8::internal
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698