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

Unified Diff: src/libplatform/default-platform.h

Issue 98123004: Lazily initialize thread pool to avoid allocating all the threads during startup (Closed) Base URL: https://v8.googlecode.com/svn/branches/bleeding_edge
Patch Set: Created 7 years 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | src/libplatform/default-platform.cc » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: src/libplatform/default-platform.h
diff --git a/src/libplatform/default-platform.h b/src/libplatform/default-platform.h
index 72e8869992ffb7f40ce7a206aab9e6712daf3334..877b3a63e7b23e5882face165b5f393e27867800 100644
--- a/src/libplatform/default-platform.h
+++ b/src/libplatform/default-platform.h
@@ -59,8 +59,11 @@ class DefaultPlatform : public Platform {
private:
static const int kMaxThreadPoolSize = 4;
+ void EnsureInitialized();
+
Mutex lock_;
bool initialized_;
+ int thread_pool_size_;
std::vector<WorkerThread*> thread_pool_;
TaskQueue queue_;
« no previous file with comments | « no previous file | src/libplatform/default-platform.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698