perf report: Clean up the default output

- extra space between columns
 - left-aligned the symbol column
 - moved the no-symbols printout to -v

Acked-by: Peter Zijlstra <a.p.zijlstra@chello.nl>
Cc: Mike Galbraith <efault@gmx.de>
Cc: Paul Mackerras <paulus@samba.org>
Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
Cc: Marcelo Tosatti <mtosatti@redhat.com>
Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: John Kacur <jkacur@redhat.com>
LKML-Reference: <new-submission>
Signed-off-by: Ingo Molnar <mingo@elte.hu>
This commit is contained in:
Ingo Molnar 2009-06-02 15:34:25 +02:00
Родитель 97124d5e2d
Коммит 4593bba867
1 изменённых файлов: 27 добавлений и 26 удалений

Просмотреть файл

@ -84,7 +84,9 @@ static struct dso *dsos__findnew(const char *name)
struct dso *dso = dsos__find(name);
int nr;
if (dso == NULL) {
if (dso)
return dso;
dso = dso__new(name, 0);
if (!dso)
goto out_delete_dso;
@ -94,14 +96,13 @@ static struct dso *dsos__findnew(const char *name)
fprintf(stderr, "Failed to open: %s\n", name);
goto out_delete_dso;
}
if (!nr) {
if (!nr && verbose) {
fprintf(stderr,
"Failed to find debug symbols for: %s, maybe install a debug package?\n",
"No symbols found in: %s, maybe install a debug package?\n",
name);
}
dsos__add(dso);
}
return dso;
@ -362,7 +363,7 @@ sort__dso_cmp(struct hist_entry *left, struct hist_entry *right)
static size_t
sort__dso_print(FILE *fp, struct hist_entry *self)
{
return fprintf(fp, " %64s", self->dso ? self->dso->name : "<unknown>");
return fprintf(fp, " %s", self->dso ? self->dso->name : "<unknown>");
}
static struct sort_entry sort_dso = {
@ -401,7 +402,7 @@ sort__sym_print(FILE *fp, struct hist_entry *self)
}
static struct sort_entry sort_sym = {
.header = "Shared Object: Symbol",
.header = " Shared Object: Symbol",
.cmp = sort__sym_cmp,
.print = sort__sym_print,
};
@ -596,7 +597,7 @@ static size_t output__fprintf(FILE *fp, uint64_t total_samples)
int i;
fprintf(fp, " ");
for (i = 0; i < strlen(se->header); i++)
for (i = 0; i < strlen(se->header)-1; i++)
fprintf(fp, ".");
}
fprintf(fp, "\n");