Remove trace_read_data() and trace_peek_data()

The trace_read_data and trace_peek_data() required a global file
descriptor for reading.  This was kept because the library libparsevent
had the function graph tracer implementation and required a callback
to read. This code has been moved out of parse_events.c and into a
special override function.

Now it still uses the global read, but since libtracecmd has a little more
scope than libparsevent, we added a thread variable

  tracecmd_curr_thread_handle

This is unique per thread, and is set right after data is read.
Yes there are some races, but we can deal with it for now.

Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
6 files changed