mirror of
https://gitlab.freedesktop.org/wayland/weston.git
synced 2026-05-07 06:08:05 +02:00
renderer-gl: Add a Perfetto trace counter for tracking GPU active
This duplicates the 'active' time slice we have in Perfetto but provides a better way to gauge instantly the GPU activity rather than a time slice. Signed-off-by: Marius Vlad <marius.vlad@collabora.com>
This commit is contained in:
parent
54a25720c6
commit
a643011bb0
1 changed files with 2 additions and 1 deletions
|
|
@ -58,6 +58,7 @@
|
|||
#include "linux-explicit-synchronization.h"
|
||||
#include "output-capture.h"
|
||||
#include "pixel-formats.h"
|
||||
#include "weston-trace.h"
|
||||
|
||||
#include "shared/fd-util.h"
|
||||
#include "shared/helpers.h"
|
||||
|
|
@ -735,7 +736,7 @@ timeline_render_point_handler(int fd, uint32_t mask, void *data)
|
|||
(int64_t) begin.tv_sec, end.tv_nsec,
|
||||
(int64_t) begin.tv_sec, end.tv_nsec,
|
||||
(float) (elapsed / 1000));
|
||||
|
||||
WESTON_TRACE_SET_COUNTER("GPU active (us)", elapsed / 1000);
|
||||
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue