aboutsummaryrefslogtreecommitdiffstats
Commit message (Collapse)AuthorAge
* trace-graph: Fix return of trace_graph_check_sched_switch()Steven Rostedt2010-02-19
| | | | | | Need to return the variable that "ret" is set as, not always 0. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* kernelshark/trace-cmd: Use command line as input_file if -i is left outSteven Rostedt2010-02-19
| | | | | | | | If a user types "kernelshark mytrace.dat" without using te -i option, still use the mytrace.dat as the input file for the trace, instead of the default trace.dat. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* trace-cmd: Fix infinite loop in trace-cmd -wSteven Rostedt2010-02-19
| | | | | | | | The search for a pid in the hash did would get into an infinite loop if that hash bucket contained more than one pid. Reported-by: Chris Mason <chris.mason@oracle.com> Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* trace-filter: Check that event has filter instead of just trivialSteven Rostedt2010-02-19
| | | | | | | | The check for if an event has trivial filter is not enough to test if the event should be shaded or not. A check of if the event has any filter is still needed. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* trace-filter: Add available event and fields for advanced filterSteven Rostedt2010-02-19
| | | | | | | Add a combo box of events and a combo box of fields that are available for the advanced filter. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* parse-events: Add pevent_event_common_fields() and pevent_event_fields()Steven Rostedt2010-02-19
| | | | | | | | Add the functions pevent_event_common_fields() and pevent_event_fields() that return an allocated array of the events common or event specific fields. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* kernelshark: Add examples to advance filtering dialogSteven Rostedt2010-02-18
| | | | Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* trace-graph: Fix scrollbar when adding plotsSteven Rostedt2010-02-18
| | | | | | | | | When adding plots with the plot menu, the scroll bar did not expand to let the new plots into the visible area. Need to recalculate the height after a plot is added or removed. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* kernelshark: Add CPU and task plotting menu optionsSteven Rostedt2010-02-18
| | | | | | | Add the CPU and task plotting menu that was implemented for trace-graph to kernelshark. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* trace-graph: Implement task plotting menuSteven Rostedt2010-02-18
| | | | | | | The task plot menu that was added with the CPU plot menu is now functional. You can add and remove task plots with using the menu. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* trace-graph: Add trace_graph_task_list()Steven Rostedt2010-02-18
| | | | | | | Add trace_graph_task_list() to return a list of tasks that are found in the graph. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* parse-events: Cache last event foundSteven Rostedt2010-02-18
| | | | | | | | | | | | | | | | | | | | | | | | | Code commonly passes around the event id and uses that to find the event. Even if the event was already found, it uses the id to find it later. By caching the last event found by the name or id, and checking that on the next query before searching, saves some time. Running trace-cmd report on 6,000,000 events went from: real 0m41.805s user 0m39.483s sys 0m2.311s to: real 0m39.769s user 0m37.401s sys 0m2.356s About a 4% speed-up. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* trace-cmd: Add -P option to record a single pidSteven Rostedt2010-02-18
| | | | | | | | Add the -P option to trace-cmd record (and start) to only trace a given pid. This is just like -F command where the pid given to -P would be the pid of the command. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* trace-graph: Move reading sched switch comms into trace-graph.cSteven Rostedt2010-02-18
| | | | | | | | Move the reading of missed comms from sched_switch events from trace-plot-cpu.c into trace-graph.c into the sched_switch check itself. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* trace-graph: Added CPU plotting menuSteven Rostedt2010-02-18
| | | | | | | | | Added menu for adding and removing CPU plots and Tasks. Only CPU updates have been implemented in this change set. Task updates will follow. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* trace-cmd: Implement trace-cmd record function filteringSteven Rostedt2010-02-17
| | | | | | | | | | | | | | | | | | | | | Now with "trace-cmd record -l func -g func -n func" you can add function filtering to the trace. Since -F and -f are taken, -l is used as "limit functions". -l func ; writes func into set_ftrace_filter -n func ; writes func into set_ftrace_notrace -g func ; writes func into set_graph_function You can specify more than one function on the command line. trace-cmd record -p function -l sys_write -l sys_read The above will set set_ftrace_filter to both sys_write and sys_read. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* kernelshark: Make sync filters between graph and list handle advanceSteven Rostedt2010-02-17
| | | | | | | Make sure the advanced filters get copied too when syncing between the graph and list filters. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* kernelshark: Add advance filters for list and graphSteven Rostedt2010-02-17
| | | | | | Add the advanced filter menu for list and graph. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* trace-graph: Add advanced event filterSteven Rostedt2010-02-17
| | | | | | | Add the menu and implementation to perform advance event filtering on the trace-graph. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* kernelshark/trace-graph: Convert to use trace_filter_event_filter_dialog()Steven Rostedt2010-02-17
| | | | | | | | Use the event_filter dialog instead of the system and event names. trace-view already does this, this patch converts kernelshark and trace-graph. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* kernelshark: Replace confusing "to" with "with" in sync filter menueSteven Rostedt2010-02-17
| | | | | | | | | | The menu "sync graph events to list" and "sync list events to graph" is confusing because the word "to" usually means to destination. But in this case, the "to" points to the source. Replacing "sync graph events with list" makes this less confusing. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* trace-view: Make advanced filters show differently in event filter dialogSteven Rostedt2010-02-17
| | | | | | | | Have the events with event filters show up greyed out in the event filter dialog. If the user keeps them active, the filter stays active. But if the user disables the filter, then it will go away. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* parse-events: Add pevent_update_trivial()Steven Rostedt2010-02-17
| | | | | | | Add pevent_update_trivial() to use one filter to update the another filter. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* parse-events: Add pevent_filter_copy()Steven Rostedt2010-02-17
| | | | | | Add pevent_filter_copy() to be able to copy one filter onto another. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* trace-cmd: Add trace-cmd read -w to show wakeup latenciesSteven Rostedt2010-02-17
| | | | | | | Add the -w option to trace-cmd read to record and display wakeup latencies. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* parse-events: Add pevent_filter_event_has_trivial()Steven Rostedt2010-02-17
| | | | | | | Add pevent_filter_event_has_trivial() to test if an event has a trivial TRUE, FALSE, or either filter. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* trace-view: Only clear non TRUE filters on all clearSteven Rostedt2010-02-17
| | | | Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* parse-events: Add pevent_filter_clear_trivial()Steven Rostedt2010-02-17
| | | | | | | Add the function pevent_filter_clear_trivial() to be able to remove just those filters that are TRUE or FALSE (or both). Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* trace-view: Add ability to show and delete advance filtersSteven Rostedt2010-02-17
| | | | | | | Add to the filter dialog the list of filters defined and a way to delete those filters. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* parse-events: Add parse_filter_remove_event() prototype to headerSteven Rostedt2010-02-17
| | | | | | Forgot to add parse_filter_remove_event() to parse_events.h Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* parse-events: Move strim() to util.hSteven Rostedt2010-02-17
| | | | | | | Add a util.h file to hold small functions that may be useful for other files. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* parse-events: Add pevent_filter_make_string()Steven Rostedt2010-02-17
| | | | | | | | Add the function pevent_filter_make_string() that will return an allocated string that translates a filter of an event. This can be used to display the defined filters back to the user. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* trace-view: Add warning output if advance filter failsSteven Rostedt2010-02-16
| | | | | | Print reason filter fails. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* parse-events: Add regex to string matches for filterSteven Rostedt2010-02-16
| | | | | | | | | | Add =~ and !~ for filtering string matches. Also fixed the == and != string matching since it was using strncmp() due to values may not being NULL terminated. Copies the data instead and compares the copy. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* parse-events: Use pevent_find_any_field() in filteringSteven Rostedt2010-02-16
| | | | | | | | Change pevent_find_field() to pevent_find_any_field() because the former does not check common fields where the later checks both. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* trace-cmd: Add advanced filteringSteven Rostedt2010-02-16
| | | | | | | | | | Add a "Advanced event filter" option that opens a text dialog that lets you write an advanced filter. This is still very primitive and needs to be cleaned up. Not only that, it needs to show previous filters. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* kernelshark: Convert to using event_filters for graph and listSteven Rostedt2010-02-16
| | | | | | | | Use the new pevent event_filter infrastructure to filter events. It removes a lot of specific graph and list code and is also faster. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* parse-events: Add pevent_filter_reset()Steven Rostedt2010-02-16
| | | | | | | Add function pevent_filter_reset() to reset and clear all filters in an event_filter structure. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* trace-view: Use info for finding tree in callbacksSteven Rostedt2010-02-16
| | | | | | | | In trace-view-main, the info passed to the callbacks is now a tree info and not the tree. The CPU and events clicked callbacks did not get updated to this change. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* parse-events: Fix init of event list in peventSteven Rostedt2010-02-16
| | | | | | | The initialization of the event list zero'd the first event item instead of the last. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* parse-events: Add pevent_event_filtered()Steven Rostedt2010-02-16
| | | | | | | Add filter function pevent_event_filtered() to return true if the event has a filter against it, and false otherwise. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* parse-events: Add pevent_filter_remove_event()Steven Rostedt2010-02-16
| | | | | | | | Create the function pevent_filter_remove_event() that takes an filter and an event id as its parameters and removes the event from the given filter. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* trace-cmd: Add trace-cmd report -v optionSteven Rostedt2010-02-16
| | | | | | | | | | | | | Add a -v option to trace-cmd report to negate all filters specified after it. That is, records that match those filters will not be displayed. ./trace-cmd report -F sched -v -F 'sched_switch: next_prio > 100' This will display all sched events except sched_switch events where the next_prio is greater than 100. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* parse-events: Add strim() to allow whitespace in filter event namesSteven Rostedt2010-02-16
| | | | | | | Adde strim() to remove leading and trailing whitespace from the event and system names being passed into the filter. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* parse-events: Fix comma delimited filtersSteven Rostedt2010-02-16
| | | | | | | | The comma deliminating event names was not being processed correctly. The index pointer was stuck at the comma instead of the next event name and this caused the filtering to fail. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* parse-events: Change report filters to allow regex on event namesSteven Rostedt2010-02-16
| | | | | | | | | | | | | | | | | Use the regex to find events and systems. Since we are now using regular expresions to add events to filters, we can no longer use the '.' to separate the system name from the event name. That is: trace-cmd report -F 'sched.sched_switch' will no longer work. It needs to be: trace-cmd report -F 'sched/sched_switch' Which is a better naming since that is how the files are distinguished anyhow. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* trace-cmd: Free filters at and of reportSteven Rostedt2010-02-16
| | | | | | Need to call pevent_filter_free() when finished with reporting. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* parse-event: Fix bug where sysname was defined but name was notSteven Rostedt2010-02-15
| | | | | | | If no name is given to the filter, then use the system name as the name and make the system name NULL. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* parse-events: Make filter add just events without filterSteven Rostedt2010-02-15
| | | | | | | Let the filter string contain just events. This will make all records that have this event match. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
* build: Add automatically generated warning to generated header filesSteven Rostedt2010-02-15
| | | | | | | | The header files tc_version.h and ks_version.h are created by the build process. Add a comment warning that changes to these files will not be sustained. Signed-off-by: Steven Rostedt <rostedt@goodmis.org>