mirror of
https://gitlab.freedesktop.org/monado/monado.git
synced 2025-01-30 18:38:32 +00:00
ipc: Trace markers
This commit is contained in:
parent
f754fb583f
commit
b4f9d07abf
src/xrt/ipc
|
@ -13,6 +13,7 @@
|
|||
#include "xrt/xrt_defines.h"
|
||||
|
||||
#include "util/u_misc.h"
|
||||
#include "util/u_trace_marker.h"
|
||||
|
||||
#include "os/os_time.h"
|
||||
|
||||
|
@ -373,6 +374,8 @@ ipc_compositor_begin_session(struct xrt_compositor *xc, enum xrt_view_type view_
|
|||
static xrt_result_t
|
||||
ipc_compositor_end_session(struct xrt_compositor *xc)
|
||||
{
|
||||
IPC_TRACE_MARKER();
|
||||
|
||||
struct ipc_client_compositor *icc = ipc_client_compositor(xc);
|
||||
|
||||
IPC_TRACE(icc->ipc_c, "Compositor end session.");
|
||||
|
@ -388,6 +391,7 @@ ipc_compositor_wait_frame(struct xrt_compositor *xc,
|
|||
uint64_t *out_predicted_display_time,
|
||||
uint64_t *out_predicted_display_period)
|
||||
{
|
||||
IPC_TRACE_MARKER();
|
||||
struct ipc_client_compositor *icc = ipc_client_compositor(xc);
|
||||
|
||||
uint64_t wake_up_time_ns = 0;
|
||||
|
|
|
@ -10,6 +10,7 @@
|
|||
#include "xrt/xrt_gfx_native.h"
|
||||
|
||||
#include "util/u_misc.h"
|
||||
#include "util/u_trace_marker.h"
|
||||
|
||||
#include "server/ipc_server.h"
|
||||
#include "ipc_server_generated.h"
|
||||
|
@ -137,6 +138,8 @@ ipc_handle_compositor_wait_frame(volatile struct ipc_client_state *ics,
|
|||
uint64_t *predicted_display_period,
|
||||
uint64_t *min_display_period)
|
||||
{
|
||||
IPC_TRACE_MARKER();
|
||||
|
||||
os_mutex_lock(&ics->server->global_state_lock);
|
||||
|
||||
u_rt_helper_predict((struct u_rt_helper *)&ics->urth, out_frame_id, predicted_display_time, wake_up_time,
|
||||
|
|
|
@ -19,6 +19,7 @@
|
|||
#include "util/u_var.h"
|
||||
#include "util/u_misc.h"
|
||||
#include "util/u_debug.h"
|
||||
#include "util/u_trace_marker.h"
|
||||
|
||||
#include "shared/ipc_shmem.h"
|
||||
#include "server/ipc_server.h"
|
||||
|
@ -197,6 +198,8 @@ handle_listen(struct ipc_server *vs, struct ipc_server_mainloop *ml)
|
|||
void
|
||||
ipc_server_mainloop_poll(struct ipc_server *vs, struct ipc_server_mainloop *ml)
|
||||
{
|
||||
IPC_TRACE_MARKER();
|
||||
|
||||
int epoll_fd = ml->epoll_fd;
|
||||
|
||||
struct epoll_event events[NUM_POLL_EVENTS] = {0};
|
||||
|
@ -226,6 +229,8 @@ ipc_server_mainloop_poll(struct ipc_server *vs, struct ipc_server_mainloop *ml)
|
|||
int
|
||||
ipc_server_mainloop_init(struct ipc_server_mainloop *ml)
|
||||
{
|
||||
IPC_TRACE_MARKER();
|
||||
|
||||
int ret = init_listen_socket(ml);
|
||||
if (ret < 0) {
|
||||
ipc_server_mainloop_deinit(ml);
|
||||
|
@ -243,6 +248,8 @@ ipc_server_mainloop_init(struct ipc_server_mainloop *ml)
|
|||
void
|
||||
ipc_server_mainloop_deinit(struct ipc_server_mainloop *ml)
|
||||
{
|
||||
IPC_TRACE_MARKER();
|
||||
|
||||
if (ml == NULL) {
|
||||
return;
|
||||
}
|
||||
|
|
|
@ -19,6 +19,7 @@
|
|||
#include "util/u_var.h"
|
||||
#include "util/u_misc.h"
|
||||
#include "util/u_debug.h"
|
||||
#include "util/u_trace_marker.h"
|
||||
|
||||
#include "shared/ipc_shmem.h"
|
||||
#include "server/ipc_server.h"
|
||||
|
@ -746,6 +747,8 @@ _overlay_sort_func(const void *a, const void *b)
|
|||
static bool
|
||||
_update_layers(struct ipc_server *s, struct xrt_compositor *xc)
|
||||
{
|
||||
IPC_TRACE_MARKER();
|
||||
|
||||
struct _z_sort_data z_data[IPC_MAX_CLIENTS];
|
||||
|
||||
// initialise, and fill in overlay app data
|
||||
|
@ -834,6 +837,8 @@ broadcast_timings(struct ipc_server *s,
|
|||
uint64_t predicted_display_period_ns,
|
||||
uint64_t diff_ns)
|
||||
{
|
||||
IPC_TRACE_MARKER();
|
||||
|
||||
os_mutex_lock(&s->global_state_lock);
|
||||
|
||||
// Broadcast the new timing information to the helpers.
|
||||
|
|
Loading…
Reference in a new issue