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

Unified Diff: third_party/WebKit/Source/bindings/core/v8/V8Initializer.cpp

Issue 1396793002: Reland "Remove IdleNotification call in the main thread of foreground tab." (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 2 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/Source/bindings/core/v8/V8Initializer.cpp
diff --git a/third_party/WebKit/Source/bindings/core/v8/V8Initializer.cpp b/third_party/WebKit/Source/bindings/core/v8/V8Initializer.cpp
index e24e5d2510830cf8e31c15e5b582dc69c0530206..6aa5999ef6d8c3038cd5ef46f2d9d805cdcdf0b0 100644
--- a/third_party/WebKit/Source/bindings/core/v8/V8Initializer.cpp
+++ b/third_party/WebKit/Source/bindings/core/v8/V8Initializer.cpp
@@ -327,23 +327,6 @@ static bool codeGenerationCheckCallbackInMainThread(v8::Local<v8::Context> conte
return false;
}
-static void idleGCTaskInMainThread(double deadlineSeconds)
-{
- ASSERT(isMainThread());
- ASSERT(RuntimeEnabledFeatures::v8IdleTasksEnabled());
- bool gcFinished = false;
- v8::Isolate* isolate = v8::Isolate::GetCurrent();
-
- Platform* platform = Platform::current();
- if (deadlineSeconds > platform->monotonicallyIncreasingTime())
- gcFinished = isolate->IdleNotificationDeadline(deadlineSeconds);
-
- if (gcFinished)
- platform->currentThread()->scheduler()->postIdleTaskAfterWakeup(FROM_HERE, WTF::bind<double>(idleGCTaskInMainThread));
- else
- platform->currentThread()->scheduler()->postIdleTask(FROM_HERE, WTF::bind<double>(idleGCTaskInMainThread));
-}
-
static void timerTraceProfilerInMainThread(const char* name, int status)
{
if (!status) {
@@ -412,8 +395,6 @@ void V8Initializer::initializeMainThreadIfNeeded()
if (RuntimeEnabledFeatures::v8IdleTasksEnabled()) {
WebScheduler* scheduler = Platform::current()->currentThread()->scheduler();
V8PerIsolateData::enableIdleTasks(isolate, adoptPtr(new V8IdleTaskRunner(scheduler)));
- // FIXME: Remove idleGCTaskInMainThread once V8 starts posting idle task explicity.
- scheduler->postIdleTask(FROM_HERE, WTF::bind<double>(idleGCTaskInMainThread));
}
isolate->SetEventLogger(timerTraceProfilerInMainThread);
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698