1. 31 3月, 2011 1 次提交
  2. 22 12月, 2010 1 次提交
  3. 04 4月, 2010 1 次提交
    • H
      perf: Swap inclusion order of util.h and string.h in util/string.c · 8141d005
      Hitoshi Mitake 提交于
      Currently util/string.c includes headers in this order: string.h, util.h
      But this causes a build error because __USE_GNU definition
      is needed for strndup() definition:
      
      	% make -j
      	touch .perf.dev.null
      	    CC util/string.o
      	cc1: warnings being treated as errors
      	util/string.c: In function ‘argv_split’:
      	util/string.c:171: error: implicit declaration of function ‘strndup’
      	util/string.c:171: error: incompatible implicit declaration of built-in function ‘strndup’
      
      So this patch swaps the headers inclusion order.
      util.h defines _GNU_SOURCE, and /usr/include/features.h defines
      __USE_GNU as 1 if _GNU_SOURCE is defined.
      Signed-off-by: NHitoshi Mitake <mitake@dcl.info.waseda.ac.jp>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
      LKML-Reference: <1270368798-27232-1-git-send-email-mitake@dcl.info.waseda.ac.jp>
      Signed-off-by: NFrederic Weisbecker <fweisbec@gmail.com>
      8141d005
  4. 26 3月, 2010 1 次提交
  5. 26 2月, 2010 1 次提交
    • M
      perf probe: Add lazy line matching support · 2a9c8c36
      Masami Hiramatsu 提交于
      Add lazy line matching support for specifying new probes.
      This also changes the syntax of perf probe a bit. Now
      perf probe accepts one of below probe event definitions.
      
      1) Define event based on function name
       [EVENT=]FUNC[@src][:RLN|+OFF|%return|;PTN] [ARG ...]
      
      2) Define event based on source file with line number
       [EVENT=]SRC:ALN [ARG ...]
      
      3) Define event based on source file with lazy pattern
       [EVENT=]SRC;PTN [ARG ...]
      
      - New lazy matching pattern(PTN) follows ';' (semicolon). And it
        must be put the end of the definition.
      - So, @src is no longer the part which must be put at the end
        of the definition.
      
      Note that ';' (semicolon) can be interpreted as the end of
      a command by the shell. This means that you need to quote it.
      (anyway you will need to quote the lazy pattern itself too,
      because it may contains other sensitive characters, like
      '[',']' etc.).
      
      Lazy matching
      -------------
      The lazy line matching is similar to glob matching except
      ignoring spaces in both of pattern and target.
      
      e.g.
      'a=*' can matches 'a=b', 'a = b', 'a == b' and so on.
      
      This provides some sort of flexibility and robustness to
      probe point definitions against minor code changes.
      (for example, actual 10th line of schedule() can be changed
       easily by modifying schedule(), but the same line matching
       'rq=cpu_rq*' may still exist.)
      
      Changes in v3:
       - Cast Dwarf_Addr to uintmax_t for printf-formats.
      
      Changes in v2:
       - Cast Dwarf_Addr to unsigned long long for printf-formats.
      Signed-off-by: NMasami Hiramatsu <mhiramat@redhat.com>
      Cc: systemtap <systemtap@sources.redhat.com>
      Cc: DLE <dle-develop@lists.sourceforge.net>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: K.Prasad <prasad@linux.vnet.ibm.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Ananth N Mavinakayanahalli <ananth@in.ibm.com>
      LKML-Reference: <20100225133611.6725.45078.stgit@localhost6.localdomain6>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      2a9c8c36
  6. 13 1月, 2010 1 次提交
    • M
      perf tools: Enhance glob string matching · 6964cd2c
      Masami Hiramatsu 提交于
      Enhance strglobmatch() for supporting character classes([CHARS],
      complementation and ranges are also supported) and escaped
      special characters (\*, \? etc).
      Signed-off-by: NMasami Hiramatsu <mhiramat@redhat.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
      Cc: systemtap <systemtap@sources.redhat.com>
      Cc: DLE <dle-develop@lists.sourceforge.net>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Mike Galbraith <efault@gmx.de>
      LKML-Reference: <20100105224724.19431.56271.stgit@dhcp-100-2-132.bos.redhat.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      6964cd2c
  7. 16 12月, 2009 1 次提交
    • M
      perf probe: Add glob matching support on --del · bbbb521b
      Masami Hiramatsu 提交于
      Add glob-expression matching support on --del option.
      You can use wildcards for specifying deleting events.
      e.g.
      
       Clear all probe events:
      
       # perf probe --del '*'
      
       Clear probes on schedule():
      
       # perf probe --del 'schedule*'
      Signed-off-by: NMasami Hiramatsu <mhiramat@redhat.com>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
      Cc: Steven Rostedt <rostedt@goodmis.org>
      Cc: Jim Keniston <jkenisto@us.ibm.com>
      Cc: Ananth N Mavinakayanahalli <ananth@in.ibm.com>
      Cc: Christoph Hellwig <hch@infradead.org>
      Cc: Frank Ch. Eigler <fche@redhat.com>
      Cc: Jason Baron <jbaron@redhat.com>
      Cc: K.Prasad <prasad@linux.vnet.ibm.com>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Srikar Dronamraju <srikar@linux.vnet.ibm.com>
      Cc: systemtap <systemtap@sources.redhat.com>
      Cc: DLE <dle-develop@lists.sourceforge.net>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      LKML-Reference: <20091215153210.17436.12327.stgit@dhcp-100-2-132.bos.redhat.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      bbbb521b
  8. 02 12月, 2009 1 次提交
  9. 01 12月, 2009 1 次提交
    • M
      perf probe: Add argv_split() from lib/argv_split.c · e1c01d61
      Masami Hiramatsu 提交于
      Add argv_split() ported from lib/argv_split.c to string.c and
      use it in util/probe-event.c.
      Signed-off-by: NMasami Hiramatsu <mhiramat@redhat.com>
      Cc: systemtap <systemtap@sources.redhat.com>
      Cc: DLE <dle-develop@lists.sourceforge.net>
      Cc: Steven Rostedt <rostedt@goodmis.org>
      Cc: Jim Keniston <jkenisto@us.ibm.com>
      Cc: Ananth N Mavinakayanahalli <ananth@in.ibm.com>
      Cc: Christoph Hellwig <hch@infradead.org>
      Cc: Frank Ch. Eigler <fche@redhat.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Jason Baron <jbaron@redhat.com>
      Cc: K.Prasad <prasad@linux.vnet.ibm.com>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Srikar Dronamraju <srikar@linux.vnet.ibm.com>
      Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      LKML-Reference: <20091201002005.10235.55602.stgit@harusame>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      e1c01d61
  10. 15 11月, 2009 1 次提交
  11. 06 10月, 2009 1 次提交
    • A
      perf tools: /proc/modules names don't always match its name · a2a99e8e
      Arnaldo Carvalho de Melo 提交于
      $ cut -d' ' -f1 /proc/modules|grep _|wc -l
       29
       $ cut -d' ' -f1 /proc/modules|grep _|sed 's/$/.ko'/g|while read n;do find /lib/modules/`uname -r` -name $n;done|wc -l
       12
      
      For instance:
      
       $ grep ^aes_x86 /proc/modules
       aes_x86_64 9056 2 - Live 0xffffffffa0091000
       $ l /lib/modules/2.6.31-tip/kernel/arch/x86/crypto/aes-x86_64.ko
       -rw-r--r-- 1 root root 136438 2009-09-22 19:05 /lib/modules/2.6.31-tip/kernel/arch/x86/crypto/aes-x86_64.ko
      
      Handle that by introducing a strxfrchar routine that replaces
      dashes with underscores when matching file names to loaded modules.
      Signed-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      Cc: Frédéric Weisbecker <fweisbec@gmail.com>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Mike Galbraith <efault@gmx.de>
      LKML-Reference: <new-submission>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      a2a99e8e
  12. 20 6月, 2009 1 次提交
    • P
      perf_counter tools: Define and use our own u64, s64 etc. definitions · 9cffa8d5
      Paul Mackerras 提交于
      On 64-bit powerpc, __u64 is defined to be unsigned long rather than
      unsigned long long.  This causes compiler warnings every time we
      print a __u64 value with %Lx.
      
      Rather than changing __u64, we define our own u64 to be unsigned long
      long on all architectures, and similarly s64 as signed long long.
      For consistency we also define u32, s32, u16, s16, u8 and s8.  These
      definitions are put in a new header, types.h, because these definitions
      are needed in util/string.h and util/symbol.h.
      
      The main change here is the mechanical change of __[us]{64,32,16,8}
      to remove the "__".  The other changes are:
      
      * Create types.h
      * Include types.h in perf.h, util/string.h and util/symbol.h
      * Add types.h to the LIB_H definition in Makefile
      * Added (u64) casts in process_overflow_event() and print_sym_table()
        to kill two remaining warnings.
      Signed-off-by: NPaul Mackerras <paulus@samba.org>
      Acked-by: NPeter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: benh@kernel.crashing.org
      LKML-Reference: <19003.33494.495844.956580@cargo.ozlabs.ibm.com>
      Signed-off-by: NIngo Molnar <mingo@elte.hu>
      9cffa8d5
  13. 07 6月, 2009 1 次提交
  14. 02 6月, 2009 1 次提交