1. 23 4月, 2014 1 次提交
  2. 14 4月, 2014 2 次提交
  3. 08 3月, 2014 1 次提交
  4. 28 2月, 2014 1 次提交
  5. 24 2月, 2014 6 次提交
    • J
      perf tools: Setup default dwarf post unwinder · 0a4f2b6a
      Jiri Olsa 提交于
      Factor NO_LIBDW_DWARF_UNWIND makefile variable and code that selects
      default DWARf post unwinder based on detected features (libdw and
      libunwind support)
      
      If both are detected the libunwind is selected as default.  Simple
      'make' will try to add:
      
        - libunwind unwinder if present
        - libdw unwinder if present
        - disable dwarf unwind if non of libunwind and libdw
          libraries are present
      
      If one of the DWARF unwind libraries is detected, message is displayed
      which one (libunwind/libdw) is compiled in.
      
      Examples:
        - compile in libdw unwinder if present:
      
          $ make NO_LIBUNWIND=1
      
        - compile in libdw (with libdw installation directory) unwinder if present:
      
          $ make LIBDW_DIR=/opt/elfutils/ NO_LIBUNWIND=1
            BUILD:   Doing 'make -j4' parallel build
      
          Auto-detecting system features:
          ...                         dwarf: [ on  ]
          ...                         glibc: [ on  ]
          ...                          gtk2: [ on  ]
          ...                      libaudit: [ on  ]
          ...                        libbfd: [ on  ]
          ...                        libelf: [ on  ]
          ...                       libnuma: [ on  ]
          ...                       libperl: [ on  ]
          ...                     libpython: [ on  ]
          ...                      libslang: [ on  ]
          ...                     libunwind: [ on  ]
          ...            libdw-dwarf-unwind: [ on  ]
          ...     DWARF post unwind library: libdw
      
        - disable post dwarf unwind completely:
      
          $ make NO_LIBUNWIND=1 NO_LIBDW_DWARF_UNWIND=1
            BUILD:   Doing 'make -j4' parallel build
      
          Auto-detecting system features:
          ...                         dwarf: [ on  ]
          ...                         glibc: [ on  ]
          ...                          gtk2: [ on  ]
          ...                      libaudit: [ on  ]
          ...                        libbfd: [ on  ]
          ...                        libelf: [ on  ]
          ...                       libnuma: [ on  ]
          ...                       libperl: [ on  ]
          ...                     libpython: [ on  ]
          ...                      libslang: [ on  ]
          ...                     libunwind: [ on  ]
          ...            libdw-dwarf-unwind: [ on  ]
          ...     DWARF post unwind library: libunwind
      Signed-off-by: NJiri Olsa <jolsa@redhat.com>
      Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Ingo Molnar <mingo@kernel.org>
      Cc: Jean Pihet <jean.pihet@linaro.org>
      Cc: Namhyung Kim <namhyung@kernel.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Link: http://lkml.kernel.org/r/1392825179-5228-6-git-send-email-jolsa@redhat.com
      [ Add suggestion about setting LIBDW_DIR when not finding libdw ]
      Signed-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      0a4f2b6a
    • J
      perf tools: Add libdw DWARF post unwind support · 5ea84154
      Jiri Olsa 提交于
      Adding libdw DWARF post unwind support, which is part of
      elfutils-devel/libdw-dev package from version 0.158.
      
      The new code is contained in unwin-libdw.c object, and implements
      unwind__get_entries unwind interface function.
      
      New Makefile variable NO_LIBDW_DWARF_UNWIND was added to control its
      compilation, and is marked as disabled now.  It's factored with the rest
      of the Makefile unwind build code in the next patch.
      
      Arch specific code was added for x86.
      Signed-off-by: NJiri Olsa <jolsa@redhat.com>
      Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Ingo Molnar <mingo@kernel.org>
      Cc: Jean Pihet <jean.pihet@linaro.org>
      Cc: Namhyung Kim <namhyung@kernel.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Link: http://lkml.kernel.org/r/1392825179-5228-5-git-send-email-jolsa@redhat.comSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      5ea84154
    • J
      perf tools: Add feature check for libdw dwarf unwind · 45757895
      Jiri Olsa 提交于
      Adding feature check test code for libdw dwarf unwind.
      Signed-off-by: NJiri Olsa <jolsa@redhat.com>
      Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Ingo Molnar <mingo@kernel.org>
      Cc: Jean Pihet <jean.pihet@linaro.org>
      Cc: Namhyung Kim <namhyung@kernel.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Link: http://lkml.kernel.org/r/1392825179-5228-4-git-send-email-jolsa@redhat.comSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      45757895
    • A
      perf tools: Warn the user about how to enable libunwind support · 7a0447d6
      Arnaldo Carvalho de Melo 提交于
      When one has libunwind installed somewhere the perf tools build process
      doesn't expects it to be, this happens:
      
        [acme@ssdandy linux]$ make O=/tmp/build/perf -C tools/perf/ install-bin
        make: Entering directory `/home/acme/git/linux/tools/perf'
          BUILD:   Doing 'make -j8' parallel build
        config/Makefile:312: No libunwind found, disabling post unwind support.  Please install libunwind-dev[el] >= 1.1
      
        Auto-detecting system features:
        <SNIP>
        ...                     libunwind: [ OFF ]
      
      Change the message so that it tells how to use a non-standard libunwind
      install directory:
      
        config/Makefile:312: No libunwind found, disabling post unwind support.  Please install libunwind-dev[el] >= 1.1 and/or set LIBUNWIND_DIR
      
        [acme@ssdandy linux]$ make LIBUNWIND_DIR=/opt/libunwind-git/ O=/tmp/build/perf -C tools/perf/ install-bin
        make: Entering directory `/home/acme/git/linux/tools/perf'
          BUILD:   Doing 'make -j8' parallel build
      
        Auto-detecting system features:
        <SNIP>
        ...                     libunwind: [ on  ]
      Acked-by: NJiri Olsa <jolsa@redhat.com>
      Cc: Adrian Hunter <adrian.hunter@intel.com>
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Jiri Olsa <jolsa@redhat.com>
      Cc: Mike Galbraith <efault@gmx.de>
      Cc: Namhyung Kim <namhyung@kernel.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <peterz@infradead.org>
      Cc: Stephane Eranian <eranian@google.com>
      Link: http://lkml.kernel.org/n/tip-huoxnou7sw85lm58k3pi1xhw@git.kernel.orgSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      7a0447d6
    • J
      perf tools: Add variable display for VF make output · 8d79076a
      Jiri Olsa 提交于
      Adding dump of interesting build directories to the make VF=1 output.
      
        $ make VF=1
          BUILD:   Doing 'make -j4' parallel build
      
        Auto-detecting system features:
        ...                         dwarf: [ on  ]
        ...                         glibc: [ on  ]
        ...                          gtk2: [ on  ]
        ...                      libaudit: [ on  ]
        ...                        libbfd: [ on  ]
        ...                        libelf: [ on  ]
        ...                       libnuma: [ on  ]
        ...                       libperl: [ on  ]
        ...                     libpython: [ on  ]
        ...                      libslang: [ on  ]
        ...                     libunwind: [ on  ]
        ...                     backtrace: [ on  ]
        ...                fortify-source: [ on  ]
        ...                  gtk2-infobar: [ on  ]
        ...             libelf-getphdrnum: [ on  ]
        ...                   libelf-mmap: [ on  ]
        ...             libpython-version: [ on  ]
        ...                       on-exit: [ on  ]
        ...            stackprotector-all: [ on  ]
        ...                       timerfd: [ on  ]
        ...         libunwind-debug-frame: [ OFF ]
        ...                        bionic: [ OFF ]
      
        ...                        prefix: /home/jolsa
        ...                        bindir: /home/jolsa/bin
        ...                        libdir: /home/jolsa/lib64
        ...                    sysconfdir: /home/jolsa/etc
      
      Adding functions to print variable/text in features display -
      feature_print_var/feature_print_text (feature_print_text is used in next
      patches).
      Signed-off-by: NJiri Olsa <jolsa@redhat.com>
      Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Ingo Molnar <mingo@kernel.org>
      Cc: Jean Pihet <jean.pihet@linaro.org>
      Cc: Namhyung Kim <namhyung@kernel.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Link: http://lkml.kernel.org/r/1392825179-5228-3-git-send-email-jolsa@redhat.comSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      8d79076a
    • J
      perf tools: Factor features display code · 0695e57b
      Jiri Olsa 提交于
      Currently the we display all detected features/libraries by following
      rules:
      
       - if one of the features is missing
       - if it's build from clean tree
      
      This patch changes changes this behavior in several ways.
      
      - We no longer display all detected features, only detected libraries
        are displayed by default:
      
        $ make
          BUILD:   Doing 'make -j4' parallel build
      
        Auto-detecting system features:
        ...                         dwarf: [ on  ]
        ...                         glibc: [ on  ]
        ...                          gtk2: [ on  ]
        ...                      libaudit: [ on  ]
        ...                        libbfd: [ on  ]
        ...                        libelf: [ on  ]
        ...                       libnuma: [ on  ]
        ...                       libperl: [ on  ]
        ...                     libpython: [ on  ]
        ...                      libslang: [ on  ]
        ...                     libunwind: [ on  ]
      
        The assumption is, that above libraries are the most interesting part
      of the detection, while we don't care much about detection of on-exit
      support.
      
      - If all above libraries are detected, the default is not shown on
        subsequent builds.
      
      - If one of the above libraries is missing, the detection output is
        forced.
      
      - The features status is stored in PERF-FEATURES file and the detection
        output is forced in case the there's difference between the file
        contents and currently detected features.
      
      - If you want to see all detected features, you can use VF=1 make
        variable, that forces the detected features output.
      
        $ make VF=1
          BUILD:   Doing 'make -j4' parallel build
      
        Auto-detecting system features:
        ...                         dwarf: [ on  ]
        ...                         glibc: [ on  ]
        ...                          gtk2: [ on  ]
        ...                      libaudit: [ on  ]
        ...                        libbfd: [ on  ]
        ...                        libelf: [ on  ]
        ...                       libnuma: [ on  ]
        ...                       libperl: [ on  ]
        ...                     libpython: [ on  ]
        ...                      libslang: [ on  ]
        ...                     libunwind: [ on  ]
        ...                     backtrace: [ on  ]
        ...                fortify-source: [ on  ]
        ...                  gtk2-infobar: [ on  ]
        ...             libelf-getphdrnum: [ on  ]
        ...                   libelf-mmap: [ on  ]
        ...             libpython-version: [ on  ]
        ...                       on-exit: [ on  ]
        ...            stackprotector-all: [ on  ]
        ...                       timerfd: [ on  ]
        ...         libunwind-debug-frame: [ OFF ]
        ...                        bionic: [ OFF ]
      Signed-off-by: NJiri Olsa <jolsa@redhat.com>
      Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Ingo Molnar <mingo@kernel.org>
      Cc: Jean Pihet <jean.pihet@linaro.org>
      Cc: Namhyung Kim <namhyung@kernel.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Link: http://lkml.kernel.org/r/1392825179-5228-2-git-send-email-jolsa@redhat.comSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      0695e57b
  6. 18 2月, 2014 1 次提交
  7. 24 1月, 2014 1 次提交
  8. 16 1月, 2014 1 次提交
    • M
      perf: tools: Fix cross building · a8a5cd8b
      Mark Rutland 提交于
      Currently the feature-checks Makefile does not inherit $(CC), and calls
      cc rather than $(CROSS_COMPILE)gcc. Thus the feature checks invoke the
      native toolchain rather than the cross toolchain, and can identify
      features as available when they are not. This can break the build.
      
      Additionally the native pkg-config is always called as opposed to
      $(CROSS_COMPILE)pkg-config, so the wrong flags and paths may be passed
      to the cross compiler.
      
      This patch passes CROSS_COMPILE down to the feature-checks Makefile, and
      forces its use. Additionally pkg-config is replaced with
      $(CROSS_COMPILE)pkg-config via a new $(PKG_CONFIG) variable. This patch
      has been build tested on x86_64 and arm.
      Signed-off-by: NMark Rutland <mark.rutland@arm.com>
      Cc: Ingo Molnar <mingo@redhat.com>
      Cc: Jiri Olsa <jolsa@redhat.com>
      Cc: Will Deacon <will.deacon@arm.com>
      Link: http://lkml.kernel.org/r/1389782648-4417-4-git-send-email-mark.rutland@arm.comSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      a8a5cd8b
  9. 14 1月, 2014 1 次提交
  10. 13 1月, 2014 3 次提交
  11. 24 12月, 2013 1 次提交
  12. 20 12月, 2013 1 次提交
  13. 11 12月, 2013 2 次提交
  14. 05 12月, 2013 2 次提交
    • J
      perf tools: Add build and install plugins targets · 3d7c0144
      Jiri Olsa 提交于
      Adding 'plugins' target along with the libtraceevent.a, so plugins are
      built together with traceevent library.
      
      Adding 'install-traceevent-plugins' Makefile install target, instructing
      perf to install plugins into:
      
        $(HOME)/.traceevent/plugins
          - If installed localy under $HOME
      
        $(DESTDIR)/$(prefix)/$(libdir)/traceevent/plugins
          - If installed globally
      
      Examples:
        $ make install
        ...
        $ find ~/.traceevent/plugins/
        /home/jolsa/.traceevent/plugins/
        /home/jolsa/.traceevent/plugins/plugin_mac80211.so
        /home/jolsa/.traceevent/plugins/plugin_kvm.so
        /home/jolsa/.traceevent/plugins/plugin_scsi.so
        /home/jolsa/.traceevent/plugins/plugin_sched_switch.so
        /home/jolsa/.traceevent/plugins/plugin_xen.so
        /home/jolsa/.traceevent/plugins/plugin_cfg80211.so
        /home/jolsa/.traceevent/plugins/plugin_function.so
        /home/jolsa/.traceevent/plugins/plugin_kmem.so
        /home/jolsa/.traceevent/plugins/plugin_hrtimer.so
        /home/jolsa/.traceevent/plugins/plugin_jbd2.so
      
        $ sudo make install DESTDIR=/opt/perf/
        ...
        $ find /opt/perf/lib64/traceevent/plugins/
        /opt/perf/lib64/traceevent/plugins/
        /opt/perf/lib64/traceevent/plugins/plugin_kvm.so
        /opt/perf/lib64/traceevent/plugins/plugin_scsi.so
        /opt/perf/lib64/traceevent/plugins/plugin_mac80211.so
        /opt/perf/lib64/traceevent/plugins/plugin_hrtimer.so
        /opt/perf/lib64/traceevent/plugins/plugin_kmem.so
        /opt/perf/lib64/traceevent/plugins/plugin_jbd2.so
        /opt/perf/lib64/traceevent/plugins/plugin_sched_switch.so
        /opt/perf/lib64/traceevent/plugins/plugin_function.so
        /opt/perf/lib64/traceevent/plugins/plugin_cfg80211.so
        /opt/perf/lib64/traceevent/plugins/plugin_xen.so
      Signed-off-by: NJiri Olsa <jolsa@redhat.com>
      Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Namhyung Kim <namhyung@kernel.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Steven Rostedt <rostedt@goodmis.org>
      Link: http://lkml.kernel.org/r/1386076182-14484-8-git-send-email-jolsa@redhat.comSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      3d7c0144
    • J
      perf tools: Remove stackprotector feature check · e6d7cee1
      Jiri Olsa 提交于
      We use -fstack-protector-all option to enable stack protecting for all
      available functions. There's no reason for enabling -Wstack-protector to
      get warning for unprotected functions.
      
      Removing stackprotector feature check which was used to enable the
      -Wstack-protector option.
      Signed-off-by: NJiri Olsa <jolsa@redhat.com>
      Cc: Corey Ashford <cjashfor@linux.vnet.ibm.com>
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Frederic Weisbecker <fweisbec@gmail.com>
      Cc: Ingo Molnar <mingo@elte.hu>
      Cc: Namhyung Kim <namhyung@kernel.org>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Peter Zijlstra <a.p.zijlstra@chello.nl>
      Cc: Steven Rostedt <rostedt@goodmis.org>
      Link: http://lkml.kernel.org/r/1386076182-14484-2-git-send-email-jolsa@redhat.comSigned-off-by: NArnaldo Carvalho de Melo <acme@redhat.com>
      e6d7cee1
  15. 03 12月, 2013 1 次提交
  16. 02 12月, 2013 1 次提交
  17. 15 11月, 2013 1 次提交
    • I
      tools/perf/build: Fix feature-libunwind-debug-frame handling · e310718d
      Ingo Molnar 提交于
      Set feature-libunwind-debug-frame. We don't want it in
      CORE_FEATURE_TESTS because it's not the generic case, but we
      need to set it in the !feature-libunwind case.
      
      Also, because x86 distributions typically don't have
      dwarf_find_debug_frame() unwinding method:
      
        test-libunwind-debug-frame.c:(.text+0x31): undefined reference to `_Ux86_64_dwarf_find_debug_frame'
      
      Restrict this new API to ARM for the time being.
      
      With this patch test-all.c works again, so repeat perf builds
      are  fast again:
      
        comet:~/tip> perf stat --null --repeat 5 make -C tools/perf/
        [...]
      
             0,452899660 seconds time elapsed                                          ( +-  0,11% )
      
      While with before it was:
      
        comet:~/tip> perf stat --null --repeat 5 make -C tools/perf/
        [...]
      
             1,674001829 seconds time elapsed                                          ( +-  0,16% )
      
      [ Includes fix to config/feature-checks/Makefile from Will Deacon. ]
      Tested-by: NWill Deacon <will.deacon@arm.com>
      Tested-by: NJean Pihet <jean.pihet@linaro.org>
      Cc: Russell King <rmk@arm.linux.org.uk>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Cc: Arnaldo Carvalho de Melo <acme@infradead.org>
      Cc: Jiri Olsa <jolsa@redhat.com>
      Link: http://lkml.kernel.org/n/tip-scsoctqzmou3rpkixCHezy9e@git.kernel.orgSigned-off-by: NIngo Molnar <mingo@kernel.org>
      e310718d
  18. 14 11月, 2013 1 次提交
    • I
      tools/perf/build: Fix timerfd feature check · bb4c5500
      Ingo Molnar 提交于
      'feature_timerfd' is checked all the time and calculated explicitly,
      in a serial fashion. Add it to CORE_FEATURE_TESTS which causes it to
      be built in parallel, using the newfangled parallel build autodetection
      code.
      
      This shaves 137 msecs off the perf build time on my system, which
      speeds up the common case cached build by 43%:
      
      Before:
      
        comet:~/tip> perf stat --null --repeat 5 make -C tools/perf/
        [...]
               0,453771441 seconds time elapsed                                          ( +-  0,09% )
      
      After:
      
        comet:~/tip> perf stat --null --repeat 5 make -C tools/perf/
        [...]
               0,316290185 seconds time elapsed                                          ( +-  0,24% )
      
      Cc: David Ahern <dsahern@gmail.com>
      Cc: Arnaldo Carvalho de Melo <acme@redhat.com>
      Cc: Linus Torvalds <torvalds@linux-foundation.org>
      Link: http://lkml.kernel.org/n/tip-bb92CmexihopoSyqnkqepvsy@git.kernel.orgSigned-off-by: NIngo Molnar <mingo@kernel.org>
      bb4c5500
  19. 05 11月, 2013 2 次提交
  20. 04 11月, 2013 2 次提交
  21. 23 10月, 2013 1 次提交
  22. 21 10月, 2013 1 次提交
  23. 14 10月, 2013 6 次提交