未验证 提交 0c8fda27 编写于 作者: N nathanrogersgoogle 提交者: GitHub

Remove the "VSYNC" trace event on Fuchsia (#5907)

Don't emit a "VSYNC" event when running on Fuchsia, as traces on Fuchsia
are typically recorded across the whole system, causing the events to
collide with each other.
上级 430ca29c
......@@ -37,10 +37,17 @@ void VsyncWaiter::FireCallback(fml::TimePoint frame_start_time,
task_runners_.GetUITaskRunner()->PostTask(
[callback, frame_start_time, frame_target_time]() {
#if defined(OS_FUCHSIA)
// In general, traces on Fuchsia are recorded across the whole system.
// Because of this, emitting a "VSYNC" event per flutter process is
// undesirable, as the events will collide with each other. We
// instead let another area of the system emit them.
TRACE_EVENT0("flutter", "vsync callback");
#else
// Note: The tag name must be "VSYNC" (it is special) so that the
// "Highlight
// Vsync" checkbox in the timeline can be enabled.
// "Highlight Vsync" checkbox in the timeline can be enabled.
TRACE_EVENT0("flutter", "VSYNC");
#endif
callback(frame_start_time, frame_target_time);
});
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册