Add dtrace probes for pts rects
parent
34ad07b267
commit
bd4c3a7286
|
@ -0,0 +1,31 @@
|
|||
/*
|
||||
* Copyright (c) 2020 Andri Yngvason
|
||||
*
|
||||
* Permission to use, copy, modify, and/or distribute this software for any
|
||||
* purpose with or without fee is hereby granted, provided that the above
|
||||
* copyright notice and this permission notice appear in all copies.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH
|
||||
* REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
|
||||
* AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT,
|
||||
* INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM
|
||||
* LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE
|
||||
* OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
||||
* PERFORMANCE OF THIS SOFTWARE.
|
||||
*/
|
||||
|
||||
#pragma once
|
||||
|
||||
#include "config.h"
|
||||
|
||||
#ifdef HAVE_USDT
|
||||
#include <sys/sdt.h>
|
||||
#else
|
||||
#define DTRACE_PROBE(...)
|
||||
#define DTRACE_PROBE1(...)
|
||||
#define DTRACE_PROBE2(...)
|
||||
#define DTRACE_PROBE3(...)
|
||||
#define DTRACE_PROBE4(...)
|
||||
#define DTRACE_PROBE5(...)
|
||||
#define DTRACE_PROBE6(...)
|
||||
#endif
|
|
@ -27,6 +27,7 @@
|
|||
#include "rfb/rfbclient.h"
|
||||
#include "vnc.h"
|
||||
#include "open-h264.h"
|
||||
#include "usdt.h"
|
||||
|
||||
#define RFB_ENCODING_OPEN_H264 50
|
||||
#define RFB_ENCODING_PTS -1000
|
||||
|
@ -97,6 +98,8 @@ static void vnc_client_finish_update(rfbClient* client)
|
|||
struct vnc_client* self = rfbClientGetClientData(client, NULL);
|
||||
assert(self);
|
||||
|
||||
DTRACE_PROBE2(wlvncc, vnc_client_finish_update, client, self->pts);
|
||||
|
||||
self->update_fb(self);
|
||||
|
||||
self->pts = NO_PTS;
|
||||
|
@ -178,6 +181,8 @@ static rfbBool vnc_client_handle_pts_rect(rfbClient* client,
|
|||
|
||||
self->pts = vnc_client_htonll(pts_msg);
|
||||
|
||||
DTRACE_PROBE1(wlvncc, vnc_client_handle_pts_rect, self->pts);
|
||||
|
||||
return TRUE;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue