aboutsummaryrefslogtreecommitdiff
path: root/trace
AgeCommit message (Collapse)Author
2011-09-21trace: use binary file open mode in simpletraceStefan Hajnoczi
For Windows portability the simple trace backend must use the 'b' file open mode. This prevents the stdio library from mangling 0x0a/0x0d newline characters. Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
2011-09-21trace: portable simple trace backend using glibStefan Hajnoczi
Convert the simple trace backend to glib so that it works under Windows. We cannot use pthread directly but glib provides portable abstractions. Also use glib atomics instead of newish gcc builtins which may not be supported on Windows toolchains. Signed-off-by: Stefan Hajnoczi <stefanha@linux.vnet.ibm.com>
2011-09-01trace: [stderr] add support for dynamically enabling/disabling eventsLluís
Uses the generic interface provided in "trace/control.h" in order to provide a programmatic interface as well as command line and monitor controls. Signed-off-by: Fabien Chouteau <chouteau@adacore.com> Signed-off-by: Lluís Vilanova <vilanova@ac.upc.edu>
2011-09-01trace: add "-trace events" argument to control initial stateLluís
The "-trace events" argument can be used to provide a file with a list of trace event names that will be enabled prior to starting execution, thus providing early tracing. This saves the user from manually toggling event states through the monitor interface or whichever backend-specific interface. Signed-off-by: Lluís Vilanova <vilanova@ac.upc.edu>
2011-09-01trace: separate trace event control and query routines from the simple backendLluís
Generalize the 'st_print_trace_events' and 'st_change_trace_event_state' into backend-specific 'trace_print_events' and 'trace_event_set_state' (respectively) in the "trace/control.h" file. Signed-off-by: Lluís Vilanova <vilanova@ac.upc.edu>
2011-09-01trace: avoid conditional code compilation during option parsingLluís
A default implementation for backend-specific routines is provided in "trace/default.c", which backends can override by setting "trace_default=no" in "configure". Signed-off-by: Lluís Vilanova <vilanova@ac.upc.edu>
2011-09-01trace: move backend-specific code into the trace/ directoryLluís
Signed-off-by: Lluís Vilanova <vilanova@ac.upc.edu>