tools/perf: Add support for record transaction flags
Add support for recording and displaying the transaction flags. They are essentially a new sort key. Also display them in a nice way to the user. Signed-off-by: Andi Kleen <ak@linux.intel.com> Acked-by: Jiri Olsa <jolsa@redhat.com> Signed-off-by: Peter Zijlstra <peterz@infradead.org> Link: http://lkml.kernel.org/r/1379688044-14173-6-git-send-email-andi@firstfloor.org Signed-off-by: Ingo Molnar <mingo@kernel.org>
This commit is contained in:
@@ -160,6 +160,10 @@ void hists__calc_col_len(struct hists *hists, struct hist_entry *h)
|
||||
hists__new_col_len(hists, HISTC_MEM_LVL, 21 + 3);
|
||||
hists__new_col_len(hists, HISTC_LOCAL_WEIGHT, 12);
|
||||
hists__new_col_len(hists, HISTC_GLOBAL_WEIGHT, 12);
|
||||
|
||||
if (h->transaction)
|
||||
hists__new_col_len(hists, HISTC_TRANSACTION,
|
||||
hist_entry__transaction_len());
|
||||
}
|
||||
|
||||
void hists__output_recalc_col_len(struct hists *hists, int max_rows)
|
||||
@@ -466,7 +470,7 @@ struct hist_entry *__hists__add_branch_entry(struct hists *self,
|
||||
struct hist_entry *__hists__add_entry(struct hists *self,
|
||||
struct addr_location *al,
|
||||
struct symbol *sym_parent, u64 period,
|
||||
u64 weight)
|
||||
u64 weight, u64 transaction)
|
||||
{
|
||||
struct hist_entry entry = {
|
||||
.thread = al->thread,
|
||||
@@ -487,6 +491,7 @@ struct hist_entry *__hists__add_entry(struct hists *self,
|
||||
.hists = self,
|
||||
.branch_info = NULL,
|
||||
.mem_info = NULL,
|
||||
.transaction = transaction,
|
||||
};
|
||||
|
||||
return add_hist_entry(self, &entry, al, period, weight);
|
||||
|
Reference in New Issue
Block a user