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

Side by Side Diff: third_party/WebKit/public/platform/scheduler/renderer/renderer_scheduler.h

Issue 2273703002: Force events to be non blocking if main thread is unresponsive. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address feedback. Created 4 years, 1 month 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
OLDNEW
1 // Copyright 2014 The Chromium Authors. All rights reserved. 1 // Copyright 2014 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef THIRD_PARTY_WEBKIT_PUBLIC_PLATFORM_SCHEDULER_RENDERER_RENDERER_SCHEDULER _H_ 5 #ifndef THIRD_PARTY_WEBKIT_PUBLIC_PLATFORM_SCHEDULER_RENDERER_RENDERER_SCHEDULER _H_
6 #define THIRD_PARTY_WEBKIT_PUBLIC_PLATFORM_SCHEDULER_RENDERER_RENDERER_SCHEDULER _H_ 6 #define THIRD_PARTY_WEBKIT_PUBLIC_PLATFORM_SCHEDULER_RENDERER_RENDERER_SCHEDULER _H_
7 7
8 #include <memory> 8 #include <memory>
9 9
10 #include "base/macros.h" 10 #include "base/macros.h"
(...skipping 168 matching lines...) Expand 10 before | Expand all | Expand 10 after
179 virtual void SetTopLevelBlameContext( 179 virtual void SetTopLevelBlameContext(
180 base::trace_event::BlameContext* blame_context) = 0; 180 base::trace_event::BlameContext* blame_context) = 0;
181 181
182 // The renderer scheduler maintains an estimated RAIL mode[1]. This observer 182 // The renderer scheduler maintains an estimated RAIL mode[1]. This observer
183 // can be used to get notified when the mode changes. The observer will be 183 // can be used to get notified when the mode changes. The observer will be
184 // called on the main thread and must outlive this class. 184 // called on the main thread and must outlive this class.
185 // [1] 185 // [1]
186 // https://developers.google.com/web/tools/chrome-devtools/profile/evaluate-pe rformance/rail 186 // https://developers.google.com/web/tools/chrome-devtools/profile/evaluate-pe rformance/rail
187 virtual void SetRAILModeObserver(RAILModeObserver* observer) = 0; 187 virtual void SetRAILModeObserver(RAILModeObserver* observer) = 0;
188 188
189 // Returns whether or not the main thread appears unresponsive, based on the
190 // length and frequency of recent main thread tasks.
191 virtual bool MainThreadSeemsUnresponsive() const = 0;
192
189 protected: 193 protected:
190 RendererScheduler(); 194 RendererScheduler();
191 DISALLOW_COPY_AND_ASSIGN(RendererScheduler); 195 DISALLOW_COPY_AND_ASSIGN(RendererScheduler);
192 }; 196 };
193 197
194 } // namespace scheduler 198 } // namespace scheduler
195 } // namespace blink 199 } // namespace blink
196 200
197 #endif // THIRD_PARTY_WEBKIT_PUBLIC_PLATFORM_SCHEDULER_RENDERER_RENDERER_SCHEDU LER_H_ 201 #endif // THIRD_PARTY_WEBKIT_PUBLIC_PLATFORM_SCHEDULER_RENDERER_RENDERER_SCHEDU LER_H_
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698