trace: deal with deprecated glib thread functions
g_thread_create() was deprecated in favor of g_thread_new() andg_cond_new() was deprecated in favor of GCond initialization. If thehost has glib 2.31 or newer, avoid using the deprecated functions.
This patch solves compiler warnings that are generated when glib's...
trace: use glib atomic int types
Juan reported that RHEL 6.4 hosts give compiler warnings because we useunsigned int while glib prototypes use volatile gint in trace/simple.c.
trace/simple.c:223: error: pointer targets in passing argument 1 of 'g_atomic_int_compare_and_exchange' differ in signedness...
trace: Fix simple trace dropped event record for big endian
We use atomic operations to keep track of dropped events.
Inconveniently, GLib supports only int and void * atomics, but thecounter dropped_events is uint64_t. Can't stop commit 62bab732: aquick (gint *)&dropped_events bludgeons the compiler into submission....
trace: Direct access of atomics is verboten, use the API
The GLib Reference Manual says:
It is very important that all accesses to a particular integer or pointer be performed using only this API and that different sizes of operation are not mixed or used on overlapping memory...
trace: Clean up the "try to update atomic until it worked" loops
Signed-off-by: Markus Armbruster <armbru@redhat.com>Reviewed-by: Laszlo Ersek <lersek@redhat.com>Reviewed-by: Harsh Prateek Bora <harsh@linux.vnet.ibm.com>Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Makefile: clean timestamp generation rule
create timestamp by rule without sideeffects.
Signed-off-by: Michael S. Tsirkin <mst@redhat.com>
build: some simplifications for "trace/Makefile.objs"
Signed-off-by: Lluís Vilanova <vilanova@ac.upc.edu>Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
build: fold trace-obj-y into libqemuutil.a
Signed-off-by: Paolo Bonzini <pbonzini@redhat.com>
build: move dtrace rules to rules.mak
build: Use separate makefile for "trace/"
Reviewed-by: Paolo Bonzini <pbonzini@redhat.com>Signed-off-by: Lluís Vilanova <vilanova@ac.upc.edu>--Changes in v2:
View revisions
Also available in: Atom