lkml.org 
[lkml]   [2019]   [Feb]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [PATCH 07/11] perf tools report: Support running scripts for current time range
    On Sun, Feb 24, 2019 at 07:37:18AM -0800, Andi Kleen wrote:

    SNIP

    > + endtime += 1*1000000;
    > + }
    > + timestamp__scnprintf_usec(starttime, start, sizeof start);
    > + timestamp__scnprintf_usec(endtime, end, sizeof end);
    > + n += snprintf(script_opt + n, len - n, " --time %s,%s", start, end);
    > + }
    > +
    > script_browse(script_opt);
    > + free(script_opt);
    > return 0;
    > }
    >
    > static int
    > -add_script_opt(struct hist_browser *browser __maybe_unused,
    > +add_script_opt_2(struct hist_browser *browser __maybe_unused,
    > struct popup_action *act, char **optstr,
    > - struct thread *thread, struct symbol *sym)
    > + struct thread *thread, struct symbol *sym,
    > + const char *tstr)
    > {
    > +
    > if (thread) {
    > - if (asprintf(optstr, "Run scripts for samples of thread [%s]",
    > - thread__comm_str(thread)) < 0)
    > + if (asprintf(optstr, "Run scripts for samples of thread [%s]%s",
    > + thread__comm_str(thread), tstr) < 0)
    > return 0;
    > } else if (sym) {
    > - if (asprintf(optstr, "Run scripts for samples of symbol [%s]",
    > - sym->name) < 0)
    > + if (asprintf(optstr, "Run scripts for samples of symbol [%s]%s",
    > + sym->name, tstr) < 0)
    > return 0;
    > } else {
    > - if (asprintf(optstr, "Run scripts for all samples") < 0)
    > + if (asprintf(optstr, "Run scripts for all samples%s", tstr) < 0)
    > return 0;

    can't see the time ranges in the menu.. what's the path
    to get them listed?

    thanks,
    jirka

    \
     
     \ /
      Last update: 2019-02-25 13:57    [W:6.217 / U:0.072 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site