OLD | NEW |
1 /* | 1 /* |
2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. | 2 * Copyright (C) 2008 Apple Inc. All Rights Reserved. |
3 * | 3 * |
4 * Redistribution and use in source and binary forms, with or without | 4 * Redistribution and use in source and binary forms, with or without |
5 * modification, are permitted provided that the following conditions | 5 * modification, are permitted provided that the following conditions |
6 * are met: | 6 * are met: |
7 * 1. Redistributions of source code must retain the above copyright | 7 * 1. Redistributions of source code must retain the above copyright |
8 * notice, this list of conditions and the following disclaimer. | 8 * notice, this list of conditions and the following disclaimer. |
9 * 2. Redistributions in binary form must reproduce the above copyright | 9 * 2. Redistributions in binary form must reproduce the above copyright |
10 * notice, this list of conditions and the following disclaimer in the | 10 * notice, this list of conditions and the following disclaimer in the |
(...skipping 18 matching lines...) Expand all Loading... |
29 #include "core/workers/WorkerThread.h" | 29 #include "core/workers/WorkerThread.h" |
30 | 30 |
31 #include "bindings/v8/ScriptSourceCode.h" | 31 #include "bindings/v8/ScriptSourceCode.h" |
32 #include "core/inspector/InspectorInstrumentation.h" | 32 #include "core/inspector/InspectorInstrumentation.h" |
33 #include "core/workers/DedicatedWorkerGlobalScope.h" | 33 #include "core/workers/DedicatedWorkerGlobalScope.h" |
34 #include "core/workers/WorkerClients.h" | 34 #include "core/workers/WorkerClients.h" |
35 #include "core/workers/WorkerThreadStartupData.h" | 35 #include "core/workers/WorkerThreadStartupData.h" |
36 #include "modules/webdatabase/DatabaseManager.h" | 36 #include "modules/webdatabase/DatabaseManager.h" |
37 #include "modules/webdatabase/DatabaseTask.h" | 37 #include "modules/webdatabase/DatabaseTask.h" |
38 #include "platform/PlatformThreadData.h" | 38 #include "platform/PlatformThreadData.h" |
| 39 #include "platform/weborigin/KURL.h" |
39 #include "public/platform/Platform.h" | 40 #include "public/platform/Platform.h" |
40 #include "public/platform/WebWorkerRunLoop.h" | 41 #include "public/platform/WebWorkerRunLoop.h" |
41 #include "weborigin/KURL.h" | |
42 #include "wtf/Noncopyable.h" | 42 #include "wtf/Noncopyable.h" |
43 #include "wtf/text/WTFString.h" | 43 #include "wtf/text/WTFString.h" |
44 | 44 |
45 #include <utility> | 45 #include <utility> |
46 | 46 |
47 namespace WebCore { | 47 namespace WebCore { |
48 | 48 |
49 static Mutex& threadSetMutex() | 49 static Mutex& threadSetMutex() |
50 { | 50 { |
51 AtomicallyInitializedStatic(Mutex&, mutex = *new Mutex); | 51 AtomicallyInitializedStatic(Mutex&, mutex = *new Mutex); |
(...skipping 177 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
229 void WorkerThread::releaseFastMallocFreeMemoryInAllThreads() | 229 void WorkerThread::releaseFastMallocFreeMemoryInAllThreads() |
230 { | 230 { |
231 MutexLocker lock(threadSetMutex()); | 231 MutexLocker lock(threadSetMutex()); |
232 HashSet<WorkerThread*>& threads = workerThreads(); | 232 HashSet<WorkerThread*>& threads = workerThreads(); |
233 HashSet<WorkerThread*>::iterator end = threads.end(); | 233 HashSet<WorkerThread*>::iterator end = threads.end(); |
234 for (HashSet<WorkerThread*>::iterator it = threads.begin(); it != end; ++it) | 234 for (HashSet<WorkerThread*>::iterator it = threads.begin(); it != end; ++it) |
235 (*it)->runLoop().postTask(adoptPtr(new ReleaseFastMallocFreeMemoryTask))
; | 235 (*it)->runLoop().postTask(adoptPtr(new ReleaseFastMallocFreeMemoryTask))
; |
236 } | 236 } |
237 | 237 |
238 } // namespace WebCore | 238 } // namespace WebCore |
OLD | NEW |