• Arnaldo Carvalho de Melo's avatar
    perf list: Remove blank lines, headers when piping output · dfc431cb
    Arnaldo Carvalho de Melo authored
    So that one can, for instance, use it with wc -l:
    
      # perf list *:*write* | wc -l
      60
    
    Or to look for the "bio" tracepoints, without 'perf list' headers:
    
      # perf list *:*bio* | head
        block:block_bio_backmerge                          [Tracepoint event]
        block:block_bio_bounce                             [Tracepoint event]
        block:block_bio_complete                           [Tracepoint event]
        block:block_bio_frontmerge                         [Tracepoint event]
        block:block_bio_queue                              [Tracepoint event]
        block:block_bio_remap                              [Tracepoint event]
      #
    
    Cc: Adrian Hunter <adrian.hunter@intel.com>
    Cc: Borislav Petkov <bp@suse.de>
    Cc: David Ahern <dsahern@gmail.com>
    Cc: Frederic Weisbecker <fweisbec@gmail.com>
    Cc: Jiri Olsa <jolsa@redhat.com>
    Cc: Namhyung Kim <namhyung@kernel.org>
    Cc: Stephane Eranian <eranian@google.com>
    Cc: Wang Nan <wangnan0@huawei.com>
    Link: http://lkml.kernel.org/n/tip-ts7sc0x8u4io4cifzkup4j44@git.kernel.orgSigned-off-by: default avatarArnaldo Carvalho de Melo <acme@redhat.com>
    dfc431cb
parse-events.c 44.3 KB