[PATCH 03/13] src: Use new tracepoint declaration files to replace the old dtrace declaration files to support multiple trace function

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Xinghai Yu <yuxinghai@xxxxxxxxxxxxxx>

In order to support multiple trace backend, we have to quit the existing 
dtrace points definition files for they are only used by dtrace and their 
format are not easy to use for supporting multiple trace backend. 

The new tracepoint format files can generate the dtrace format files to 
support dtrace backend and also generate the ftrace format files to 
support ftrace backend.

Signed-off-by: Xinghai Yu <yuxinghai@xxxxxxxxxxxxxx>
---
 src/libvirt_probes.d          | 82 -------------------------------------------
 src/libvirt_qemu_probes.d     | 22 ------------
 src/libvirt_qemu_trace_events | 15 ++++++++
 src/libvirt_trace_events      | 70 ++++++++++++++++++++++++++++++++++++
 4 files changed, 85 insertions(+), 104 deletions(-)
 delete mode 100644 src/libvirt_probes.d
 delete mode 100644 src/libvirt_qemu_probes.d
 create mode 100644 src/libvirt_qemu_trace_events
 create mode 100644 src/libvirt_trace_events

diff --git a/src/libvirt_probes.d b/src/libvirt_probes.d
deleted file mode 100644
index 340d665..0000000
--- a/src/libvirt_probes.d
+++ /dev/null
@@ -1,82 +0,0 @@
-provider libvirt {
-	# file: src/util/event_poll.c
-	# prefix: event_poll
-	probe event_poll_add_handle(int watch, int fd, int events, void *cb, void *opaque, void *ff);
-	probe event_poll_update_handle(int watch, int events);
-	probe event_poll_remove_handle(int watch);
-	probe event_poll_dispatch_handle(int watch, int events);
-	probe event_poll_purge_handle(int watch);
-
-	probe event_poll_add_timeout(int timer, int frequency, void *cb, void *opaque, void *ff);
-	probe event_poll_update_timeout(int timer, int frequency);
-	probe event_poll_remove_timeout(int timer);
-	probe event_poll_dispatch_timeout(int timer);
-	probe event_poll_purge_timeout(int timer);
-
-	probe event_poll_run(int nfds, int timeout);
-
-
-        # file: src/util/virobject.c
-        # prefix: object
-        probe object_new(void *obj, const char *klassname);
-        probe object_ref(void *obj);
-        probe object_unref(void *obj);
-        probe object_dispose(void *obj);
-
-	# file: src/rpc/virnetsocket.c
-	# prefix: rpc
-	probe rpc_socket_new(void *sock, int fd, int errfd, pid_t pid, const char *localAddr, const char *remoteAddr);
-	probe rpc_socket_dispose(void *sock);
-	probe rpc_socket_send_fd(void *sock, int fd);
-	probe rpc_socket_recv_fd(void *sock, int fd);
-
-
-	# file: src/rpc/virnetserverclient.c
-	# prefix: rpc
-	probe rpc_server_client_new(void *client, void *sock);
-	probe rpc_server_client_dispose(void *client);
-	probe rpc_server_client_msg_tx_queue(void *client, int len, int prog, int vers, int proc, int type, int status, int serial);
-	probe rpc_server_client_msg_rx(void *client, int len, int prog, int vers, int proc, int type, int status, int serial);
-
-
-	# file: src/rpc/virnetclient.c
-	# prefix: rpc
-	probe rpc_client_new(void *client, void *sock);
-	probe rpc_client_dispose(void *client);
-	probe rpc_client_msg_tx_queue(void *client, int len, int prog, int vers, int proc, int type, int status, int serial);
-	probe rpc_client_msg_rx(void *client, int len, int prog, int vers, int proc, int type, int status, int serial);
-
-
-	# file: daemon/libvirtd.c
-	# prefix: rpc
-	probe rpc_server_client_auth_allow(void *client, int authtype, const char *identity);
-	probe rpc_server_client_auth_deny(void *client, int authtype, const char *identity);
-	probe rpc_server_client_auth_fail(void *client, int authtype);
-
-
-	# file: src/rpc/virnettlscontext.c
-	# prefix: rpc
-	probe rpc_tls_context_new(void *ctxt, const char *cacert, const char *cacrl,
-				  const char *cert, const char *key, int sanityCheckCert, int requireValidCert, int isServer);
-	probe rpc_tls_context_dispose(void *ctxt);
-	probe rpc_tls_context_session_allow(void *ctxt, void *sess, const char *dname);
-	probe rpc_tls_context_session_deny(void *ctxt, void *sess, const char *dname);
-	probe rpc_tls_context_session_fail(void *ctxt, void *sess);
-
-
-	probe rpc_tls_session_new(void *sess, void *ctxt, const char *hostname, int isServer);
-	probe rpc_tls_session_dispose(void *sess);
-	probe rpc_tls_session_handshake_pass(void *sess);
-	probe rpc_tls_session_handshake_fail(void *sess);
-
-
-	# file: src/rpc/virkeepalive.c
-	# prefix: rpc
-	probe rpc_keepalive_new(void *ka, void *client);
-	probe rpc_keepalive_dispose(void *ka);
-	probe rpc_keepalive_start(void *ka, void *client, int interval, int count);
-	probe rpc_keepalive_stop(void *ka, void *client);
-	probe rpc_keepalive_send(void *ka, void *client, int prog, int vers, int proc);
-	probe rpc_keepalive_received(void *ka, void *client, int prog, int vers, int proc);
-	probe rpc_keepalive_timeout(void *ka, void *client, int coundToDeath, int idle);
-};
diff --git a/src/libvirt_qemu_probes.d b/src/libvirt_qemu_probes.d
deleted file mode 100644
index e4449a9..0000000
--- a/src/libvirt_qemu_probes.d
+++ /dev/null
@@ -1,22 +0,0 @@
-provider libvirt {
-        # file: src/qemu/qemu_monitor.c
-        # prefix: qemu
-        # binary: libvirtd
-        # module: libvirt/connection-driver/libvirt_driver_qemu.so
-        # Monitor lifecycle
-        probe qemu_monitor_new(void *mon, int refs, int fd);
-        probe qemu_monitor_ref(void *mon, int refs);
-        probe qemu_monitor_unref(void *mon, int refs);
-        probe qemu_monitor_close(void *monm, int refs);
-
-        # High level monitor message processing
-        probe qemu_monitor_send_msg(void *mon, const char *msg, int fd);
-        probe qemu_monitor_recv_reply(void *mon, const char *reply);
-        probe qemu_monitor_recv_event(void *mon, const char *event);
-
-        # Low level monitor I/O processing
-        probe qemu_monitor_io_process(void *mon, const char *buf, unsigned int len);
-        probe qemu_monitor_io_read(void *mon, const char *buf, unsigned int len, int ret, int errno);
-        probe qemu_monitor_io_write(void *mon, const char *buf, unsigned int len, int ret, int errno);
-        probe qemu_monitor_io_send_fd(void *mon, int fd, int ret, int errno);
-};
diff --git a/src/libvirt_qemu_trace_events b/src/libvirt_qemu_trace_events
new file mode 100644
index 0000000..f6c3fd2
--- /dev/null
+++ b/src/libvirt_qemu_trace_events
@@ -0,0 +1,15 @@
+# file: src/qemu/qemu_monitor.c
+# prefix: qemu
+# binary: libvirtd
+# module: libvirt/connection-driver/libvirt_driver_qemu.so
+# Monitor lifecycle
+qemu_monitor_new(void *mon, int refs, int fd) "mon=%p refs=%d fd=%d"
+qemu_monitor_close(void *mon, int refs)  "mon=%p refs=%d"
+qemu_monitor_send_msg(void *mon, char *msg, int fd) "mon=%p msg=%s fd=%d"
+
+qemu_monitor_io_process(void *mon, char *buf, size_t len ) "mon=%p buf=%s len=%zu"
+qemu_monitor_io_write(void *mon, char *buf, int len, int ret, int err) "mon=%p buf=%s len=%d ret=%d errno=%d"
+qemu_monitor_io_send_fd(void *mon, int fd, int ret, int err) "mon=%p fd=%d ret=%d errno=%d"
+
+qemu_monitor_recv_event(void *mon, const char *line) "mon=%p event=%s" 
+qemu_monitor_recv_reply(void *mon, const char *line) "mon=%p reply=%s"
diff --git a/src/libvirt_trace_events b/src/libvirt_trace_events
new file mode 100644
index 0000000..5b11e62
--- /dev/null
+++ b/src/libvirt_trace_events
@@ -0,0 +1,70 @@
+# file: src/util/vireventpoll.c
+# prefix: event_poll
+event_poll_add_handle(int watch, int  fd, int  events, void * cb, void *opaque, void *ff) "watch=%d fd=%d events=%d cb=%p opaque=%p ff=%p"
+event_poll_update_handle( int watch, int  events) "watch=%d events=%d"
+event_poll_remove_handle(int watch)  "watch=%d"
+event_poll_dispatch_handle( int watch, int Events) "watch=%d events=%d"
+event_poll_purge_handle(int watch)  "watch=%d"
+
+event_poll_add_timeout(int ret, int  frequency, void *cb, void *opaque, void *ff) "timer=%d frequency=%d cb=%p opaque=%p ff=%p"
+event_poll_update_timeout(int timer, int frequency) "timer=%d frequency=%d"
+event_poll_remove_timeout(int timer) "timer=%d"
+event_poll_dispatch_timeout(int timer) "timer=%d"
+event_poll_purge_timeout(int timer) "timer=%d"
+
+event_poll_run(int nfds, int timeout) "nhandles=%d timeout=%d"
+
+# file: src/util/virobject.c
+# prefix: object
+object_new( void *obj, const char *classname) "obj=%p classname=%s"
+object_ref(void *obj) "obj=%p"
+object_unref(void *obj) "obj=%p"
+object_dispose(void *obj) "obj=%p"
+
+# file: src/rpc/virnetsocket.c
+# prefix: rpc
+rpc_socket_new(void *sock, int fd, int errfd, long long pid, const char *localAddr, const char *remoteAddr ) "sock=%p fd=%d errfd=%d pid=%lld localAddr=%s, remoteAddr=%s"
+rpc_socket_dispose(void *sock) "sock=%p"
+rpc_socket_send_fd(void *sock, int fd) "sock=%p fd=%d"
+rpc_socket_recv_fd(void *sock, int fd) "sock=%p fd=%d" 
+
+# file: src/rpc/virnetserverclient.c
+# prefix: rpc
+rpc_server_client_new(void *client, void *sock) "client=%p sock=%p"
+rpc_server_client_dispose(void *client) "client=%p"
+rpc_server_client_msg_tx_queue(void *client, size_t len, unsigned int prog, unsigned int vers, unsigned int proc, unsigned int type, unsigned int status, unsigned int serial )"client=%p len=%zu prog=%u vers=%u proc=%u type=%u status=%u serial=%u"
+rpc_server_client_msg_rx(void *client, size_t len, unsigned int prog, unsigned int vers, unsigned int proc, unsigned int type, unsigned int status, unsigned int serial ) "client=%p len=%zu prog=%u vers=%u proc=%u type=%u status=%u serial=%u"
+
+# file: src/rpc/virnetclient.c
+# prefix: rpc
+rpc_client_new(void *client, void *sock) "client=%p sock=%p"
+rpc_client_dispose(void *client)  "client=%p"
+rpc_client_msg_tx_queue(void *client, size_t len, unsigned int prog, unsigned int vers, unsigned int proc, unsigned int type, unsigned int status, unsigned int serial ) "client=%p len=%zu prog=%u vers=%u proc=%u type=%u status=%u serial=%u"
+rpc_client_msg_rx(void *client, size_t len, unsigned int prog, unsigned int vers, unsigned int proc, unsigned int type, unsigned int status, unsigned int serial)  "client=%p len=%zu prog=%u vers=%u proc=%u type=%u status=%u serial=%u"
+
+# file: daemon/libvirtd.c
+# prefix: rpc
+rpc_server_client_auth_allow(void *client, int auth, const char *identity) "client=%p auth=%d identity=%s"
+rpc_server_client_auth_deny(void *client, int auth, const char *identity) "client=%p auth=%d identity=%s"
+rpc_server_client_auth_fail(void *client, int auth) "client=%p auth=%d"
+
+# file: src/rpc/virnettlscontext.c
+# prefix: rpc
+rpc_tls_context_new(void *ctxt, const char *cacert, const char *cacrl, const char *cert, const char *key, int sanityCheckCert, int requireValidCert, int isServer ) "ctxt=%p cacert=%s cacrl=%s cert=%s key=%s sanityCheckCert=%d requireValidCert=%d isServer=%d"
+rpc_tls_context_dispose(void *ctxt) "ctxt=%p"
+rpc_tls_context_session_allow(void *ctxt, void *sess, const char *dname) "ctxt=%p sess=%p dname=%s"
+rpc_tls_context_session_deny(void *ctxt, void *sess, const char *dname) "ctxt=%p sess=%p dname=%s"
+rpc_tls_context_session_fail(void *ctxt, void *sess) "ctxt=%p sess=%p"
+
+rpc_tls_session_new(void *ctxt, void *sess, const char *hostname, int isServer) "sess=%p ctxt=%p hostname=%s isServer=%d"
+rpc_tls_session_dispose(void *sess) "sess=%p"
+
+# file: src/rpc/virkeepalive.c
+# prefix: rpc
+rpc_keepalive_new(void *ka, void *client)  "ka=%p client=%p"
+rpc_keepalive_dispose(void *ka)  "ka=%p"
+rpc_keepalive_start(void *ka, void *client, int interval, unsigned int count) "ka=%p client=%p interval=%d count=%u"
+rpc_keepalive_stop(void *ka, void *client) "ka=%p client=%p"
+rpc_keepalive_send(void *ka, void *client, int prog, int vers, int proc ) "ka=%p client=%p prog=%d vers=%d proc=%d"
+rpc_keepalive_received(void *ka, void *client, int prog, int vers, int proc) "ka=%p client=%p prog=%d vers=%d proc=%d"
+rpc_keepalive_timeout(void *ka, void *client, int countToDeath, int idle) "ka=%p client=%p countToDeath=%d idle=%d"
-- 
1.8.3.1

--
libvir-list mailing list
libvir-list@xxxxxxxxxx
https://www.redhat.com/mailman/listinfo/libvir-list




[Index of Archives]     [Virt Tools]     [Libvirt Users]     [Lib OS Info]     [Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Big List of Linux Books]     [Yosemite News]     [KDE Users]     [Fedora Tools]